@amoa/casting 0.1.5 → 0.1.7
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/dist/export/index.js +10 -9
- package/dist/export/index.js.map +1 -0
- package/dist/form/buttons/index.js +3 -2
- package/dist/form/buttons/index.js.map +1 -0
- package/dist/form/buttons/index.module.css.js +1 -0
- package/dist/form/buttons/index.module.css.js.map +1 -0
- package/dist/form/caption/index.js +3 -2
- package/dist/form/caption/index.js.map +1 -0
- package/dist/form/caption/index.module.css.js +1 -0
- package/dist/form/caption/index.module.css.js.map +1 -0
- package/dist/form/description/index.js +3 -2
- package/dist/form/description/index.js.map +1 -0
- package/dist/form/description/index.module.css.js +1 -0
- package/dist/form/description/index.module.css.js.map +1 -0
- package/dist/form/email/index.js +4 -3
- package/dist/form/email/index.js.map +1 -0
- package/dist/form/index.js +5 -4
- package/dist/form/index.js.map +1 -0
- package/dist/form/index.module.css.js +1 -0
- package/dist/form/index.module.css.js.map +1 -0
- package/dist/form/inputs/index.js +3 -2
- package/dist/form/inputs/index.js.map +1 -0
- package/dist/form/inputs/index.module.css.js +1 -0
- package/dist/form/inputs/index.module.css.js.map +1 -0
- package/dist/form/password/index.js +4 -3
- package/dist/form/password/index.js.map +1 -0
- package/dist/index.css +1 -1708
- package/dist/waiter/index.js +12 -13
- package/dist/waiter/index.js.map +1 -0
- package/dist/waiter/index.module.css.js +1 -0
- package/dist/waiter/index.module.css.js.map +1 -0
- package/package.json +4 -3
- package/dist/_virtual/_commonjsHelpers.js +0 -5
- package/dist/_virtual/_interop_require_default.js +0 -3
- package/dist/_virtual/_interop_require_wildcard.js +0 -3
- package/dist/_virtual/action-async-storage-instance.js +0 -3
- package/dist/_virtual/action-async-storage.external.js +0 -3
- package/dist/_virtual/add-base-path.js +0 -3
- package/dist/_virtual/add-locale.js +0 -3
- package/dist/_virtual/add-locale2.js +0 -3
- package/dist/_virtual/add-path-prefix.js +0 -3
- package/dist/_virtual/app-paths.js +0 -3
- package/dist/_virtual/app-router-context.shared-runtime.js +0 -3
- package/dist/_virtual/app-router-headers.js +0 -3
- package/dist/_virtual/app.js +0 -3
- package/dist/_virtual/async-local-storage.js +0 -3
- package/dist/_virtual/bailout-to-csr.js +0 -3
- package/dist/_virtual/boundary-constants.js +0 -3
- package/dist/_virtual/constants.js +0 -3
- package/dist/_virtual/deployment-id.js +0 -3
- package/dist/_virtual/detect-domain-locale.js +0 -3
- package/dist/_virtual/detect-domain-locale2.js +0 -3
- package/dist/_virtual/dynamic-rendering-utils.js +0 -3
- package/dist/_virtual/dynamic-rendering.js +0 -3
- package/dist/_virtual/ensure-leading-slash.js +0 -3
- package/dist/_virtual/error-once.js +0 -3
- package/dist/_virtual/escape-regexp.js +0 -3
- package/dist/_virtual/find-closest-quality.js +0 -3
- package/dist/_virtual/forbidden.js +0 -3
- package/dist/_virtual/format-url.js +0 -3
- package/dist/_virtual/get-domain-locale.js +0 -3
- package/dist/_virtual/get-dynamic-param.js +0 -3
- package/dist/_virtual/get-img-props.js +0 -3
- package/dist/_virtual/get-segment-param.js +0 -3
- package/dist/_virtual/has-base-path.js +0 -3
- package/dist/_virtual/head-manager-context.shared-runtime.js +0 -3
- package/dist/_virtual/head.js +0 -3
- package/dist/_virtual/hooks-client-context.shared-runtime.js +0 -3
- package/dist/_virtual/hooks-server-context.js +0 -3
- package/dist/_virtual/http-access-fallback.js +0 -3
- package/dist/_virtual/image-blur-svg.js +0 -3
- package/dist/_virtual/image-component.js +0 -3
- package/dist/_virtual/image-config-context.shared-runtime.js +0 -3
- package/dist/_virtual/image-config.js +0 -3
- package/dist/_virtual/image-external.js +0 -3
- package/dist/_virtual/image-loader.js +0 -3
- package/dist/_virtual/image.js +0 -7
- package/dist/_virtual/index.js +0 -3
- package/dist/_virtual/index2.js +0 -3
- package/dist/_virtual/index3.js +0 -3
- package/dist/_virtual/interception-prefix-from-param-type.js +0 -3
- package/dist/_virtual/interception-routes.js +0 -3
- package/dist/_virtual/interpolate-as.js +0 -3
- package/dist/_virtual/invariant-error.js +0 -3
- package/dist/_virtual/is-dynamic.js +0 -3
- package/dist/_virtual/is-local-url.js +0 -3
- package/dist/_virtual/is-next-router-error.js +0 -3
- package/dist/_virtual/is-postpone.js +0 -3
- package/dist/_virtual/jsx-runtime.js +0 -5
- package/dist/_virtual/jsx-runtime2.js +0 -3
- package/dist/_virtual/link.js +0 -7
- package/dist/_virtual/link2.js +0 -3
- package/dist/_virtual/match-local-pattern.js +0 -3
- package/dist/_virtual/match-remote-pattern.js +0 -3
- package/dist/_virtual/navigation.js +0 -3
- package/dist/_virtual/navigation.react-server.js +0 -3
- package/dist/_virtual/navigation2.js +0 -3
- package/dist/_virtual/normalize-locale-path.js +0 -3
- package/dist/_virtual/normalize-locale-path2.js +0 -3
- package/dist/_virtual/normalize-trailing-slash.js +0 -3
- package/dist/_virtual/not-found.js +0 -3
- package/dist/_virtual/omit.js +0 -3
- package/dist/_virtual/parse-loader-tree.js +0 -3
- package/dist/_virtual/parse-path.js +0 -3
- package/dist/_virtual/path-has-prefix.js +0 -3
- package/dist/_virtual/querystring.js +0 -3
- package/dist/_virtual/react-jsx-runtime.development.js +0 -3
- package/dist/_virtual/react-jsx-runtime.production.js +0 -3
- package/dist/_virtual/readonly-url-search-params.js +0 -3
- package/dist/_virtual/redirect-error.js +0 -3
- package/dist/_virtual/redirect-status-code.js +0 -3
- package/dist/_virtual/redirect.js +0 -3
- package/dist/_virtual/remove-trailing-slash.js +0 -3
- package/dist/_virtual/request-idle-callback.js +0 -3
- package/dist/_virtual/resolve-href.js +0 -3
- package/dist/_virtual/resolve-param-value.js +0 -3
- package/dist/_virtual/route-match-utils.js +0 -3
- package/dist/_virtual/route-matcher.js +0 -3
- package/dist/_virtual/route-pattern-normalizer.js +0 -3
- package/dist/_virtual/route-regex.js +0 -3
- package/dist/_virtual/router-context.shared-runtime.js +0 -3
- package/dist/_virtual/scheduler.js +0 -3
- package/dist/_virtual/segment.js +0 -3
- package/dist/_virtual/server-inserted-html.shared-runtime.js +0 -3
- package/dist/_virtual/side-effect.js +0 -3
- package/dist/_virtual/sorted-routes.js +0 -3
- package/dist/_virtual/static-generation-bailout.js +0 -3
- package/dist/_virtual/unauthorized.js +0 -3
- package/dist/_virtual/unrecognized-action-error.js +0 -3
- package/dist/_virtual/unstable-rethrow.browser.js +0 -3
- package/dist/_virtual/unstable-rethrow.js +0 -3
- package/dist/_virtual/unstable-rethrow.server.js +0 -3
- package/dist/_virtual/use-intersection.js +0 -3
- package/dist/_virtual/use-merged-ref.js +0 -3
- package/dist/_virtual/utils.js +0 -3
- package/dist/_virtual/warn-once.js +0 -3
- package/dist/_virtual/work-async-storage-instance.js +0 -3
- package/dist/_virtual/work-async-storage.external.js +0 -3
- package/dist/_virtual/work-unit-async-storage-instance.js +0 -3
- package/dist/_virtual/work-unit-async-storage.external.js +0 -3
- package/dist/config/config.json.js +0 -37
- package/dist/node_modules/@swc/helpers/cjs/_interop_require_default.js +0 -16
- package/dist/node_modules/@swc/helpers/cjs/_interop_require_wildcard.js +0 -48
- package/dist/node_modules/next/dist/client/add-base-path.js +0 -38
- package/dist/node_modules/next/dist/client/add-locale.js +0 -39
- package/dist/node_modules/next/dist/client/components/app-router-headers.js +0 -112
- package/dist/node_modules/next/dist/client/components/forbidden.js +0 -62
- package/dist/node_modules/next/dist/client/components/hooks-server-context.js +0 -50
- package/dist/node_modules/next/dist/client/components/http-access-fallback/http-access-fallback.js +0 -77
- package/dist/node_modules/next/dist/client/components/is-next-router-error.js +0 -37
- package/dist/node_modules/next/dist/client/components/navigation.js +0 -198
- package/dist/node_modules/next/dist/client/components/navigation.react-server.js +0 -80
- package/dist/node_modules/next/dist/client/components/not-found.js +0 -56
- package/dist/node_modules/next/dist/client/components/readonly-url-search-params.js +0 -58
- package/dist/node_modules/next/dist/client/components/redirect-error.js +0 -60
- package/dist/node_modules/next/dist/client/components/redirect-status-code.js +0 -36
- package/dist/node_modules/next/dist/client/components/redirect.js +0 -98
- package/dist/node_modules/next/dist/client/components/static-generation-bailout.js +0 -50
- package/dist/node_modules/next/dist/client/components/unauthorized.js +0 -63
- package/dist/node_modules/next/dist/client/components/unrecognized-action-error.js +0 -47
- package/dist/node_modules/next/dist/client/components/unstable-rethrow.browser.js +0 -42
- package/dist/node_modules/next/dist/client/components/unstable-rethrow.js +0 -41
- package/dist/node_modules/next/dist/client/components/unstable-rethrow.server.js +0 -50
- package/dist/node_modules/next/dist/client/detect-domain-locale.js +0 -36
- package/dist/node_modules/next/dist/client/get-domain-locale.js +0 -51
- package/dist/node_modules/next/dist/client/has-base-path.js +0 -36
- package/dist/node_modules/next/dist/client/image-component.js +0 -343
- package/dist/node_modules/next/dist/client/link.js +0 -466
- package/dist/node_modules/next/dist/client/normalize-locale-path.js +0 -40
- package/dist/node_modules/next/dist/client/normalize-trailing-slash.js +0 -54
- package/dist/node_modules/next/dist/client/request-idle-callback.js +0 -52
- package/dist/node_modules/next/dist/client/resolve-href.js +0 -124
- package/dist/node_modules/next/dist/client/use-intersection.js +0 -126
- package/dist/node_modules/next/dist/client/use-merged-ref.js +0 -79
- package/dist/node_modules/next/dist/compiled/path-to-regexp/index.js +0 -439
- package/dist/node_modules/next/dist/compiled/picomatch/index.js +0 -1662
- package/dist/node_modules/next/dist/lib/constants.js +0 -339
- package/dist/node_modules/next/dist/lib/framework/boundary-constants.js +0 -41
- package/dist/node_modules/next/dist/lib/route-pattern-normalizer.js +0 -114
- package/dist/node_modules/next/dist/lib/scheduler.js +0 -69
- package/dist/node_modules/next/dist/server/app-render/action-async-storage-instance.js +0 -26
- package/dist/node_modules/next/dist/server/app-render/action-async-storage.external.js +0 -25
- package/dist/node_modules/next/dist/server/app-render/async-local-storage.js +0 -83
- package/dist/node_modules/next/dist/server/app-render/dynamic-rendering.js +0 -804
- package/dist/node_modules/next/dist/server/app-render/work-async-storage-instance.js +0 -26
- package/dist/node_modules/next/dist/server/app-render/work-async-storage.external.js +0 -25
- package/dist/node_modules/next/dist/server/app-render/work-unit-async-storage-instance.js +0 -26
- package/dist/node_modules/next/dist/server/app-render/work-unit-async-storage.external.js +0 -221
- package/dist/node_modules/next/dist/server/dynamic-rendering-utils.js +0 -90
- package/dist/node_modules/next/dist/server/lib/router-utils/is-postpone.js +0 -27
- package/dist/node_modules/next/dist/shared/lib/app-router-context.shared-runtime.js +0 -56
- package/dist/node_modules/next/dist/shared/lib/deployment-id.js +0 -41
- package/dist/node_modules/next/dist/shared/lib/escape-regexp.js +0 -32
- package/dist/node_modules/next/dist/shared/lib/find-closest-quality.js +0 -30
- package/dist/node_modules/next/dist/shared/lib/get-img-props.js +0 -617
- package/dist/node_modules/next/dist/shared/lib/head-manager-context.shared-runtime.js +0 -31
- package/dist/node_modules/next/dist/shared/lib/head.js +0 -177
- package/dist/node_modules/next/dist/shared/lib/hooks-client-context.shared-runtime.js +0 -65
- package/dist/node_modules/next/dist/shared/lib/i18n/detect-domain-locale.js +0 -36
- package/dist/node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js +0 -66
- package/dist/node_modules/next/dist/shared/lib/image-blur-svg.js +0 -42
- package/dist/node_modules/next/dist/shared/lib/image-config-context.shared-runtime.js +0 -33
- package/dist/node_modules/next/dist/shared/lib/image-config.js +0 -56
- package/dist/node_modules/next/dist/shared/lib/image-external.js +0 -60
- package/dist/node_modules/next/dist/shared/lib/image-loader.js +0 -119
- package/dist/node_modules/next/dist/shared/lib/invariant-error.js +0 -29
- package/dist/node_modules/next/dist/shared/lib/lazy-dynamic/bailout-to-csr.js +0 -43
- package/dist/node_modules/next/dist/shared/lib/match-local-pattern.js +0 -54
- package/dist/node_modules/next/dist/shared/lib/match-remote-pattern.js +0 -71
- package/dist/node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.js +0 -31
- package/dist/node_modules/next/dist/shared/lib/router/routes/app.js +0 -130
- package/dist/node_modules/next/dist/shared/lib/router/utils/add-locale.js +0 -41
- package/dist/node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js +0 -36
- package/dist/node_modules/next/dist/shared/lib/router/utils/app-paths.js +0 -61
- package/dist/node_modules/next/dist/shared/lib/router/utils/format-url.js +0 -88
- package/dist/node_modules/next/dist/shared/lib/router/utils/get-dynamic-param.js +0 -176
- package/dist/node_modules/next/dist/shared/lib/router/utils/get-segment-param.js +0 -89
- package/dist/node_modules/next/dist/shared/lib/router/utils/index.js +0 -38
- package/dist/node_modules/next/dist/shared/lib/router/utils/interception-prefix-from-param-type.js +0 -44
- package/dist/node_modules/next/dist/shared/lib/router/utils/interception-routes.js +0 -109
- package/dist/node_modules/next/dist/shared/lib/router/utils/interpolate-as.js +0 -71
- package/dist/node_modules/next/dist/shared/lib/router/utils/is-dynamic.js +0 -38
- package/dist/node_modules/next/dist/shared/lib/router/utils/is-local-url.js +0 -39
- package/dist/node_modules/next/dist/shared/lib/router/utils/omit.js +0 -32
- package/dist/node_modules/next/dist/shared/lib/router/utils/parse-loader-tree.js +0 -46
- package/dist/node_modules/next/dist/shared/lib/router/utils/parse-path.js +0 -46
- package/dist/node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js +0 -34
- package/dist/node_modules/next/dist/shared/lib/router/utils/querystring.js +0 -82
- package/dist/node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js +0 -34
- package/dist/node_modules/next/dist/shared/lib/router/utils/resolve-param-value.js +0 -128
- package/dist/node_modules/next/dist/shared/lib/router/utils/route-match-utils.js +0 -122
- package/dist/node_modules/next/dist/shared/lib/router/utils/route-matcher.js +0 -61
- package/dist/node_modules/next/dist/shared/lib/router/utils/route-regex.js +0 -312
- package/dist/node_modules/next/dist/shared/lib/router/utils/sorted-routes.js +0 -246
- package/dist/node_modules/next/dist/shared/lib/router-context.shared-runtime.js +0 -31
- package/dist/node_modules/next/dist/shared/lib/segment.js +0 -102
- package/dist/node_modules/next/dist/shared/lib/server-inserted-html.shared-runtime.js +0 -44
- package/dist/node_modules/next/dist/shared/lib/side-effect.js +0 -78
- package/dist/node_modules/next/dist/shared/lib/utils/error-once.js +0 -33
- package/dist/node_modules/next/dist/shared/lib/utils/warn-once.js +0 -33
- package/dist/node_modules/next/dist/shared/lib/utils.js +0 -192
- package/dist/node_modules/next/image.js +0 -13
- package/dist/node_modules/next/link.js +0 -13
- package/dist/node_modules/next/navigation.js +0 -13
- package/dist/node_modules/react/cjs/react-jsx-runtime.development.js +0 -240
- package/dist/node_modules/react/cjs/react-jsx-runtime.production.js +0 -44
- package/dist/node_modules/react/jsx-runtime.js +0 -19
- package/dist/node_modules/style-inject/dist/style-inject.es.js +0 -26
- package/dist/packages/carving/src/carving.js +0 -34
- package/dist/packages/carving/src/condo.js +0 -17
- package/dist/packages/carving/src/logos/amoa.js +0 -17
- package/dist/packages/forge/src/classes.js +0 -17
- package/dist/packages/forge/src/dates/date.js +0 -8
- package/dist/packages/forge/src/dates/day.js +0 -7
- package/dist/packages/forge/src/dates/index.js +0 -31
- package/dist/packages/forge/src/dates/month.js +0 -35
- package/dist/packages/forge/src/dates/year.js +0 -16
- package/dist/packages/forge/src/fetcher/index.js +0 -37
- package/dist/packages/forge/src/fetcher/querystring.js +0 -9
- package/dist/packages/forge/src/files.js +0 -17
- package/dist/packages/forge/src/numbers/index.js +0 -5
- package/dist/packages/forge/src/strings/characters.js +0 -3
- package/dist/packages/forge/src/strings/diacritics.js +0 -261
- package/dist/packages/forge/src/strings/index.js +0 -24
- package/dist/packages/hooks/src/use-debounce.js +0 -19
- package/dist/packages/hooks/src/use-tooltip.js +0 -27
- package/dist/packages/ingots/src/address/api/form.js +0 -12
- package/dist/packages/ingots/src/address/config.json.js +0 -16
- package/dist/packages/ingots/src/address/index.js +0 -115
- package/dist/packages/ingots/src/address/index.module.css.js +0 -3
- package/dist/packages/ingots/src/address/service.js +0 -41
- package/dist/packages/ingots/src/backdrop/index.js +0 -18
- package/dist/packages/ingots/src/backdrop/index.module.css.js +0 -3
- package/dist/packages/ingots/src/button/index.js +0 -56
- package/dist/packages/ingots/src/button/index.module.css.js +0 -3
- package/dist/packages/ingots/src/checkbox/index.js +0 -47
- package/dist/packages/ingots/src/checkbox/index.module.css.js +0 -3
- package/dist/packages/ingots/src/date/erase/index.js +0 -22
- package/dist/packages/ingots/src/date/erase/index.module.css.js +0 -3
- package/dist/packages/ingots/src/date/input/index.js +0 -113
- package/dist/packages/ingots/src/date/input/index.module.css.js +0 -3
- package/dist/packages/ingots/src/date/picker/day/index.js +0 -35
- package/dist/packages/ingots/src/date/picker/day/index.module.css.js +0 -3
- package/dist/packages/ingots/src/date/picker/days/index.js +0 -59
- package/dist/packages/ingots/src/date/picker/days/index.module.css.js +0 -3
- package/dist/packages/ingots/src/date/picker/handle/index.js +0 -40
- package/dist/packages/ingots/src/date/picker/handle/index.module.css.js +0 -3
- package/dist/packages/ingots/src/date/picker/index.js +0 -154
- package/dist/packages/ingots/src/date/picker/index.module.css.js +0 -3
- package/dist/packages/ingots/src/date/picker/menu/index.js +0 -32
- package/dist/packages/ingots/src/date/picker/menu/index.module.css.js +0 -3
- package/dist/packages/ingots/src/date/picker/menu/item.js +0 -30
- package/dist/packages/ingots/src/date/picker/menu/item.module.css.js +0 -3
- package/dist/packages/ingots/src/file/api/index.js +0 -14
- package/dist/packages/ingots/src/file/card/index.js +0 -65
- package/dist/packages/ingots/src/file/card/index.module.css.js +0 -3
- package/dist/packages/ingots/src/file/index.js +0 -34
- package/dist/packages/ingots/src/file/index.module.css.js +0 -3
- package/dist/packages/ingots/src/file/input/index.js +0 -261
- package/dist/packages/ingots/src/file/input/index.module.css.js +0 -3
- package/dist/packages/ingots/src/input/index.js +0 -75
- package/dist/packages/ingots/src/input/src/validation/index.js +0 -3
- package/dist/packages/ingots/src/loader/index.js +0 -23
- package/dist/packages/ingots/src/loader/index.module.css.js +0 -3
- package/dist/packages/ingots/src/loader/variants/spinner/index.js +0 -31
- package/dist/packages/ingots/src/loader/variants/spinner/index.module.css.js +0 -3
- package/dist/packages/ingots/src/select/card/index.js +0 -33
- package/dist/packages/ingots/src/select/card/index.module.css.js +0 -3
- package/dist/packages/ingots/src/select/category/index.js +0 -13
- package/dist/packages/ingots/src/select/category/index.module.css.js +0 -3
- package/dist/packages/ingots/src/select/content/index.js +0 -46
- package/dist/packages/ingots/src/select/index.js +0 -155
- package/dist/packages/ingots/src/select/index.module.css.js +0 -3
- package/dist/packages/ingots/src/select/option/index.js +0 -35
- package/dist/packages/ingots/src/select/option/index.module.css.js +0 -3
- package/dist/packages/ingots/src/select/options/index.js +0 -59
- package/dist/packages/ingots/src/select/options/index.module.css.js +0 -3
- package/dist/packages/ingots/src/snackbar/context.js +0 -9
- package/dist/packages/ingots/src/tag/index.js +0 -16
- package/dist/packages/ingots/src/tag/index.module.css.js +0 -3
- package/dist/packages/ingots/src/text/index.js +0 -92
- package/dist/packages/ingots/src/text/index.module.css.js +0 -3
- package/dist/packages/ingots/src/textarea/index.js +0 -62
- package/dist/packages/ingots/src/textarea/index.module.css.js +0 -3
- package/dist/packages/ingots/src/toggle/index.js +0 -43
- package/dist/packages/ingots/src/toggle/index.module.css.js +0 -3
- package/dist/packages/runes/src/icon.js +0 -16
- package/dist/packages/runes/src/paths/alert.js +0 -18
- package/dist/packages/runes/src/paths/arrow/path.js +0 -18
- package/dist/packages/runes/src/paths/calendar.js +0 -18
- package/dist/packages/runes/src/paths/check/fill.js +0 -18
- package/dist/packages/runes/src/paths/check/regular.js +0 -18
- package/dist/packages/runes/src/paths/chevron/down.js +0 -18
- package/dist/packages/runes/src/paths/chevron/left.js +0 -18
- package/dist/packages/runes/src/paths/chevron/right.js +0 -18
- package/dist/packages/runes/src/paths/click.js +0 -18
- package/dist/packages/runes/src/paths/cross/regular.js +0 -16
- package/dist/packages/runes/src/paths/download.js +0 -18
- package/dist/packages/runes/src/paths/file.js +0 -18
- package/dist/packages/runes/src/paths/link.js +0 -23
- package/dist/packages/wares/src/authentication/index.js +0 -11
|
@@ -1,176 +0,0 @@
|
|
|
1
|
-
import { __exports as getDynamicParam } from '../../../../../../../_virtual/get-dynamic-param.js';
|
|
2
|
-
import { __require as requireInvariantError } from '../../invariant-error.js';
|
|
3
|
-
import { __require as requireParseLoaderTree } from './parse-loader-tree.js';
|
|
4
|
-
import { __require as requireApp } from '../routes/app.js';
|
|
5
|
-
import { __require as requireResolveParamValue } from './resolve-param-value.js';
|
|
6
|
-
|
|
7
|
-
var hasRequiredGetDynamicParam;
|
|
8
|
-
|
|
9
|
-
function requireGetDynamicParam () {
|
|
10
|
-
if (hasRequiredGetDynamicParam) return getDynamicParam;
|
|
11
|
-
hasRequiredGetDynamicParam = 1;
|
|
12
|
-
(function (exports$1) {
|
|
13
|
-
|
|
14
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
15
|
-
value: true
|
|
16
|
-
});
|
|
17
|
-
function _export(target, all) {
|
|
18
|
-
for (var name in all) Object.defineProperty(target, name, {
|
|
19
|
-
enumerable: true,
|
|
20
|
-
get: all[name]
|
|
21
|
-
});
|
|
22
|
-
}
|
|
23
|
-
_export(exports$1, {
|
|
24
|
-
PARAMETER_PATTERN: function () {
|
|
25
|
-
return PARAMETER_PATTERN;
|
|
26
|
-
},
|
|
27
|
-
getDynamicParam: function () {
|
|
28
|
-
return getDynamicParam;
|
|
29
|
-
},
|
|
30
|
-
interpolateParallelRouteParams: function () {
|
|
31
|
-
return interpolateParallelRouteParams;
|
|
32
|
-
},
|
|
33
|
-
parseMatchedParameter: function () {
|
|
34
|
-
return parseMatchedParameter;
|
|
35
|
-
},
|
|
36
|
-
parseParameter: function () {
|
|
37
|
-
return parseParameter;
|
|
38
|
-
}
|
|
39
|
-
});
|
|
40
|
-
const _invarianterror = requireInvariantError();
|
|
41
|
-
const _parseloadertree = requireParseLoaderTree();
|
|
42
|
-
const _app = requireApp();
|
|
43
|
-
const _resolveparamvalue = requireResolveParamValue();
|
|
44
|
-
/**
|
|
45
|
-
* Gets the value of a param from the params object. This correctly handles the
|
|
46
|
-
* case where the param is a fallback route param and encodes the resulting
|
|
47
|
-
* value.
|
|
48
|
-
*
|
|
49
|
-
* @param interpolatedParams - The params object.
|
|
50
|
-
* @param segmentKey - The key of the segment.
|
|
51
|
-
* @param fallbackRouteParams - The fallback route params.
|
|
52
|
-
* @returns The value of the param.
|
|
53
|
-
*/
|
|
54
|
-
function getParamValue(interpolatedParams, segmentKey, fallbackRouteParams) {
|
|
55
|
-
let value = interpolatedParams[segmentKey];
|
|
56
|
-
if (fallbackRouteParams?.has(segmentKey)) {
|
|
57
|
-
// We know that the fallback route params has the segment key because we
|
|
58
|
-
// checked that above.
|
|
59
|
-
const [searchValue] = fallbackRouteParams.get(segmentKey);
|
|
60
|
-
value = searchValue;
|
|
61
|
-
} else if (Array.isArray(value)) {
|
|
62
|
-
value = value.map(i => encodeURIComponent(i));
|
|
63
|
-
} else if (typeof value === 'string') {
|
|
64
|
-
value = encodeURIComponent(value);
|
|
65
|
-
}
|
|
66
|
-
return value;
|
|
67
|
-
}
|
|
68
|
-
function interpolateParallelRouteParams(loaderTree, params, pagePath, fallbackRouteParams) {
|
|
69
|
-
const interpolated = structuredClone(params);
|
|
70
|
-
// Stack-based traversal with depth tracking
|
|
71
|
-
const stack = [{
|
|
72
|
-
tree: loaderTree,
|
|
73
|
-
depth: 0
|
|
74
|
-
}];
|
|
75
|
-
// Parse the route from the provided page path.
|
|
76
|
-
const route = (0, _app.parseAppRoute)(pagePath, true);
|
|
77
|
-
while (stack.length > 0) {
|
|
78
|
-
const {
|
|
79
|
-
tree,
|
|
80
|
-
depth
|
|
81
|
-
} = stack.pop();
|
|
82
|
-
const {
|
|
83
|
-
segment,
|
|
84
|
-
parallelRoutes
|
|
85
|
-
} = (0, _parseloadertree.parseLoaderTree)(tree);
|
|
86
|
-
const appSegment = (0, _app.parseAppRouteSegment)(segment);
|
|
87
|
-
if (appSegment?.type === 'dynamic' && !interpolated.hasOwnProperty(appSegment.param.paramName) &&
|
|
88
|
-
// If the param is in the fallback route params, we don't need to
|
|
89
|
-
// interpolate it because it's already marked as being unknown.
|
|
90
|
-
!fallbackRouteParams?.has(appSegment.param.paramName)) {
|
|
91
|
-
const {
|
|
92
|
-
paramName,
|
|
93
|
-
paramType
|
|
94
|
-
} = appSegment.param;
|
|
95
|
-
const paramValue = (0, _resolveparamvalue.resolveParamValue)(paramName, paramType, depth, route, interpolated);
|
|
96
|
-
if (paramValue !== undefined) {
|
|
97
|
-
interpolated[paramName] = paramValue;
|
|
98
|
-
} else if (paramType !== 'optional-catchall') {
|
|
99
|
-
throw Object.defineProperty(new _invarianterror.InvariantError(`Could not resolve param value for segment: ${paramName}`), "__NEXT_ERROR_CODE", {
|
|
100
|
-
value: "E932",
|
|
101
|
-
enumerable: false,
|
|
102
|
-
configurable: true
|
|
103
|
-
});
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
// Calculate next depth - increment if this is not a route group and not empty
|
|
107
|
-
let nextDepth = depth;
|
|
108
|
-
if (appSegment && appSegment.type !== 'route-group' && appSegment.type !== 'parallel-route') {
|
|
109
|
-
nextDepth++;
|
|
110
|
-
}
|
|
111
|
-
// Add all parallel routes to the stack for processing
|
|
112
|
-
for (const parallelRoute of Object.values(parallelRoutes)) {
|
|
113
|
-
stack.push({
|
|
114
|
-
tree: parallelRoute,
|
|
115
|
-
depth: nextDepth
|
|
116
|
-
});
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
return interpolated;
|
|
120
|
-
}
|
|
121
|
-
function getDynamicParam(interpolatedParams, segmentKey, dynamicParamType, fallbackRouteParams) {
|
|
122
|
-
let value = getParamValue(interpolatedParams, segmentKey, fallbackRouteParams);
|
|
123
|
-
// handle the case where an optional catchall does not have a value,
|
|
124
|
-
// e.g. `/dashboard/[[...slug]]` when requesting `/dashboard`
|
|
125
|
-
if (!value || value.length === 0) {
|
|
126
|
-
if (dynamicParamType === 'oc') {
|
|
127
|
-
return {
|
|
128
|
-
param: segmentKey,
|
|
129
|
-
value: null,
|
|
130
|
-
type: dynamicParamType,
|
|
131
|
-
treeSegment: [segmentKey, '', dynamicParamType]
|
|
132
|
-
};
|
|
133
|
-
}
|
|
134
|
-
throw Object.defineProperty(new _invarianterror.InvariantError(`Missing value for segment key: "${segmentKey}" with dynamic param type: ${dynamicParamType}`), "__NEXT_ERROR_CODE", {
|
|
135
|
-
value: "E864",
|
|
136
|
-
enumerable: false,
|
|
137
|
-
configurable: true
|
|
138
|
-
});
|
|
139
|
-
}
|
|
140
|
-
return {
|
|
141
|
-
param: segmentKey,
|
|
142
|
-
// The value that is passed to user code.
|
|
143
|
-
value,
|
|
144
|
-
// The value that is rendered in the router tree.
|
|
145
|
-
treeSegment: [segmentKey, Array.isArray(value) ? value.join('/') : value, dynamicParamType],
|
|
146
|
-
type: dynamicParamType
|
|
147
|
-
};
|
|
148
|
-
}
|
|
149
|
-
const PARAMETER_PATTERN = /^([^[]*)\[((?:\[[^\]]*\])|[^\]]+)\](.*)$/;
|
|
150
|
-
function parseParameter(param) {
|
|
151
|
-
const match = param.match(PARAMETER_PATTERN);
|
|
152
|
-
if (!match) {
|
|
153
|
-
return parseMatchedParameter(param);
|
|
154
|
-
}
|
|
155
|
-
return parseMatchedParameter(match[2]);
|
|
156
|
-
}
|
|
157
|
-
function parseMatchedParameter(param) {
|
|
158
|
-
const optional = param.startsWith('[') && param.endsWith(']');
|
|
159
|
-
if (optional) {
|
|
160
|
-
param = param.slice(1, -1);
|
|
161
|
-
}
|
|
162
|
-
const repeat = param.startsWith('...');
|
|
163
|
-
if (repeat) {
|
|
164
|
-
param = param.slice(3);
|
|
165
|
-
}
|
|
166
|
-
return {
|
|
167
|
-
key: param,
|
|
168
|
-
repeat,
|
|
169
|
-
optional
|
|
170
|
-
};
|
|
171
|
-
}
|
|
172
|
-
} (getDynamicParam));
|
|
173
|
-
return getDynamicParam;
|
|
174
|
-
}
|
|
175
|
-
|
|
176
|
-
export { requireGetDynamicParam as __require };
|
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
import { __exports as getSegmentParam } from '../../../../../../../_virtual/get-segment-param.js';
|
|
2
|
-
import { __require as requireInterceptionRoutes } from './interception-routes.js';
|
|
3
|
-
|
|
4
|
-
var hasRequiredGetSegmentParam;
|
|
5
|
-
|
|
6
|
-
function requireGetSegmentParam () {
|
|
7
|
-
if (hasRequiredGetSegmentParam) return getSegmentParam;
|
|
8
|
-
hasRequiredGetSegmentParam = 1;
|
|
9
|
-
(function (exports$1) {
|
|
10
|
-
|
|
11
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
12
|
-
value: true
|
|
13
|
-
});
|
|
14
|
-
function _export(target, all) {
|
|
15
|
-
for (var name in all) Object.defineProperty(target, name, {
|
|
16
|
-
enumerable: true,
|
|
17
|
-
get: all[name]
|
|
18
|
-
});
|
|
19
|
-
}
|
|
20
|
-
_export(exports$1, {
|
|
21
|
-
getParamProperties: function () {
|
|
22
|
-
return getParamProperties;
|
|
23
|
-
},
|
|
24
|
-
getSegmentParam: function () {
|
|
25
|
-
return getSegmentParam;
|
|
26
|
-
},
|
|
27
|
-
isCatchAll: function () {
|
|
28
|
-
return isCatchAll;
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
const _interceptionroutes = requireInterceptionRoutes();
|
|
32
|
-
function getSegmentParam(segment) {
|
|
33
|
-
const interceptionMarker = _interceptionroutes.INTERCEPTION_ROUTE_MARKERS.find(marker => segment.startsWith(marker));
|
|
34
|
-
// if an interception marker is part of the path segment, we need to jump ahead
|
|
35
|
-
// to the relevant portion for param parsing
|
|
36
|
-
if (interceptionMarker) {
|
|
37
|
-
segment = segment.slice(interceptionMarker.length);
|
|
38
|
-
}
|
|
39
|
-
if (segment.startsWith('[[...') && segment.endsWith(']]')) {
|
|
40
|
-
return {
|
|
41
|
-
// TODO-APP: Optional catchall does not currently work with parallel routes,
|
|
42
|
-
// so for now aren't handling a potential interception marker.
|
|
43
|
-
paramType: 'optional-catchall',
|
|
44
|
-
paramName: segment.slice(5, -2)
|
|
45
|
-
};
|
|
46
|
-
}
|
|
47
|
-
if (segment.startsWith('[...') && segment.endsWith(']')) {
|
|
48
|
-
return {
|
|
49
|
-
paramType: interceptionMarker ? `catchall-intercepted-${interceptionMarker}` : 'catchall',
|
|
50
|
-
paramName: segment.slice(4, -1)
|
|
51
|
-
};
|
|
52
|
-
}
|
|
53
|
-
if (segment.startsWith('[') && segment.endsWith(']')) {
|
|
54
|
-
return {
|
|
55
|
-
paramType: interceptionMarker ? `dynamic-intercepted-${interceptionMarker}` : 'dynamic',
|
|
56
|
-
paramName: segment.slice(1, -1)
|
|
57
|
-
};
|
|
58
|
-
}
|
|
59
|
-
return null;
|
|
60
|
-
}
|
|
61
|
-
function isCatchAll(type) {
|
|
62
|
-
return type === 'catchall' || type === 'catchall-intercepted-(..)(..)' || type === 'catchall-intercepted-(.)' || type === 'catchall-intercepted-(..)' || type === 'catchall-intercepted-(...)' || type === 'optional-catchall';
|
|
63
|
-
}
|
|
64
|
-
function getParamProperties(paramType) {
|
|
65
|
-
let repeat = false;
|
|
66
|
-
let optional = false;
|
|
67
|
-
switch (paramType) {
|
|
68
|
-
case 'catchall':
|
|
69
|
-
case 'catchall-intercepted-(..)(..)':
|
|
70
|
-
case 'catchall-intercepted-(.)':
|
|
71
|
-
case 'catchall-intercepted-(..)':
|
|
72
|
-
case 'catchall-intercepted-(...)':
|
|
73
|
-
repeat = true;
|
|
74
|
-
break;
|
|
75
|
-
case 'optional-catchall':
|
|
76
|
-
repeat = true;
|
|
77
|
-
optional = true;
|
|
78
|
-
break;
|
|
79
|
-
}
|
|
80
|
-
return {
|
|
81
|
-
repeat,
|
|
82
|
-
optional
|
|
83
|
-
};
|
|
84
|
-
}
|
|
85
|
-
} (getSegmentParam));
|
|
86
|
-
return getSegmentParam;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
export { requireGetSegmentParam as __require };
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { __exports as utils } from '../../../../../../../_virtual/index.js';
|
|
2
|
-
import { __require as requireSortedRoutes } from './sorted-routes.js';
|
|
3
|
-
import { __require as requireIsDynamic } from './is-dynamic.js';
|
|
4
|
-
|
|
5
|
-
var hasRequiredUtils;
|
|
6
|
-
|
|
7
|
-
function requireUtils () {
|
|
8
|
-
if (hasRequiredUtils) return utils;
|
|
9
|
-
hasRequiredUtils = 1;
|
|
10
|
-
(function (exports$1) {
|
|
11
|
-
|
|
12
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
13
|
-
value: true
|
|
14
|
-
});
|
|
15
|
-
function _export(target, all) {
|
|
16
|
-
for (var name in all) Object.defineProperty(target, name, {
|
|
17
|
-
enumerable: true,
|
|
18
|
-
get: all[name]
|
|
19
|
-
});
|
|
20
|
-
}
|
|
21
|
-
_export(exports$1, {
|
|
22
|
-
getSortedRouteObjects: function () {
|
|
23
|
-
return _sortedroutes.getSortedRouteObjects;
|
|
24
|
-
},
|
|
25
|
-
getSortedRoutes: function () {
|
|
26
|
-
return _sortedroutes.getSortedRoutes;
|
|
27
|
-
},
|
|
28
|
-
isDynamicRoute: function () {
|
|
29
|
-
return _isdynamic.isDynamicRoute;
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
const _sortedroutes = requireSortedRoutes();
|
|
33
|
-
const _isdynamic = requireIsDynamic();
|
|
34
|
-
} (utils));
|
|
35
|
-
return utils;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
export { requireUtils as __require };
|
package/dist/node_modules/next/dist/shared/lib/router/utils/interception-prefix-from-param-type.js
DELETED
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import { __exports as interceptionPrefixFromParamType } from '../../../../../../../_virtual/interception-prefix-from-param-type.js';
|
|
2
|
-
|
|
3
|
-
var hasRequiredInterceptionPrefixFromParamType;
|
|
4
|
-
|
|
5
|
-
function requireInterceptionPrefixFromParamType () {
|
|
6
|
-
if (hasRequiredInterceptionPrefixFromParamType) return interceptionPrefixFromParamType;
|
|
7
|
-
hasRequiredInterceptionPrefixFromParamType = 1;
|
|
8
|
-
(function (exports$1) {
|
|
9
|
-
|
|
10
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
11
|
-
value: true
|
|
12
|
-
});
|
|
13
|
-
Object.defineProperty(exports$1, "interceptionPrefixFromParamType", {
|
|
14
|
-
enumerable: true,
|
|
15
|
-
get: function () {
|
|
16
|
-
return interceptionPrefixFromParamType;
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
function interceptionPrefixFromParamType(paramType) {
|
|
20
|
-
switch (paramType) {
|
|
21
|
-
case 'catchall-intercepted-(..)(..)':
|
|
22
|
-
case 'dynamic-intercepted-(..)(..)':
|
|
23
|
-
return '(..)(..)';
|
|
24
|
-
case 'catchall-intercepted-(.)':
|
|
25
|
-
case 'dynamic-intercepted-(.)':
|
|
26
|
-
return '(.)';
|
|
27
|
-
case 'catchall-intercepted-(..)':
|
|
28
|
-
case 'dynamic-intercepted-(..)':
|
|
29
|
-
return '(..)';
|
|
30
|
-
case 'catchall-intercepted-(...)':
|
|
31
|
-
case 'dynamic-intercepted-(...)':
|
|
32
|
-
return '(...)';
|
|
33
|
-
case 'catchall':
|
|
34
|
-
case 'dynamic':
|
|
35
|
-
case 'optional-catchall':
|
|
36
|
-
default:
|
|
37
|
-
return null;
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
} (interceptionPrefixFromParamType));
|
|
41
|
-
return interceptionPrefixFromParamType;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
export { requireInterceptionPrefixFromParamType as __require };
|
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
import { __exports as interceptionRoutes } from '../../../../../../../_virtual/interception-routes.js';
|
|
2
|
-
import { __require as requireAppPaths } from './app-paths.js';
|
|
3
|
-
|
|
4
|
-
var hasRequiredInterceptionRoutes;
|
|
5
|
-
|
|
6
|
-
function requireInterceptionRoutes () {
|
|
7
|
-
if (hasRequiredInterceptionRoutes) return interceptionRoutes;
|
|
8
|
-
hasRequiredInterceptionRoutes = 1;
|
|
9
|
-
(function (exports$1) {
|
|
10
|
-
|
|
11
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
12
|
-
value: true
|
|
13
|
-
});
|
|
14
|
-
function _export(target, all) {
|
|
15
|
-
for (var name in all) Object.defineProperty(target, name, {
|
|
16
|
-
enumerable: true,
|
|
17
|
-
get: all[name]
|
|
18
|
-
});
|
|
19
|
-
}
|
|
20
|
-
_export(exports$1, {
|
|
21
|
-
INTERCEPTION_ROUTE_MARKERS: function () {
|
|
22
|
-
return INTERCEPTION_ROUTE_MARKERS;
|
|
23
|
-
},
|
|
24
|
-
extractInterceptionRouteInformation: function () {
|
|
25
|
-
return extractInterceptionRouteInformation;
|
|
26
|
-
},
|
|
27
|
-
isInterceptionRouteAppPath: function () {
|
|
28
|
-
return isInterceptionRouteAppPath;
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
const _apppaths = requireAppPaths();
|
|
32
|
-
const INTERCEPTION_ROUTE_MARKERS = ['(..)(..)', '(.)', '(..)', '(...)'];
|
|
33
|
-
function isInterceptionRouteAppPath(path) {
|
|
34
|
-
// TODO-APP: add more serious validation
|
|
35
|
-
return path.split('/').find(segment => INTERCEPTION_ROUTE_MARKERS.find(m => segment.startsWith(m))) !== undefined;
|
|
36
|
-
}
|
|
37
|
-
function extractInterceptionRouteInformation(path) {
|
|
38
|
-
let interceptingRoute;
|
|
39
|
-
let marker;
|
|
40
|
-
let interceptedRoute;
|
|
41
|
-
for (const segment of path.split('/')) {
|
|
42
|
-
marker = INTERCEPTION_ROUTE_MARKERS.find(m => segment.startsWith(m));
|
|
43
|
-
if (marker) {
|
|
44
|
-
[interceptingRoute, interceptedRoute] = path.split(marker, 2);
|
|
45
|
-
break;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
if (!interceptingRoute || !marker || !interceptedRoute) {
|
|
49
|
-
throw Object.defineProperty(new Error(`Invalid interception route: ${path}. Must be in the format /<intercepting route>/(..|...|..)(..)/<intercepted route>`), "__NEXT_ERROR_CODE", {
|
|
50
|
-
value: "E269",
|
|
51
|
-
enumerable: false,
|
|
52
|
-
configurable: true
|
|
53
|
-
});
|
|
54
|
-
}
|
|
55
|
-
interceptingRoute = (0, _apppaths.normalizeAppPath)(interceptingRoute) // normalize the path, e.g. /(blog)/feed -> /feed
|
|
56
|
-
;
|
|
57
|
-
switch (marker) {
|
|
58
|
-
case '(.)':
|
|
59
|
-
// (.) indicates that we should match with sibling routes, so we just need to append the intercepted route to the intercepting route
|
|
60
|
-
if (interceptingRoute === '/') {
|
|
61
|
-
interceptedRoute = `/${interceptedRoute}`;
|
|
62
|
-
} else {
|
|
63
|
-
interceptedRoute = interceptingRoute + '/' + interceptedRoute;
|
|
64
|
-
}
|
|
65
|
-
break;
|
|
66
|
-
case '(..)':
|
|
67
|
-
// (..) indicates that we should match at one level up, so we need to remove the last segment of the intercepting route
|
|
68
|
-
if (interceptingRoute === '/') {
|
|
69
|
-
throw Object.defineProperty(new Error(`Invalid interception route: ${path}. Cannot use (..) marker at the root level, use (.) instead.`), "__NEXT_ERROR_CODE", {
|
|
70
|
-
value: "E207",
|
|
71
|
-
enumerable: false,
|
|
72
|
-
configurable: true
|
|
73
|
-
});
|
|
74
|
-
}
|
|
75
|
-
interceptedRoute = interceptingRoute.split('/').slice(0, -1).concat(interceptedRoute).join('/');
|
|
76
|
-
break;
|
|
77
|
-
case '(...)':
|
|
78
|
-
// (...) will match the route segment in the root directory, so we need to use the root directory to prepend the intercepted route
|
|
79
|
-
interceptedRoute = '/' + interceptedRoute;
|
|
80
|
-
break;
|
|
81
|
-
case '(..)(..)':
|
|
82
|
-
// (..)(..) indicates that we should match at two levels up, so we need to remove the last two segments of the intercepting route
|
|
83
|
-
const splitInterceptingRoute = interceptingRoute.split('/');
|
|
84
|
-
if (splitInterceptingRoute.length <= 2) {
|
|
85
|
-
throw Object.defineProperty(new Error(`Invalid interception route: ${path}. Cannot use (..)(..) marker at the root level or one level up.`), "__NEXT_ERROR_CODE", {
|
|
86
|
-
value: "E486",
|
|
87
|
-
enumerable: false,
|
|
88
|
-
configurable: true
|
|
89
|
-
});
|
|
90
|
-
}
|
|
91
|
-
interceptedRoute = splitInterceptingRoute.slice(0, -2).concat(interceptedRoute).join('/');
|
|
92
|
-
break;
|
|
93
|
-
default:
|
|
94
|
-
throw Object.defineProperty(new Error('Invariant: unexpected marker'), "__NEXT_ERROR_CODE", {
|
|
95
|
-
value: "E112",
|
|
96
|
-
enumerable: false,
|
|
97
|
-
configurable: true
|
|
98
|
-
});
|
|
99
|
-
}
|
|
100
|
-
return {
|
|
101
|
-
interceptingRoute,
|
|
102
|
-
interceptedRoute
|
|
103
|
-
};
|
|
104
|
-
}
|
|
105
|
-
} (interceptionRoutes));
|
|
106
|
-
return interceptionRoutes;
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
export { requireInterceptionRoutes as __require };
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
import { __exports as interpolateAs } from '../../../../../../../_virtual/interpolate-as.js';
|
|
2
|
-
import { __require as requireRouteMatcher } from './route-matcher.js';
|
|
3
|
-
import { __require as requireRouteRegex } from './route-regex.js';
|
|
4
|
-
|
|
5
|
-
var hasRequiredInterpolateAs;
|
|
6
|
-
|
|
7
|
-
function requireInterpolateAs () {
|
|
8
|
-
if (hasRequiredInterpolateAs) return interpolateAs;
|
|
9
|
-
hasRequiredInterpolateAs = 1;
|
|
10
|
-
(function (exports$1) {
|
|
11
|
-
|
|
12
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
13
|
-
value: true
|
|
14
|
-
});
|
|
15
|
-
Object.defineProperty(exports$1, "interpolateAs", {
|
|
16
|
-
enumerable: true,
|
|
17
|
-
get: function () {
|
|
18
|
-
return interpolateAs;
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
const _routematcher = requireRouteMatcher();
|
|
22
|
-
const _routeregex = requireRouteRegex();
|
|
23
|
-
function interpolateAs(route, asPathname, query) {
|
|
24
|
-
let interpolatedRoute = '';
|
|
25
|
-
const dynamicRegex = (0, _routeregex.getRouteRegex)(route);
|
|
26
|
-
const dynamicGroups = dynamicRegex.groups;
|
|
27
|
-
const dynamicMatches =
|
|
28
|
-
// Try to match the dynamic route against the asPath
|
|
29
|
-
(asPathname !== route ? (0, _routematcher.getRouteMatcher)(dynamicRegex)(asPathname) : '') ||
|
|
30
|
-
// Fall back to reading the values from the href
|
|
31
|
-
// TODO: should this take priority; also need to change in the router.
|
|
32
|
-
query;
|
|
33
|
-
interpolatedRoute = route;
|
|
34
|
-
const params = Object.keys(dynamicGroups);
|
|
35
|
-
if (!params.every(param => {
|
|
36
|
-
let value = dynamicMatches[param] || '';
|
|
37
|
-
const {
|
|
38
|
-
repeat,
|
|
39
|
-
optional
|
|
40
|
-
} = dynamicGroups[param];
|
|
41
|
-
// support single-level catch-all
|
|
42
|
-
// TODO: more robust handling for user-error (passing `/`)
|
|
43
|
-
let replaced = `[${repeat ? '...' : ''}${param}]`;
|
|
44
|
-
if (optional) {
|
|
45
|
-
replaced = `${!value ? '/' : ''}[${replaced}]`;
|
|
46
|
-
}
|
|
47
|
-
if (repeat && !Array.isArray(value)) value = [value];
|
|
48
|
-
return (optional || param in dynamicMatches) && (
|
|
49
|
-
// Interpolate group into data URL if present
|
|
50
|
-
interpolatedRoute = interpolatedRoute.replace(replaced, repeat ? value.map(
|
|
51
|
-
// these values should be fully encoded instead of just
|
|
52
|
-
// path delimiter escaped since they are being inserted
|
|
53
|
-
// into the URL and we expect URL encoded segments
|
|
54
|
-
// when parsing dynamic route params
|
|
55
|
-
segment => encodeURIComponent(segment)).join('/') : encodeURIComponent(value)) || '/');
|
|
56
|
-
})) {
|
|
57
|
-
interpolatedRoute = '' // did not satisfy all requirements
|
|
58
|
-
;
|
|
59
|
-
// n.b. We ignore this error because we handle warning for this case in
|
|
60
|
-
// development in the `<Link>` component directly.
|
|
61
|
-
}
|
|
62
|
-
return {
|
|
63
|
-
params,
|
|
64
|
-
result: interpolatedRoute
|
|
65
|
-
};
|
|
66
|
-
}
|
|
67
|
-
} (interpolateAs));
|
|
68
|
-
return interpolateAs;
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
export { requireInterpolateAs as __require };
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { __exports as isDynamic } from '../../../../../../../_virtual/is-dynamic.js';
|
|
2
|
-
import { __require as requireInterceptionRoutes } from './interception-routes.js';
|
|
3
|
-
|
|
4
|
-
var hasRequiredIsDynamic;
|
|
5
|
-
|
|
6
|
-
function requireIsDynamic () {
|
|
7
|
-
if (hasRequiredIsDynamic) return isDynamic;
|
|
8
|
-
hasRequiredIsDynamic = 1;
|
|
9
|
-
(function (exports$1) {
|
|
10
|
-
|
|
11
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
12
|
-
value: true
|
|
13
|
-
});
|
|
14
|
-
Object.defineProperty(exports$1, "isDynamicRoute", {
|
|
15
|
-
enumerable: true,
|
|
16
|
-
get: function () {
|
|
17
|
-
return isDynamicRoute;
|
|
18
|
-
}
|
|
19
|
-
});
|
|
20
|
-
const _interceptionroutes = requireInterceptionRoutes();
|
|
21
|
-
// Identify /.*[param].*/ in route string
|
|
22
|
-
const TEST_ROUTE = /\/[^/]*\[[^/]+\][^/]*(?=\/|$)/;
|
|
23
|
-
// Identify /[param]/ in route string
|
|
24
|
-
const TEST_STRICT_ROUTE = /\/\[[^/]+\](?=\/|$)/;
|
|
25
|
-
function isDynamicRoute(route, strict = true) {
|
|
26
|
-
if ((0, _interceptionroutes.isInterceptionRouteAppPath)(route)) {
|
|
27
|
-
route = (0, _interceptionroutes.extractInterceptionRouteInformation)(route).interceptedRoute;
|
|
28
|
-
}
|
|
29
|
-
if (strict) {
|
|
30
|
-
return TEST_STRICT_ROUTE.test(route);
|
|
31
|
-
}
|
|
32
|
-
return TEST_ROUTE.test(route);
|
|
33
|
-
}
|
|
34
|
-
} (isDynamic));
|
|
35
|
-
return isDynamic;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
export { requireIsDynamic as __require };
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { __exports as isLocalUrl } from '../../../../../../../_virtual/is-local-url.js';
|
|
2
|
-
import { __require as requireUtils } from '../../utils.js';
|
|
3
|
-
import { __require as requireHasBasePath } from '../../../../client/has-base-path.js';
|
|
4
|
-
|
|
5
|
-
var hasRequiredIsLocalUrl;
|
|
6
|
-
|
|
7
|
-
function requireIsLocalUrl () {
|
|
8
|
-
if (hasRequiredIsLocalUrl) return isLocalUrl;
|
|
9
|
-
hasRequiredIsLocalUrl = 1;
|
|
10
|
-
(function (exports$1) {
|
|
11
|
-
|
|
12
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
13
|
-
value: true
|
|
14
|
-
});
|
|
15
|
-
Object.defineProperty(exports$1, "isLocalURL", {
|
|
16
|
-
enumerable: true,
|
|
17
|
-
get: function () {
|
|
18
|
-
return isLocalURL;
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
const _utils = requireUtils();
|
|
22
|
-
const _hasbasepath = requireHasBasePath();
|
|
23
|
-
function isLocalURL(url) {
|
|
24
|
-
// prevent a hydration mismatch on href for url with anchor refs
|
|
25
|
-
if (!(0, _utils.isAbsoluteUrl)(url)) return true;
|
|
26
|
-
try {
|
|
27
|
-
// absolute urls can be local if they are on the same origin
|
|
28
|
-
const locationOrigin = (0, _utils.getLocationOrigin)();
|
|
29
|
-
const resolved = new URL(url, locationOrigin);
|
|
30
|
-
return resolved.origin === locationOrigin && (0, _hasbasepath.hasBasePath)(resolved.pathname);
|
|
31
|
-
} catch (_) {
|
|
32
|
-
return false;
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
} (isLocalUrl));
|
|
36
|
-
return isLocalUrl;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
export { requireIsLocalUrl as __require };
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { __exports as omit } from '../../../../../../../_virtual/omit.js';
|
|
2
|
-
|
|
3
|
-
var hasRequiredOmit;
|
|
4
|
-
|
|
5
|
-
function requireOmit () {
|
|
6
|
-
if (hasRequiredOmit) return omit;
|
|
7
|
-
hasRequiredOmit = 1;
|
|
8
|
-
(function (exports$1) {
|
|
9
|
-
|
|
10
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
11
|
-
value: true
|
|
12
|
-
});
|
|
13
|
-
Object.defineProperty(exports$1, "omit", {
|
|
14
|
-
enumerable: true,
|
|
15
|
-
get: function () {
|
|
16
|
-
return omit;
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
function omit(object, keys) {
|
|
20
|
-
const omitted = {};
|
|
21
|
-
Object.keys(object).forEach(key => {
|
|
22
|
-
if (!keys.includes(key)) {
|
|
23
|
-
omitted[key] = object[key];
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
|
-
return omitted;
|
|
27
|
-
}
|
|
28
|
-
} (omit));
|
|
29
|
-
return omit;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
export { requireOmit as __require };
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import { __exports as parseLoaderTree } from '../../../../../../../_virtual/parse-loader-tree.js';
|
|
2
|
-
import { __require as requireSegment } from '../../segment.js';
|
|
3
|
-
|
|
4
|
-
var hasRequiredParseLoaderTree;
|
|
5
|
-
|
|
6
|
-
function requireParseLoaderTree () {
|
|
7
|
-
if (hasRequiredParseLoaderTree) return parseLoaderTree;
|
|
8
|
-
hasRequiredParseLoaderTree = 1;
|
|
9
|
-
(function (exports$1) {
|
|
10
|
-
|
|
11
|
-
Object.defineProperty(exports$1, "__esModule", {
|
|
12
|
-
value: true
|
|
13
|
-
});
|
|
14
|
-
Object.defineProperty(exports$1, "parseLoaderTree", {
|
|
15
|
-
enumerable: true,
|
|
16
|
-
get: function () {
|
|
17
|
-
return parseLoaderTree;
|
|
18
|
-
}
|
|
19
|
-
});
|
|
20
|
-
const _segment = requireSegment();
|
|
21
|
-
function parseLoaderTree(tree) {
|
|
22
|
-
const [segment, parallelRoutes, modules] = tree;
|
|
23
|
-
const {
|
|
24
|
-
layout,
|
|
25
|
-
template
|
|
26
|
-
} = modules;
|
|
27
|
-
let {
|
|
28
|
-
page
|
|
29
|
-
} = modules;
|
|
30
|
-
// a __DEFAULT__ segment means that this route didn't match any of the
|
|
31
|
-
// segments in the route, so we should use the default page
|
|
32
|
-
page = segment === _segment.DEFAULT_SEGMENT_KEY ? modules.defaultPage : page;
|
|
33
|
-
const conventionPath = layout?.[1] || template?.[1] || page?.[1];
|
|
34
|
-
return {
|
|
35
|
-
page,
|
|
36
|
-
segment,
|
|
37
|
-
modules,
|
|
38
|
-
/* it can be either layout / template / page */conventionPath,
|
|
39
|
-
parallelRoutes
|
|
40
|
-
};
|
|
41
|
-
}
|
|
42
|
-
} (parseLoaderTree));
|
|
43
|
-
return parseLoaderTree;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
export { requireParseLoaderTree as __require };
|