mirror of
https://github.com/Mastermindzh/react-cookie-consent.git
synced 2025-04-25 16:23:31 +02:00
adding some pretty badges :)
This commit is contained in:
parent
d502d28739
commit
8561858333
11
README.md
11
README.md
@ -8,6 +8,8 @@ Demo: https://mastermindzh.github.io/react-cookie-consent/
|
|||||||
|
|
||||||
Example branch: https://github.com/Mastermindzh/react-cookie-consent/tree/example
|
Example branch: https://github.com/Mastermindzh/react-cookie-consent/tree/example
|
||||||
|
|
||||||
|
     
|
||||||
|
|
||||||
## Default look
|
## Default look
|
||||||
|
|
||||||

|

|
||||||
@ -112,7 +114,7 @@ If the decline button is enabled then the (onDecline) prop function can be used,
|
|||||||
## Props
|
## Props
|
||||||
|
|
||||||
| Prop | Type | Default value | Description |
|
| Prop | Type | Default value | Description |
|
||||||
| ------------------------ | :-------------------------------: | --------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------ | :-------------------------------: | ------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| location | string, "top", "bottom" or "none" | "bottom" | Syntactic sugar to easily enable you to place the bar at the top or the bottom of the browser window. Use "none" to disable. |
|
| location | string, "top", "bottom" or "none" | "bottom" | Syntactic sugar to easily enable you to place the bar at the top or the bottom of the browser window. Use "none" to disable. |
|
||||||
| children | string or React component | | Content to appear inside the bar |
|
| children | string or React component | | Content to appear inside the bar |
|
||||||
| disableStyles | boolean | false | If enabled the component will have no default style. (you can still supply style through props) |
|
| disableStyles | boolean | false | If enabled the component will have no default style. (you can still supply style through props) |
|
||||||
@ -278,12 +280,7 @@ If you're crazy enough you can even make a rainbow colored bar:
|
|||||||
You can also generate a page-obfuscating overlay that will prevent actions other than interacting with the cookie consent button(s).
|
You can also generate a page-obfuscating overlay that will prevent actions other than interacting with the cookie consent button(s).
|
||||||
|
|
||||||
```js
|
```js
|
||||||
<CookieConsent
|
<CookieConsent location="bottom" cookieName="myAwesomeCookieName3" expires={999} overlay>
|
||||||
location="bottom"
|
|
||||||
cookieName="myAwesomeCookieName3"
|
|
||||||
expires={999}
|
|
||||||
overlay
|
|
||||||
>
|
|
||||||
This website uses cookies to enhance the user experience.
|
This website uses cookies to enhance the user experience.
|
||||||
</CookieConsent>
|
</CookieConsent>
|
||||||
```
|
```
|
||||||
|
Loading…
x
Reference in New Issue
Block a user