payload 0.12.11-beta.0 → 0.13.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -66
- package/components/forms.ts +2 -1
- package/components/index.js +2 -2
- package/dist/admin/components/elements/PreviewButton/index.js +19 -4
- package/dist/admin/components/elements/SearchFilter/index.js +6 -3
- package/dist/admin/components/elements/WhereBuilder/Condition/Relationship/types.d.ts +1 -1
- package/dist/admin/components/forms/DraggableSection/SectionTitle/index.js +2 -2
- package/dist/admin/components/forms/field-types/Array/Array.js +2 -2
- package/dist/admin/components/forms/field-types/Blocks/Blocks.js +2 -2
- package/dist/admin/components/forms/field-types/Checkbox/index.js +2 -2
- package/dist/admin/components/forms/field-types/Code/Code.js +2 -2
- package/dist/admin/components/forms/field-types/ConfirmPassword/index.js +2 -2
- package/dist/admin/components/forms/field-types/DateTime/index.js +2 -2
- package/dist/admin/components/forms/field-types/Email/index.js +2 -2
- package/dist/admin/components/forms/field-types/HiddenInput/index.js +2 -2
- package/dist/admin/components/forms/field-types/Number/index.js +2 -2
- package/dist/admin/components/forms/field-types/Password/index.js +2 -2
- package/dist/admin/components/forms/field-types/Point/index.js +2 -2
- package/dist/admin/components/forms/field-types/RadioGroup/index.js +2 -2
- package/dist/admin/components/forms/field-types/Relationship/index.js +2 -2
- package/dist/admin/components/forms/field-types/Relationship/types.d.ts +1 -1
- package/dist/admin/components/forms/field-types/RichText/RichText.js +2 -2
- package/dist/admin/components/forms/field-types/Select/index.js +32 -16
- package/dist/admin/components/forms/field-types/Text/index.js +19 -6
- package/dist/admin/components/forms/field-types/Textarea/index.js +2 -2
- package/dist/admin/components/forms/field-types/Upload/index.js +21 -8
- package/dist/admin/components/forms/useField/index.d.ts +3 -0
- package/dist/admin/components/forms/{useFieldType → useField}/index.js +30 -9
- package/dist/admin/components/forms/{useFieldType → useField}/types.d.ts +0 -0
- package/dist/admin/components/forms/{useFieldType → useField}/types.js +0 -0
- package/dist/admin/components/views/collections/Edit/Auth/APIKey.js +2 -2
- package/dist/admin/components/views/collections/Edit/Upload/index.js +2 -2
- package/dist/admin/components/views/collections/List/types.d.ts +1 -1
- package/dist/auth/getExecuteStaticAccess.d.ts +1 -1
- package/dist/auth/getExecuteStaticAccess.js +20 -4
- package/dist/bin/generateTypes.js +20 -9
- package/dist/collections/config/types.d.ts +102 -39
- package/dist/collections/operations/create.d.ts +1 -0
- package/dist/collections/operations/create.js +12 -4
- package/dist/collections/operations/delete.js +5 -5
- package/dist/collections/operations/find.d.ts +2 -2
- package/dist/collections/operations/find.js +17 -8
- package/dist/collections/operations/findByID.d.ts +2 -3
- package/dist/collections/operations/findByID.js +1 -1
- package/dist/collections/operations/local/create.d.ts +1 -0
- package/dist/collections/operations/local/create.js +3 -2
- package/dist/collections/operations/local/delete.d.ts +2 -1
- package/dist/collections/operations/local/delete.js +1 -1
- package/dist/collections/operations/local/find.d.ts +2 -2
- package/dist/collections/operations/local/find.js +1 -1
- package/dist/collections/operations/local/findByID.d.ts +2 -1
- package/dist/collections/operations/local/findByID.js +1 -1
- package/dist/collections/operations/local/update.d.ts +2 -1
- package/dist/collections/operations/local/update.js +1 -1
- package/dist/collections/operations/update.js +11 -3
- package/dist/collections/requestHandlers/find.d.ts +2 -2
- package/dist/collections/requestHandlers/find.js +1 -1
- package/dist/config/types.d.ts +4 -1
- package/dist/express/static.js +2 -2
- package/dist/fields/baseFields/getBaseUploadFields.js +3 -1
- package/dist/fields/config/types.d.ts +20 -15
- package/dist/fields/config/types.js +1 -1
- package/dist/fields/validations.d.ts +17 -17
- package/dist/index.d.ts +8 -9
- package/dist/index.js +1 -1
- package/dist/mongoose/buildQuery.js +14 -11
- package/dist/mongoose/buildSchema.js +6 -1
- package/dist/mongoose/sanitizeFormattedValue.js +2 -2
- package/dist/uploads/fileExists.d.ts +2 -2
- package/dist/uploads/fileExists.js +4 -3
- package/dist/uploads/fileOrDocExists.d.ts +3 -0
- package/dist/uploads/fileOrDocExists.js +22 -0
- package/dist/uploads/getSafeFilename.d.ts +2 -1
- package/dist/uploads/getSafeFilename.js +4 -4
- package/dist/uploads/imageResizer.d.ts +11 -1
- package/dist/uploads/imageResizer.js +2 -2
- package/dist/utilities/sanitizeInternalFields.d.ts +2 -1
- package/dist/utilities/sanitizeInternalFields.js +1 -1
- package/docs/admin/components.mdx +3 -3
- package/docs/fields/blocks.mdx +9 -0
- package/docs/fields/overview.mdx +12 -0
- package/docs/fields/rich-text.mdx +11 -0
- package/docs/hooks/collections.mdx +23 -0
- package/docs/hooks/fields.mdx +28 -0
- package/docs/hooks/globals.mdx +17 -0
- package/docs/typescript/generating-types.mdx +114 -0
- package/docs/typescript/overview.mdx +36 -0
- package/package.json +1 -1
- package/types.d.ts +18 -2
- package/dist/admin/components/forms/useFieldType/index.d.ts +0 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,91 +1,43 @@
|
|
|
1
|
-
## [0.
|
|
1
|
+
## [0.13.1](https://github.com/payloadcms/payload/compare/v0.13.0...v0.13.1) (2021-11-29)
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
### Bug Fixes
|
|
5
5
|
|
|
6
|
-
*
|
|
7
|
-
* bug with relationship cell when no doc is available ([40b33d9](https://github.com/payloadcms/payload/commit/40b33d9f5e99285cb0de148dbe059259817fcad8))
|
|
8
|
-
* ensures 'like' query param remains functional in all cases ([20d4e72](https://github.com/payloadcms/payload/commit/20d4e72a951dfcbf1cc301d0938e5095932436b9))
|
|
9
|
-
* ensures buildQuery works with fields as well as simultaneous or / and ([72fc413](https://github.com/payloadcms/payload/commit/72fc413764c6c42ba64a45f01d99b68ad3bd46c4))
|
|
10
|
-
* ensures relationship field search can return more than 10 options ([57c0346](https://github.com/payloadcms/payload/commit/57c0346a00286a3df695ea46e5c2630494183b5b))
|
|
11
|
-
* ensures richtext links retain proper formatting ([abf61d0](https://github.com/payloadcms/payload/commit/abf61d0734c09fd0fc5c5b827cb0631e11701f71))
|
|
12
|
-
* ensures tquerying by relationship subpaths works ([37b21b0](https://github.com/payloadcms/payload/commit/37b21b07628e892e85c2cf979d9e2c8af0d291f7))
|
|
13
|
-
* issue with querying by id and using comma-separated values ([d9e1b5e](https://github.com/payloadcms/payload/commit/d9e1b5ede33616893f9ba6990eeccf5410b75ae1))
|
|
14
|
-
* updates field description type to include react nodes ([291c193](https://github.com/payloadcms/payload/commit/291c193ad4a9ec8ce9310cc63c714eba10eca102))
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
### Features
|
|
18
|
-
|
|
19
|
-
* adds field types to type generation ([6dd1b0e](https://github.com/payloadcms/payload/commit/6dd1b0e0339490bf9e500f03f47ed59381644d85))
|
|
20
|
-
* adds relationship filter field ([463c4e6](https://github.com/payloadcms/payload/commit/463c4e60de8e647fca6268b826d826f9c6e45412))
|
|
21
|
-
* baseline type generation ([5a965d2](https://github.com/payloadcms/payload/commit/5a965d2263d1b246149c5220d039a6d97953d5e8))
|
|
22
|
-
* ensures update hooks have access to full original docs even in spite of access control ([b2c5b7e](https://github.com/payloadcms/payload/commit/b2c5b7e5752e829c7a53c054decceb43ec33065e))
|
|
23
|
-
* finishes typing all fields ([ed5a5eb](https://github.com/payloadcms/payload/commit/ed5a5ebe7e16d20577556ab233032a52bef6d2cb))
|
|
24
|
-
* generates further field types ([2ca76ba](https://github.com/payloadcms/payload/commit/2ca76ba8ce6c61ee7b0a01a557b6f013ca483d6d))
|
|
25
|
-
* improves querying logic ([4c85747](https://github.com/payloadcms/payload/commit/4c8574784995b1cb1f939648f4d2158286089b3d))
|
|
26
|
-
|
|
27
|
-
## [0.12.10-beta.0](https://github.com/payloadcms/payload/compare/v0.12.3...v0.12.10-beta.0) (2021-11-17)
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
### Bug Fixes
|
|
31
|
-
|
|
32
|
-
* [#351](https://github.com/payloadcms/payload/issues/351) ([94c2b8d](https://github.com/payloadcms/payload/commit/94c2b8d80b046c067057d4ad089ed6a2edd656cf))
|
|
33
|
-
* bug with relationship cell when no doc is available ([40b33d9](https://github.com/payloadcms/payload/commit/40b33d9f5e99285cb0de148dbe059259817fcad8))
|
|
34
|
-
* ensures 'like' query param remains functional in all cases ([20d4e72](https://github.com/payloadcms/payload/commit/20d4e72a951dfcbf1cc301d0938e5095932436b9))
|
|
35
|
-
* ensures buildQuery works with fields as well as simultaneous or / and ([72fc413](https://github.com/payloadcms/payload/commit/72fc413764c6c42ba64a45f01d99b68ad3bd46c4))
|
|
36
|
-
* ensures relationship field search can return more than 10 options ([57c0346](https://github.com/payloadcms/payload/commit/57c0346a00286a3df695ea46e5c2630494183b5b))
|
|
37
|
-
* ensures richtext links retain proper formatting ([abf61d0](https://github.com/payloadcms/payload/commit/abf61d0734c09fd0fc5c5b827cb0631e11701f71))
|
|
38
|
-
* ensures tquerying by relationship subpaths works ([37b21b0](https://github.com/payloadcms/payload/commit/37b21b07628e892e85c2cf979d9e2c8af0d291f7))
|
|
6
|
+
* ensures sorting by _id instead of improper id ([ded891e](https://github.com/payloadcms/payload/commit/ded891e390a93f71963762c0200c97a0beec5cad))
|
|
39
7
|
|
|
40
8
|
|
|
41
9
|
### Features
|
|
42
10
|
|
|
43
|
-
* adds
|
|
44
|
-
* adds relationship filter field ([463c4e6](https://github.com/payloadcms/payload/commit/463c4e60de8e647fca6268b826d826f9c6e45412))
|
|
45
|
-
* baseline type generation ([5a965d2](https://github.com/payloadcms/payload/commit/5a965d2263d1b246149c5220d039a6d97953d5e8))
|
|
46
|
-
* ensures update hooks have access to full original docs even in spite of access control ([b2c5b7e](https://github.com/payloadcms/payload/commit/b2c5b7e5752e829c7a53c054decceb43ec33065e))
|
|
47
|
-
* finishes typing all fields ([ed5a5eb](https://github.com/payloadcms/payload/commit/ed5a5ebe7e16d20577556ab233032a52bef6d2cb))
|
|
48
|
-
* generates further field types ([2ca76ba](https://github.com/payloadcms/payload/commit/2ca76ba8ce6c61ee7b0a01a557b6f013ca483d6d))
|
|
49
|
-
* improves querying logic ([4c85747](https://github.com/payloadcms/payload/commit/4c8574784995b1cb1f939648f4d2158286089b3d))
|
|
11
|
+
* only adds list search query param if value is present ([d6d76d4](https://github.com/payloadcms/payload/commit/d6d76d4088a23ed43122333873ada6846c808d37))
|
|
50
12
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
### Bug Fixes
|
|
55
|
-
|
|
56
|
-
* [#351](https://github.com/payloadcms/payload/issues/351) ([94c2b8d](https://github.com/payloadcms/payload/commit/94c2b8d80b046c067057d4ad089ed6a2edd656cf))
|
|
57
|
-
* bug with relationship cell when no doc is available ([40b33d9](https://github.com/payloadcms/payload/commit/40b33d9f5e99285cb0de148dbe059259817fcad8))
|
|
58
|
-
* ensures 'like' query param remains functional in all cases ([20d4e72](https://github.com/payloadcms/payload/commit/20d4e72a951dfcbf1cc301d0938e5095932436b9))
|
|
59
|
-
* ensures buildQuery works with fields as well as simultaneous or / and ([72fc413](https://github.com/payloadcms/payload/commit/72fc413764c6c42ba64a45f01d99b68ad3bd46c4))
|
|
60
|
-
* ensures relationship field search can return more than 10 options ([57c0346](https://github.com/payloadcms/payload/commit/57c0346a00286a3df695ea46e5c2630494183b5b))
|
|
61
|
-
* ensures richtext links retain proper formatting ([abf61d0](https://github.com/payloadcms/payload/commit/abf61d0734c09fd0fc5c5b827cb0631e11701f71))
|
|
62
|
-
* ensures tquerying by relationship subpaths works ([37b21b0](https://github.com/payloadcms/payload/commit/37b21b07628e892e85c2cf979d9e2c8af0d291f7))
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
### Features
|
|
66
|
-
|
|
67
|
-
* adds field types to type generation ([6dd1b0e](https://github.com/payloadcms/payload/commit/6dd1b0e0339490bf9e500f03f47ed59381644d85))
|
|
68
|
-
* adds relationship filter field ([463c4e6](https://github.com/payloadcms/payload/commit/463c4e60de8e647fca6268b826d826f9c6e45412))
|
|
69
|
-
* baseline type generation ([5a965d2](https://github.com/payloadcms/payload/commit/5a965d2263d1b246149c5220d039a6d97953d5e8))
|
|
70
|
-
* ensures update hooks have access to full original docs even in spite of access control ([b2c5b7e](https://github.com/payloadcms/payload/commit/b2c5b7e5752e829c7a53c054decceb43ec33065e))
|
|
71
|
-
* finishes typing all fields ([ed5a5eb](https://github.com/payloadcms/payload/commit/ed5a5ebe7e16d20577556ab233032a52bef6d2cb))
|
|
72
|
-
* generates further field types ([2ca76ba](https://github.com/payloadcms/payload/commit/2ca76ba8ce6c61ee7b0a01a557b6f013ca483d6d))
|
|
73
|
-
* improves querying logic ([4c85747](https://github.com/payloadcms/payload/commit/4c8574784995b1cb1f939648f4d2158286089b3d))
|
|
74
|
-
|
|
75
|
-
## [0.12.8-beta.0](https://github.com/payloadcms/payload/compare/v0.12.3...v0.12.8-beta.0) (2021-11-10)
|
|
13
|
+
# [0.13.0](https://github.com/payloadcms/payload/compare/v0.12.3...v0.13.0) (2021-11-26)
|
|
76
14
|
|
|
77
15
|
|
|
78
16
|
### Bug Fixes
|
|
79
17
|
|
|
80
18
|
* [#351](https://github.com/payloadcms/payload/issues/351) ([94c2b8d](https://github.com/payloadcms/payload/commit/94c2b8d80b046c067057d4ad089ed6a2edd656cf))
|
|
19
|
+
* [#358](https://github.com/payloadcms/payload/issues/358) - reuploading with existing filenames ([a0fb48c](https://github.com/payloadcms/payload/commit/a0fb48c9a37beceafc6f0638604e9946d0814635))
|
|
20
|
+
* allows sync or async preview urls ([da6e1df](https://github.com/payloadcms/payload/commit/da6e1df293ce46bc4d0c84645db61feea2881aa7))
|
|
81
21
|
* bug with relationship cell when no doc is available ([40b33d9](https://github.com/payloadcms/payload/commit/40b33d9f5e99285cb0de148dbe059259817fcad8))
|
|
22
|
+
3839ef75151f))
|
|
82
23
|
* ensures richtext links retain proper formatting ([abf61d0](https://github.com/payloadcms/payload/commit/abf61d0734c09fd0fc5c5b827cb0631e11701f71))
|
|
24
|
+
* ensures that querying by relationship subpaths works ([37b21b0](https://github.com/payloadcms/payload/commit/37b21b07628e892e85c2cf979d9e2c8af0d291f7))
|
|
25
|
+
* ensures uploads can be fetched with CORS ([96421b3](https://github.com/payloadcms/payload/commit/96421b3d59a87f8a3d781005c02344fe5d3a607f))
|
|
26
|
+
* typing for collection description ([bb18e82](https://github.com/payloadcms/payload/commit/bb18e8250c5742d9615e5780c1cd02d33ecca3d0))
|
|
27
|
+
* updates field description type to include react nodes ([291c193](https://github.com/payloadcms/payload/commit/291c193ad4a9ec8ce9310cc63c714eba10eca102))
|
|
83
28
|
|
|
84
29
|
### Features
|
|
85
30
|
|
|
31
|
+
* :tada: :tada: builds a way to automatically generate types for collections and globals!.
|
|
32
|
+
* :tada: dramatically improves Payload types like local API methods and hooks to function as `generic`s
|
|
86
33
|
* adds relationship filter field ([463c4e6](https://github.com/payloadcms/payload/commit/463c4e60de8e647fca6268b826d826f9c6e45412))
|
|
34
|
+
* applies upload access control to all auto-generated image sizes ([051b7d4](https://github.com/payloadcms/payload/commit/051b7d45befc331af3f73a669b2bb6467505902f))
|
|
35
|
+
* azure cosmos compatibility ([6fd5ac2](https://github.com/payloadcms/payload/commit/6fd5ac2c082a5a5e6f510d781b2a2e12b7b62cb9))
|
|
87
36
|
* ensures update hooks have access to full original docs even in spite of access control ([b2c5b7e](https://github.com/payloadcms/payload/commit/b2c5b7e5752e829c7a53c054decceb43ec33065e))
|
|
88
37
|
* improves querying logic ([4c85747](https://github.com/payloadcms/payload/commit/4c8574784995b1cb1f939648f4d2158286089b3d))
|
|
38
|
+
* indexes filenames ([5d43262](https://github.com/payloadcms/payload/commit/5d43262f42e0529a44572f398aa1ec5fd7858286))
|
|
39
|
+
* renames useFieldType to useField ([0245747](https://github.com/payloadcms/payload/commit/0245747020c7c039b15d055f54a4548a364d047e))
|
|
40
|
+
* supports custom onChange handling in text, select, and upload fields ([4affdc3](https://github.com/payloadcms/payload/commit/4affdc3a9397d70f5baacdd12753c8fc8c7d8368))
|
|
89
41
|
|
|
90
42
|
## [0.12.3](https://github.com/payloadcms/payload/compare/v0.12.2...v0.12.3) (2021-10-23)
|
|
91
43
|
|
package/components/forms.ts
CHANGED
|
@@ -6,7 +6,8 @@ export {
|
|
|
6
6
|
useFormModified,
|
|
7
7
|
} from '../dist/admin/components/forms/Form/context';
|
|
8
8
|
|
|
9
|
-
export { default as
|
|
9
|
+
export { default as useField } from '../dist/admin/components/forms/useField';
|
|
10
|
+
export { default as useFieldType } from '../dist/admin/components/forms/useField';
|
|
10
11
|
|
|
11
12
|
export { default as Form } from '../dist/admin/components/forms/Form';
|
|
12
13
|
|
package/components/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(()=>{var e={720:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(206));t.default=function(e){var t=e.children,n=o.default();return t?"function"==typeof t?t(n):t:null}},761:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(497).createContext({});t.default=r},788:function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)},a=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),c=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),u=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&a(t,e,n);return c(t,e),t},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var l=u(n(497)),f=s(n(761)),d=function(e){function t(t){var n=e.call(this,t)||this;return n.requestAnimation=function(e){n.state.animationScheduled||n.setState({animationScheduled:!0},(function(){return requestAnimationFrame((function(t){return n.updateScrollInfo(e,t)}))}))},n.updateScrollInfo=function(e,t){var r=n.state,o=r.x,i=r.y,a=r.xDirection,c=r.yDirection,u=r.eventsFired,s=r.hasScrolled||Boolean(t),l=s?window.pageXOffset:0,f=s?window.pageYOffset:0,d=s?u+1:u,p=l-o,h=f-i,v=l/(document.body.scrollWidth-window.innerWidth)*100,m=f/(document.body.scrollHeight-window.innerHeight)*100,y=(v+m)/2,g=p>0?"right":p<0?"left":a,w=h>0?"down":h<0?"up":c;n.setState({x:l,y:f,xDifference:p,yDifference:h,xDirection:g,yDirection:w,xPercentage:v,yPercentage:m,totalPercentage:y,eventsFired:d,hasScrolled:s,animationScheduled:!1})},n.state={x:0,y:0,xDifference:0,yDifference:0,xDirection:void 0,yDirection:void 0,xPercentage:0,yPercentage:0,totalPercentage:0,eventsFired:0,hasScrolled:!1,animationScheduled:!1},n}return o(t,e),t.prototype.componentDidMount=function(){window.addEventListener("scroll",this.requestAnimation),this.updateScrollInfo()},t.prototype.componentWillUnmount=function(){window.removeEventListener("scroll",this.requestAnimation)},t.prototype.render=function(){var e=this.props.children,t=i({},this.state);return delete t.hasScrolled,delete t.animationScheduled,l.default.createElement(f.default.Provider,{value:i({},t)},e&&e)},t}(l.Component);t.default=d},719:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.withScrollInfo=t.useScrollInfo=t.ScrollInfoProvider=t.ScrollInfoContext=t.ScrollInfo=void 0;var o=n(720);Object.defineProperty(t,"ScrollInfo",{enumerable:!0,get:function(){return r(o).default}});var i=n(761);Object.defineProperty(t,"ScrollInfoContext",{enumerable:!0,get:function(){return r(i).default}});var a=n(788);Object.defineProperty(t,"ScrollInfoProvider",{enumerable:!0,get:function(){return r(a).default}});var c=n(206);Object.defineProperty(t,"useScrollInfo",{enumerable:!0,get:function(){return r(c).default}});var u=n(576);Object.defineProperty(t,"withScrollInfo",{enumerable:!0,get:function(){return r(u).default}})},206:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(497),i=r(n(761));t.default=function(){return o.useContext(i.default)}},576:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},r.apply(this,arguments)},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=o(n(497)),a=n(719);t.default=function(e){return function(t){var n=a.useScrollInfo();return i.default.createElement(e,r({},r(r({},t),{scrollInfo:n})))}}},698:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(796));t.default=function(e){var t=e.children,n=o.default();return t?"function"==typeof t?t(n):t:null}},181:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(497).createContext({});t.default=r},71:function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)},a=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),c=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),u=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&a(t,e,n);return c(t,e),t},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var l=u(n(497)),f=s(n(181)),d=function(e){function t(t){var n=e.call(this,t)||this;return n.updateWindowInfoWithTimeout=function(){setTimeout((function(){n.requestAnimation()}),500)},n.requestAnimation=function(){n.state.animationScheduled||n.setState({animationScheduled:!0},(function(){return requestAnimationFrame(n.updateWindowInfo)}))},n.updateWindowInfo=function(){var e=n.props.breakpoints,t=void 0===e?{}:e,r=t.xs,o=t.s,i=t.m,a=t.l,c=t.xl,u=n.state.eventsFired,s=document.documentElement,l=s.style,f=s.clientWidth,d=s.clientHeight,p=window.innerWidth,h=window.innerHeight,v=f/100+"px",m=d/100+"px";n.setState({width:p,height:h,"--vw":v,"--vh":m,breakpoints:{xs:window.matchMedia("(max-width: "+r+"px)").matches,s:window.matchMedia("(max-width: "+o+"px)").matches,m:window.matchMedia("(max-width: "+i+"px)").matches,l:window.matchMedia("(max-width: "+a+"px)").matches,xl:window.matchMedia("(max-width: "+c+"px)").matches},eventsFired:u+1,animationScheduled:!1}),l.setProperty("--vw",v),l.setProperty("--vh",m)},n.state={width:0,height:0,"--vw":"0px","--vh":"0px",breakpoints:{xs:!1,s:!1,m:!1,l:!1,xl:!1},eventsFired:0,animationScheduled:!1},n}return o(t,e),t.prototype.componentDidMount=function(){window.addEventListener("resize",this.requestAnimation),window.addEventListener("orientationchange",this.updateWindowInfoWithTimeout),this.updateWindowInfo()},t.prototype.componentWillUnmount=function(){window.removeEventListener("resize",this.requestAnimation),window.removeEventListener("orientationchange",this.updateWindowInfoWithTimeout)},t.prototype.render=function(){var e=this.props.children,t=i({},this.state);return delete t.animationScheduled,l.default.createElement(f.default.Provider,{value:i({},t)},e&&e)},t}(l.Component);t.default=d},727:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.withWindowInfo=t.WindowInfoProvider=t.WindowInfoContext=t.WindowInfo=t.useWindowInfo=void 0;var o=n(796);Object.defineProperty(t,"useWindowInfo",{enumerable:!0,get:function(){return r(o).default}});var i=n(698);Object.defineProperty(t,"WindowInfo",{enumerable:!0,get:function(){return r(i).default}});var a=n(181);Object.defineProperty(t,"WindowInfoContext",{enumerable:!0,get:function(){return r(a).default}});var c=n(71);Object.defineProperty(t,"WindowInfoProvider",{enumerable:!0,get:function(){return r(c).default}});var u=n(917);Object.defineProperty(t,"withWindowInfo",{enumerable:!0,get:function(){return r(u).default}})},796:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(497),i=r(n(181));t.default=function(){return o.useContext(i.default)}},917:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},r.apply(this,arguments)},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=o(n(497)),a=o(n(796));t.default=function(e){return function(t){var n=a.default();return i.default.createElement(e,r({},r(r({},t),{windowInfo:n})))}}},679:(e,t,n)=>{"use strict";var r=n(864),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},c={};function u(e){return r.isMemo(e)?a:c[e.$$typeof]||o}c[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},c[r.Memo]=a;var s=Object.defineProperty,l=Object.getOwnPropertyNames,f=Object.getOwnPropertySymbols,d=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(h){var o=p(n);o&&o!==h&&e(t,o,r)}var a=l(n);f&&(a=a.concat(f(n)));for(var c=u(t),v=u(n),m=0;m<a.length;++m){var y=a[m];if(!(i[y]||r&&r[y]||v&&v[y]||c&&c[y])){var g=d(n,y);try{s(t,y,g)}catch(e){}}}}return t}},826:e=>{e.exports=Array.isArray||function(e){return"[object Array]"==Object.prototype.toString.call(e)}},703:(e,t,n)=>{"use strict";var r=n(414);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},697:(e,t,n)=>{e.exports=n(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},921:(e,t)=>{"use strict";
|
|
1
|
+
(()=>{var e={720:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(206));t.default=function(e){var t=e.children,n=o.default();return t?"function"==typeof t?t(n):t:null}},761:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(497).createContext({});t.default=r},788:function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)},a=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),c=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),u=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&a(t,e,n);return c(t,e),t},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var l=u(n(497)),f=s(n(761)),d=function(e){function t(t){var n=e.call(this,t)||this;return n.requestAnimation=function(e){n.state.animationScheduled||n.setState({animationScheduled:!0},(function(){return requestAnimationFrame((function(t){return n.updateScrollInfo(e,t)}))}))},n.updateScrollInfo=function(e,t){var r=n.state,o=r.x,i=r.y,a=r.xDirection,c=r.yDirection,u=r.eventsFired,s=r.hasScrolled||Boolean(t),l=s?window.pageXOffset:0,f=s?window.pageYOffset:0,d=s?u+1:u,p=l-o,h=f-i,v=l/(document.body.scrollWidth-window.innerWidth)*100,m=f/(document.body.scrollHeight-window.innerHeight)*100,y=(v+m)/2,g=p>0?"right":p<0?"left":a,w=h>0?"down":h<0?"up":c;n.setState({x:l,y:f,xDifference:p,yDifference:h,xDirection:g,yDirection:w,xPercentage:v,yPercentage:m,totalPercentage:y,eventsFired:d,hasScrolled:s,animationScheduled:!1})},n.state={x:0,y:0,xDifference:0,yDifference:0,xDirection:void 0,yDirection:void 0,xPercentage:0,yPercentage:0,totalPercentage:0,eventsFired:0,hasScrolled:!1,animationScheduled:!1},n}return o(t,e),t.prototype.componentDidMount=function(){window.addEventListener("scroll",this.requestAnimation),this.updateScrollInfo()},t.prototype.componentWillUnmount=function(){window.removeEventListener("scroll",this.requestAnimation)},t.prototype.render=function(){var e=this.props.children,t=i({},this.state);return delete t.hasScrolled,delete t.animationScheduled,l.default.createElement(f.default.Provider,{value:i({},t)},e&&e)},t}(l.Component);t.default=d},719:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.withScrollInfo=t.useScrollInfo=t.ScrollInfoProvider=t.ScrollInfoContext=t.ScrollInfo=void 0;var o=n(720);Object.defineProperty(t,"ScrollInfo",{enumerable:!0,get:function(){return r(o).default}});var i=n(761);Object.defineProperty(t,"ScrollInfoContext",{enumerable:!0,get:function(){return r(i).default}});var a=n(788);Object.defineProperty(t,"ScrollInfoProvider",{enumerable:!0,get:function(){return r(a).default}});var c=n(206);Object.defineProperty(t,"useScrollInfo",{enumerable:!0,get:function(){return r(c).default}});var u=n(576);Object.defineProperty(t,"withScrollInfo",{enumerable:!0,get:function(){return r(u).default}})},206:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(497),i=r(n(761));t.default=function(){return o.useContext(i.default)}},576:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},r.apply(this,arguments)},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=o(n(497)),a=n(719);t.default=function(e){return function(t){var n=a.useScrollInfo();return i.default.createElement(e,r({},r(r({},t),{scrollInfo:n})))}}},698:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(796));t.default=function(e){var t=e.children,n=o.default();return t?"function"==typeof t?t(n):t:null}},181:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(497).createContext({});t.default=r},71:function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)},a=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),c=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),u=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&a(t,e,n);return c(t,e),t},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var l=u(n(497)),f=s(n(181)),d=function(e){function t(t){var n=e.call(this,t)||this;return n.updateWindowInfoWithTimeout=function(){setTimeout((function(){n.requestAnimation()}),500)},n.requestAnimation=function(){n.state.animationScheduled||n.setState({animationScheduled:!0},(function(){return requestAnimationFrame(n.updateWindowInfo)}))},n.updateWindowInfo=function(){var e=n.props.breakpoints,t=void 0===e?{}:e,r=t.xs,o=t.s,i=t.m,a=t.l,c=t.xl,u=n.state.eventsFired,s=document.documentElement,l=s.style,f=s.clientWidth,d=s.clientHeight,p=window.innerWidth,h=window.innerHeight,v=f/100+"px",m=d/100+"px";n.setState({width:p,height:h,"--vw":v,"--vh":m,breakpoints:{xs:window.matchMedia("(max-width: "+r+"px)").matches,s:window.matchMedia("(max-width: "+o+"px)").matches,m:window.matchMedia("(max-width: "+i+"px)").matches,l:window.matchMedia("(max-width: "+a+"px)").matches,xl:window.matchMedia("(max-width: "+c+"px)").matches},eventsFired:u+1,animationScheduled:!1}),l.setProperty("--vw",v),l.setProperty("--vh",m)},n.state={width:0,height:0,"--vw":"0px","--vh":"0px",breakpoints:{xs:!1,s:!1,m:!1,l:!1,xl:!1},eventsFired:0,animationScheduled:!1},n}return o(t,e),t.prototype.componentDidMount=function(){window.addEventListener("resize",this.requestAnimation),window.addEventListener("orientationchange",this.updateWindowInfoWithTimeout),this.updateWindowInfo()},t.prototype.componentWillUnmount=function(){window.removeEventListener("resize",this.requestAnimation),window.removeEventListener("orientationchange",this.updateWindowInfoWithTimeout)},t.prototype.render=function(){var e=this.props.children,t=i({},this.state);return delete t.animationScheduled,l.default.createElement(f.default.Provider,{value:i({},t)},e&&e)},t}(l.Component);t.default=d},727:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.withWindowInfo=t.WindowInfoProvider=t.WindowInfoContext=t.WindowInfo=t.useWindowInfo=void 0;var o=n(796);Object.defineProperty(t,"useWindowInfo",{enumerable:!0,get:function(){return r(o).default}});var i=n(698);Object.defineProperty(t,"WindowInfo",{enumerable:!0,get:function(){return r(i).default}});var a=n(181);Object.defineProperty(t,"WindowInfoContext",{enumerable:!0,get:function(){return r(a).default}});var c=n(71);Object.defineProperty(t,"WindowInfoProvider",{enumerable:!0,get:function(){return r(c).default}});var u=n(917);Object.defineProperty(t,"withWindowInfo",{enumerable:!0,get:function(){return r(u).default}})},796:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(497),i=r(n(181));t.default=function(){return o.useContext(i.default)}},917:function(e,t,n){"use strict";var r=this&&this.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},r.apply(this,arguments)},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=o(n(497)),a=o(n(796));t.default=function(e){return function(t){var n=a.default();return i.default.createElement(e,r({},r(r({},t),{windowInfo:n})))}}},679:(e,t,n)=>{"use strict";var r=n(864),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},c={};function u(e){return r.isMemo(e)?a:c[e.$$typeof]||o}c[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},c[r.Memo]=a;var s=Object.defineProperty,l=Object.getOwnPropertyNames,f=Object.getOwnPropertySymbols,d=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(h){var o=p(n);o&&o!==h&&e(t,o,r)}var a=l(n);f&&(a=a.concat(f(n)));for(var c=u(t),v=u(n),m=0;m<a.length;++m){var y=a[m];if(!(i[y]||r&&r[y]||v&&v[y]||c&&c[y])){var g=d(n,y);try{s(t,y,g)}catch(e){}}}}return t}},826:e=>{e.exports=Array.isArray||function(e){return"[object Array]"==Object.prototype.toString.call(e)}},779:(e,t,n)=>{var r=n(826);e.exports=p,e.exports.parse=i,e.exports.compile=function(e,t){return c(i(e,t),t)},e.exports.tokensToFunction=c,e.exports.tokensToRegExp=d;var o=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function i(e,t){for(var n,r=[],i=0,a=0,c="",l=t&&t.delimiter||"/";null!=(n=o.exec(e));){var f=n[0],d=n[1],p=n.index;if(c+=e.slice(a,p),a=p+f.length,d)c+=d[1];else{var h=e[a],v=n[2],m=n[3],y=n[4],g=n[5],w=n[6],b=n[7];c&&(r.push(c),c="");var x=null!=v&&null!=h&&h!==v,_="+"===w||"*"===w,O="?"===w||"*"===w,E=n[2]||l,P=y||g;r.push({name:m||i++,prefix:v||"",delimiter:E,optional:O,repeat:_,partial:x,asterisk:!!b,pattern:P?s(P):b?".*":"[^"+u(E)+"]+?"})}}return a<e.length&&(c+=e.substr(a)),c&&r.push(c),r}function a(e){return encodeURI(e).replace(/[\/?#]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function c(e,t){for(var n=new Array(e.length),o=0;o<e.length;o++)"object"==typeof e[o]&&(n[o]=new RegExp("^(?:"+e[o].pattern+")$",f(t)));return function(t,o){for(var i="",c=t||{},u=(o||{}).pretty?a:encodeURIComponent,s=0;s<e.length;s++){var l=e[s];if("string"!=typeof l){var f,d=c[l.name];if(null==d){if(l.optional){l.partial&&(i+=l.prefix);continue}throw new TypeError('Expected "'+l.name+'" to be defined')}if(r(d)){if(!l.repeat)throw new TypeError('Expected "'+l.name+'" to not repeat, but received `'+JSON.stringify(d)+"`");if(0===d.length){if(l.optional)continue;throw new TypeError('Expected "'+l.name+'" to not be empty')}for(var p=0;p<d.length;p++){if(f=u(d[p]),!n[s].test(f))throw new TypeError('Expected all "'+l.name+'" to match "'+l.pattern+'", but received `'+JSON.stringify(f)+"`");i+=(0===p?l.prefix:l.delimiter)+f}}else{if(f=l.asterisk?encodeURI(d).replace(/[?#]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})):u(d),!n[s].test(f))throw new TypeError('Expected "'+l.name+'" to match "'+l.pattern+'", but received "'+f+'"');i+=l.prefix+f}}else i+=l}return i}}function u(e){return e.replace(/([.+*?=^!:${}()[\]|\/\\])/g,"\\$1")}function s(e){return e.replace(/([=!:$\/()])/g,"\\$1")}function l(e,t){return e.keys=t,e}function f(e){return e&&e.sensitive?"":"i"}function d(e,t,n){r(t)||(n=t||n,t=[]);for(var o=(n=n||{}).strict,i=!1!==n.end,a="",c=0;c<e.length;c++){var s=e[c];if("string"==typeof s)a+=u(s);else{var d=u(s.prefix),p="(?:"+s.pattern+")";t.push(s),s.repeat&&(p+="(?:"+d+p+")*"),a+=p=s.optional?s.partial?d+"("+p+")?":"(?:"+d+"("+p+"))?":d+"("+p+")"}}var h=u(n.delimiter||"/"),v=a.slice(-h.length)===h;return o||(a=(v?a.slice(0,-h.length):a)+"(?:"+h+"(?=$))?"),a+=i?"$":o&&v?"":"(?="+h+"|$)",l(new RegExp("^"+a,f(n)),t)}function p(e,t,n){return r(t)||(n=t||n,t=[]),n=n||{},e instanceof RegExp?function(e,t){var n=e.source.match(/\((?!\?)/g);if(n)for(var r=0;r<n.length;r++)t.push({name:r,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,asterisk:!1,pattern:null});return l(e,t)}(e,t):r(e)?function(e,t,n){for(var r=[],o=0;o<e.length;o++)r.push(p(e[o],t,n).source);return l(new RegExp("(?:"+r.join("|")+")",f(n)),t)}(e,t,n):function(e,t,n){return d(i(e,n),t,n)}(e,t,n)}},703:(e,t,n)=>{"use strict";var r=n(414);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},697:(e,t,n)=>{e.exports=n(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},921:(e,t)=>{"use strict";
|
|
2
2
|
/** @license React v16.13.1
|
|
3
3
|
* react-is.production.min.js
|
|
4
4
|
*
|
|
@@ -6,4 +6,4 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var n="function"==typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,o=n?Symbol.for("react.portal"):60106,i=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,c=n?Symbol.for("react.profiler"):60114,u=n?Symbol.for("react.provider"):60109,s=n?Symbol.for("react.context"):60110,l=n?Symbol.for("react.async_mode"):60111,f=n?Symbol.for("react.concurrent_mode"):60111,d=n?Symbol.for("react.forward_ref"):60112,p=n?Symbol.for("react.suspense"):60113,h=n?Symbol.for("react.suspense_list"):60120,v=n?Symbol.for("react.memo"):60115,m=n?Symbol.for("react.lazy"):60116,y=n?Symbol.for("react.block"):60121,g=n?Symbol.for("react.fundamental"):60117,w=n?Symbol.for("react.responder"):60118,b=n?Symbol.for("react.scope"):60119;function x(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case l:case f:case i:case c:case a:case p:return e;default:switch(e=e&&e.$$typeof){case s:case d:case m:case v:case u:return e;default:return t}}case o:return t}}}function _(e){return x(e)===f}t.AsyncMode=l,t.ConcurrentMode=f,t.ContextConsumer=s,t.ContextProvider=u,t.Element=r,t.ForwardRef=d,t.Fragment=i,t.Lazy=m,t.Memo=v,t.Portal=o,t.Profiler=c,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return _(e)||x(e)===l},t.isConcurrentMode=_,t.isContextConsumer=function(e){return x(e)===s},t.isContextProvider=function(e){return x(e)===u},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return x(e)===d},t.isFragment=function(e){return x(e)===i},t.isLazy=function(e){return x(e)===m},t.isMemo=function(e){return x(e)===v},t.isPortal=function(e){return x(e)===o},t.isProfiler=function(e){return x(e)===c},t.isStrictMode=function(e){return x(e)===a},t.isSuspense=function(e){return x(e)===p},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===f||e===c||e===a||e===p||e===h||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===v||e.$$typeof===u||e.$$typeof===s||e.$$typeof===d||e.$$typeof===g||e.$$typeof===w||e.$$typeof===b||e.$$typeof===y)},t.typeOf=x},864:(e,t,n)=>{"use strict";e.exports=n(921)},658:(e,t,n)=>{var r=n(826);e.exports=p,e.exports.parse=i,e.exports.compile=function(e,t){return c(i(e,t),t)},e.exports.tokensToFunction=c,e.exports.tokensToRegExp=d;var o=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function i(e,t){for(var n,r=[],i=0,a=0,c="",l=t&&t.delimiter||"/";null!=(n=o.exec(e));){var f=n[0],d=n[1],p=n.index;if(c+=e.slice(a,p),a=p+f.length,d)c+=d[1];else{var h=e[a],v=n[2],m=n[3],y=n[4],g=n[5],w=n[6],b=n[7];c&&(r.push(c),c="");var x=null!=v&&null!=h&&h!==v,_="+"===w||"*"===w,O="?"===w||"*"===w,E=n[2]||l,P=y||g;r.push({name:m||i++,prefix:v||"",delimiter:E,optional:O,repeat:_,partial:x,asterisk:!!b,pattern:P?s(P):b?".*":"[^"+u(E)+"]+?"})}}return a<e.length&&(c+=e.substr(a)),c&&r.push(c),r}function a(e){return encodeURI(e).replace(/[\/?#]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function c(e,t){for(var n=new Array(e.length),o=0;o<e.length;o++)"object"==typeof e[o]&&(n[o]=new RegExp("^(?:"+e[o].pattern+")$",f(t)));return function(t,o){for(var i="",c=t||{},u=(o||{}).pretty?a:encodeURIComponent,s=0;s<e.length;s++){var l=e[s];if("string"!=typeof l){var f,d=c[l.name];if(null==d){if(l.optional){l.partial&&(i+=l.prefix);continue}throw new TypeError('Expected "'+l.name+'" to be defined')}if(r(d)){if(!l.repeat)throw new TypeError('Expected "'+l.name+'" to not repeat, but received `'+JSON.stringify(d)+"`");if(0===d.length){if(l.optional)continue;throw new TypeError('Expected "'+l.name+'" to not be empty')}for(var p=0;p<d.length;p++){if(f=u(d[p]),!n[s].test(f))throw new TypeError('Expected all "'+l.name+'" to match "'+l.pattern+'", but received `'+JSON.stringify(f)+"`");i+=(0===p?l.prefix:l.delimiter)+f}}else{if(f=l.asterisk?encodeURI(d).replace(/[?#]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})):u(d),!n[s].test(f))throw new TypeError('Expected "'+l.name+'" to match "'+l.pattern+'", but received "'+f+'"');i+=l.prefix+f}}else i+=l}return i}}function u(e){return e.replace(/([.+*?=^!:${}()[\]|\/\\])/g,"\\$1")}function s(e){return e.replace(/([=!:$\/()])/g,"\\$1")}function l(e,t){return e.keys=t,e}function f(e){return e&&e.sensitive?"":"i"}function d(e,t,n){r(t)||(n=t||n,t=[]);for(var o=(n=n||{}).strict,i=!1!==n.end,a="",c=0;c<e.length;c++){var s=e[c];if("string"==typeof s)a+=u(s);else{var d=u(s.prefix),p="(?:"+s.pattern+")";t.push(s),s.repeat&&(p+="(?:"+d+p+")*"),a+=p=s.optional?s.partial?d+"("+p+")?":"(?:"+d+"("+p+"))?":d+"("+p+")"}}var h=u(n.delimiter||"/"),v=a.slice(-h.length)===h;return o||(a=(v?a.slice(0,-h.length):a)+"(?:"+h+"(?=$))?"),a+=i?"$":o&&v?"":"(?="+h+"|$)",l(new RegExp("^"+a,f(n)),t)}function p(e,t,n){return r(t)||(n=t||n,t=[]),n=n||{},e instanceof RegExp?function(e,t){var n=e.source.match(/\((?!\?)/g);if(n)for(var r=0;r<n.length;r++)t.push({name:r,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,asterisk:!1,pattern:null});return l(e,t)}(e,t):r(e)?function(e,t,n){for(var r=[],o=0;o<e.length;o++)r.push(p(e[o],t,n).source);return l(new RegExp("(?:"+r.join("|")+")",f(n)),t)}(e,t,n):function(e,t,n){return d(i(e,n),t,n)}(e,t,n)}},497:e=>{"use strict";e.exports=require("react")}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r].call(i.exports,i,i.exports,n),i.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};(()=>{"use strict";n.r(r),n.d(r,{Banner:()=>Oe,Button:()=>he,Check:()=>Se,Chevron:()=>le,Menu:()=>Ce,MinimalTemplate:()=>Pe,Pill:()=>Te,Popup:()=>xe,Search:()=>je,X:()=>se});var e=n(497),t=n.n(e);function o(e,t){return o=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},o(e,t)}function i(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,o(e,t)}var a=n(697),c=n.n(a);function u(){return u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},u.apply(this,arguments)}function s(e){return"/"===e.charAt(0)}function l(e,t){for(var n=t,r=n+1,o=e.length;r<o;n+=1,r+=1)e[n]=e[r];e.pop()}const f=function(e,t){void 0===t&&(t="");var n,r=e&&e.split("/")||[],o=t&&t.split("/")||[],i=e&&s(e),a=t&&s(t),c=i||a;if(e&&s(e)?o=r:r.length&&(o.pop(),o=o.concat(r)),!o.length)return"/";if(o.length){var u=o[o.length-1];n="."===u||".."===u||""===u}else n=!1;for(var f=0,d=o.length;d>=0;d--){var p=o[d];"."===p?l(o,d):".."===p?(l(o,d),f++):f&&(l(o,d),f--)}if(!c)for(;f--;f)o.unshift("..");!c||""===o[0]||o[0]&&s(o[0])||o.unshift("");var h=o.join("/");return n&&"/"!==h.substr(-1)&&(h+="/"),h};var d="Invariant failed";const p=function(e,t){if(!e)throw new Error(d)};function h(e){return"/"===e.charAt(0)?e:"/"+e}function v(e){return"/"===e.charAt(0)?e.substr(1):e}function m(e,t){return function(e,t){return 0===e.toLowerCase().indexOf(t.toLowerCase())&&-1!=="/?#".indexOf(e.charAt(t.length))}(e,t)?e.substr(t.length):e}function y(e){return"/"===e.charAt(e.length-1)?e.slice(0,-1):e}function g(e){var t=e.pathname,n=e.search,r=e.hash,o=t||"/";return n&&"?"!==n&&(o+="?"===n.charAt(0)?n:"?"+n),r&&"#"!==r&&(o+="#"===r.charAt(0)?r:"#"+r),o}function w(e,t,n,r){var o;"string"==typeof e?(o=function(e){var t=e||"/",n="",r="",o=t.indexOf("#");-1!==o&&(r=t.substr(o),t=t.substr(0,o));var i=t.indexOf("?");return-1!==i&&(n=t.substr(i),t=t.substr(0,i)),{pathname:t,search:"?"===n?"":n,hash:"#"===r?"":r}}(e),o.state=t):(void 0===(o=u({},e)).pathname&&(o.pathname=""),o.search?"?"!==o.search.charAt(0)&&(o.search="?"+o.search):o.search="",o.hash?"#"!==o.hash.charAt(0)&&(o.hash="#"+o.hash):o.hash="",void 0!==t&&void 0===o.state&&(o.state=t));try{o.pathname=decodeURI(o.pathname)}catch(e){throw e instanceof URIError?new URIError('Pathname "'+o.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):e}return n&&(o.key=n),r?o.pathname?"/"!==o.pathname.charAt(0)&&(o.pathname=f(o.pathname,r.pathname)):o.pathname=r.pathname:o.pathname||(o.pathname="/"),o}function b(){var e=null;var t=[];return{setPrompt:function(t){return t,function(){e===t&&null}},confirmTransitionTo:function(t,n,r,o){if(null!=e){var i="function"==typeof e?e(t,n):e;"string"==typeof i?"function"==typeof r?r(i,o):o(!0):o(!1!==i)}else o(!0)},appendListener:function(e){var n=!0;function r(){n&&e.apply(void 0,arguments)}return t.push(r),function(){!1,t.filter((function(e){return e!==r}))}},notifyListeners:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];t.forEach((function(e){return e.apply(void 0,n)}))}}}var x=!("undefined"==typeof window||!window.document||!window.document.createElement);function _(e,t){t(window.confirm(e))}var O="popstate",E="hashchange";function P(){try{return window.history.state||{}}catch(e){return{}}}function S(e){void 0===e&&{},x||p(!1);var t,n=window.history,r=(-1===window.navigator.userAgent.indexOf("Android 2.")&&-1===t.indexOf("Android 4.0")||-1===t.indexOf("Mobile Safari")||-1!==t.indexOf("Chrome")||-1!==t.indexOf("Windows Phone"))&&window.history&&"pushState"in window.history,o=!(-1===window.navigator.userAgent.indexOf("Trident")),i=e,a=i.forceRefresh,c=void 0!==a&&a,s=i.getUserConfirmation,l=void 0===s?_:s,f=i.keyLength,d=void 0===f?6:f,v=e.basename?y(h(e.basename)):"";function S(e){var t=e||{},n=t.key,r=t.state,o=window.location,i=o.pathname+o.search+o.hash;return v&&m(i,v),w(i,r,n)}function j(){return Math.random().toString(36).substr(2,d)}var C=b();function k(e){u(F,e),F.length=n.length,C.notifyListeners(F.location,F.action)}function T(e){(function(e){return void 0===e.state&&-1===navigator.userAgent.indexOf("CriOS")})(e)||I(S(e.state))}function M(){I(S(P()))}var A=!1;function I(e){if(A)!1,k();else{C.confirmTransitionTo(e,"POP",l,(function(t){t?k({action:"POP",location:e}):function(e){var t=F.location,n=L.indexOf(t.key);-1===n&&0;var r=L.indexOf(e.key);-1===r&&0;var o=n-r;o&&(!0,D(o))}(e)}))}}var N=S(P()),L=[N.key];function R(e){return v+g(e)}function D(e){n.go(e)}var $=0;function W(e){1===($+=e)&&1===e?(window.addEventListener(O,T),o&&window.addEventListener(E,M)):0===$&&(window.removeEventListener(O,T),o&&window.removeEventListener(E,M))}var B=!1;var F={length:n.length,action:"POP",location:N,createHref:R,push:function(e,t){var o="PUSH",i=w(e,t,j(),F.location);C.confirmTransitionTo(i,o,l,(function(e){if(e){var t=R(i),a=i.key,u=i.state;if(r)if(n.pushState({key:a,state:u},null,t),c)window.location.href=t;else{var s=L.indexOf(F.location.key),l=L.slice(0,s+1);l.push(i.key),l,k({action:o,location:i})}else window.location.href=t}}))},replace:function(e,t){var o="REPLACE",i=w(e,t,j(),F.location);C.confirmTransitionTo(i,o,l,(function(e){if(e){var t=R(i),a=i.key,u=i.state;if(r)if(n.replaceState({key:a,state:u},null,t),c)window.location.replace(t);else{var s=L.indexOf(F.location.key);-1!==s&&(L[s]=i.key),k({action:o,location:i})}else window.location.replace(t)}}))},go:D,goBack:function(){D(-1)},goForward:function(){D(1)},block:function(e){void 0===e&&!1;var t=C.setPrompt(e);return B||(W(1),!0),function(){return B&&(!1,W(-1)),t()}},listen:function(e){var t=C.appendListener(e);return W(1),function(){W(-1),t()}}};return F}var j="hashchange",C={hashbang:{encodePath:function(e){return"!"===e.charAt(0)?e:"!/"+v(e)},decodePath:function(e){return"!"===e.charAt(0)?e.substr(1):e}},noslash:{encodePath:v,decodePath:h},slash:{encodePath:h,decodePath:h}};function k(e){var t=e.indexOf("#");return-1===t?e:e.slice(0,t)}function T(){var e=window.location.href,t=e.indexOf("#");return-1===t?"":e.substring(t+1)}function M(e){window.location.replace(k(window.location.href)+"#"+e)}function A(e){void 0===e&&{},x||p(!1);var t=window.history,n=(window.navigator.userAgent.indexOf("Firefox"),e),r=n.getUserConfirmation,o=void 0===r?_:r,i=n.hashType,a=void 0===i?"slash":i,c=e.basename?y(h(e.basename)):"",s=C[a],l=s.encodePath,f=s.decodePath;function d(){var e=f(T());return c&&m(e,c),w(e)}var v=b();function O(e){u(B,e),B.length=t.length,v.notifyListeners(B.location,B.action)}var E=!1,P=null;function S(){var e,t,n=T(),r=l(n);if(n!==r)M(r);else{var i=d(),a=B.location;if(!E&&(i,a.pathname===t.pathname&&e.search===t.search&&e.hash===t.hash))return;if(P===g(i))return;null,function(e){if(E)!1,O();else{var t="POP";v.confirmTransitionTo(e,t,o,(function(n){n?O({action:t,location:e}):function(e){var t=B.location,n=L.lastIndexOf(g(t));-1===n&&0;var r=L.lastIndexOf(g(e));-1===r&&0;var o=n-r;o&&(!0,R(o))}(e)}))}}(i)}}var A=T(),I=l(A);A!==I&&M(I);var N=d(),L=[g(N)];function R(e){t.go(e)}var D=0;function $(e){1===(D+=e)&&1===e?window.addEventListener(j,S):0===D&&window.removeEventListener(j,S)}var W=!1;var B={length:t.length,action:"POP",location:N,createHref:function(e){var t=document.querySelector("base"),n="";return t&&t.getAttribute("href")&&k(window.location.href),n+"#"+l(c+g(e))},push:function(e,t){var n="PUSH",r=w(e,void 0,void 0,B.location);v.confirmTransitionTo(r,n,o,(function(e){if(e){var t=g(r),o=l(c+t);if(T()!==o){t,function(e){window.location.hash=e}(o);var i=L.lastIndexOf(g(B.location)),a=L.slice(0,i+1);a.push(t),a,O({action:n,location:r})}else O()}}))},replace:function(e,t){var n="REPLACE",r=w(e,void 0,void 0,B.location);v.confirmTransitionTo(r,n,o,(function(e){if(e){var t=g(r),o=l(c+t);T()!==o&&(t,M(o));var i=L.indexOf(g(B.location));-1!==i&&(L[i]=t),O({action:n,location:r})}}))},go:R,goBack:function(){R(-1)},goForward:function(){R(1)},block:function(e){void 0===e&&!1;var t=v.setPrompt(e);return W||($(1),!0),function(){return W&&(!1,$(-1)),t()}},listen:function(e){var t=v.appendListener(e);return $(1),function(){$(-1),t()}}};return B}function I(e,t,n){return Math.min(Math.max(e,t),n)}function N(e){void 0===e&&{};var t=e,n=t.getUserConfirmation,r=t.initialEntries,o=void 0===r?["/"]:r,i=t.initialIndex,a=void 0===i?0:i,c=t.keyLength,s=void 0===c?6:c,l=b();function f(e){u(y,e),y.length=y.entries.length,l.notifyListeners(y.location,y.action)}function d(){return Math.random().toString(36).substr(2,s)}var p=I(a,0,o.length-1),h=o.map((function(e){return w(e,void 0,"string"==typeof e?d():e.key||d())})),v=g;function m(e){var t=I(y.index+e,0,y.entries.length-1),r=y.entries[t];l.confirmTransitionTo(r,"POP",n,(function(e){e?f({action:"POP",location:r,index:t}):f()}))}var y={length:h.length,action:"POP",location:h[p],index:p,entries:h,createHref:v,push:function(e,t){var r="PUSH",o=w(e,t,d(),y.location);l.confirmTransitionTo(o,r,n,(function(e){if(e){var t=y.index+1,n=y.entries.slice(0);n.length>t?n.splice(t,n.length-t,o):n.push(o),f({action:r,location:o,index:t,entries:n})}}))},replace:function(e,t){var r="REPLACE",o=w(e,t,d(),y.location);l.confirmTransitionTo(o,r,n,(function(e){e&&(y.entries[y.index]=o,f({action:r,location:o}))}))},go:m,goBack:function(){m(-1)},goForward:function(){m(1)},canGo:function(e){var t=y.index+e;return t>=0&&t<y.entries.length},block:function(e){return void 0===e&&!1,l.setPrompt(e)},listen:function(e){return l.appendListener(e)}};return y}var L=1073741823,R="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:{};function D(e){var t=[];return{on:function(e){t.push(e)},off:function(e){t=t.filter((function(t){return t!==e}))},get:function(){return e},set:function(n,r){e=n,t.forEach((function(t){return t(e,r)}))}}}var $=t().createContext||function(t,n){var r,o,a="__create-react-context-"+function(){var e="__global_unique_id__";return R[e]=(R[e]||0)+1}()+"__",u=function(e){function t(){var t;return(t=e.apply(this,arguments)||this).emitter=D(t.props.value),t}i(t,e);var r=t.prototype;return r.getChildContext=function(){var e;return(e={})[a]=this.emitter,e},r.componentWillReceiveProps=function(e){if(this.props.value!==e.value){var t,r=this.props.value,o=e.value;((i=r)===(a=o)?0!==i||1/i==1/a:i!=i&&a!=a)?t=0:(t="function"==typeof n?n(r,o):L,0!==(t|=0)&&this.emitter.set(e.value,t))}var i,a},r.render=function(){return this.props.children},t}(e.Component);u.childContextTypes=((r={})[a]=c().object.isRequired,r);var s=function(e){function n(){var t;return(t=e.apply(this,arguments)||this).state={value:t.getValue()},t.onUpdate=function(e,n){0!=((0|t.observedBits)&n)&&t.setState({value:t.getValue()})},t}i(n,e);var r=n.prototype;return r.componentWillReceiveProps=function(e){var t=e.observedBits;this.observedBits=null==t?L:t},r.componentDidMount=function(){this.context[a]&&this.context[a].on(this.onUpdate);var e=this.props.observedBits;this.observedBits=null==e?L:e},r.componentWillUnmount=function(){this.context[a]&&this.context[a].off(this.onUpdate)},r.getValue=function(){return this.context[a]?this.context[a].get():t},r.render=function(){return(e=this.props.children,Array.isArray(e)?e[0]:e)(this.state.value);var e},n}(e.Component);return s.contextTypes=((o={})[a]=c().object,o),{Provider:u,Consumer:s}};const W=$;var B=n(658),F=n.n(B);n(864);function U(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}n(679);var q=function(e){var t=W();return t.displayName=e,t},H=q("Router-History"),z=q("Router"),V=function(e){function n(t){var n;return(n=e.call(this,t)||this).state={location:t.history.location},n._isMounted=!1,n._pendingLocation=null,t.staticContext||(n.unlisten=t.history.listen((function(e){n._isMounted?n.setState({location:e}):n._pendingLocation=e}))),n}i(n,e),n.computeRootMatch=function(e){return{path:"/",url:"/",params:{},isExact:"/"===e}};var r=n.prototype;return r.componentDidMount=function(){this._isMounted=!0,this._pendingLocation&&this.setState({location:this._pendingLocation})},r.componentWillUnmount=function(){this.unlisten&&(this.unlisten(),this._isMounted=!1,this._pendingLocation=null)},r.render=function(){return t().createElement(z.Provider,{value:{history:this.props.history,location:this.state.location,match:n.computeRootMatch(this.state.location.pathname),staticContext:this.props.staticContext}},t().createElement(H.Provider,{children:this.props.children||null,value:this.props.history}))},n}(t().Component);t().Component;t().Component;var K={},J=0;function X(e,t){void 0===t&&(t={}),("string"==typeof t||Array.isArray(t))&&(t={path:t});var n=t,r=n.path,o=n.exact,i=void 0!==o&&o,a=n.strict,c=void 0!==a&&a,u=n.sensitive,s=void 0!==u&&u;return[].concat(r).reduce((function(t,n){if(!n&&""!==n)return null;if(t)return t;var r=function(e,t){var n=""+t.end+t.strict+t.sensitive,r=K[n]||(K[n]={});if(r[e])return r[e];var o=[],i={regexp:F()(e,o,t),keys:o};return J<1e4&&(r[e]=i,J++),i}(n,{end:i,strict:c,sensitive:s}),o=r.regexp,a=r.keys,u=o.exec(e);if(!u)return null;var l=u[0],f=u.slice(1),d=e===l;return i&&!d?null:{path:n,url:"/"===n&&""===l?"/":l,isExact:d,params:a.reduce((function(e,t,n){return e[t.name]=f[n],e}),{})}}),null)}t().Component;function Y(e){return"/"===e.charAt(0)?e:"/"+e}function G(e,t){if(!e)return t;var n=Y(e);return 0!==t.pathname.indexOf(n)?t:u({},t,{pathname:t.pathname.substr(n.length)})}function Q(e){return"string"==typeof e?e:g(e)}function Z(e){return function(){p(!1)}}function ee(){}t().Component;t().Component;t().useContext;t().Component;t().Component;var te=function(e,t){return"function"==typeof e?e(t):e},ne=function(e,t){return"string"==typeof e?w(e,null,null,t):e},re=function(e){return e},oe=t().forwardRef;void 0===oe&&(oe=re);var ie=oe((function(e,n){var r=e.innerRef,o=e.navigate,i=e.onClick,a=U(e,["innerRef","navigate","onClick"]),c=a.target,s=u({},a,{onClick:function(e){try{i&&i(e)}catch(t){throw e.preventDefault(),t}e.defaultPrevented||0!==e.button||c&&"_self"!==c||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e)||(e.preventDefault(),o())}});return s.ref=re!==oe&&n||r,t().createElement("a",s)}));var ae=oe((function(e,n){var r=e.component,o=void 0===r?ie:r,i=e.replace,a=e.to,c=e.innerRef,s=U(e,["component","replace","to","innerRef"]);return t().createElement(z.Consumer,null,(function(e){e||p(!1);var r=e.history,l=ne(te(a,e.location),e.location),f=l?r.createHref(l):"",d=u({},s,{href:f,navigate:function(){var t=te(a,e.location),n=g(e.location)===g(ne(t));(i||n?r.replace:r.push)(t)}});return re!==oe?d.ref=n||c:d.innerRef=c,t().createElement(o,d)}))})),ce=function(e){return e},ue=t().forwardRef;void 0===ue&&(ue=ce);ue((function(e,n){var r=e["aria-current"],o=void 0===r?"page":r,i=e.activeClassName,a=void 0===i?"active":i,c=e.activeStyle,s=e.className,l=e.exact,f=e.isActive,d=e.location,h=e.sensitive,v=e.strict,m=e.style,y=e.to,g=e.innerRef,w=U(e,["aria-current","activeClassName","activeStyle","className","exact","isActive","location","sensitive","strict","style","to","innerRef"]);return t().createElement(z.Consumer,null,(function(e){e||p(!1);var r=d||e.location,i=ne(te(y,r),r),b=i.pathname,x=b&&b.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1"),_=x?X(r.pathname,{path:x,exact:l,sensitive:h,strict:v}):null,O=!!(f?f(_,r):_),E="function"==typeof s?s(O):s,P="function"==typeof m?m(O):m;O&&(E=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.filter((function(e){return e})).join(" ")}(E,a),P=u({},P,c));var S=u({"aria-current":O&&o||null,className:E,style:P,to:i},w);return ce!==ue?S.ref=n||g:S.innerRef=g,t().createElement(ae,S)}))}));const se=()=>t().createElement("svg",{width:"25",height:"25",className:"icon icon--x",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("line",{className:"stroke",x1:"8.74612",y1:"16.347",x2:"16.3973",y2:"8.69584"}),t().createElement("line",{className:"stroke",x1:"8.6027",y1:"8.69585",x2:"16.2539",y2:"16.3471"})),le=({className:e})=>t().createElement("svg",{className:["icon icon--chevron",e].filter(Boolean).join(" "),xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("path",{className:"stroke",d:"M9 10.5L12.5 14.5L16 10.5"})),fe={plus:()=>t().createElement("svg",{className:"icon icon--plus",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("line",{x1:"12.4589",y1:"16.9175",x2:"12.4589",y2:"8.50115",className:"stroke"}),t().createElement("line",{x1:"8.05164",y1:"12.594",x2:"16.468",y2:"12.594",className:"stroke"})),x:se,chevron:le,edit:()=>t().createElement("svg",{className:"icon icon--edit",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("polygon",{className:"fill",points:"16.92 16.86 8.25 16.86 8.25 8.21 12.54 8.21 12.54 6.63 6.68 6.63 6.68 18.43 18.5 18.43 18.5 12.53 16.92 12.53 16.92 16.86"}),t().createElement("polygon",{className:"fill",points:"16.31 7.33 17.42 8.44 12.66 13.2 11.51 13.24 11.55 12.09 16.31 7.33"}),t().createElement("rect",{className:"fill",x:"16.94",y:"6.44",width:"1.58",height:"1.15",transform:"translate(10.16 -10.48) rotate(45)"}))},de="btn",pe=({children:n,icon:r})=>{const o=fe[r];return t().createElement("span",{className:"".concat(de,"__content")},n&&t().createElement("span",{className:"".concat(de,"__label")},n),r&&t().createElement("span",{className:"".concat(de,"__icon")},(0,e.isValidElement)(r)&&r,o&&t().createElement(o,null)))},he=e=>{const{className:n,type:r="button",el:o,to:i,url:a,children:c,onClick:u,disabled:s,icon:l,iconStyle:f="without-border",buttonStyle:d="primary",round:p,size:h="medium",iconPosition:v="right",newTab:m}=e,y=[de,n&&n,d&&"".concat(de,"--style-").concat(d),l&&"".concat(de,"--icon"),f&&"".concat(de,"--icon-style-").concat(f),l&&!c&&"".concat(de,"--icon-only"),s&&"".concat(de,"--disabled"),p&&"".concat(de,"--round"),h&&"".concat(de,"--size-").concat(h),v&&"".concat(de,"--icon-position-").concat(v)].filter(Boolean).join(" ");const g={type:r,className:y,onClick:function(e){"submit"!==r&&u&&e.preventDefault(),u&&u(e)},rel:m?"noopener noreferrer":void 0,target:m?"_blank":void 0};switch(o){case"link":return t().createElement(ae,{...g,to:i||a},t().createElement(pe,{icon:l},c));case"anchor":return t().createElement("a",{...g,href:a},t().createElement(pe,{icon:l},c));default:return t().createElement("button",{type:"submit",...g},t().createElement(pe,{icon:l},c))}};var ve=n(727),me=n(719);const ye=(t,n,r=[])=>{const o=(0,e.useRef)(Date.now());(0,e.useEffect)((()=>{const e=setTimeout((()=>{Date.now()-o.current>=n&&(t(),o.current=Date.now())}),n-(Date.now()-o.current));return()=>{clearTimeout(e)}}),[n,...r])},ge="popup-button",we=e=>{const{buttonType:n,button:r,setActive:o,active:i}=e,a=[ge,"".concat(ge,"--").concat(n)].filter(Boolean).join(" "),c=()=>{o(!i)};return"none"===n?null:"custom"===n?t().createElement("div",{role:"button",tabIndex:0,onKeyDown:e=>{"Enter"===e.key&&c()},onClick:c,className:a},r):t().createElement("button",{type:"button",onClick:()=>o(!i),className:a},r)},be="popup",xe=n=>{const{className:r,render:o,size:i="small",color:a="light",button:c,buttonType:u="default",children:s,showOnHover:l=!1,horizontalAlign:f="left",initActive:d=!1,onToggleOpen:p,padding:h,forceOpen:v}=n,m=(0,e.useRef)(null),y=(0,e.useRef)(null),[g,w]=(0,e.useState)(d),[b,x]=(0,e.useState)("top"),[_,O]=(0,e.useState)(null),{y:E}=(0,me.useScrollInfo)(),{height:P}=(0,ve.useWindowInfo)(),S=e=>{y.current.contains(e.target)||w(!1)};ye((()=>{if(y.current&&m.current){const{height:e,width:t,right:n}=y.current.getBoundingClientRect(),{y:r}=m.current.getBoundingClientRect(),o=window.innerWidth-n,i=n-t;O("left"===f&&o<=0?"right":"right"===f&&i<=0?"left":"center"===f&&(i<=t/2||o<=t/2)?o>i?"left":"right":null),x(r>e?"top":"bottom")}}),500,[x,y,E,P]),(0,e.useEffect)((()=>("function"==typeof p&&p(g),g?document.addEventListener("mousedown",S):document.removeEventListener("mousedown",S),()=>{document.removeEventListener("mousedown",S)})),[g,p]),(0,e.useEffect)((()=>{w(v)}),[v]);const j=[be,r,"".concat(be,"--size-").concat(i),"".concat(be,"--color-").concat(a),"".concat(be,"--v-align-").concat(b),"".concat(be,"--h-align-").concat(f),_&&"".concat(be,"--force-h-align-").concat(_),g&&"".concat(be,"--active")].filter(Boolean).join(" ");return t().createElement("div",{className:j},t().createElement("div",{ref:m,className:"".concat(be,"__wrapper")},l?t().createElement("div",{className:"".concat(be,"__on-hover-watch"),onMouseEnter:()=>w(!0),onMouseLeave:()=>w(!1)},t().createElement(we,{buttonType:u,button:c,setActive:w,active:g})):t().createElement(we,{buttonType:u,button:c,setActive:w,active:g})),t().createElement("div",{className:"".concat(be,"__content"),ref:y},t().createElement("div",{className:"".concat(be,"__wrap")},t().createElement("div",{className:"".concat(be,"__scroll"),style:{padding:h}},o&&o({close:()=>w(!1)}),s&&s))))},_e="banner",Oe=({children:e,className:n,to:r,icon:o,alignIcon:i="right",onClick:a,type:c="default"})=>{const u=[_e,"".concat(_e,"--type-").concat(c),n&&n,r&&"".concat(_e,"--has-link"),(r||a)&&"".concat(_e,"--has-action"),o&&"".concat(_e,"--has-icon"),o&&"".concat(_e,"--align-icon-").concat(i)].filter(Boolean).join(" ");let s="div";return a&&!r&&(s="button"),r&&(s=ae),t().createElement(s,{className:u,onClick:a,to:r||void 0},o&&"left"===i&&t().createElement(t().Fragment,null,o),t().createElement("span",{className:"".concat(_e,"__content")},e),o&&"right"===i&&t().createElement(t().Fragment,null,o))},Ee="template-minimal",Pe=e=>{const{className:n,style:r={},children:o,width:i="normal"}=e,a=[n,Ee,"".concat(Ee,"--width-").concat(i)].filter(Boolean).join(" ");return t().createElement("section",{className:a,style:r},t().createElement("div",{className:"".concat(Ee,"__wrap")},o))},Se=()=>t().createElement("svg",{className:"icon icon--check",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("path",{d:"M10.6092 16.0192L17.6477 8.98076",className:"stroke",strokeLinecap:"square",strokeLinejoin:"bevel"}),t().createElement("path",{d:"M7.35229 12.7623L10.6092 16.0192",className:"stroke",strokeLinecap:"square",strokeLinejoin:"bevel"})),je=()=>t().createElement("svg",{width:"25",height:"25",viewBox:"0 0 25 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"icon icon--search"},t().createElement("circle",{cx:"11.2069",cy:"10.7069",r:"5",stroke:"#333333",strokeWidth:"2"}),t().createElement("line",{x1:"14.914",y1:"13.9998",x2:"20.5002",y2:"19.586",stroke:"#333333",strokeWidth:"2"})),Ce=()=>t().createElement("svg",{width:"25",height:"25",viewBox:"0 0 25 25",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t().createElement("rect",{x:"3.5",y:"4.5",width:"18",height:"2",fill:"#333333"}),t().createElement("rect",{x:"3.5",y:"11.5",width:"18",height:"2",fill:"#333333"}),t().createElement("rect",{x:"3.5",y:"18.5",width:"18",height:"2",fill:"#333333"})),ke="pill",Te=({children:e,className:n,to:r,icon:o,alignIcon:i="right",onClick:a,pillStyle:c="light"})=>{const u=[ke,"".concat(ke,"--style-").concat(c),n&&n,r&&"".concat(ke,"--has-link"),(r||a)&&"".concat(ke,"--has-action"),o&&"".concat(ke,"--has-icon"),o&&"".concat(ke,"--align-icon-").concat(i)].filter(Boolean).join(" ");let s="div";return a&&!r&&(s="button"),r&&(s=ae),t().createElement(s,{className:u,onClick:a,type:"button"===s?"button":void 0,to:r||void 0},o&&"left"===i&&t().createElement(t().Fragment,null,o),e,o&&"right"===i&&t().createElement(t().Fragment,null,o))}})(),module.exports=r})();
|
|
9
|
+
*/var n="function"==typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,o=n?Symbol.for("react.portal"):60106,i=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,c=n?Symbol.for("react.profiler"):60114,u=n?Symbol.for("react.provider"):60109,s=n?Symbol.for("react.context"):60110,l=n?Symbol.for("react.async_mode"):60111,f=n?Symbol.for("react.concurrent_mode"):60111,d=n?Symbol.for("react.forward_ref"):60112,p=n?Symbol.for("react.suspense"):60113,h=n?Symbol.for("react.suspense_list"):60120,v=n?Symbol.for("react.memo"):60115,m=n?Symbol.for("react.lazy"):60116,y=n?Symbol.for("react.block"):60121,g=n?Symbol.for("react.fundamental"):60117,w=n?Symbol.for("react.responder"):60118,b=n?Symbol.for("react.scope"):60119;function x(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case l:case f:case i:case c:case a:case p:return e;default:switch(e=e&&e.$$typeof){case s:case d:case m:case v:case u:return e;default:return t}}case o:return t}}}function _(e){return x(e)===f}t.AsyncMode=l,t.ConcurrentMode=f,t.ContextConsumer=s,t.ContextProvider=u,t.Element=r,t.ForwardRef=d,t.Fragment=i,t.Lazy=m,t.Memo=v,t.Portal=o,t.Profiler=c,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return _(e)||x(e)===l},t.isConcurrentMode=_,t.isContextConsumer=function(e){return x(e)===s},t.isContextProvider=function(e){return x(e)===u},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return x(e)===d},t.isFragment=function(e){return x(e)===i},t.isLazy=function(e){return x(e)===m},t.isMemo=function(e){return x(e)===v},t.isPortal=function(e){return x(e)===o},t.isProfiler=function(e){return x(e)===c},t.isStrictMode=function(e){return x(e)===a},t.isSuspense=function(e){return x(e)===p},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===f||e===c||e===a||e===p||e===h||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===v||e.$$typeof===u||e.$$typeof===s||e.$$typeof===d||e.$$typeof===g||e.$$typeof===w||e.$$typeof===b||e.$$typeof===y)},t.typeOf=x},864:(e,t,n)=>{"use strict";e.exports=n(921)},497:e=>{"use strict";e.exports=require("react")}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r].call(i.exports,i,i.exports,n),i.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};(()=>{"use strict";n.r(r),n.d(r,{Banner:()=>Ce,Button:()=>we,Check:()=>Me,Chevron:()=>ve,Menu:()=>Ie,MinimalTemplate:()=>Te,Pill:()=>Le,Popup:()=>Se,Search:()=>Ae,X:()=>he});var e=n(497),t=n.n(e);function o(e,t){return o=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},o(e,t)}function i(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,o(e,t)}var a=n(697),c=n.n(a);function u(){return u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},u.apply(this,arguments)}function s(e){return"/"===e.charAt(0)}function l(e,t){for(var n=t,r=n+1,o=e.length;r<o;n+=1,r+=1)e[n]=e[r];e.pop()}const f=function(e,t){void 0===t&&(t="");var n,r=e&&e.split("/")||[],o=t&&t.split("/")||[],i=e&&s(e),a=t&&s(t),c=i||a;if(e&&s(e)?o=r:r.length&&(o.pop(),o=o.concat(r)),!o.length)return"/";if(o.length){var u=o[o.length-1];n="."===u||".."===u||""===u}else n=!1;for(var f=0,d=o.length;d>=0;d--){var p=o[d];"."===p?l(o,d):".."===p?(l(o,d),f++):f&&(l(o,d),f--)}if(!c)for(;f--;f)o.unshift("..");!c||""===o[0]||o[0]&&s(o[0])||o.unshift("");var h=o.join("/");return n&&"/"!==h.substr(-1)&&(h+="/"),h};var d="Invariant failed";const p=function(e,t){if(!e)throw new Error(d)};function h(e){return"/"===e.charAt(0)?e:"/"+e}function v(e){return"/"===e.charAt(0)?e.substr(1):e}function m(e,t){return function(e,t){return 0===e.toLowerCase().indexOf(t.toLowerCase())&&-1!=="/?#".indexOf(e.charAt(t.length))}(e,t)?e.substr(t.length):e}function y(e){return"/"===e.charAt(e.length-1)?e.slice(0,-1):e}function g(e){var t=e.pathname,n=e.search,r=e.hash,o=t||"/";return n&&"?"!==n&&("?"===n.charAt(0)?n:"?"+n),r&&"#"!==r&&("#"===r.charAt(0)?r:"#"+r),o}function w(e,t,n,r){var o;"string"==typeof e?(o=function(e){var t=e||"/",n="",r="",o=t.indexOf("#");-1!==o&&(r=t.substr(o),t=t.substr(0,o));var i=t.indexOf("?");return-1!==i&&(n=t.substr(i),t=t.substr(0,i)),{pathname:t,search:"?"===n?"":n,hash:"#"===r?"":r}}(e),o.state=t):(void 0===(o=u({},e)).pathname&&(o.pathname=""),o.search?"?"!==o.search.charAt(0)&&(o.search="?"+o.search):o.search="",o.hash?"#"!==o.hash.charAt(0)&&(o.hash="#"+o.hash):o.hash="",void 0!==t&&void 0===o.state&&(o.state=t));try{o.pathname=decodeURI(o.pathname)}catch(e){throw e instanceof URIError?new URIError('Pathname "'+o.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):e}return n&&(o.key=n),r?o.pathname?"/"!==o.pathname.charAt(0)&&(o.pathname=f(o.pathname,r.pathname)):o.pathname=r.pathname:o.pathname||(o.pathname="/"),o}function b(){var e=null;var t=[];return{setPrompt:function(t){return t,function(){e===t&&null}},confirmTransitionTo:function(t,n,r,o){if(null!=e){var i="function"==typeof e?e(t,n):e;"string"==typeof i?"function"==typeof r?r(i,o):o(!0):o(!1!==i)}else o(!0)},appendListener:function(e){var n=!0;function r(){n&&e.apply(void 0,arguments)}return t.push(r),function(){!1,t.filter((function(e){return e!==r}))}},notifyListeners:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];t.forEach((function(e){return e.apply(void 0,n)}))}}}var x=!("undefined"==typeof window||!window.document||!window.document.createElement);function _(e,t){t(window.confirm(e))}var O="popstate",E="hashchange";function P(){try{return window.history.state||{}}catch(e){return{}}}function S(e){void 0===e&&{},x||p(!1);var t,n=window.history,r=(-1===window.navigator.userAgent.indexOf("Android 2.")&&-1===t.indexOf("Android 4.0")||-1===t.indexOf("Mobile Safari")||-1!==t.indexOf("Chrome")||-1!==t.indexOf("Windows Phone"))&&window.history&&"pushState"in window.history,o=!(-1===window.navigator.userAgent.indexOf("Trident")),i=e,a=i.forceRefresh,c=void 0!==a&&a,s=i.getUserConfirmation,l=void 0===s?_:s,f=i.keyLength,d=void 0===f?6:f,v=e.basename?y(h(e.basename)):"";function S(e){var t=e||{},n=t.key,r=t.state,o=window.location,i=o.pathname+o.search+o.hash;return v&&m(i,v),w(i,r,n)}function j(){return Math.random().toString(36).substr(2,d)}var C=b();function k(e){u(F,e),F.length=n.length,C.notifyListeners(F.location,F.action)}function T(e){(function(e){return void 0===e.state&&-1===navigator.userAgent.indexOf("CriOS")})(e)||I(S(e.state))}function M(){I(S(P()))}var A=!1;function I(e){if(A)!1,k();else{C.confirmTransitionTo(e,"POP",l,(function(t){t?k({action:"POP",location:e}):function(e){var t=F.location,n=L.indexOf(t.key);-1===n&&0;var r=L.indexOf(e.key);-1===r&&0;var o=n-r;o&&(!0,D(o))}(e)}))}}var N=S(P()),L=[N.key];function R(e){return v+g(e)}function D(e){n.go(e)}var $=0;function W(e){1===($+=e)&&1===e?(window.addEventListener(O,T),o&&window.addEventListener(E,M)):0===$&&(window.removeEventListener(O,T),o&&window.removeEventListener(E,M))}var B=!1;var F={length:n.length,action:"POP",location:N,createHref:R,push:function(e,t){var o="PUSH",i=w(e,t,j(),F.location);C.confirmTransitionTo(i,o,l,(function(e){if(e){var t=R(i),a=i.key,u=i.state;if(r)if(n.pushState({key:a,state:u},null,t),c)window.location.href=t;else{var s=L.indexOf(F.location.key),l=L.slice(0,s+1);l.push(i.key),l,k({action:o,location:i})}else window.location.href=t}}))},replace:function(e,t){var o="REPLACE",i=w(e,t,j(),F.location);C.confirmTransitionTo(i,o,l,(function(e){if(e){var t=R(i),a=i.key,u=i.state;if(r)if(n.replaceState({key:a,state:u},null,t),c)window.location.replace(t);else{var s=L.indexOf(F.location.key);-1!==s&&(L[s]=i.key),k({action:o,location:i})}else window.location.replace(t)}}))},go:D,goBack:function(){D(-1)},goForward:function(){D(1)},block:function(e){void 0===e&&!1;var t=C.setPrompt(e);return B||(W(1),!0),function(){return B&&(!1,W(-1)),t()}},listen:function(e){var t=C.appendListener(e);return W(1),function(){W(-1),t()}}};return F}var j="hashchange",C={hashbang:{encodePath:function(e){return"!"===e.charAt(0)?e:"!/"+v(e)},decodePath:function(e){return"!"===e.charAt(0)?e.substr(1):e}},noslash:{encodePath:v,decodePath:h},slash:{encodePath:h,decodePath:h}};function k(e){var t=e.indexOf("#");return-1===t?e:e.slice(0,t)}function T(){var e=window.location.href,t=e.indexOf("#");return-1===t?"":e.substring(t+1)}function M(e){window.location.replace(k(window.location.href)+"#"+e)}function A(e){void 0===e&&{},x||p(!1);var t=window.history,n=(window.navigator.userAgent.indexOf("Firefox"),e),r=n.getUserConfirmation,o=void 0===r?_:r,i=n.hashType,a=void 0===i?"slash":i,c=e.basename?y(h(e.basename)):"",s=C[a],l=s.encodePath,f=s.decodePath;function d(){var e=f(T());return c&&m(e,c),w(e)}var v=b();function O(e){u(B,e),B.length=t.length,v.notifyListeners(B.location,B.action)}var E=!1,P=null;function S(){var e,t,n=T(),r=l(n);if(n!==r)M(r);else{var i=d(),a=B.location;if(!E&&(i,a.pathname===t.pathname&&e.search===t.search&&e.hash===t.hash))return;if(P===g(i))return;null,function(e){if(E)!1,O();else{var t="POP";v.confirmTransitionTo(e,t,o,(function(n){n?O({action:t,location:e}):function(e){var t=B.location,n=L.lastIndexOf(g(t));-1===n&&0;var r=L.lastIndexOf(g(e));-1===r&&0;var o=n-r;o&&(!0,R(o))}(e)}))}}(i)}}var A=T(),I=l(A);A!==I&&M(I);var N=d(),L=[g(N)];function R(e){t.go(e)}var D=0;function $(e){1===(D+=e)&&1===e?window.addEventListener(j,S):0===D&&window.removeEventListener(j,S)}var W=!1;var B={length:t.length,action:"POP",location:N,createHref:function(e){var t=document.querySelector("base"),n="";return t&&t.getAttribute("href")&&k(window.location.href),n+"#"+l(c+g(e))},push:function(e,t){var n="PUSH",r=w(e,void 0,void 0,B.location);v.confirmTransitionTo(r,n,o,(function(e){if(e){var t=g(r),o=l(c+t);if(T()!==o){t,function(e){window.location.hash=e}(o);var i=L.lastIndexOf(g(B.location)),a=L.slice(0,i+1);a.push(t),a,O({action:n,location:r})}else O()}}))},replace:function(e,t){var n="REPLACE",r=w(e,void 0,void 0,B.location);v.confirmTransitionTo(r,n,o,(function(e){if(e){var t=g(r),o=l(c+t);T()!==o&&(t,M(o));var i=L.indexOf(g(B.location));-1!==i&&(L[i]=t),O({action:n,location:r})}}))},go:R,goBack:function(){R(-1)},goForward:function(){R(1)},block:function(e){void 0===e&&!1;var t=v.setPrompt(e);return W||($(1),!0),function(){return W&&(!1,$(-1)),t()}},listen:function(e){var t=v.appendListener(e);return $(1),function(){$(-1),t()}}};return B}function I(e,t,n){return Math.min(Math.max(e,t),n)}function N(e){void 0===e&&{};var t=e,n=t.getUserConfirmation,r=t.initialEntries,o=void 0===r?["/"]:r,i=t.initialIndex,a=void 0===i?0:i,c=t.keyLength,s=void 0===c?6:c,l=b();function f(e){u(y,e),y.length=y.entries.length,l.notifyListeners(y.location,y.action)}function d(){return Math.random().toString(36).substr(2,s)}var p=I(a,0,o.length-1),h=o.map((function(e){return w(e,void 0,"string"==typeof e?d():e.key||d())})),v=g;function m(e){var t=I(y.index+e,0,y.entries.length-1),r=y.entries[t];l.confirmTransitionTo(r,"POP",n,(function(e){e?f({action:"POP",location:r,index:t}):f()}))}var y={length:h.length,action:"POP",location:h[p],index:p,entries:h,createHref:v,push:function(e,t){var r="PUSH",o=w(e,t,d(),y.location);l.confirmTransitionTo(o,r,n,(function(e){if(e){var t=y.index+1,n=y.entries.slice(0);n.length>t?n.splice(t,n.length-t,o):n.push(o),f({action:r,location:o,index:t,entries:n})}}))},replace:function(e,t){var r="REPLACE",o=w(e,t,d(),y.location);l.confirmTransitionTo(o,r,n,(function(e){e&&(y.entries[y.index]=o,f({action:r,location:o}))}))},go:m,goBack:function(){m(-1)},goForward:function(){m(1)},canGo:function(e){var t=y.index+e;return t>=0&&t<y.entries.length},block:function(e){return void 0===e&&!1,l.setPrompt(e)},listen:function(e){return l.appendListener(e)}};return y}var L=1073741823,R="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:{};function D(e){var t=[];return{on:function(e){t.push(e)},off:function(e){t=t.filter((function(t){return t!==e}))},get:function(){return e},set:function(n,r){e=n,t.forEach((function(t){return t(e,r)}))}}}var $=t().createContext||function(t,n){var r,o,a="__create-react-context-"+function(){var e="__global_unique_id__";return R[e]=(R[e]||0)+1}()+"__",u=function(e){function t(){var t;return(t=e.apply(this,arguments)||this).emitter=D(t.props.value),t}i(t,e);var r=t.prototype;return r.getChildContext=function(){var e;return(e={})[a]=this.emitter,e},r.componentWillReceiveProps=function(e){if(this.props.value!==e.value){var t,r=this.props.value,o=e.value;((i=r)===(a=o)?0!==i||1/i==1/a:i!=i&&a!=a)?t=0:(t="function"==typeof n?n(r,o):L,0!==(t|=0)&&this.emitter.set(e.value,t))}var i,a},r.render=function(){return this.props.children},t}(e.Component);u.childContextTypes=((r={})[a]=c().object.isRequired,r);var s=function(e){function n(){var t;return(t=e.apply(this,arguments)||this).state={value:t.getValue()},t.onUpdate=function(e,n){0!=((0|t.observedBits)&n)&&t.setState({value:t.getValue()})},t}i(n,e);var r=n.prototype;return r.componentWillReceiveProps=function(e){var t=e.observedBits;this.observedBits=null==t?L:t},r.componentDidMount=function(){this.context[a]&&this.context[a].on(this.onUpdate);var e=this.props.observedBits;this.observedBits=null==e?L:e},r.componentWillUnmount=function(){this.context[a]&&this.context[a].off(this.onUpdate)},r.getValue=function(){return this.context[a]?this.context[a].get():t},r.render=function(){return(e=this.props.children,Array.isArray(e)?e[0]:e)(this.state.value);var e},n}(e.Component);return s.contextTypes=((o={})[a]=c().object,o),{Provider:u,Consumer:s}};const W=$;var B="Invariant failed";const F=function(e,t){if(!e)throw new Error(B)};var U=n(779),q=n.n(U);n(864);function H(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}n(679);var z=function(e){var t=W();return t.displayName=e,t},V=z("Router-History"),K=function(e){var t=W();return t.displayName=e,t},J=K("Router"),X=function(e){function n(t){var n;return(n=e.call(this,t)||this).state={location:t.history.location},n._isMounted=!1,n._pendingLocation=null,t.staticContext||(n.unlisten=t.history.listen((function(e){n._isMounted?n.setState({location:e}):n._pendingLocation=e}))),n}i(n,e),n.computeRootMatch=function(e){return{path:"/",url:"/",params:{},isExact:"/"===e}};var r=n.prototype;return r.componentDidMount=function(){this._isMounted=!0,this._pendingLocation&&this.setState({location:this._pendingLocation})},r.componentWillUnmount=function(){this.unlisten&&this.unlisten()},r.render=function(){return t().createElement(J.Provider,{value:{history:this.props.history,location:this.state.location,match:n.computeRootMatch(this.state.location.pathname),staticContext:this.props.staticContext}},t().createElement(V.Provider,{children:this.props.children||null,value:this.props.history}))},n}(t().Component);t().Component;t().Component;var Y={},G=0;function Q(e,t){void 0===t&&(t={}),("string"==typeof t||Array.isArray(t))&&(t={path:t});var n=t,r=n.path,o=n.exact,i=void 0!==o&&o,a=n.strict,c=void 0!==a&&a,u=n.sensitive,s=void 0!==u&&u;return[].concat(r).reduce((function(t,n){if(!n&&""!==n)return null;if(t)return t;var r=function(e,t){var n=""+t.end+t.strict+t.sensitive,r=Y[n]||(Y[n]={});if(r[e])return r[e];var o=[],i={regexp:q()(e,o,t),keys:o};return G<1e4&&(r[e]=i,G++),i}(n,{end:i,strict:c,sensitive:s}),o=r.regexp,a=r.keys,u=o.exec(e);if(!u)return null;var l=u[0],f=u.slice(1),d=e===l;return i&&!d?null:{path:n,url:"/"===n&&""===l?"/":l,isExact:d,params:a.reduce((function(e,t,n){return e[t.name]=f[n],e}),{})}}),null)}t().Component;function Z(e){return"/"===e.charAt(0)?e:"/"+e}function ee(e,t){if(!e)return t;var n=Z(e);return 0!==t.pathname.indexOf(n)?t:u({},t,{pathname:t.pathname.substr(n.length)})}function te(e){return"string"==typeof e?e:g(e)}function ne(e){return function(){F(!1)}}function re(){}t().Component;t().Component;t().useContext;var oe="Invariant failed";const ie=function(e,t){if(!e)throw new Error(oe)};t().Component;t().Component;var ae=function(e,t){return"function"==typeof e?e(t):e},ce=function(e,t){return"string"==typeof e?w(e,null,null,t):e},ue=function(e){return e},se=t().forwardRef;void 0===se&&(se=ue);var le=se((function(e,n){var r=e.innerRef,o=e.navigate,i=e.onClick,a=H(e,["innerRef","navigate","onClick"]),c=a.target,s=u({},a,{onClick:function(e){try{i&&i(e)}catch(t){throw e.preventDefault(),t}e.defaultPrevented||0!==e.button||c&&"_self"!==c||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e)||(e.preventDefault(),o())}});return s.ref=ue!==se&&n||r,t().createElement("a",s)}));var fe=se((function(e,n){var r=e.component,o=void 0===r?le:r,i=e.replace,a=e.to,c=e.innerRef,s=H(e,["component","replace","to","innerRef"]);return t().createElement(J.Consumer,null,(function(e){e||ie(!1);var r=e.history,l=ce(ae(a,e.location),e.location),f=l?r.createHref(l):"",d=u({},s,{href:f,navigate:function(){var t=ae(a,e.location);(i?r.replace:r.push)(t)}});return ue!==se?d.ref=n||c:d.innerRef=c,t().createElement(o,d)}))})),de=function(e){return e},pe=t().forwardRef;void 0===pe&&(pe=de);pe((function(e,n){var r=e["aria-current"],o=void 0===r?"page":r,i=e.activeClassName,a=void 0===i?"active":i,c=e.activeStyle,s=e.className,l=e.exact,f=e.isActive,d=e.location,p=e.sensitive,h=e.strict,v=e.style,m=e.to,y=e.innerRef,g=H(e,["aria-current","activeClassName","activeStyle","className","exact","isActive","location","sensitive","strict","style","to","innerRef"]);return t().createElement(J.Consumer,null,(function(e){e||ie(!1);var r=d||e.location,i=ce(ae(m,r),r),w=i.pathname,b=w&&w.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1"),x=b?Q(r.pathname,{path:b,exact:l,sensitive:p,strict:h}):null,_=!!(f?f(x,r):x),O=_?function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.filter((function(e){return e})).join(" ")}(s,a):s,E=_?u({},v,{},c):v,P=u({"aria-current":_&&o||null,className:O,style:E,to:i},g);return de!==pe?P.ref=n||y:P.innerRef=y,t().createElement(fe,P)}))}));const he=()=>t().createElement("svg",{width:"25",height:"25",className:"icon icon--x",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("line",{className:"stroke",x1:"8.74612",y1:"16.347",x2:"16.3973",y2:"8.69584"}),t().createElement("line",{className:"stroke",x1:"8.6027",y1:"8.69585",x2:"16.2539",y2:"16.3471"})),ve=({className:e})=>t().createElement("svg",{className:["icon icon--chevron",e].filter(Boolean).join(" "),xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("path",{className:"stroke",d:"M9 10.5L12.5 14.5L16 10.5"})),me={plus:()=>t().createElement("svg",{className:"icon icon--plus",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("line",{x1:"12.4589",y1:"16.9175",x2:"12.4589",y2:"8.50115",className:"stroke"}),t().createElement("line",{x1:"8.05164",y1:"12.594",x2:"16.468",y2:"12.594",className:"stroke"})),x:he,chevron:ve,edit:()=>t().createElement("svg",{className:"icon icon--edit",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("polygon",{className:"fill",points:"16.92 16.86 8.25 16.86 8.25 8.21 12.54 8.21 12.54 6.63 6.68 6.63 6.68 18.43 18.5 18.43 18.5 12.53 16.92 12.53 16.92 16.86"}),t().createElement("polygon",{className:"fill",points:"16.31 7.33 17.42 8.44 12.66 13.2 11.51 13.24 11.55 12.09 16.31 7.33"}),t().createElement("rect",{className:"fill",x:"16.94",y:"6.44",width:"1.58",height:"1.15",transform:"translate(10.16 -10.48) rotate(45)"}))},ye="btn",ge=({children:n,icon:r})=>{const o=me[r];return t().createElement("span",{className:"".concat(ye,"__content")},n&&t().createElement("span",{className:"".concat(ye,"__label")},n),r&&t().createElement("span",{className:"".concat(ye,"__icon")},(0,e.isValidElement)(r)&&r,o&&t().createElement(o,null)))},we=e=>{const{className:n,type:r="button",el:o,to:i,url:a,children:c,onClick:u,disabled:s,icon:l,iconStyle:f="without-border",buttonStyle:d="primary",round:p,size:h="medium",iconPosition:v="right",newTab:m}=e,y=[ye,n&&n,d&&"".concat(ye,"--style-").concat(d),l&&"".concat(ye,"--icon"),f&&"".concat(ye,"--icon-style-").concat(f),l&&!c&&"".concat(ye,"--icon-only"),s&&"".concat(ye,"--disabled"),p&&"".concat(ye,"--round"),h&&"".concat(ye,"--size-").concat(h),v&&"".concat(ye,"--icon-position-").concat(v)].filter(Boolean).join(" ");const g={type:r,className:y,onClick:function(e){"submit"!==r&&u&&e.preventDefault(),u&&u(e)},rel:m?"noopener noreferrer":void 0,target:m?"_blank":void 0};switch(o){case"link":return t().createElement(fe,{...g,to:i||a},t().createElement(ge,{icon:l},c));case"anchor":return t().createElement("a",{...g,href:a},t().createElement(ge,{icon:l},c));default:return t().createElement("button",{type:"submit",...g},t().createElement(ge,{icon:l},c))}};var be=n(727),xe=n(719);const _e=(t,n,r=[])=>{const o=(0,e.useRef)(Date.now());(0,e.useEffect)((()=>{const e=setTimeout((()=>{Date.now()-o.current>=n&&(t(),o.current=Date.now())}),n-(Date.now()-o.current));return()=>{clearTimeout(e)}}),[n,...r])},Oe="popup-button",Ee=e=>{const{buttonType:n,button:r,setActive:o,active:i}=e,a=[Oe,"".concat(Oe,"--").concat(n)].filter(Boolean).join(" "),c=()=>{o(!i)};return"none"===n?null:"custom"===n?t().createElement("div",{role:"button",tabIndex:0,onKeyDown:e=>{"Enter"===e.key&&c()},onClick:c,className:a},r):t().createElement("button",{type:"button",onClick:()=>o(!i),className:a},r)},Pe="popup",Se=n=>{const{className:r,render:o,size:i="small",color:a="light",button:c,buttonType:u="default",children:s,showOnHover:l=!1,horizontalAlign:f="left",initActive:d=!1,onToggleOpen:p,padding:h,forceOpen:v}=n,m=(0,e.useRef)(null),y=(0,e.useRef)(null),[g,w]=(0,e.useState)(d),[b,x]=(0,e.useState)("top"),[_,O]=(0,e.useState)(null),{y:E}=(0,xe.useScrollInfo)(),{height:P}=(0,be.useWindowInfo)(),S=e=>{y.current.contains(e.target)||w(!1)};_e((()=>{if(y.current&&m.current){const{height:e,width:t,right:n}=y.current.getBoundingClientRect(),{y:r}=m.current.getBoundingClientRect(),o=window.innerWidth-n,i=n-t;O("left"===f&&o<=0?"right":"right"===f&&i<=0?"left":"center"===f&&(i<=t/2||o<=t/2)?o>i?"left":"right":null),x(r>e?"top":"bottom")}}),500,[x,y,E,P]),(0,e.useEffect)((()=>("function"==typeof p&&p(g),g?document.addEventListener("mousedown",S):document.removeEventListener("mousedown",S),()=>{document.removeEventListener("mousedown",S)})),[g,p]),(0,e.useEffect)((()=>{w(v)}),[v]);const j=[Pe,r,"".concat(Pe,"--size-").concat(i),"".concat(Pe,"--color-").concat(a),"".concat(Pe,"--v-align-").concat(b),"".concat(Pe,"--h-align-").concat(f),_&&"".concat(Pe,"--force-h-align-").concat(_),g&&"".concat(Pe,"--active")].filter(Boolean).join(" ");return t().createElement("div",{className:j},t().createElement("div",{ref:m,className:"".concat(Pe,"__wrapper")},l?t().createElement("div",{className:"".concat(Pe,"__on-hover-watch"),onMouseEnter:()=>w(!0),onMouseLeave:()=>w(!1)},t().createElement(Ee,{buttonType:u,button:c,setActive:w,active:g})):t().createElement(Ee,{buttonType:u,button:c,setActive:w,active:g})),t().createElement("div",{className:"".concat(Pe,"__content"),ref:y},t().createElement("div",{className:"".concat(Pe,"__wrap")},t().createElement("div",{className:"".concat(Pe,"__scroll"),style:{padding:h}},o&&o({close:()=>w(!1)}),s&&s))))},je="banner",Ce=({children:e,className:n,to:r,icon:o,alignIcon:i="right",onClick:a,type:c="default"})=>{const u=[je,"".concat(je,"--type-").concat(c),n&&n,r&&"".concat(je,"--has-link"),(r||a)&&"".concat(je,"--has-action"),o&&"".concat(je,"--has-icon"),o&&"".concat(je,"--align-icon-").concat(i)].filter(Boolean).join(" ");let s="div";return a&&!r&&(s="button"),r&&(s=fe),t().createElement(s,{className:u,onClick:a,to:r||void 0},o&&"left"===i&&t().createElement(t().Fragment,null,o),t().createElement("span",{className:"".concat(je,"__content")},e),o&&"right"===i&&t().createElement(t().Fragment,null,o))},ke="template-minimal",Te=e=>{const{className:n,style:r={},children:o,width:i="normal"}=e,a=[n,ke,"".concat(ke,"--width-").concat(i)].filter(Boolean).join(" ");return t().createElement("section",{className:a,style:r},t().createElement("div",{className:"".concat(ke,"__wrap")},o))},Me=()=>t().createElement("svg",{className:"icon icon--check",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 25"},t().createElement("path",{d:"M10.6092 16.0192L17.6477 8.98076",className:"stroke",strokeLinecap:"square",strokeLinejoin:"bevel"}),t().createElement("path",{d:"M7.35229 12.7623L10.6092 16.0192",className:"stroke",strokeLinecap:"square",strokeLinejoin:"bevel"})),Ae=()=>t().createElement("svg",{width:"25",height:"25",viewBox:"0 0 25 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"icon icon--search"},t().createElement("circle",{cx:"11.2069",cy:"10.7069",r:"5",stroke:"#333333",strokeWidth:"2"}),t().createElement("line",{x1:"14.914",y1:"13.9998",x2:"20.5002",y2:"19.586",stroke:"#333333",strokeWidth:"2"})),Ie=()=>t().createElement("svg",{width:"25",height:"25",viewBox:"0 0 25 25",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t().createElement("rect",{x:"3.5",y:"4.5",width:"18",height:"2",fill:"#333333"}),t().createElement("rect",{x:"3.5",y:"11.5",width:"18",height:"2",fill:"#333333"}),t().createElement("rect",{x:"3.5",y:"18.5",width:"18",height:"2",fill:"#333333"})),Ne="pill",Le=({children:e,className:n,to:r,icon:o,alignIcon:i="right",onClick:a,pillStyle:c="light"})=>{const u=[Ne,"".concat(Ne,"--style-").concat(c),n&&n,r&&"".concat(Ne,"--has-link"),(r||a)&&"".concat(Ne,"--has-action"),o&&"".concat(Ne,"--has-icon"),o&&"".concat(Ne,"--align-icon-").concat(i)].filter(Boolean).join(" ");let s="div";return a&&!r&&(s="button"),r&&(s=fe),t().createElement(s,{className:u,onClick:a,type:"button"===s?"button":void 0,to:r||void 0},o&&"left"===i&&t().createElement(t().Fragment,null,o),e,o&&"right"===i&&t().createElement(t().Fragment,null,o))}})(),module.exports=r})();
|
|
@@ -1,13 +1,28 @@
|
|
|
1
|
-
import React from 'react';
|
|
1
|
+
import React, { useEffect, useState } from 'react';
|
|
2
2
|
import { useAuth } from '@payloadcms/config-provider';
|
|
3
3
|
import Button from '../Button';
|
|
4
4
|
import { useLocale } from '../../utilities/Locale';
|
|
5
5
|
const baseClass = 'preview-btn';
|
|
6
|
-
const PreviewButton = (
|
|
6
|
+
const PreviewButton = (props) => {
|
|
7
|
+
const { generatePreviewURL, data } = props;
|
|
8
|
+
const [url, setUrl] = useState(undefined);
|
|
7
9
|
const locale = useLocale();
|
|
8
10
|
const { token } = useAuth();
|
|
9
|
-
|
|
10
|
-
|
|
11
|
+
useEffect(() => {
|
|
12
|
+
if (generatePreviewURL && typeof generatePreviewURL === 'function') {
|
|
13
|
+
const makeRequest = async () => {
|
|
14
|
+
const previewURL = await generatePreviewURL(data, { locale, token });
|
|
15
|
+
setUrl(previewURL);
|
|
16
|
+
};
|
|
17
|
+
makeRequest();
|
|
18
|
+
}
|
|
19
|
+
}, [
|
|
20
|
+
generatePreviewURL,
|
|
21
|
+
locale,
|
|
22
|
+
token,
|
|
23
|
+
data
|
|
24
|
+
]);
|
|
25
|
+
if (url) {
|
|
11
26
|
return (React.createElement(Button, { el: "anchor", className: baseClass, buttonStyle: "secondary", url: url, newTab: true }, "Preview"));
|
|
12
27
|
}
|
|
13
28
|
return null;
|
|
@@ -13,7 +13,7 @@ const SearchFilter = (props) => {
|
|
|
13
13
|
const [search, setSearch] = useState(() => { var _a, _b; return ((_b = (_a = params === null || params === void 0 ? void 0 : params.where) === null || _a === void 0 ? void 0 : _a[fieldName]) === null || _b === void 0 ? void 0 : _b.like) || ''; });
|
|
14
14
|
const debouncedSearch = useDebounce(search, 300);
|
|
15
15
|
useEffect(() => {
|
|
16
|
-
var _a, _b;
|
|
16
|
+
var _a, _b, _c, _d, _e;
|
|
17
17
|
if (debouncedSearch !== ((_b = (_a = params === null || params === void 0 ? void 0 : params.where) === null || _a === void 0 ? void 0 : _a[fieldName]) === null || _b === void 0 ? void 0 : _b.like)) {
|
|
18
18
|
const newWhere = {
|
|
19
19
|
...(typeof (params === null || params === void 0 ? void 0 : params.where) === 'object' ? params.where : {}),
|
|
@@ -21,9 +21,12 @@ const SearchFilter = (props) => {
|
|
|
21
21
|
like: debouncedSearch,
|
|
22
22
|
},
|
|
23
23
|
};
|
|
24
|
+
if (!debouncedSearch) {
|
|
25
|
+
delete newWhere[fieldName];
|
|
26
|
+
}
|
|
24
27
|
if (handleChange)
|
|
25
28
|
handleChange(newWhere);
|
|
26
|
-
if (modifySearchQuery) {
|
|
29
|
+
if (modifySearchQuery && ((_d = (_c = params === null || params === void 0 ? void 0 : params.where) === null || _c === void 0 ? void 0 : _c[fieldName]) === null || _d === void 0 ? void 0 : _d.like) !== ((_e = newWhere === null || newWhere === void 0 ? void 0 : newWhere[fieldName]) === null || _e === void 0 ? void 0 : _e.like)) {
|
|
27
30
|
history.replace({
|
|
28
31
|
search: queryString.stringify({
|
|
29
32
|
...params,
|
|
@@ -35,7 +38,7 @@ const SearchFilter = (props) => {
|
|
|
35
38
|
}
|
|
36
39
|
}, [debouncedSearch, history, fieldName, params, handleChange, modifySearchQuery]);
|
|
37
40
|
return (React.createElement("div", { className: baseClass },
|
|
38
|
-
React.createElement("input", { className: `${baseClass}__input`, placeholder: `Search by ${fieldLabel}`, type: "text", value: search, onChange: (e) => setSearch(e.target.value) }),
|
|
41
|
+
React.createElement("input", { className: `${baseClass}__input`, placeholder: `Search by ${fieldLabel}`, type: "text", value: search || '', onChange: (e) => setSearch(e.target.value) }),
|
|
39
42
|
React.createElement(Search, null)));
|
|
40
43
|
};
|
|
41
44
|
export default SearchFilter;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import
|
|
2
|
+
import useField from '../../useField';
|
|
3
3
|
import Pill from '../../../elements/Pill';
|
|
4
4
|
import './index.scss';
|
|
5
5
|
const baseClass = 'section-title';
|
|
6
6
|
const SectionTitle = (props) => {
|
|
7
7
|
const { label, path, readOnly } = props;
|
|
8
|
-
const { value, setValue } =
|
|
8
|
+
const { value, setValue } = useField({ path });
|
|
9
9
|
const classes = [
|
|
10
10
|
baseClass,
|
|
11
11
|
].filter(Boolean).join(' ');
|
|
@@ -6,7 +6,7 @@ import DraggableSection from '../../DraggableSection';
|
|
|
6
6
|
import reducer from '../rowReducer';
|
|
7
7
|
import { useForm } from '../../Form/context';
|
|
8
8
|
import buildStateFromSchema from '../../Form/buildStateFromSchema';
|
|
9
|
-
import
|
|
9
|
+
import useField from '../../useField';
|
|
10
10
|
import Error from '../../Error';
|
|
11
11
|
import { array } from '../../../../../fields/validations';
|
|
12
12
|
import Banner from '../../../elements/Banner';
|
|
@@ -36,7 +36,7 @@ const ArrayFieldType = (props) => {
|
|
|
36
36
|
return validationResult;
|
|
37
37
|
}, [validate, maxRows, minRows, required]);
|
|
38
38
|
const [disableFormData, setDisableFormData] = useState(false);
|
|
39
|
-
const { showError, errorMessage, value, setValue, } =
|
|
39
|
+
const { showError, errorMessage, value, setValue, } = useField({
|
|
40
40
|
path,
|
|
41
41
|
validate: memoizedValidate,
|
|
42
42
|
disableFormData,
|
|
@@ -9,7 +9,7 @@ import { useForm } from '../../Form/context';
|
|
|
9
9
|
import buildStateFromSchema from '../../Form/buildStateFromSchema';
|
|
10
10
|
import DraggableSection from '../../DraggableSection';
|
|
11
11
|
import Error from '../../Error';
|
|
12
|
-
import
|
|
12
|
+
import useField from '../../useField';
|
|
13
13
|
import Popup from '../../../elements/Popup';
|
|
14
14
|
import BlockSelector from './BlockSelector';
|
|
15
15
|
import { blocks as blocksValidator } from '../../../../../fields/validations';
|
|
@@ -36,7 +36,7 @@ const Blocks = (props) => {
|
|
|
36
36
|
return validationResult;
|
|
37
37
|
}, [validate, maxRows, minRows, labels, blocks, required]);
|
|
38
38
|
const [disableFormData, setDisableFormData] = useState(false);
|
|
39
|
-
const { showError, errorMessage, value, setValue, } =
|
|
39
|
+
const { showError, errorMessage, value, setValue, } = useField({
|
|
40
40
|
path,
|
|
41
41
|
validate: memoizedValidate,
|
|
42
42
|
disableFormData,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { useCallback } from 'react';
|
|
2
|
-
import
|
|
2
|
+
import useField from '../../useField';
|
|
3
3
|
import withCondition from '../../withCondition';
|
|
4
4
|
import Error from '../../Error';
|
|
5
5
|
import { checkbox } from '../../../../../fields/validations';
|
|
@@ -14,7 +14,7 @@ const Checkbox = (props) => {
|
|
|
14
14
|
const validationResult = validate(value, { required });
|
|
15
15
|
return validationResult;
|
|
16
16
|
}, [validate, required]);
|
|
17
|
-
const { value, showError, errorMessage, setValue, } =
|
|
17
|
+
const { value, showError, errorMessage, setValue, } = useField({
|
|
18
18
|
path,
|
|
19
19
|
validate: memoizedValidate,
|
|
20
20
|
disableFormData,
|
|
@@ -3,7 +3,7 @@ import Editor from 'react-simple-code-editor';
|
|
|
3
3
|
import { highlight, languages } from 'prismjs/components/prism-core';
|
|
4
4
|
import 'prismjs/components/prism-clike';
|
|
5
5
|
import 'prismjs/components/prism-javascript';
|
|
6
|
-
import
|
|
6
|
+
import useField from '../../useField';
|
|
7
7
|
import withCondition from '../../withCondition';
|
|
8
8
|
import Label from '../../Label';
|
|
9
9
|
import Error from '../../Error';
|
|
@@ -23,7 +23,7 @@ const Code = (props) => {
|
|
|
23
23
|
const validationResult = validate(value, { minLength, maxLength, required });
|
|
24
24
|
return validationResult;
|
|
25
25
|
}, [validate, maxLength, minLength, required]);
|
|
26
|
-
const { value, showError, setValue, errorMessage, } =
|
|
26
|
+
const { value, showError, setValue, errorMessage, } = useField({
|
|
27
27
|
path,
|
|
28
28
|
validate: memoizedValidate,
|
|
29
29
|
enableDebouncedValue: true,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { useCallback } from 'react';
|
|
2
|
-
import
|
|
2
|
+
import useField from '../../useField';
|
|
3
3
|
import Label from '../../Label';
|
|
4
4
|
import Error from '../../Error';
|
|
5
5
|
import { useWatchForm } from '../../Form/context';
|
|
@@ -13,7 +13,7 @@ const ConfirmPassword = () => {
|
|
|
13
13
|
}
|
|
14
14
|
return 'Passwords do not match.';
|
|
15
15
|
}, [password]);
|
|
16
|
-
const { value, showError, setValue, errorMessage, } =
|
|
16
|
+
const { value, showError, setValue, errorMessage, } = useField({
|
|
17
17
|
path: 'confirm-password',
|
|
18
18
|
disableFormData: true,
|
|
19
19
|
validate,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useCallback } from 'react';
|
|
2
2
|
import DatePicker from '../../../elements/DatePicker';
|
|
3
3
|
import withCondition from '../../withCondition';
|
|
4
|
-
import
|
|
4
|
+
import useField from '../../useField';
|
|
5
5
|
import Label from '../../Label';
|
|
6
6
|
import Error from '../../Error';
|
|
7
7
|
import FieldDescription from '../../FieldDescription';
|
|
@@ -15,7 +15,7 @@ const DateTime = (props) => {
|
|
|
15
15
|
const validationResult = validate(value, { required });
|
|
16
16
|
return validationResult;
|
|
17
17
|
}, [validate, required]);
|
|
18
|
-
const { value, showError, errorMessage, setValue, } =
|
|
18
|
+
const { value, showError, errorMessage, setValue, } = useField({
|
|
19
19
|
path,
|
|
20
20
|
validate: memoizedValidate,
|
|
21
21
|
condition,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { useCallback } from 'react';
|
|
2
2
|
import withCondition from '../../withCondition';
|
|
3
|
-
import
|
|
3
|
+
import useField from '../../useField';
|
|
4
4
|
import Label from '../../Label';
|
|
5
5
|
import Error from '../../Error';
|
|
6
6
|
import FieldDescription from '../../FieldDescription';
|
|
@@ -13,7 +13,7 @@ const Email = (props) => {
|
|
|
13
13
|
const validationResult = validate(value, { required });
|
|
14
14
|
return validationResult;
|
|
15
15
|
}, [validate, required]);
|
|
16
|
-
const fieldType =
|
|
16
|
+
const fieldType = useField({
|
|
17
17
|
path,
|
|
18
18
|
validate: memoizedValidate,
|
|
19
19
|
enableDebouncedValue: true,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React, { useEffect } from 'react';
|
|
2
|
-
import
|
|
2
|
+
import useField from '../../useField';
|
|
3
3
|
import withCondition from '../../withCondition';
|
|
4
4
|
const HiddenInput = (props) => {
|
|
5
5
|
const { name, path: pathFromProps, value: valueFromProps, modifyForm = true, } = props;
|
|
6
6
|
const path = pathFromProps || name;
|
|
7
|
-
const { value, setValue } =
|
|
7
|
+
const { value, setValue } = useField({
|
|
8
8
|
path,
|
|
9
9
|
});
|
|
10
10
|
useEffect(() => {
|