@hanzo/team 0.1.13 → 0.1.15
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/README.md +1 -0
- package/dist/404.html +26 -3
- package/dist/admin/index.html +26 -3
- package/dist/agents/algo/index.html +26 -3
- package/dist/agents/art/index.html +26 -3
- package/dist/agents/biz/index.html +26 -3
- package/dist/agents/cal/index.html +26 -3
- package/dist/agents/core/index.html +26 -3
- package/dist/agents/cyber/index.html +26 -3
- package/dist/agents/data/index.html +26 -3
- package/dist/agents/db/index.html +26 -3
- package/dist/agents/des/index.html +26 -3
- package/dist/agents/dev/index.html +26 -3
- package/dist/agents/doc/index.html +26 -3
- package/dist/agents/ed/index.html +26 -3
- package/dist/agents/fin/index.html +26 -3
- package/dist/agents/gov/index.html +26 -3
- package/dist/agents/huma/index.html +26 -3
- package/dist/agents/index.html +26 -3
- package/dist/agents/lang/index.html +26 -3
- package/dist/agents/law/index.html +26 -3
- package/dist/agents/mana/index.html +26 -3
- package/dist/agents/mark/index.html +26 -3
- package/dist/agents/mo/index.html +26 -3
- package/dist/agents/mu/index.html +26 -3
- package/dist/agents/opera/index.html +26 -3
- package/dist/agents/rev/index.html +26 -3
- package/dist/agents/sal/index.html +26 -3
- package/dist/agents/sci/index.html +26 -3
- package/dist/agents/sec/index.html +26 -3
- package/dist/agents/su/index.html +26 -3
- package/dist/agents/vi/index.html +26 -3
- package/dist/apps/ads/index.html +26 -3
- package/dist/apps/ai-chat/index.html +26 -3
- package/dist/apps/analytics/index.html +26 -3
- package/dist/apps/billing/index.html +26 -3
- package/dist/apps/bots/index.html +26 -3
- package/dist/apps/cal/index.html +26 -3
- package/dist/apps/chat/index.html +26 -3
- package/dist/apps/cms/index.html +26 -3
- package/dist/apps/commerce/index.html +26 -3
- package/dist/apps/console/index.html +26 -3
- package/dist/apps/crm/index.html +26 -3
- package/dist/apps/dataroom/index.html +26 -3
- package/dist/apps/dev/index.html +26 -3
- package/dist/apps/email/index.html +26 -3
- package/dist/apps/index.html +26 -3
- package/dist/apps/meet/index.html +26 -3
- package/dist/apps/platform/index.html +26 -3
- package/dist/apps/sign/index.html +26 -3
- package/dist/apps/social/index.html +26 -3
- package/dist/apps/tracker/index.html +26 -3
- package/dist/assets/Bots-B8ku2Lx_.js +174 -0
- package/dist/assets/Bots-B8ku2Lx_.js.map +1 -0
- package/dist/assets/ThemeToggleNext-Ch0Z0z5a.js +2 -0
- package/dist/assets/{ThemeToggleNext-Dl_lG82A.js.map → ThemeToggleNext-Ch0Z0z5a.js.map} +1 -1
- package/dist/assets/index-DVi69rnL.css +1 -0
- package/dist/assets/index-x1c3_XFq.js +186 -0
- package/dist/assets/index-x1c3_XFq.js.map +1 -0
- package/dist/assets/instrument-D2ByLhpL.js +42 -0
- package/dist/assets/instrument-D2ByLhpL.js.map +1 -0
- package/dist/assets/rolldown-runtime-B0Z9INg1.js +1 -0
- package/dist/assets/sha3-DDKddPFc.js +2 -0
- package/dist/assets/sha3-DDKddPFc.js.map +1 -0
- package/dist/auth/callback/index.html +26 -3
- package/dist/auth/index.html +26 -3
- package/dist/bots/index.html +26 -3
- package/dist/cal/index.html +26 -3
- package/dist/calendar/index.html +26 -3
- package/dist/chat/c-design/index.html +26 -3
- package/dist/chat/c-general/index.html +26 -3
- package/dist/chat/c-lux-bank/index.html +26 -3
- package/dist/chat/c-lux-bridge/index.html +26 -3
- package/dist/chat/c-revenue/index.html +26 -3
- package/dist/chat/c-support/index.html +26 -3
- package/dist/chat/c-tracker/index.html +26 -3
- package/dist/chat/c-ui/index.html +26 -3
- package/dist/chat/c-video/index.html +26 -3
- package/dist/chat/dm-algo/index.html +26 -3
- package/dist/chat/dm-art/index.html +26 -3
- package/dist/chat/dm-biz/index.html +26 -3
- package/dist/chat/dm-cal/index.html +26 -3
- package/dist/chat/dm-core/index.html +26 -3
- package/dist/chat/dm-cyber/index.html +26 -3
- package/dist/chat/dm-data/index.html +26 -3
- package/dist/chat/dm-db/index.html +26 -3
- package/dist/chat/dm-des/index.html +26 -3
- package/dist/chat/dm-dev/index.html +26 -3
- package/dist/chat/dm-doc/index.html +26 -3
- package/dist/chat/dm-ed/index.html +26 -3
- package/dist/chat/dm-fin/index.html +26 -3
- package/dist/chat/dm-gov/index.html +26 -3
- package/dist/chat/dm-huma/index.html +26 -3
- package/dist/chat/dm-lang/index.html +26 -3
- package/dist/chat/dm-law/index.html +26 -3
- package/dist/chat/dm-mana/index.html +26 -3
- package/dist/chat/dm-mark/index.html +26 -3
- package/dist/chat/dm-mo/index.html +26 -3
- package/dist/chat/dm-mu/index.html +26 -3
- package/dist/chat/dm-opera/index.html +26 -3
- package/dist/chat/dm-rev/index.html +26 -3
- package/dist/chat/dm-sal/index.html +26 -3
- package/dist/chat/dm-sci/index.html +26 -3
- package/dist/chat/dm-sec/index.html +26 -3
- package/dist/chat/dm-su/index.html +26 -3
- package/dist/chat/dm-vi/index.html +26 -3
- package/dist/chat/index.html +26 -3
- package/dist/crm/analytics/index.html +26 -3
- package/dist/crm/automations/index.html +26 -3
- package/dist/crm/campaigns/index.html +26 -3
- package/dist/crm/companies/index.html +26 -3
- package/dist/crm/contacts/index.html +26 -3
- package/dist/crm/customers/index.html +26 -3
- package/dist/crm/deliverability/index.html +26 -3
- package/dist/crm/forms/index.html +26 -3
- package/dist/crm/funds/index.html +26 -3
- package/dist/crm/index.html +26 -3
- package/dist/crm/investors/index.html +26 -3
- package/dist/crm/journeys/index.html +26 -3
- package/dist/crm/leads/index.html +26 -3
- package/dist/crm/lists/index.html +26 -3
- package/dist/crm/opportunities/index.html +26 -3
- package/dist/crm/segments/index.html +26 -3
- package/dist/crm/settings/index.html +26 -3
- package/dist/crm/templates/index.html +26 -3
- package/dist/crm/webhooks/index.html +26 -3
- package/dist/docs/index.html +26 -3
- package/dist/files/index.html +26 -3
- package/dist/inbox/index.html +26 -3
- package/dist/index.html +26 -3
- package/dist/issues/index.html +26 -3
- package/dist/issues/kanban/index.html +26 -3
- package/dist/issues/list/index.html +26 -3
- package/dist/login/index.html +26 -3
- package/dist/mail/index.html +26 -3
- package/dist/meet/index.html +26 -3
- package/dist/mine/index.html +26 -3
- package/dist/people/index.html +26 -3
- package/dist/projects/index.html +26 -3
- package/dist/projects/proj-crm/components/index.html +26 -3
- package/dist/projects/proj-crm/index.html +26 -3
- package/dist/projects/proj-crm/issues/index.html +26 -3
- package/dist/projects/proj-crm/issues/kanban/index.html +26 -3
- package/dist/projects/proj-crm/issues/list/index.html +26 -3
- package/dist/projects/proj-crm/milestones/index.html +26 -3
- package/dist/projects/proj-crm/templates/index.html +26 -3
- package/dist/projects/proj-dev/components/index.html +26 -3
- package/dist/projects/proj-dev/index.html +26 -3
- package/dist/projects/proj-dev/issues/index.html +26 -3
- package/dist/projects/proj-dev/issues/kanban/index.html +26 -3
- package/dist/projects/proj-dev/issues/list/index.html +26 -3
- package/dist/projects/proj-dev/milestones/index.html +26 -3
- package/dist/projects/proj-dev/templates/index.html +26 -3
- package/dist/projects/proj-mkt/components/index.html +26 -3
- package/dist/projects/proj-mkt/index.html +26 -3
- package/dist/projects/proj-mkt/issues/index.html +26 -3
- package/dist/projects/proj-mkt/issues/kanban/index.html +26 -3
- package/dist/projects/proj-mkt/issues/list/index.html +26 -3
- package/dist/projects/proj-mkt/milestones/index.html +26 -3
- package/dist/projects/proj-mkt/templates/index.html +26 -3
- package/dist/projects/proj-next/components/index.html +26 -3
- package/dist/projects/proj-next/index.html +26 -3
- package/dist/projects/proj-next/issues/index.html +26 -3
- package/dist/projects/proj-next/issues/kanban/index.html +26 -3
- package/dist/projects/proj-next/issues/list/index.html +26 -3
- package/dist/projects/proj-next/milestones/index.html +26 -3
- package/dist/projects/proj-next/templates/index.html +26 -3
- package/dist/settings/index.html +26 -3
- package/dist/time/index.html +26 -3
- package/package.json +9 -2
- package/dist/assets/ThemeToggleNext-Dl_lG82A.js +0 -2
- package/dist/assets/index-B-xfsR5K.js +0 -221
- package/dist/assets/index-B-xfsR5K.js.map +0 -1
- package/dist/assets/index-Cs7y8nyH.css +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"instrument-D2ByLhpL.js","names":["KEY","parse","sheet","DEFAULT_HOST","isBrowser","registry","track","cache","React","_jsx","useContext","createContext","useCallback","useEffect","useLayoutEffect","conf","cache","prefixes","matchMedia","matchMedia","listeners","States","subscribe","useRef","useReducer","incReducer","cache","cache","emptyObject","createContext","useContext","useId","useRef","useReducer","res","useRef","defaultOffset","defaultOffset","normalizeColor","normalizeValueWithProperty","normalizeValueWithProperty","conf","normalizeValueWithProperty","createAtomicRules","defaultOffset","normalizeColor","createDeclarationBlock","hyphenateStyleName","toHyphenLower","sheet","cache","normalizeColor","normalizeStyle","normalizeValueWithProperty","fn","normalizeStyle","mediaState","globalMediaState","validStyles","validStylesView","normalizeValueWithProperty","createContext","useContext","_jsx","forwardRef","Children","isValidElement","cloneElement","useRef","_jsx","_jsx","_jsx","_Fragment","useRef","isDisabled","useState","memo","forwardRef","isValidElement","cloneElement","Children","_jsx","_Fragment","useMemo","_jsx","_jsxs","_Fragment","cache","createGui","getCSS","getCSSHelper","View","View","_jsx","_jsx","useId","GuiProvider","_jsx","_jsxs","_Fragment","Text","createContext","useId","_jsx","useElementLayout","useContext","measureLayout","_jsx","WebGuiProvider","createGuiWeb","View","WebView","Text","WebText","styled","View","styled","SizableText","styled","Text","cache","styled","Text","_jsx","emptyObject","_typeof","_typeof","_typeof","unitlessNumbers","prefixes","prefixKey","normalizeColor","normalizeColor","unitlessNumbers","normalizeColor","emptyObject","uppercasePattern","msPattern","cache","toHyphenLower","hyphenateStyleName","cache","toHyphenLower","cache","uppercasePattern","RE","RE","prefixes","RE","crossFade","imageSet","logical","position","sizing","transition","createPrefixer","staticData","_excluded","cache","emptyObject","_objectSpread","prefixStyles","hyphenateStyleName","emptyObject","normalizeColor","_excluded","styleq","localizeStyle","_objectSpread","_excluded","emptyObject","StyleSheet","_objectSpread","useContext","createElement","getBoundingClientRect","isUnitlessNumber","measureLayout","getBoundingClientRect","pick","useLayoutEffect","useEffect","useStable","useStable","emptyObject","getBoundingClientRect","emptyObject","ResponderSystem.getResponderNode","forwardedProps.defaultProps","forwardedProps.accessibilityProps","forwardedProps.clickProps","forwardedProps.focusProps","forwardedProps.keyboardProps","forwardedProps.mouseProps","forwardedProps.touchProps","forwardedProps.styleProps","pick","createElement","StyleSheet","listeners","twoArgumentPooler","twoArgumentPooler","_objectSpread","normalizeColor","styled","View","_jsx","useContext","_jsxs","g","resolve","StyleSheet","resolve","createElement","Text","_jsx","createContext","useContext","useSyncExternalStore","createElement","Fragment","createContext","useContext","useCallback"],"sources":["../../node_modules/.pnpm/react@19.2.8/node_modules/react/cjs/react.production.js","../../node_modules/.pnpm/react@19.2.8/node_modules/react/index.js","../../node_modules/.pnpm/react-dom@19.2.8_react@19.2.8/node_modules/react-dom/cjs/react-dom.production.js","../../node_modules/.pnpm/react-dom@19.2.8_react@19.2.8/node_modules/react-dom/index.js","../../node_modules/.pnpm/@hanzo+events@0.3.2/node_modules/@hanzo/events/dist/names.js","../../node_modules/.pnpm/@hanzo+events@0.3.2/node_modules/@hanzo/events/dist/platforms.js","../../node_modules/.pnpm/@hanzo+events@0.3.2/node_modules/@hanzo/events/dist/funnels.js","../../node_modules/.pnpm/@hanzo+events@0.3.2/node_modules/@hanzo/events/dist/index.js","../../node_modules/.pnpm/@hanzo+event@0.3.66_react@19.2.8/node_modules/@hanzo/event/dist/index.mjs","../../node_modules/.pnpm/react@19.2.8/node_modules/react/cjs/react-jsx-runtime.production.js","../../node_modules/.pnpm/react@19.2.8/node_modules/react/jsx-runtime.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/pseudoDescriptors.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/mergeProps.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/objectIdentityKey.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/createStyledContext.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/contexts/ComponentContext.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/contexts/GroupContext.js","../../node_modules/.pnpm/@hanzogui+is-equal-shallow@8.3.5_react@19.2.8/node_modules/@hanzogui/is-equal-shallow/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+constants@8.3.5_react@19.2.8/node_modules/@hanzogui/constants/dist/esm/constants.js","../../node_modules/.pnpm/@hanzogui+constants@8.3.5_react@19.2.8/node_modules/@hanzogui/constants/dist/esm/platformDriver.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/constants/constants.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/config.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/mediaObjectToString.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/mediaState.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/getGroupPropParts.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/createMediaStyle.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/matchMedia.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/hooks/useMedia.js","../../node_modules/.pnpm/@hanzogui+simple-hash@8.3.5/node_modules/@hanzogui/simple-hash/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+helpers@8.3.5_react@19.2.8/node_modules/@hanzogui/helpers/dist/esm/composeEventHandlers.js","../../node_modules/.pnpm/@hanzogui+helpers@8.3.5_react@19.2.8/node_modules/@hanzogui/helpers/dist/esm/webOnlyStyleProps.js","../../node_modules/.pnpm/@hanzogui+helpers@8.3.5_react@19.2.8/node_modules/@hanzogui/helpers/dist/esm/validStyleProps.js","../../node_modules/.pnpm/@hanzogui+helpers@8.3.5_react@19.2.8/node_modules/@hanzogui/helpers/dist/esm/withStaticProperties.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/createVariable.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/hooks/getThemeProxied.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/hooks/useThemeState.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/hooks/useTheme.js","../../node_modules/.pnpm/@hanzogui+compose-refs@8.3.5_react@19.2.8/node_modules/@hanzogui/compose-refs/dist/esm/compose-refs.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/defaultComponentState.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/eventHandling.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/getDefaultProps.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/resolveAnimationDriver.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/defaultOffset.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/normalizeShadow.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/expandStyles.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/normalizeColor.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/normalizeValueWithProperty.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/transformsToString.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/getCSSStylesAtomic.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/insertStyleRule.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/isActivePlatform.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/isActiveTheme.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/expandStyle.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/getVariantExtras.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/getTokenForKey.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/isObj.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/styleOriginalValues.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/normalizeStyle.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/platformResolveValue.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/resolveCompoundTokens.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/resolveRem.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/nativeOnlyProps.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/skipProps.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/propMapper.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/sortString.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/getSplitStyles.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/mergeSlotStyleProps.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/mergeRenderElementProps.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/pointerEvents.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/pseudoTransitions.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/setupHooks.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/setElementProps.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/subscribeToContextGroup.js","../../node_modules/.pnpm/@hanzogui+use-did-finish-ssr@8.3.5_react@19.2.8/node_modules/@hanzogui/use-did-finish-ssr/dist/esm/ClientOnly.js","../../node_modules/.pnpm/@hanzogui+use-did-finish-ssr@8.3.5_react@19.2.8/node_modules/@hanzogui/use-did-finish-ssr/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/views/Theme.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/themeable.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/wrapStyleTags.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/hooks/useComponentState.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/views/Slot.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/createComponent.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/registerCSSVariable.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/getThemeCSSRules.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/proxyThemeToParents.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/themes.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/createVariables.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/defaultAnimationDriver.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/createDesignSystem.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/insertFont.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/createGui.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/setupReactNative.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/helpers/mergeVariants.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/styled.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/views/View.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/hooks/useProps.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/views/GuiRoot.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/views/ThemeProvider.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/views/GuiProvider.js","../../node_modules/.pnpm/@hanzogui+web@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/web/dist/esm/views/Text.js","../../node_modules/.pnpm/@hanzogui+use-event@8.3.5_react@19.2.8/node_modules/@hanzogui/use-event/dist/esm/useGet.js","../../node_modules/.pnpm/@hanzogui+use-event@8.3.5_react@19.2.8/node_modules/@hanzogui/use-event/dist/esm/useEvent.js","../../node_modules/.pnpm/@hanzogui+react-native-media-driver@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/react-native-media-driver/dist/esm/matchMedia.js","../../node_modules/.pnpm/@hanzogui+react-native-media-driver@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/react-native-media-driver/dist/esm/createMedia.js","../../node_modules/.pnpm/@hanzogui+use-element-layout@8.3.5_react@19.2.8/node_modules/@hanzogui/use-element-layout/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+core@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/core/dist/esm/getBaseViews.js","../../node_modules/.pnpm/@hanzogui+core@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/core/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+stacks@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/stacks/dist/esm/getElevation.js","../../node_modules/.pnpm/@hanzogui+stacks@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/stacks/dist/esm/Stacks.js","../../node_modules/.pnpm/@hanzogui+stacks@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/stacks/dist/esm/variants.js","../../node_modules/.pnpm/@hanzogui+stacks@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/stacks/dist/esm/ThemeableStack.js","../../node_modules/.pnpm/@hanzogui+get-token@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/get-token/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+get-button-sized@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/get-button-sized/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+stacks@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/stacks/dist/esm/NestingContext.js","../../node_modules/.pnpm/@hanzogui+get-font-sized@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/get-font-sized/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+text@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/text/dist/esm/SizableText.js","../../node_modules/.pnpm/@hanzogui+text@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/text/dist/esm/wrapChildrenInText.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/AccessibilityUtil/isDisabled.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/AccessibilityUtil/propsToAriaRole.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/AccessibilityUtil/propsToAccessibilityComponent.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/AccessibilityUtil/index.js","../../node_modules/.pnpm/@babel+runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/typeof.js","../../node_modules/.pnpm/@babel+runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/toPrimitive.js","../../node_modules/.pnpm/@babel+runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/toPropertyKey.js","../../node_modules/.pnpm/@babel+runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/defineProperty.js","../../node_modules/.pnpm/@babel+runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/objectSpread2.js","../../node_modules/.pnpm/@babel+runtime@7.29.7/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/compiler/unitlessNumbers.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/isWebColor/index.js","../../node_modules/.pnpm/@react-native+normalize-colors@0.74.89/node_modules/@react-native/normalize-colors/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/processColor/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/compiler/normalizeColor.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/compiler/normalizeValueWithProperty.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/canUseDom/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/compiler/createReactDOMStyle.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/compiler/hash.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/compiler/hyphenateStyleName.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/utils/capitalizeString.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/utils/prefixProperty.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/utils/prefixValue.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/utils/addNewValuesOnly.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/utils/isObject.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/createPrefixer.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/assignStyle.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/camelCaseProperty.js","../../node_modules/.pnpm/hyphenate-style-name@1.1.0/node_modules/hyphenate-style-name/index.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/hyphenateProperty.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/cssifyDeclaration.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/cssifyObject.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/isPrefixedProperty.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/isPrefixedValue.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/isUnitlessProperty.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/unprefixProperty.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/normalizeProperty.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/resolveArrayValue.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/unprefixValue.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/es/index.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/plugins/crossFade.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/lib/isPrefixedValue.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/plugins/imageSet.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/plugins/logical.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/plugins/position.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/plugins/sizing.js","../../node_modules/.pnpm/css-in-js-utils@3.1.0/node_modules/css-in-js-utils/lib/hyphenateProperty.js","../../node_modules/.pnpm/inline-style-prefixer@7.0.1/node_modules/inline-style-prefixer/lib/plugins/transition.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/prefixStyles/static.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/prefixStyles/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/compiler/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/dom/createCSSStyleSheet.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/dom/createOrderedCSSStyleSheet.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/dom/index.js","../../node_modules/.pnpm/styleq@0.1.3/node_modules/styleq/dist/transform-localize-style.js","../../node_modules/.pnpm/styleq@0.1.3/node_modules/styleq/transform-localize-style.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/warnOnce/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/preprocess.js","../../node_modules/.pnpm/styleq@0.1.3/node_modules/styleq/dist/styleq.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/StyleSheet/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/createDOMProps/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useLocale/isLocaleRTL.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useLocale/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/createElement/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/getBoundingClientRect/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/unitlessNumbers/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/setValueForStyles/dangerousStyleValue.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/setValueForStyles/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/UIManager/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/forwardedProps/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/pick/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useLayoutEffect/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useElementLayout/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/mergeRefs/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useMergeRefs/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useStable/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/usePlatformMethods/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useResponderEvents/createResponderEvent.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useResponderEvents/ResponderEventTypes.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/isSelectionValid/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useResponderEvents/utils.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useResponderEvents/ResponderTouchHistoryStore.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useResponderEvents/ResponderSystem.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/useResponderEvents/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/Text/TextAncestorContext.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/View/index.js","../../node_modules/.pnpm/fbjs@3.0.5/node_modules/fbjs/lib/invariant.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/Dimensions/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/modules/AssetRegistry/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/PixelRatio/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/vendor/react-native/PooledClass/index.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/Touchable/BoundingDimensions.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/Touchable/Position.js","../../node_modules/.pnpm/react-native-web@0.21.2_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/react-native-web/dist/exports/Touchable/index.js","../../node_modules/.pnpm/@hanzogui+font-size@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/font-size/dist/esm/getFontSize.js","../../node_modules/.pnpm/@hanzogui+component-helpers@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/component-helpers/dist/esm/useCurrentColor.js","../../node_modules/.pnpm/@hanzogui+component-helpers@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/component-helpers/dist/esm/getIcon.js","../../node_modules/.pnpm/@hanzogui+button@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/button/dist/esm/Button.js","../../node_modules/.pnpm/@hanzogui+sizable-context@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/sizable-context/dist/esm/index.js","../../node_modules/.pnpm/@hanzogui+telemetry@8.3.5_react@19.2.8/node_modules/@hanzogui/telemetry/dist/esm/consent.js","../../node_modules/.pnpm/@hanzogui+telemetry@8.3.5_react@19.2.8/node_modules/@hanzogui/telemetry/dist/esm/here.js","../../node_modules/.pnpm/@hanzogui+telemetry@8.3.5_react@19.2.8/node_modules/@hanzogui/telemetry/dist/esm/env.js","../../node_modules/.pnpm/@hanzogui+telemetry@8.3.5_react@19.2.8/node_modules/@hanzogui/telemetry/dist/esm/telemetry.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/web/utils/index.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/web/utils/hasProperty.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/lib/Matrix2D.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/lib/extract/transform.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/lib/extract/transformToRn.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/lib/extract/extractTransform.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/web/utils/parseTransform.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/lib/resolve.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/lib/resolveAssetUri.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/web/utils/prepare.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/web/utils/convertInt32Color.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/lib/SvgTouchableMixin.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/web/WebShape.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/elements.web.js","../../node_modules/.pnpm/react-native-svg@15.15.5_react-native@0.87.1_@babel+core@7.29.7_supports-color@8.1.1__@_cf8186b4ffe026f12fa31d1000c9a462/node_modules/react-native-svg/lib/module/xml.js","../../node_modules/.pnpm/@hanzogui+helpers-icon@8.3.5_react-dom@19.2.8_react@19.2.8__react@19.2.8/node_modules/@hanzogui/helpers-icon/dist/esm/themed.js","../../node_modules/.pnpm/@hanzo+i18n@0.6.1_react@19.2.8/node_modules/@hanzo/i18n/dist/review.js","../../node_modules/.pnpm/@hanzo+i18n@0.6.1_react@19.2.8/node_modules/@hanzo/i18n/dist/locales.js","../../node_modules/.pnpm/@hanzo+i18n@0.6.1_react@19.2.8/node_modules/@hanzo/i18n/dist/resolve.js","../../node_modules/.pnpm/@hanzo+i18n@0.6.1_react@19.2.8/node_modules/@hanzo/i18n/dist/message.js","../../node_modules/.pnpm/@hanzo+i18n@0.6.1_react@19.2.8/node_modules/@hanzo/i18n/dist/format.js","../../node_modules/.pnpm/@hanzo+i18n@0.6.1_react@19.2.8/node_modules/@hanzo/i18n/dist/react.js","../../node_modules/.pnpm/@hanzo+ui@8.32.4_b8d39b8c7f735cdf822db78faac56616/node_modules/@hanzo/ui/dist/product/instrument.js"],"sourcesContent":["/**\n * @license React\n * react.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n MAYBE_ITERATOR_SYMBOL = Symbol.iterator;\nfunction getIteratorFn(maybeIterable) {\n if (null === maybeIterable || \"object\" !== typeof maybeIterable) return null;\n maybeIterable =\n (MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||\n maybeIterable[\"@@iterator\"];\n return \"function\" === typeof maybeIterable ? maybeIterable : null;\n}\nvar ReactNoopUpdateQueue = {\n isMounted: function () {\n return !1;\n },\n enqueueForceUpdate: function () {},\n enqueueReplaceState: function () {},\n enqueueSetState: function () {}\n },\n assign = Object.assign,\n emptyObject = {};\nfunction Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n}\nComponent.prototype.isReactComponent = {};\nComponent.prototype.setState = function (partialState, callback) {\n if (\n \"object\" !== typeof partialState &&\n \"function\" !== typeof partialState &&\n null != partialState\n )\n throw Error(\n \"takes an object of state variables to update or a function which returns an object of state variables.\"\n );\n this.updater.enqueueSetState(this, partialState, callback, \"setState\");\n};\nComponent.prototype.forceUpdate = function (callback) {\n this.updater.enqueueForceUpdate(this, callback, \"forceUpdate\");\n};\nfunction ComponentDummy() {}\nComponentDummy.prototype = Component.prototype;\nfunction PureComponent(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n}\nvar pureComponentPrototype = (PureComponent.prototype = new ComponentDummy());\npureComponentPrototype.constructor = PureComponent;\nassign(pureComponentPrototype, Component.prototype);\npureComponentPrototype.isPureReactComponent = !0;\nvar isArrayImpl = Array.isArray;\nfunction noop() {}\nvar ReactSharedInternals = { H: null, A: null, T: null, S: null },\n hasOwnProperty = Object.prototype.hasOwnProperty;\nfunction ReactElement(type, key, props) {\n var refProp = props.ref;\n return {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n ref: void 0 !== refProp ? refProp : null,\n props: props\n };\n}\nfunction cloneAndReplaceKey(oldElement, newKey) {\n return ReactElement(oldElement.type, newKey, oldElement.props);\n}\nfunction isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n}\nfunction escape(key) {\n var escaperLookup = { \"=\": \"=0\", \":\": \"=2\" };\n return (\n \"$\" +\n key.replace(/[=:]/g, function (match) {\n return escaperLookup[match];\n })\n );\n}\nvar userProvidedKeyEscapeRegex = /\\/+/g;\nfunction getElementKey(element, index) {\n return \"object\" === typeof element && null !== element && null != element.key\n ? escape(\"\" + element.key)\n : index.toString(36);\n}\nfunction resolveThenable(thenable) {\n switch (thenable.status) {\n case \"fulfilled\":\n return thenable.value;\n case \"rejected\":\n throw thenable.reason;\n default:\n switch (\n (\"string\" === typeof thenable.status\n ? thenable.then(noop, noop)\n : ((thenable.status = \"pending\"),\n thenable.then(\n function (fulfilledValue) {\n \"pending\" === thenable.status &&\n ((thenable.status = \"fulfilled\"),\n (thenable.value = fulfilledValue));\n },\n function (error) {\n \"pending\" === thenable.status &&\n ((thenable.status = \"rejected\"), (thenable.reason = error));\n }\n )),\n thenable.status)\n ) {\n case \"fulfilled\":\n return thenable.value;\n case \"rejected\":\n throw thenable.reason;\n }\n }\n throw thenable;\n}\nfunction mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {\n var type = typeof children;\n if (\"undefined\" === type || \"boolean\" === type) children = null;\n var invokeCallback = !1;\n if (null === children) invokeCallback = !0;\n else\n switch (type) {\n case \"bigint\":\n case \"string\":\n case \"number\":\n invokeCallback = !0;\n break;\n case \"object\":\n switch (children.$$typeof) {\n case REACT_ELEMENT_TYPE:\n case REACT_PORTAL_TYPE:\n invokeCallback = !0;\n break;\n case REACT_LAZY_TYPE:\n return (\n (invokeCallback = children._init),\n mapIntoArray(\n invokeCallback(children._payload),\n array,\n escapedPrefix,\n nameSoFar,\n callback\n )\n );\n }\n }\n if (invokeCallback)\n return (\n (callback = callback(children)),\n (invokeCallback =\n \"\" === nameSoFar ? \".\" + getElementKey(children, 0) : nameSoFar),\n isArrayImpl(callback)\n ? ((escapedPrefix = \"\"),\n null != invokeCallback &&\n (escapedPrefix =\n invokeCallback.replace(userProvidedKeyEscapeRegex, \"$&/\") + \"/\"),\n mapIntoArray(callback, array, escapedPrefix, \"\", function (c) {\n return c;\n }))\n : null != callback &&\n (isValidElement(callback) &&\n (callback = cloneAndReplaceKey(\n callback,\n escapedPrefix +\n (null == callback.key ||\n (children && children.key === callback.key)\n ? \"\"\n : (\"\" + callback.key).replace(\n userProvidedKeyEscapeRegex,\n \"$&/\"\n ) + \"/\") +\n invokeCallback\n )),\n array.push(callback)),\n 1\n );\n invokeCallback = 0;\n var nextNamePrefix = \"\" === nameSoFar ? \".\" : nameSoFar + \":\";\n if (isArrayImpl(children))\n for (var i = 0; i < children.length; i++)\n (nameSoFar = children[i]),\n (type = nextNamePrefix + getElementKey(nameSoFar, i)),\n (invokeCallback += mapIntoArray(\n nameSoFar,\n array,\n escapedPrefix,\n type,\n callback\n ));\n else if (((i = getIteratorFn(children)), \"function\" === typeof i))\n for (\n children = i.call(children), i = 0;\n !(nameSoFar = children.next()).done;\n\n )\n (nameSoFar = nameSoFar.value),\n (type = nextNamePrefix + getElementKey(nameSoFar, i++)),\n (invokeCallback += mapIntoArray(\n nameSoFar,\n array,\n escapedPrefix,\n type,\n callback\n ));\n else if (\"object\" === type) {\n if (\"function\" === typeof children.then)\n return mapIntoArray(\n resolveThenable(children),\n array,\n escapedPrefix,\n nameSoFar,\n callback\n );\n array = String(children);\n throw Error(\n \"Objects are not valid as a React child (found: \" +\n (\"[object Object]\" === array\n ? \"object with keys {\" + Object.keys(children).join(\", \") + \"}\"\n : array) +\n \"). If you meant to render a collection of children, use an array instead.\"\n );\n }\n return invokeCallback;\n}\nfunction mapChildren(children, func, context) {\n if (null == children) return children;\n var result = [],\n count = 0;\n mapIntoArray(children, result, \"\", \"\", function (child) {\n return func.call(context, child, count++);\n });\n return result;\n}\nfunction lazyInitializer(payload) {\n if (-1 === payload._status) {\n var ctor = payload._result;\n ctor = ctor();\n ctor.then(\n function (moduleObject) {\n if (0 === payload._status || -1 === payload._status)\n (payload._status = 1), (payload._result = moduleObject);\n },\n function (error) {\n if (0 === payload._status || -1 === payload._status)\n (payload._status = 2), (payload._result = error);\n }\n );\n -1 === payload._status && ((payload._status = 0), (payload._result = ctor));\n }\n if (1 === payload._status) return payload._result.default;\n throw payload._result;\n}\nvar reportGlobalError =\n \"function\" === typeof reportError\n ? reportError\n : function (error) {\n if (\n \"object\" === typeof window &&\n \"function\" === typeof window.ErrorEvent\n ) {\n var event = new window.ErrorEvent(\"error\", {\n bubbles: !0,\n cancelable: !0,\n message:\n \"object\" === typeof error &&\n null !== error &&\n \"string\" === typeof error.message\n ? String(error.message)\n : String(error),\n error: error\n });\n if (!window.dispatchEvent(event)) return;\n } else if (\n \"object\" === typeof process &&\n \"function\" === typeof process.emit\n ) {\n process.emit(\"uncaughtException\", error);\n return;\n }\n console.error(error);\n },\n Children = {\n map: mapChildren,\n forEach: function (children, forEachFunc, forEachContext) {\n mapChildren(\n children,\n function () {\n forEachFunc.apply(this, arguments);\n },\n forEachContext\n );\n },\n count: function (children) {\n var n = 0;\n mapChildren(children, function () {\n n++;\n });\n return n;\n },\n toArray: function (children) {\n return (\n mapChildren(children, function (child) {\n return child;\n }) || []\n );\n },\n only: function (children) {\n if (!isValidElement(children))\n throw Error(\n \"React.Children.only expected to receive a single React element child.\"\n );\n return children;\n }\n };\nexports.Activity = REACT_ACTIVITY_TYPE;\nexports.Children = Children;\nexports.Component = Component;\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.Profiler = REACT_PROFILER_TYPE;\nexports.PureComponent = PureComponent;\nexports.StrictMode = REACT_STRICT_MODE_TYPE;\nexports.Suspense = REACT_SUSPENSE_TYPE;\nexports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =\n ReactSharedInternals;\nexports.__COMPILER_RUNTIME = {\n __proto__: null,\n c: function (size) {\n return ReactSharedInternals.H.useMemoCache(size);\n }\n};\nexports.cache = function (fn) {\n return function () {\n return fn.apply(null, arguments);\n };\n};\nexports.cacheSignal = function () {\n return null;\n};\nexports.cloneElement = function (element, config, children) {\n if (null === element || void 0 === element)\n throw Error(\n \"The argument must be a React element, but you passed \" + element + \".\"\n );\n var props = assign({}, element.props),\n key = element.key;\n if (null != config)\n for (propName in (void 0 !== config.key && (key = \"\" + config.key), config))\n !hasOwnProperty.call(config, propName) ||\n \"key\" === propName ||\n \"__self\" === propName ||\n \"__source\" === propName ||\n (\"ref\" === propName && void 0 === config.ref) ||\n (props[propName] = config[propName]);\n var propName = arguments.length - 2;\n if (1 === propName) props.children = children;\n else if (1 < propName) {\n for (var childArray = Array(propName), i = 0; i < propName; i++)\n childArray[i] = arguments[i + 2];\n props.children = childArray;\n }\n return ReactElement(element.type, key, props);\n};\nexports.createContext = function (defaultValue) {\n defaultValue = {\n $$typeof: REACT_CONTEXT_TYPE,\n _currentValue: defaultValue,\n _currentValue2: defaultValue,\n _threadCount: 0,\n Provider: null,\n Consumer: null\n };\n defaultValue.Provider = defaultValue;\n defaultValue.Consumer = {\n $$typeof: REACT_CONSUMER_TYPE,\n _context: defaultValue\n };\n return defaultValue;\n};\nexports.createElement = function (type, config, children) {\n var propName,\n props = {},\n key = null;\n if (null != config)\n for (propName in (void 0 !== config.key && (key = \"\" + config.key), config))\n hasOwnProperty.call(config, propName) &&\n \"key\" !== propName &&\n \"__self\" !== propName &&\n \"__source\" !== propName &&\n (props[propName] = config[propName]);\n var childrenLength = arguments.length - 2;\n if (1 === childrenLength) props.children = children;\n else if (1 < childrenLength) {\n for (var childArray = Array(childrenLength), i = 0; i < childrenLength; i++)\n childArray[i] = arguments[i + 2];\n props.children = childArray;\n }\n if (type && type.defaultProps)\n for (propName in ((childrenLength = type.defaultProps), childrenLength))\n void 0 === props[propName] &&\n (props[propName] = childrenLength[propName]);\n return ReactElement(type, key, props);\n};\nexports.createRef = function () {\n return { current: null };\n};\nexports.forwardRef = function (render) {\n return { $$typeof: REACT_FORWARD_REF_TYPE, render: render };\n};\nexports.isValidElement = isValidElement;\nexports.lazy = function (ctor) {\n return {\n $$typeof: REACT_LAZY_TYPE,\n _payload: { _status: -1, _result: ctor },\n _init: lazyInitializer\n };\n};\nexports.memo = function (type, compare) {\n return {\n $$typeof: REACT_MEMO_TYPE,\n type: type,\n compare: void 0 === compare ? null : compare\n };\n};\nexports.startTransition = function (scope) {\n var prevTransition = ReactSharedInternals.T,\n currentTransition = {};\n ReactSharedInternals.T = currentTransition;\n try {\n var returnValue = scope(),\n onStartTransitionFinish = ReactSharedInternals.S;\n null !== onStartTransitionFinish &&\n onStartTransitionFinish(currentTransition, returnValue);\n \"object\" === typeof returnValue &&\n null !== returnValue &&\n \"function\" === typeof returnValue.then &&\n returnValue.then(noop, reportGlobalError);\n } catch (error) {\n reportGlobalError(error);\n } finally {\n null !== prevTransition &&\n null !== currentTransition.types &&\n (prevTransition.types = currentTransition.types),\n (ReactSharedInternals.T = prevTransition);\n }\n};\nexports.unstable_useCacheRefresh = function () {\n return ReactSharedInternals.H.useCacheRefresh();\n};\nexports.use = function (usable) {\n return ReactSharedInternals.H.use(usable);\n};\nexports.useActionState = function (action, initialState, permalink) {\n return ReactSharedInternals.H.useActionState(action, initialState, permalink);\n};\nexports.useCallback = function (callback, deps) {\n return ReactSharedInternals.H.useCallback(callback, deps);\n};\nexports.useContext = function (Context) {\n return ReactSharedInternals.H.useContext(Context);\n};\nexports.useDebugValue = function () {};\nexports.useDeferredValue = function (value, initialValue) {\n return ReactSharedInternals.H.useDeferredValue(value, initialValue);\n};\nexports.useEffect = function (create, deps) {\n return ReactSharedInternals.H.useEffect(create, deps);\n};\nexports.useEffectEvent = function (callback) {\n return ReactSharedInternals.H.useEffectEvent(callback);\n};\nexports.useId = function () {\n return ReactSharedInternals.H.useId();\n};\nexports.useImperativeHandle = function (ref, create, deps) {\n return ReactSharedInternals.H.useImperativeHandle(ref, create, deps);\n};\nexports.useInsertionEffect = function (create, deps) {\n return ReactSharedInternals.H.useInsertionEffect(create, deps);\n};\nexports.useLayoutEffect = function (create, deps) {\n return ReactSharedInternals.H.useLayoutEffect(create, deps);\n};\nexports.useMemo = function (create, deps) {\n return ReactSharedInternals.H.useMemo(create, deps);\n};\nexports.useOptimistic = function (passthrough, reducer) {\n return ReactSharedInternals.H.useOptimistic(passthrough, reducer);\n};\nexports.useReducer = function (reducer, initialArg, init) {\n return ReactSharedInternals.H.useReducer(reducer, initialArg, init);\n};\nexports.useRef = function (initialValue) {\n return ReactSharedInternals.H.useRef(initialValue);\n};\nexports.useState = function (initialState) {\n return ReactSharedInternals.H.useState(initialState);\n};\nexports.useSyncExternalStore = function (\n subscribe,\n getSnapshot,\n getServerSnapshot\n) {\n return ReactSharedInternals.H.useSyncExternalStore(\n subscribe,\n getSnapshot,\n getServerSnapshot\n );\n};\nexports.useTransition = function () {\n return ReactSharedInternals.H.useTransition();\n};\nexports.version = \"19.2.8\";\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react.production.js');\n} else {\n module.exports = require('./cjs/react.development.js');\n}\n","/**\n * @license React\n * react-dom.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar React = require(\"react\");\nfunction formatProdErrorMessage(code) {\n var url = \"https://react.dev/errors/\" + code;\n if (1 < arguments.length) {\n url += \"?args[]=\" + encodeURIComponent(arguments[1]);\n for (var i = 2; i < arguments.length; i++)\n url += \"&args[]=\" + encodeURIComponent(arguments[i]);\n }\n return (\n \"Minified React error #\" +\n code +\n \"; visit \" +\n url +\n \" for the full message or use the non-minified dev environment for full errors and additional helpful warnings.\"\n );\n}\nfunction noop() {}\nvar Internals = {\n d: {\n f: noop,\n r: function () {\n throw Error(formatProdErrorMessage(522));\n },\n D: noop,\n C: noop,\n L: noop,\n m: noop,\n X: noop,\n S: noop,\n M: noop\n },\n p: 0,\n findDOMNode: null\n },\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\");\nfunction createPortal$1(children, containerInfo, implementation) {\n var key =\n 3 < arguments.length && void 0 !== arguments[3] ? arguments[3] : null;\n return {\n $$typeof: REACT_PORTAL_TYPE,\n key: null == key ? null : \"\" + key,\n children: children,\n containerInfo: containerInfo,\n implementation: implementation\n };\n}\nvar ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;\nfunction getCrossOriginStringAs(as, input) {\n if (\"font\" === as) return \"\";\n if (\"string\" === typeof input)\n return \"use-credentials\" === input ? input : \"\";\n}\nexports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =\n Internals;\nexports.createPortal = function (children, container) {\n var key =\n 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : null;\n if (\n !container ||\n (1 !== container.nodeType &&\n 9 !== container.nodeType &&\n 11 !== container.nodeType)\n )\n throw Error(formatProdErrorMessage(299));\n return createPortal$1(children, container, null, key);\n};\nexports.flushSync = function (fn) {\n var previousTransition = ReactSharedInternals.T,\n previousUpdatePriority = Internals.p;\n try {\n if (((ReactSharedInternals.T = null), (Internals.p = 2), fn)) return fn();\n } finally {\n (ReactSharedInternals.T = previousTransition),\n (Internals.p = previousUpdatePriority),\n Internals.d.f();\n }\n};\nexports.preconnect = function (href, options) {\n \"string\" === typeof href &&\n (options\n ? ((options = options.crossOrigin),\n (options =\n \"string\" === typeof options\n ? \"use-credentials\" === options\n ? options\n : \"\"\n : void 0))\n : (options = null),\n Internals.d.C(href, options));\n};\nexports.prefetchDNS = function (href) {\n \"string\" === typeof href && Internals.d.D(href);\n};\nexports.preinit = function (href, options) {\n if (\"string\" === typeof href && options && \"string\" === typeof options.as) {\n var as = options.as,\n crossOrigin = getCrossOriginStringAs(as, options.crossOrigin),\n integrity =\n \"string\" === typeof options.integrity ? options.integrity : void 0,\n fetchPriority =\n \"string\" === typeof options.fetchPriority\n ? options.fetchPriority\n : void 0;\n \"style\" === as\n ? Internals.d.S(\n href,\n \"string\" === typeof options.precedence ? options.precedence : void 0,\n {\n crossOrigin: crossOrigin,\n integrity: integrity,\n fetchPriority: fetchPriority\n }\n )\n : \"script\" === as &&\n Internals.d.X(href, {\n crossOrigin: crossOrigin,\n integrity: integrity,\n fetchPriority: fetchPriority,\n nonce: \"string\" === typeof options.nonce ? options.nonce : void 0\n });\n }\n};\nexports.preinitModule = function (href, options) {\n if (\"string\" === typeof href)\n if (\"object\" === typeof options && null !== options) {\n if (null == options.as || \"script\" === options.as) {\n var crossOrigin = getCrossOriginStringAs(\n options.as,\n options.crossOrigin\n );\n Internals.d.M(href, {\n crossOrigin: crossOrigin,\n integrity:\n \"string\" === typeof options.integrity ? options.integrity : void 0,\n nonce: \"string\" === typeof options.nonce ? options.nonce : void 0\n });\n }\n } else null == options && Internals.d.M(href);\n};\nexports.preload = function (href, options) {\n if (\n \"string\" === typeof href &&\n \"object\" === typeof options &&\n null !== options &&\n \"string\" === typeof options.as\n ) {\n var as = options.as,\n crossOrigin = getCrossOriginStringAs(as, options.crossOrigin);\n Internals.d.L(href, as, {\n crossOrigin: crossOrigin,\n integrity:\n \"string\" === typeof options.integrity ? options.integrity : void 0,\n nonce: \"string\" === typeof options.nonce ? options.nonce : void 0,\n type: \"string\" === typeof options.type ? options.type : void 0,\n fetchPriority:\n \"string\" === typeof options.fetchPriority\n ? options.fetchPriority\n : void 0,\n referrerPolicy:\n \"string\" === typeof options.referrerPolicy\n ? options.referrerPolicy\n : void 0,\n imageSrcSet:\n \"string\" === typeof options.imageSrcSet ? options.imageSrcSet : void 0,\n imageSizes:\n \"string\" === typeof options.imageSizes ? options.imageSizes : void 0,\n media: \"string\" === typeof options.media ? options.media : void 0\n });\n }\n};\nexports.preloadModule = function (href, options) {\n if (\"string\" === typeof href)\n if (options) {\n var crossOrigin = getCrossOriginStringAs(options.as, options.crossOrigin);\n Internals.d.m(href, {\n as:\n \"string\" === typeof options.as && \"script\" !== options.as\n ? options.as\n : void 0,\n crossOrigin: crossOrigin,\n integrity:\n \"string\" === typeof options.integrity ? options.integrity : void 0\n });\n } else Internals.d.m(href);\n};\nexports.requestFormReset = function (form) {\n Internals.d.r(form);\n};\nexports.unstable_batchedUpdates = function (fn, a) {\n return fn(a);\n};\nexports.useFormState = function (action, initialState, permalink) {\n return ReactSharedInternals.H.useFormState(action, initialState, permalink);\n};\nexports.useFormStatus = function () {\n return ReactSharedInternals.H.useHostTransitionStatus();\n};\nexports.version = \"19.2.8\";\n","'use strict';\n\nfunction checkDCE() {\n /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */\n if (\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined' ||\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE !== 'function'\n ) {\n return;\n }\n if (process.env.NODE_ENV !== 'production') {\n // This branch is unreachable because this function is only called\n // in production, but the condition is true only in development.\n // Therefore if the branch is still here, dead code elimination wasn't\n // properly applied.\n // Don't change the message. React DevTools relies on it. Also make sure\n // this message doesn't occur elsewhere in this function, or it will cause\n // a false positive.\n throw new Error('^_^');\n }\n try {\n // Verify that the code above has been dead code eliminated (DCE'd).\n __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE);\n } catch (err) {\n // DevTools shouldn't crash React, no matter what.\n // We should still report in case we break this code.\n console.error(err);\n }\n}\n\nif (process.env.NODE_ENV === 'production') {\n // DCE check should happen before ReactDOM bundle executes so that\n // DevTools can report bad minification during injection.\n checkDCE();\n module.exports = require('./cjs/react-dom.production.js');\n} else {\n module.exports = require('./cjs/react-dom.development.js');\n}\n","// The ONE product-analytics vocabulary. Every Hanzo surface emits these exact\n// names so funnels, goals, and cohorts line up across console/chat/app/site/admin.\n// Pageviews use the reserved \"$pageview\" name (emitted by analytics.pageview()),\n// matching the server read lens.\n//\n// Naming is a closed convention, not a style preference (see TAXONOMY.md):\n// • snake_case, `<object>_<verb-in-past-tense>` — signup_completed, plan_clicked.\n// • Names are CONSTANTS, never interpolated. A dimension (framework, model,\n// plan, source) is a PROPERTY, never part of the name. `deploy_succeeded`\n// with {framework:'static'} — never `deploy_static_succeeded`.\n// • One name per user-visible moment, shared by every surface. The surface is\n// already on the wire as `product`, so a name is never product-prefixed.\nexport const EVENTS = {\n // Signup funnel: view -> submit -> verify -> completed -> first action.\n SIGNUP_VIEWED: 'signup_viewed',\n SIGNUP_SUBMITTED: 'signup_submitted',\n SIGNUP_VERIFIED: 'signup_verified',\n SIGNUP_COMPLETED: 'signup_completed',\n /** A RETURNING user authenticated — the non-signup half of the IAM callback.\n * Keeping it distinct is what stops returning logins from inflating signups. */\n LOGIN_COMPLETED: 'login_completed',\n LOGOUT_COMPLETED: 'logout_completed',\n /** Activation: the first moment of real value. ONE event for every product —\n * the product-specific moment is the `action` property (api_call, app_live,\n * chat_reply), never a new event name. */\n FIRST_ACTION: 'first_action',\n // Waitlist + referral.\n WAITLIST_JOINED: 'waitlist_joined',\n WAITLIST_SHARED: 'waitlist_shared',\n REFERRAL_USED: 'referral_used',\n REFERRAL_CLAIMED: 'referral_claimed',\n // Upgrade-intent + purchase.\n PRICING_VIEWED: 'pricing_viewed',\n PLAN_CLICKED: 'plan_clicked',\n PLAN_SELECTED: 'plan_selected',\n PLAN_SKIPPED: 'plan_skipped',\n PLAN_CHANGED: 'plan_changed',\n UPGRADE_CLICKED: 'upgrade_clicked',\n CHECKOUT_STARTED: 'checkout_started',\n PAYMENT_INFO_ADDED: 'payment_info_added',\n CHECKOUT_FAILED: 'checkout_failed',\n ORDER_COMPLETED: 'order_completed',\n SUBSCRIPTION_CHANGED: 'subscription_changed',\n SUBSCRIPTION_CANCELED: 'subscription_canceled',\n ORDER_REFUNDED: 'order_refunded',\n SALES_CONTACTED: 'sales_contacted',\n // Marketing: what the site's audiences are built from. A product, model or\n // service page seen, a search asked, a call to action pressed, and the three\n // ways in short of an account — the newsletter, a beta application, a research\n // access request. The page or product is a property, never part of the name.\n PRODUCT_VIEWED: 'product_viewed',\n SEARCH_PERFORMED: 'search_performed',\n CTA_CLICKED: 'cta_clicked',\n NEWSLETTER_SUBSCRIBED: 'newsletter_subscribed',\n BETA_SUBMITTED: 'beta_submitted',\n RESEARCH_ACCESS_APPLIED: 'research_access_applied',\n // Onboarding, after sign-in: how it will be used, the team, the notice, the\n // name, the role, the first prompt.\n USAGE_SELECTED: 'usage_selected',\n TEAM_CREATED: 'team_created',\n FIRST_CHAT_NOTICE_ACCEPTED: 'first_chat_notice_accepted',\n NAME_SET: 'name_set',\n ROLE_SELECTED: 'role_selected',\n STARTER_PROMPT_USED: 'starter_prompt_used',\n OWN_TOPIC_CHOSEN: 'own_topic_chosen',\n // Feature usage — generic + the common key surfaces across products.\n FEATURE_USED: 'feature_used',\n API_KEY_CREATED: 'api_key_created',\n APP_CREATED: 'app_created',\n PROJECT_CREATED: 'project_created',\n AGENT_CREATED: 'agent_created',\n CHAT_STARTED: 'chat_started',\n CHAT_MESSAGE_SENT: 'chat_message_sent',\n /** The user switched model/endpoint — the single strongest quality signal a\n * chat surface emits (a switch usually follows a bad answer). */\n MODEL_SWITCHED: 'model_switched',\n TASK_STARTED: 'task_started',\n TASK_COMPLETED: 'task_completed',\n // Build → ship. `build_*` is a MODEL producing an artifact; `deploy_*` is that\n // artifact going live. Intent (build_started) is never the same event as the\n // artifact existing (app_created) — conflating them makes the funnel lie.\n BUILD_STARTED: 'build_started',\n /** A model finished producing an artifact (an app build, a chat reply, an agent\n * run). Carries `durationMs` — the outcome event owns its own duration, so no\n * paired start event is needed. */\n GENERATION_COMPLETED: 'generation_completed',\n GENERATION_FAILED: 'generation_failed',\n DEPLOY_STARTED: 'deploy_started',\n DEPLOY_SUCCEEDED: 'deploy_succeeded',\n DEPLOY_FAILED: 'deploy_failed',\n};\n/** The reserved event name a pageview is stored under (server + read lens). */\nexport const PAGEVIEW = '$pageview';\n/** The reserved name every captured exception is emitted under. Error Tracking\n * reads exactly this name; an exception emitted under its own message instead\n * makes every distinct message a permanent entry in the event taxonomy. */\nexport const EXCEPTION = '$exception';\n","/**\n * What each event is called on every ad and analytics platform.\n *\n * ONE table, two readers. The browser tag loader in @hanzo/event reads it to\n * fire each platform's pixel under the event's own id, and cloud's server-side\n * forwarder reads it (as `platforms` in catalog.json) to send the same event\n * to each platform's conversion API. Because both read this file, a browser\n * copy and its server copy carry the same name and the platform counts one.\n *\n * An event absent from a platform's column is not sent there. A value that is\n * an array sends each name in order, under the same event id: the first is the\n * event, the rest are what the platform also wants for the same moment.\n *\n * LinkedIn and X do not name events in the pixel: an advertiser creates one\n * conversion rule per kind, and the pixel is told which rule fired. Their\n * column names the KIND (`sign_up`, `purchase`, `lead`, `begin_checkout`); the\n * rule ids for each kind are tag configuration, never code.\n *\n * `standard` is the normalized name cloud's adapters that do not name events\n * (Google Ads, Pinterest, Reddit) key on. `ads` marks the moments Google Ads\n * (and so YouTube ads) counts as conversions. `money` marks the moments that\n * state an amount (a purchase, a change of subscription, a refund): cloud sends\n * one to a platform only when a peer app or the org's secret key stated it.\n */\nexport const PLATFORMS = {\n // ── Sign-up ────────────────────────────────────────────────────\n signup_viewed: { standard: 'view_content', ga4: 'view_item', meta: 'ViewContent', tiktok: 'ViewContent' },\n signup_submitted: { standard: 'lead', ga4: 'generate_lead', meta: 'Lead' },\n signup_completed: {\n standard: 'signup',\n ga4: 'sign_up',\n meta: 'CompleteRegistration',\n linkedin: 'sign_up',\n x: 'sign_up',\n tiktok: 'CompleteRegistration',\n ads: true,\n },\n login_completed: { standard: 'login', ga4: 'login' },\n first_action: { ga4: 'first_message' },\n // ── Plans and checkout: the commerce funnel ────────────────────\n pricing_viewed: { standard: 'view_item_list', ga4: 'view_item_list', meta: 'ViewContent', tiktok: 'ViewContent' },\n plan_clicked: { standard: 'select_item', ga4: 'select_item', meta: 'PlanClicked', tiktok: 'ClickButton' },\n plan_selected: { standard: 'add_to_cart', ga4: 'add_to_cart', meta: 'AddToCart', x: 'add_to_cart', tiktok: 'AddToCart' },\n plan_changed: { ga4: ['remove_from_cart', 'add_to_cart'], meta: 'CustomizeProduct' },\n plan_skipped: { ga4: 'plan_skipped', meta: 'PlanSkipped' },\n upgrade_clicked: { ga4: 'select_promotion', meta: 'UpgradeClicked' },\n checkout_started: {\n standard: 'start_checkout',\n ga4: 'begin_checkout',\n meta: 'InitiateCheckout',\n linkedin: 'begin_checkout',\n x: 'begin_checkout',\n tiktok: 'InitiateCheckout',\n ads: true,\n },\n payment_info_added: { ga4: 'add_payment_info', meta: 'AddPaymentInfo', tiktok: 'AddPaymentInfo' },\n checkout_failed: { ga4: 'checkout_failed', meta: 'CheckoutFailed' },\n order_completed: {\n standard: 'purchase',\n ga4: 'purchase',\n meta: ['Purchase', 'Subscribe'],\n linkedin: 'purchase',\n x: 'purchase',\n tiktok: 'CompletePayment',\n ads: true,\n money: true,\n },\n subscription_changed: { ga4: 'purchase', meta: 'Subscribe', money: true },\n subscription_canceled: { ga4: 'subscription_canceled', meta: 'SubscriptionCanceled' },\n order_refunded: { ga4: 'refund', meta: 'OrderRefunded', money: true },\n // ── Leads ──────────────────────────────────────────────────────\n sales_contacted: {\n standard: 'lead',\n ga4: 'generate_lead',\n meta: 'Lead',\n linkedin: 'lead',\n x: 'lead',\n tiktok: 'SubmitForm',\n ads: true,\n },\n waitlist_joined: { standard: 'lead', ga4: 'generate_lead', meta: 'Lead', linkedin: 'lead', x: 'lead', tiktok: 'SubmitForm' },\n referral_used: { standard: 'lead' },\n newsletter_subscribed: { standard: 'lead', ga4: 'generate_lead', meta: 'Lead', linkedin: 'lead', x: 'lead', tiktok: 'SubmitForm' },\n beta_submitted: { standard: 'lead', ga4: 'generate_lead', meta: 'Lead', linkedin: 'lead', x: 'lead', tiktok: 'SubmitForm' },\n research_access_applied: { standard: 'lead', ga4: 'generate_lead', meta: 'Lead', linkedin: 'lead', x: 'lead', tiktok: 'SubmitForm' },\n // ── Audiences: what retargeting is built from ──────────────────\n product_viewed: { standard: 'view_content', ga4: 'view_item', meta: 'ViewContent', tiktok: 'ViewContent' },\n search_performed: { standard: 'search', ga4: 'search', meta: 'Search', tiktok: 'Search' },\n // A custom event on each: no platform has a standard name for a pressed button.\n cta_clicked: { ga4: 'cta_click', meta: 'CTAClicked', tiktok: 'ClickButton' },\n};\n/** The names an event goes by on a platform: [] when the platform is not sent it. */\nexport function namesOn(event, platform) {\n const n = PLATFORMS[event]?.[platform];\n return n === undefined ? [] : typeof n === 'string' ? [n] : n;\n}\n","// The ONE funnel registry. A funnel is DATA — an ordered list of event names —\n// so the products, the read lens and the docs can never drift: every step is a\n// name from EVENTS (test/funnels.mjs fails the build otherwise), and a GOAL that\n// has a funnel points AT one of these rather than restating the steps.\n//\n// It lives beside the vocabulary rather than in the client because the read lens\n// is Go and cannot import TypeScript. The catalog already ships as JSON for that\n// reader, so the funnels ride the same file: one definition, two readers, and no\n// second place a step could be named.\nimport { EVENTS, PAGEVIEW } from './names.js';\n/** The emitting surfaces — the closed set of `AnalyticsConfig.product` values.\n * `product` is on every event, so a funnel scopes by product instead of every\n * surface prefixing its event names. */\nexport const PRODUCTS = [\n 'site',\n 'app',\n 'chat',\n 'console',\n 'admin',\n 'cloud',\n 'id',\n 'billing',\n 'pay',\n 'commerce',\n];\nconst s = (event, label, extra) => ({ event, label, ...(extra ?? {}) });\nexport const FUNNELS = {\n /** Land on hanzo.ai → account created. hanzo.id hosts the form and is its own\n * registrable domain, so the middle of this journey is a different identity\n * space from the ends: AGGREGATE, and read step over step. Those two id steps\n * are the part that used to be dark — everything between \"we sent them to\n * sign up\" and \"they came back\" happened where nothing was counted. */\n signup: {\n label: 'Signup',\n products: ['site', 'id'],\n join: 'aggregate',\n steps: [\n s(PAGEVIEW, 'Landed', { product: 'site' }),\n s(EVENTS.SIGNUP_VIEWED, 'Opened signup', { product: 'site' }),\n s(EVENTS.SIGNUP_SUBMITTED, 'Redirected to Hanzo ID', { product: 'site' }),\n s(EVENTS.SIGNUP_VIEWED, 'Saw the form', { product: 'id' }),\n s(EVENTS.SIGNUP_SUBMITTED, 'Submitted the form', { product: 'id' }),\n s(EVENTS.SIGNUP_COMPLETED, 'Account created', { product: 'site' }),\n ],\n },\n /** One visitor, first page to first use: sign-up, how they will use Hanzo, the\n * plan, checkout, the first action. Every surface emits the same names, so it\n * joins per person; the plan step is `plan_selected` or `plan_skipped`, and\n * the funnel counts the paid path (skipped is the free branch). */\n journey: {\n label: 'Hanzo journey',\n products: ['site', 'app', 'chat', 'pay', 'commerce'],\n join: 'person',\n steps: [\n s(PAGEVIEW, 'Landed'),\n s(EVENTS.SIGNUP_VIEWED, 'Saw sign-up'),\n s(EVENTS.SIGNUP_SUBMITTED, 'Asked for an account'),\n s(EVENTS.SIGNUP_COMPLETED, 'Account created'),\n s(EVENTS.USAGE_SELECTED, 'Said how they will use Hanzo'),\n s(EVENTS.PRICING_VIEWED, 'Saw plans'),\n s(EVENTS.PLAN_CLICKED, 'Pressed a plan'),\n s(EVENTS.PLAN_SELECTED, 'Opened checkout on a plan'),\n s(EVENTS.CHECKOUT_STARTED, 'Saw the billing form'),\n s(EVENTS.PAYMENT_INFO_ADDED, 'Card tokenized'),\n s(EVENTS.ORDER_COMPLETED, 'Paid'),\n s(EVENTS.FIRST_ACTION, 'First action'),\n ],\n },\n /** The developer activation path: an account is worth nothing until a key has\n * made a call. `first_action{action:'api_call'}` is emitted SERVER-SIDE by\n * Cloud on an org's first successful /v1 request — a browser cannot see it. */\n apiActivation: {\n label: 'API activation',\n products: ['site', 'cloud'],\n join: 'person',\n steps: [\n s(EVENTS.SIGNUP_COMPLETED, 'Account created'),\n s(EVENTS.API_KEY_CREATED, 'Key minted'),\n s(EVENTS.FIRST_ACTION, 'First successful API call', {\n where: { property: 'action', equals: 'api_call' },\n }),\n ],\n },\n /** Upgrade intent → revenue, and the whole path is under one registrable\n * domain (www, billing and pay are all hanzo.ai), so it joins per PERSON.\n * The two checkout steps are two surfaces: billing hands off to pay, and a\n * buyer lost in that hop is the drop-off nobody could see. */\n upgrade: {\n label: 'Upgrade',\n products: ['site', 'app', 'console', 'billing', 'pay'],\n join: 'person',\n steps: [\n s(EVENTS.PRICING_VIEWED, 'Viewed pricing'),\n s(EVENTS.PLAN_CLICKED, 'Chose a plan'),\n s(EVENTS.CHECKOUT_STARTED, 'Left for checkout', { product: 'billing' }),\n s(EVENTS.CHECKOUT_STARTED, 'Reached the card form', { product: 'pay' }),\n s(EVENTS.ORDER_COMPLETED, 'Paid'),\n ],\n },\n /** hanzo.app: describe → build → deploy → live URL. The whole product thesis\n * in five steps; `deploy_succeeded` is the moment a live URL exists. */\n appShip: {\n label: 'Describe → ship',\n products: ['app'],\n join: 'person',\n steps: [\n s(PAGEVIEW, 'Landed'),\n s(EVENTS.BUILD_STARTED, 'Described an app'),\n s(EVENTS.GENERATION_COMPLETED, 'Got a working build'),\n s(EVENTS.DEPLOY_STARTED, 'Hit publish'),\n s(EVENTS.DEPLOY_SUCCEEDED, 'Live URL'),\n ],\n },\n /** hanzo.chat: visit → first message → answer. `generation_completed` is what\n * separates \"typed something\" from \"got value\". */\n chatEngage: {\n label: 'Chat engagement',\n products: ['chat'],\n join: 'person',\n steps: [\n s(PAGEVIEW, 'Landed'),\n s(EVENTS.CHAT_STARTED, 'Started a conversation'),\n s(EVENTS.CHAT_MESSAGE_SENT, 'Sent a message'),\n s(EVENTS.GENERATION_COMPLETED, 'Got an answer'),\n ],\n },\n /** The cross-surface handoff: the hanzo.ai composer forwards its prompt to\n * hanzo.chat. Two origins, two anonymousIds — so this is an AGGREGATE funnel.\n * The join is the `referrerProduct` property hanzo.chat reads off `?hz_ref=`,\n * which makes the drop-off measurable without any cross-domain identity. */\n siteToChat: {\n label: 'Site → Chat handoff',\n products: ['site', 'chat'],\n join: 'aggregate',\n steps: [\n s(EVENTS.CHAT_STARTED, 'Submitted the hanzo.ai composer', {\n product: 'site',\n where: { property: 'source', equals: 'composer' },\n }),\n s(EVENTS.CHAT_STARTED, 'Landed in hanzo.chat', {\n product: 'chat',\n where: { property: 'referrerProduct', equals: 'site' },\n }),\n s(EVENTS.GENERATION_COMPLETED, 'Got an answer'),\n ],\n },\n};\n/** eventsOf flattens a funnel to its ordered event names — what a goal's `funnel`\n * field carries, so the steps are defined exactly once (here). */\nexport function eventsOf(id) {\n return FUNNELS[id].steps.map((step) => step.event);\n}\n","/**\n * @hanzo/events — the canonical event schema.\n *\n * Which events exist, what each one means, and what it carries. This is the\n * vocabulary; @hanzo/event is the client that sends one.\n *\n * Plural and singular split along the thing they describe: many events are\n * defined here, one event is sent by a call there. The client depends on this\n * package and re-exports EVENTS, so a surface can keep importing either — but\n * there is only one definition, here.\n *\n * The catalog also ships as `catalog.json` beside the built output, because the\n * ingest endpoint is Go and cannot import TypeScript. One source, two readers.\n */\nexport { EVENTS, PAGEVIEW, EXCEPTION } from './names.js';\nexport { SCHEMA } from './schema.js';\nexport { PLATFORMS, namesOn } from './platforms.js';\nexport { FUNNELS, PRODUCTS, eventsOf } from './funnels.js';\nimport { EVENTS, PAGEVIEW, EXCEPTION } from './names.js';\nimport { SCHEMA } from './schema.js';\n/** Every event name in the vocabulary, as it travels on the wire. */\nexport const NAMES = Object.freeze(Object.values(EVENTS));\n/** The two reserved names: a pageview and a captured exception. */\nexport const RESERVED = Object.freeze([PAGEVIEW, EXCEPTION]);\n/**\n * Is this a name the vocabulary knows?\n *\n * The ingest endpoint RECORDS an unknown event rather than refusing it, and flags\n * it. Refusing would mean a surface shipping a new event before the catalog\n * does loses the data outright, and the data is the thing you cannot recover;\n * a flag you can act on later. So this answers a question about the catalog,\n * never about whether to accept.\n */\nexport function isKnown(name) {\n return name in SCHEMA || RESERVED.includes(name);\n}\n/** What an event means and carries, or undefined if it is not in the catalog. */\nexport function specFor(name) {\n return SCHEMA[name];\n}\n","import { eventsOf, EVENTS, PAGEVIEW, namesOn } from '@hanzo/events';\nexport { EVENTS, EXCEPTION, FUNNELS, PAGEVIEW, PRODUCTS, eventsOf } from '@hanzo/events';\n\n// src/attribution.ts\nvar SOCIAL_HOSTS = [\n \"facebook.\",\n \"instagram.\",\n \"twitter.\",\n \"x.com\",\n \"t.co\",\n \"linkedin.\",\n \"reddit.\",\n \"youtube.\",\n \"tiktok.\",\n \"pinterest.\",\n \"news.ycombinator.com\"\n];\nvar SEARCH_HOSTS = [\"google.\", \"bing.\", \"duckduckgo.\", \"yahoo.\", \"baidu.\", \"ecosia.\"];\nfunction parseAttribution(search, referrer) {\n const q = new URLSearchParams(search || \"\");\n const get2 = (k) => {\n const v = q.get(k);\n return v ? v.trim() : void 0;\n };\n const a = {\n utm: {\n source: get2(\"utm_source\"),\n medium: get2(\"utm_medium\"),\n campaign: get2(\"utm_campaign\"),\n term: get2(\"utm_term\"),\n content: get2(\"utm_content\")\n },\n referrer: referrer ? referrer.trim() : void 0,\n refCode: get2(\"ref\") || get2(\"refCode\") || get2(\"ref_code\") || void 0\n };\n a.channel = deriveChannel(a);\n return a;\n}\nfunction deriveChannel(a) {\n const medium = (a.utm.medium || \"\").toLowerCase();\n if (/(cpc|ppc|paid|paidsearch|display|cpm)/.test(medium)) return \"paid\";\n if (a.utm.source || a.utm.campaign) return \"campaign\";\n if (a.refCode) return \"referral\";\n const host = hostOf(a.referrer);\n if (!host) return \"direct\";\n if (SOCIAL_HOSTS.some((h) => host.includes(h))) return \"social\";\n if (SEARCH_HOSTS.some((h) => host.includes(h))) return \"organic\";\n return \"referral\";\n}\nfunction hostOf(raw) {\n if (!raw) return \"\";\n let s = raw.trim();\n const scheme = s.indexOf(\"://\");\n if (scheme >= 0) s = s.slice(scheme + 3);\n const cut = s.search(/[/?#]/);\n if (cut >= 0) s = s.slice(0, cut);\n const at = s.indexOf(\"@\");\n if (at >= 0) s = s.slice(at + 1);\n const colon = s.indexOf(\":\");\n if (colon >= 0) s = s.slice(0, colon);\n return s.toLowerCase().trim();\n}\nfunction hasAttribution(a) {\n return Boolean(\n a.utm.source || a.utm.medium || a.utm.campaign || a.utm.term || a.utm.content || a.refCode || a.referrer && hostOf(a.referrer)\n );\n}\nfunction isoWeek(d) {\n const date = new Date(Date.UTC(d.getUTCFullYear(), d.getUTCMonth(), d.getUTCDate()));\n const day = date.getUTCDay() || 7;\n date.setUTCDate(date.getUTCDate() + 4 - day);\n const yearStart = new Date(Date.UTC(date.getUTCFullYear(), 0, 1));\n const week = Math.ceil(((date.getTime() - yearStart.getTime()) / 864e5 + 1) / 7);\n return `${date.getUTCFullYear()}-W${String(week).padStart(2, \"0\")}`;\n}\n\n// src/org.ts\nvar ORG_DOMAIN = Object.freeze({\n // A brand's domains are not a pattern — `hanzoskills.com` is Hanzo's and does\n // not end in `hanzo.ai`, while `hanzo.works` is a registrable domain of its own\n // rather than a subdomain of anything here. Each is stated because each is a\n // separate fact, which is the whole reason this is a table.\n hanzo: Object.freeze([\n \"hanzo.ai\",\n \"hanzo.agency\",\n \"hanzo.app\",\n \"hanzo.bot\",\n \"hanzo.chat\",\n \"hanzo.codes\",\n \"hanzo.community\",\n \"hanzo.computer\",\n \"hanzo.help\",\n \"hanzo.id\",\n \"hanzo.industries\",\n \"hanzo.market\",\n \"hanzo.network\",\n \"hanzo.sh\",\n \"hanzo.team\",\n \"hanzo.ventures\",\n \"hanzo.works\",\n \"hanzoskills.com\"\n ]),\n lux: Object.freeze([\n \"lux.network\",\n \"lux.exchange\",\n \"lux.market\",\n \"lux.finance\",\n \"lux.financial\",\n \"lux.credit\",\n \"lux.fund\",\n \"lux.id\"\n ]),\n zoo: Object.freeze([\"zoo.ngo\", \"zoo.network\", \"zoolabs.id\", \"zoolabs.io\"])\n});\nvar ORG_KEY = Object.freeze({\n hanzo: \"pk-CmfLA2K6kvsPflrS9DSkt06H_kSoQB_21sjedt6VJdc\",\n lux: \"pk-gUZp6ZVfhJzSwK-rb4oLbVkpCnMBx5uSCpxf_5yEhQk\",\n zoo: \"pk-3TKpKnERV9AQSsBUERWkZejC1O1mUxc1jRzsP3MPbs4\"\n});\nvar SITE_KEY = Object.freeze({\n \"hanzo.ai\": \"pk-CmfLA2K6kvsPflrS9DSkt06H_kSoQB_21sjedt6VJdc\",\n \"www.hanzo.ai\": \"pk-CmfLA2K6kvsPflrS9DSkt06H_kSoQB_21sjedt6VJdc\",\n \"hanzo.app\": \"pk-wlnXN2a9_vmCm60yTFtQ629Q8TyuaxBNZbY1RWT72gQ\",\n \"hanzo.team\": \"pk-NCzD2FiHpZv8KUpkCX4olT1LJOJsMxBC_Z8NkiQsOFQ\",\n \"pay.hanzo.ai\": \"pk-eX6kv7JZNoiYn1WkeJH3tT_8OvkVYScmCXnLMwxTKf8\",\n \"platform.hanzo.ai\": \"pk-My1RpZLEUnTj8vAdPbWKYdDUuhxZJ4dVjHcwjZN4rZ8\",\n \"docs.hanzo.ai\": \"pk-jukhtjMT2ymoeBDAeFjINQWlBv-v9sNn1TPztiCrrwk\",\n \"hanzo.bot\": \"pk-W5d7Mn7ZukT7igyscIy6Pqe8JpA0Ge604Yn4xNR4JCU\",\n \"hanzo.chat\": \"pk-ATxWeB2jNyRSxDgqnkGoDj3CCbzrmTxSktUh9zlrO-E\",\n \"hanzo.id\": \"pk-_GVF3KlaqprlPHDumBMRFeFU1lIGOaarQfgimNVDIo8\",\n \"hanzo.industries\": \"pk-Vh1wvL2HqIAv9qpVvmrznTI9uMHrTD-jyIC-vnlBsgY\",\n \"hanzo.market\": \"pk-DN3xQFa0H61epUVg9OkiOYLzCdteNt9hE6f-S-ednjQ\",\n \"hanzo.network\": \"pk-YJ2eiA_7ckLStMPte8Ar8FsmRp_ycmeIeRbpGprZYmM\",\n \"hanzo.agency\": \"pk-26a2clOaJFe24aKJZ0PkI-GWR9F4EEa8rthHzgy_Efw\",\n \"console.hanzo.ai\": \"pk-oFNXoiO1wOD8PqGdHYyiSq6jaNCdrd7TpztGpwM2ZiQ\",\n \"admin.hanzo.ai\": \"pk-RYZwxkomW-tlAnEu2DKo_kAzcxFbSF2YiYcsUY48QL0\",\n \"bot.hanzo.ai\": \"pk-W5d7Mn7ZukT7igyscIy6Pqe8JpA0Ge604Yn4xNR4JCU\",\n \"cloud.hanzo.ai\": \"pk-RAfEGHPoNdCEU9fnA_cPd_Xo9Tci44rlYQV9xuJ1Ob0\"\n});\nfunction siteKey(host) {\n const h = normalize(host).replace(/^www\\./, \"\");\n return SITE_KEY[h] ?? (h.endsWith(\".hanzo.app\") ? SITE_KEY[\"hanzo.app\"] : void 0);\n}\nvar PUBLISHABLE = \"pk-\";\nvar normalize = (host) => host.trim().toLowerCase().replace(/\\.$/, \"\").split(\":\")[0] ?? \"\";\nfunction orgOf(host) {\n const h = normalize(host);\n if (!h) return void 0;\n let best;\n let bestLen = 0;\n for (const [org, domains] of Object.entries(ORG_DOMAIN)) {\n for (const d of domains) {\n if ((h === d || h.endsWith(`.${d}`)) && d.length > bestLen) {\n best = org;\n bestLen = d.length;\n }\n }\n }\n return best;\n}\nfunction keyFor(host, keyring = ORG_KEY) {\n if (keyring === ORG_KEY) {\n const site = siteKey(host);\n if (site) return site;\n }\n const org = orgOf(host);\n if (!org) return void 0;\n const key = keyring[org];\n if (typeof key !== \"string\") return void 0;\n const trimmed = key.trim();\n return trimmed.startsWith(PUBLISHABLE) ? trimmed : void 0;\n}\nfunction keyForPage(keyring = ORG_KEY) {\n if (typeof location === \"undefined\") return void 0;\n return keyFor(location.hostname, keyring);\n}\n\n// src/scrub.ts\nvar REDACTED = \"[redacted]\";\nvar EMAIL_MARK = \"[email]\";\nvar IP_MARK = \"[ip]\";\nvar SECRET_PATTERNS = [\n /-----BEGIN[ A-Z]*PRIVATE KEY-----[\\s\\S]*?-----END[ A-Z]*PRIVATE KEY-----/g,\n /eyJ[A-Za-z0-9_-]{8,}\\.[A-Za-z0-9_-]{6,}\\.[A-Za-z0-9_-]{6,}/g,\n // JWT\n /\\bbearer\\s+[A-Za-z0-9._~+/-]{12,}=*/gi,\n // bearer token\n /\\b(?:sk|pk|rk)-[A-Za-z0-9]{2,}-?[A-Za-z0-9]{12,}/g,\n // openai-style\n /\\b(?:sk|pk)_(?:live|test)_[A-Za-z0-9]{16,}/g,\n // stripe\n /\\bhk-[A-Za-z0-9]{16,}/g,\n // hanzo key\n /\\bAKIA[0-9A-Z]{16}\\b/g,\n // aws access key id\n /\\bASIA[0-9A-Z]{16}\\b/g,\n // aws sts key id\n /\\bAIza[0-9A-Za-z_-]{20,}/g,\n // google api key\n /\\bgh[posru]_[A-Za-z0-9]{20,}/g,\n // github token\n /\\bxox[baprs]-[A-Za-z0-9-]{10,}/g,\n // slack token\n // Creds in a URL/DSN. The repetition is BOUNDED on purpose: the unbounded form\n // ([^\\s:@/]+:[^\\s@/]+@) backtracks quadratically on colon-rich text with no\n // terminating '@' — an HTML error page pasted into an error message took 4.9s\n // at 32KB and >60s at 128KB, freezing the main thread from inside captureError.\n // Real userinfo is far below these caps, so bounding costs nothing.\n /[a-zA-Z][a-zA-Z0-9+.-]{0,32}:\\/\\/[^\\s:@/]{1,256}:[^\\s@/]{1,256}@/g\n];\nvar RE_PAN = /\\b(?:\\d[ -]?){13,19}\\b/g;\nfunction luhn(digits) {\n let sum = 0;\n let alt = false;\n for (let i = digits.length - 1; i >= 0; i--) {\n let d = digits.charCodeAt(i) - 48;\n if (alt) {\n d *= 2;\n if (d > 9) d -= 9;\n }\n sum += d;\n alt = !alt;\n }\n return sum % 10 === 0;\n}\nfunction redactPAN(s) {\n return s.replace(RE_PAN, (m) => {\n const digits = m.replace(/[ -]/g, \"\");\n if (digits.length < 13 || digits.length > 19) return m;\n return luhn(digits) ? REDACTED : m;\n });\n}\nvar RE_EMAIL = /[A-Za-z0-9._%+-]{1,64}@[A-Za-z0-9.-]{1,255}\\.[A-Za-z]{2,24}/g;\nvar RE_IPV4 = /\\b(?:\\d{1,3}\\.){3}\\d{1,3}\\b/g;\nvar RE_IPV6 = /\\b(?:[0-9A-Fa-f]{1,4}:){2,7}[0-9A-Fa-f]{1,4}\\b/g;\nvar CREDENTIAL_PARAMS = [\n \"code\",\n \"state\",\n \"token\",\n \"access_token\",\n \"id_token\",\n \"refresh_token\",\n \"auth\",\n \"authorization\",\n \"secret\",\n \"client_secret\",\n \"password\",\n \"passwd\",\n \"pwd\",\n \"api_key\",\n \"apikey\",\n \"key\",\n \"session\",\n \"session_id\",\n \"sid\",\n \"sig\",\n \"signature\",\n \"nonce\",\n \"otp\",\n \"invite\",\n \"invitation\",\n \"reset_token\",\n \"confirmation_token\",\n \"magic\",\n \"ticket\",\n \"assertion\"\n];\nvar RE_CREDENTIAL_PARAM = new RegExp(\n \"([?&#;](?:\" + CREDENTIAL_PARAMS.join(\"|\") + \")=)[^&#;\\\\s]{1,4096}\",\n \"gi\"\n);\nfunction redactCredentialParams(s) {\n return s.replace(RE_CREDENTIAL_PARAM, (_m, prefix) => prefix + REDACTED);\n}\nvar RE_SECRET43 = /(^|[^A-Za-z0-9_-]|%[0-9A-Fa-f]{2})((?=[A-Za-z0-9_-]{0,42}[a-z])(?=[A-Za-z0-9_-]{0,42}[A-Z])[A-Za-z0-9_-]{43})(?![A-Za-z0-9_-])/g;\nfunction redactSecrets(s) {\n s = redactCredentialParams(s);\n for (const re of SECRET_PATTERNS) s = s.replace(re, REDACTED);\n s = s.replace(RE_SECRET43, (_m, lead) => lead + REDACTED);\n return redactPAN(s);\n}\nfunction withoutFragment(url) {\n const at = url.indexOf(\"#\");\n return at < 0 ? url : url.slice(0, at);\n}\nfunction scrubPII(s) {\n s = s.replace(RE_EMAIL, EMAIL_MARK);\n s = s.replace(RE_IPV6, IP_MARK);\n s = s.replace(RE_IPV4, IP_MARK);\n return s;\n}\nvar MAX_SCRUB_LEN = 8192;\nfunction truncate(s, max = MAX_SCRUB_LEN) {\n return s.length > max ? s.slice(0, max) + \"\\u2026 [truncated]\" : s;\n}\nfunction scrubText(s, capturePII = false) {\n if (!s) return s ?? \"\";\n s = truncate(s);\n s = redactSecrets(s);\n if (!capturePII) s = scrubPII(s);\n return s;\n}\n\n// src/throwable.ts\nvar MAX_FRAMES = 50;\nvar MAX_LINES = 500;\nvar MAX_LINE_LEN = 2048;\nvar V8_FRAME = /^\\s*at\\s+(?:(.+?)\\s+\\()?(?:(.+?):(\\d+):(\\d+)|([^)]+))\\)?\\s*$/;\nvar MOZ_FRAME = /^\\s*(?:(.*?)@)?(.+?):(\\d+):(\\d+)\\s*$/;\nfunction inApp(file) {\n if (!file) return false;\n return !(file.includes(\"node_modules\") || file.startsWith(\"webpack-internal\") || file.startsWith(\"webpack://\") || file.startsWith(\"chrome-extension://\") || file.startsWith(\"moz-extension://\"));\n}\nfunction framesFromStack(stack) {\n if (!stack) return [];\n const lines = stack.split(\"\\n\", MAX_LINES);\n const frames = [];\n for (const raw of lines) {\n if (raw.length > MAX_LINE_LEN) continue;\n const line = raw.trimEnd();\n if (!line) continue;\n let fn;\n let file = \"\";\n let lineno = 0;\n let colno = 0;\n const v = V8_FRAME.exec(line);\n if (v) {\n fn = v[1];\n if (v[2]) {\n file = v[2];\n lineno = Number(v[3]) || 0;\n colno = Number(v[4]) || 0;\n } else {\n file = (v[5] || \"\").trim();\n }\n } else {\n const f = MOZ_FRAME.exec(line);\n if (!f) continue;\n fn = f[1];\n file = f[2];\n lineno = Number(f[3]) || 0;\n colno = Number(f[4]) || 0;\n }\n if (!file && !fn) continue;\n frames.push({\n function: fn || \"<anonymous>\",\n filename: file,\n abs_path: file,\n lineno,\n colno,\n in_app: inApp(file)\n });\n }\n frames.reverse();\n if (frames.length > MAX_FRAMES) return frames.slice(frames.length - MAX_FRAMES);\n return frames;\n}\nfunction normalizeError(err) {\n if (err instanceof Error) {\n const name = read(err, \"name\");\n const message = read(err, \"message\");\n const stack = read(err, \"stack\");\n return {\n name: typeof name === \"string\" && name ? name : \"Error\",\n message: typeof message === \"string\" && message ? message : str(err),\n stack: typeof stack === \"string\" ? stack : void 0\n };\n }\n if (typeof err === \"string\") return { name: \"Error\", message: err };\n try {\n return { name: \"Error\", message: JSON.stringify(err) ?? str(err) };\n } catch {\n return { name: \"Error\", message: str(err) };\n }\n}\nfunction read(o, k) {\n try {\n return o[k];\n } catch {\n return void 0;\n }\n}\nfunction str(v) {\n try {\n return String(v);\n } catch {\n return \"[unstringifiable]\";\n }\n}\n\n// src/anon.js\nvar HZ_ANON_KEY = \"iam-anon-id\";\nvar HZ_ANON_ADOPT = [\"hz_anon_id\", \"hz_id\"];\nvar HZ_ANON_DOMAIN = \"hanzo.ai\";\nvar HZ_ANON_MAX_AGE = 2 * 365 * 24 * 60 * 60;\nvar hzAnonMemo;\nfunction hzUuidv7(now2) {\n var b = new Uint8Array(16);\n var i;\n var c = typeof crypto !== \"undefined\" ? crypto : void 0;\n if (c && typeof c.getRandomValues === \"function\") c.getRandomValues(b);\n else for (i = 0; i < 16; i++) b[i] = Math.random() * 256 | 0;\n var t = Math.floor(now2 === void 0 ? Date.now() : now2);\n for (i = 5; i >= 0; i--) {\n b[i] = t % 256;\n t = Math.floor(t / 256);\n }\n b[6] = 112 | b[6] & 15;\n b[8] = 128 | b[8] & 63;\n var h = \"\";\n for (i = 0; i < 16; i++) {\n h += (b[i] + 256).toString(16).slice(1);\n if (i === 3 || i === 5 || i === 7 || i === 9) h += \"-\";\n }\n return h;\n}\nfunction hzAnonJar() {\n try {\n if (typeof document === \"undefined\" || typeof document.cookie !== \"string\") return null;\n return document;\n } catch (e) {\n return null;\n }\n}\nfunction hzAnonStore() {\n try {\n if (typeof window === \"undefined\" || !window.localStorage) return null;\n return window.localStorage;\n } catch (e) {\n return null;\n }\n}\nfunction hzAnonItem(store, name) {\n try {\n return store && store.getItem(name) || \"\";\n } catch (e) {\n return \"\";\n }\n}\nfunction hzAnonCookie(name) {\n var d = hzAnonJar();\n if (!d) return \"\";\n var parts = d.cookie.split(\";\");\n for (var i = 0; i < parts.length; i++) {\n var eq = parts[i].indexOf(\"=\");\n if (eq < 0 || parts[i].slice(0, eq).trim() !== name) continue;\n var v = parts[i].slice(eq + 1).trim();\n if (!v) continue;\n try {\n return decodeURIComponent(v);\n } catch (e) {\n return v;\n }\n }\n return \"\";\n}\nfunction hzAnonWrite(name, value) {\n var d = hzAnonJar();\n if (!d) return;\n var host = \"\";\n var secure = false;\n try {\n if (typeof window !== \"undefined\" && window.location) {\n host = window.location.hostname || \"\";\n secure = window.location.protocol === \"https:\";\n }\n } catch (e) {\n }\n var c = name + \"=\" + encodeURIComponent(value);\n c += \"; Path=/; Max-Age=\" + HZ_ANON_MAX_AGE + \"; SameSite=Lax\";\n if ((\".\" + host).slice(-(HZ_ANON_DOMAIN.length + 1)) === \".\" + HZ_ANON_DOMAIN) {\n c += \"; Domain=\" + HZ_ANON_DOMAIN;\n }\n if (secure) c += \"; Secure\";\n try {\n d.cookie = c;\n } catch (e) {\n }\n}\nfunction hzAnonAdopted(s) {\n for (var i = 0; i < HZ_ANON_ADOPT.length; i++) {\n var id = hzAnonCookie(HZ_ANON_ADOPT[i]) || hzAnonItem(s, HZ_ANON_ADOPT[i]);\n if (id) return id;\n }\n return \"\";\n}\nfunction hzAnonId() {\n if (typeof window === \"undefined\") return \"\";\n var s = hzAnonStore();\n var id = hzAnonCookie(HZ_ANON_KEY) || hzAnonItem(s, HZ_ANON_KEY) || hzAnonAdopted(s) || hzAnonMemo || hzUuidv7();\n hzAnonMemo = id;\n hzAnonWrite(HZ_ANON_KEY, id);\n try {\n if (s && s.getItem(HZ_ANON_KEY) !== id) s.setItem(HZ_ANON_KEY, id);\n } catch (e) {\n }\n return id;\n}\nfunction hzAnonAdopt(id) {\n hzAnonMemo = id;\n hzAnonWrite(HZ_ANON_KEY, id);\n try {\n var s = hzAnonStore();\n if (s) s.setItem(HZ_ANON_KEY, id);\n } catch (e) {\n }\n}\n\n// src/uid.ts\nfunction uuidv7Time(id) {\n return parseInt(id.slice(0, 8) + id.slice(9, 13), 16);\n}\n\n// src/storage.ts\nvar KEY = {\n session: \"hz_session\",\n firstTouch: \"hz_first_touch\",\n lastTouch: \"hz_last_touch\",\n cohort: \"hz_cohort\"\n};\nvar LAST_TOUCH_MS = 90 * 24 * 60 * 60 * 1e3;\nvar SESSION_TTL_MS = 30 * 60 * 1e3;\nfunction ls() {\n try {\n if (typeof window === \"undefined\" || !window.localStorage) return void 0;\n return window.localStorage;\n } catch {\n return void 0;\n }\n}\nfunction anonId() {\n return hzAnonId() || void 0;\n}\nfunction sessionId(now2 = Date.now()) {\n const s = ls();\n if (!s) return void 0;\n let state = null;\n try {\n state = JSON.parse(s.getItem(KEY.session) || \"null\");\n } catch {\n state = null;\n }\n if (!state || now2 - state.last > SESSION_TTL_MS) {\n state = { id: hzUuidv7(now2), last: now2 };\n } else {\n state.last = now2;\n }\n s.setItem(KEY.session, JSON.stringify(state));\n return state.id;\n}\nfunction adoptSession(id, now2 = Date.now()) {\n const s = ls();\n if (s) s.setItem(KEY.session, JSON.stringify({ id, last: now2 }));\n}\nfunction adoptAnonId(id) {\n hzAnonAdopt(id);\n}\nfunction getFirstTouch() {\n const s = ls();\n if (!s) return void 0;\n try {\n const v = s.getItem(KEY.firstTouch);\n return v ? JSON.parse(v) : void 0;\n } catch {\n return void 0;\n }\n}\nfunction setFirstTouchOnce(a) {\n const s = ls();\n const existing = getFirstTouch();\n if (existing) return existing;\n if (s) s.setItem(KEY.firstTouch, JSON.stringify(a));\n return a;\n}\nfunction getLastTouch(now2 = Date.now()) {\n const s = ls();\n if (!s) return void 0;\n try {\n const v = JSON.parse(s.getItem(KEY.lastTouch) || \"null\");\n if (!v?.utm || typeof v.at !== \"number\" || now2 - v.at > LAST_TOUCH_MS) return void 0;\n return v.utm;\n } catch {\n return void 0;\n }\n}\nfunction setLastTouch(utm, now2 = Date.now()) {\n const s = ls();\n if (s) s.setItem(KEY.lastTouch, JSON.stringify({ utm, at: now2 }));\n}\nfunction getCohort() {\n const s = ls();\n if (!s) return void 0;\n try {\n const v = s.getItem(KEY.cohort);\n return v ? JSON.parse(v) : void 0;\n } catch {\n return void 0;\n }\n}\nfunction mergeCohort(patch) {\n const s = ls();\n const cur = getCohort() || {};\n const next = {\n signupWeek: cur.signupWeek || patch.signupWeek,\n channel: patch.channel || cur.channel,\n refCode: cur.refCode || patch.refCode\n };\n if (s) s.setItem(KEY.cohort, JSON.stringify(next));\n return next;\n}\n\n// src/cookie.ts\nvar DAY = 86400;\nvar TENANTS = /* @__PURE__ */ new Set([\"hanzo.app\"]);\nfunction brand(h) {\n for (const domains of Object.values(ORG_DOMAIN)) {\n for (const d of domains) if (!TENANTS.has(d) && (h === d || h.endsWith(`.${d}`))) return d;\n }\n return \"\";\n}\nfunction domain() {\n const d = brand(window.location.hostname.toLowerCase());\n return d ? `; Domain=.${d}` : \"\";\n}\nfunction get(name) {\n if (typeof document === \"undefined\" || typeof document.cookie !== \"string\") return void 0;\n const hit = document.cookie.split(\"; \").find((c) => c.startsWith(`${name}=`));\n return hit ? decodeURIComponent(hit.slice(name.length + 1)) : void 0;\n}\nfunction set(name, value, days) {\n if (typeof document === \"undefined\") return;\n const secure = window.location.protocol === \"https:\" ? \"; Secure\" : \"\";\n document.cookie = `${name}=${encodeURIComponent(value)}; Max-Age=${days * DAY}; Path=/; SameSite=Lax${domain()}${secure}`;\n}\nfunction own(name) {\n return typeof window !== \"undefined\" && window.location?.protocol === \"https:\" ? `__Host-${name}` : name;\n}\nfunction setOwn(name, value, days) {\n if (typeof document === \"undefined\") return;\n const secure = window.location.protocol === \"https:\" ? \"; Secure\" : \"\";\n document.cookie = `${own(name)}=${encodeURIComponent(value)}; Max-Age=${days * DAY}; Path=/; SameSite=Lax${secure}`;\n}\nfunction forget(names, patterns = []) {\n if (typeof document === \"undefined\" || typeof document.cookie !== \"string\") return;\n const held2 = document.cookie.split(\"; \").map((c) => c.slice(0, c.indexOf(\"=\")));\n const gone = /* @__PURE__ */ new Set([...names, ...held2.filter((n) => patterns.some((p) => p.test(n)))]);\n const labels = window.location.hostname.split(\".\");\n const scopes = /* @__PURE__ */ new Set([\"\", domain(), ...labels.slice(0, -1).map((_, i) => `; Domain=.${labels.slice(i).join(\".\")}`)]);\n for (const n of gone) for (const scope of scopes) document.cookie = `${n}=; Max-Age=0; Path=/${scope}`;\n}\n\n// src/automated.ts\nvar automated = () => typeof navigator !== \"undefined\" && navigator.webdriver === true;\nvar MARK = \"hz_internal\";\nfunction internal() {\n if (automated()) return true;\n if (typeof window === \"undefined\" || typeof document === \"undefined\") return false;\n if (typeof document.cookie !== \"string\") return false;\n const asked = new URLSearchParams(window.location?.search ?? \"\").get(MARK);\n if (asked === \"1\") set(MARK, \"1\", 365);\n if (asked === \"0\") {\n set(MARK, \"\", 0);\n return false;\n }\n return asked === \"1\" || get(MARK) === \"1\";\n}\nfunction mark() {\n if (typeof document === \"undefined\" || typeof document.cookie !== \"string\") return;\n set(MARK, \"1\", 365);\n}\n\n// src/link.ts\nvar LINK_PARAMS = { anon: \"hz_aid\", session: \"hz_sid\", firstTouch: \"hz_ft\" };\nvar UUID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;\nvar isId = (v) => !!v && UUID.test(v);\nfunction encodeFirstTouch(a) {\n return JSON.stringify([\n a.utm.source,\n a.utm.medium,\n a.utm.campaign,\n a.utm.term,\n a.utm.content,\n a.refCode,\n a.referrer,\n a.channel\n ].map((v) => v ?? \"\"));\n}\nfunction decodeFirstTouch(raw) {\n if (!raw || raw.length > 1024) return void 0;\n try {\n const t = JSON.parse(raw);\n if (!Array.isArray(t) || t.length !== 8 || t.some((v) => typeof v !== \"string\")) return void 0;\n const [source, medium, campaign, term, content, refCode, referrer, channel] = t;\n const u = (v) => v || void 0;\n return {\n utm: { source: u(source), medium: u(medium), campaign: u(campaign), term: u(term), content: u(content) },\n refCode: u(refCode),\n referrer: u(referrer),\n channel: u(channel)\n };\n } catch {\n return void 0;\n }\n}\nfunction linkUrl(url, state, fromHost, base) {\n let u;\n try {\n u = new URL(url, base);\n } catch {\n return url;\n }\n if (u.protocol !== \"https:\" && u.protocol !== \"http:\") return url;\n if (!orgOf(u.hostname) || u.hostname === fromHost) return url;\n const set2 = (k, v) => v && u.searchParams.set(k, v);\n if (isId(state.anonId)) set2(LINK_PARAMS.anon, state.anonId);\n if (isId(state.sessionId)) set2(LINK_PARAMS.session, state.sessionId);\n if (state.firstTouch) set2(LINK_PARAMS.firstTouch, encodeFirstTouch(state.firstTouch));\n return u.toString();\n}\nfunction readLink(search) {\n const q = new URLSearchParams(search || \"\");\n const a = q.get(LINK_PARAMS.anon);\n const s = q.get(LINK_PARAMS.session);\n return {\n anonId: isId(a) ? a : void 0,\n sessionId: isId(s) ? s : void 0,\n firstTouch: decodeFirstTouch(q.get(LINK_PARAMS.firstTouch))\n };\n}\nfunction stripLink(href) {\n const u = new URL(href);\n let hit = false;\n for (const k of Object.values(LINK_PARAMS)) {\n if (u.searchParams.has(k)) {\n u.searchParams.delete(k);\n hit = true;\n }\n }\n return hit ? u.pathname + u.search + u.hash : void 0;\n}\n\n// src/consent.ts\nvar CONSENT_COOKIE = \"hz_consent\";\nvar CONSENT_VERSION_COOKIE = \"hz_consent_v\";\nvar RULE_COOKIE = \"hz_consent_rule\";\nvar NOTICE_COOKIE = \"hz_consent_notice\";\nvar CONSENT_VERSION = 3;\nvar CONSENT_FLOOR = 2;\nvar POLICY_EVENT = \"hzpolicy\";\nvar CONSENT_EVENT = \"hzconsent\";\nvar NONE = { analytics: false, marketing: false, ads: false };\nvar ALL = { analytics: true, marketing: true, ads: true };\nvar MODES = [\"eu\", \"us_privacy\", \"global\"];\nvar CACHE = \"hz_consent_policy\";\nvar SLOT = /* @__PURE__ */ Symbol.for(\"hanzo.event.consent\");\nfunction slot() {\n const g2 = globalThis;\n return g2[SLOT] ?? (g2[SLOT] = {});\n}\nfunction parse(p) {\n if (p == null || typeof p !== \"object\") return void 0;\n const d = p;\n if (typeof d.version !== \"number\" && typeof d.mode !== \"string\") return void 0;\n return {\n mode: MODES.includes(d.mode) ? d.mode : \"eu\",\n refused: d.refused === true,\n version: Number(d.version) || 0,\n region: String(d.region ?? \"\"),\n floor: Number(d.floor) || CONSENT_FLOOR\n };\n}\nfunction session() {\n try {\n return typeof window === \"undefined\" ? void 0 : window.sessionStorage;\n } catch {\n return void 0;\n }\n}\nfunction serve(p) {\n const s = parse(p);\n slot().served = s;\n try {\n if (s) session()?.setItem(CACHE, JSON.stringify(s));\n } catch {\n }\n if (!s) return;\n honour();\n if (typeof window !== \"undefined\") window.dispatchEvent(new Event(POLICY_EVENT));\n}\nfunction served() {\n const s = slot().served;\n if (s) return s;\n try {\n const c = parse(JSON.parse(session()?.getItem(CACHE) ?? \"null\"));\n if (c) return c;\n } catch {\n }\n return { mode: \"eu\", refused: false, version: CONSENT_VERSION, region: \"\", floor: CONSENT_FLOOR };\n}\nfunction policy() {\n const s = served();\n return { mode: s.mode, refused: s.refused || refused(), version: version(), region: s.region };\n}\nfunction gpc() {\n if (typeof navigator === \"undefined\") return false;\n return navigator.globalPrivacyControl === true;\n}\nfunction refused() {\n if (typeof window === \"undefined\") return false;\n const n = typeof navigator === \"undefined\" ? {} : navigator;\n const dnt = n.doNotTrack ?? window.doNotTrack ?? n.msDoNotTrack;\n return gpc() || dnt === \"1\" || dnt === \"yes\";\n}\nvar version = () => Math.max(slot().served?.version ?? 0, CONSENT_VERSION);\nvar declined = () => policy().refused;\nfunction kept() {\n const c = get(own(CONSENT_COOKIE));\n if (c === void 0) return void 0;\n const v = Number(get(own(CONSENT_VERSION_COOKIE)));\n const rule = get(own(RULE_COOKIE));\n if (policy().mode === \"eu\" && !(rule === \"eu\" || rule === void 0 && v === 2)) return void 0;\n const on = c.split(\",\");\n return {\n held: { analytics: on.includes(\"analytics\"), marketing: on.includes(\"marketing\"), ads: on.includes(\"ads\") },\n current: v >= served().floor && v <= version()\n };\n}\nvar any = (c) => c.analytics || c.marketing || c.ads;\nfunction stored() {\n const k = kept();\n return k !== void 0 && (k.current || !any(k.held));\n}\nfunction read2() {\n const p = policy();\n if (p.refused) return { ...NONE };\n const base = p.mode === \"eu\" ? NONE : ALL;\n const k = kept();\n if (!k) return { ...base };\n if (k.current) return { ...k.held };\n return { analytics: base.analytics && k.held.analytics, marketing: base.marketing && k.held.marketing, ads: base.ads && k.held.ads };\n}\nfunction honour() {\n const k = kept();\n if (declined() && k && any(k.held)) save({ ...NONE });\n}\nfunction asks() {\n if (typeof document === \"undefined\") return false;\n const p = policy();\n return p.mode === \"eu\" && !p.refused && !stored();\n}\nfunction sheet(open2) {\n slot().sheet = open2;\n if (!open2 && typeof window !== \"undefined\") window.dispatchEvent(new Event(CONSENT_EVENT));\n}\nvar open = () => slot().sheet === true;\nfunction notice() {\n setOwn(NOTICE_COOKIE, \"1\", 395);\n if (typeof window !== \"undefined\") window.dispatchEvent(new Event(CONSENT_EVENT));\n}\nvar noticed = () => get(own(NOTICE_COOKIE)) === \"1\";\nfunction render(c) {\n return [\"analytics\", \"marketing\", \"ads\"].filter((k) => c[k]).join(\",\");\n}\nfunction save(c) {\n const p = policy();\n const out = p.refused ? { ...NONE } : { analytics: c.analytics, marketing: c.marketing, ads: c.ads };\n setOwn(CONSENT_COOKIE, render(out), 395);\n setOwn(CONSENT_VERSION_COOKIE, String(version()), 395);\n setOwn(RULE_COOKIE, p.mode, 395);\n if (!out.analytics) withdraw(ANALYTICS);\n if (!out.marketing) withdraw(MARKETING);\n if (!out.ads) withdraw(ADS);\n if (typeof window !== \"undefined\") window.dispatchEvent(new Event(CONSENT_EVENT));\n}\nvar ANALYTICS = {\n cookies: [\"_ga\", \"_gid\", \"_gat\", \"hz_cid\"],\n patterns: [/^_ga_[A-Z0-9]+$/, /^_gat_[\\w-]+$/],\n storage: []\n};\nvar MARKETING = {\n cookies: [\n \"hz_touch\",\n \"_fbp\",\n \"_fbc\",\n \"_ttp\",\n \"_tt_enable_cookie\",\n \"ttcsid\",\n \"_twclid\",\n \"li_fat_id\",\n \"li_giant\",\n \"_uetsid\",\n \"_uetvid\",\n \"_pin_unauth\",\n \"_epik\",\n \"_derived_epik\",\n \"_rdt_uuid\",\n \"_rdt_cid\"\n ],\n patterns: [/^ttcsid_[A-Z0-9]+$/],\n storage: []\n};\nvar ADS = {\n cookies: [],\n patterns: [/^_gcl_[a-z]+$/, /^_gac_[\\w-]+$/],\n storage: []\n};\nfunction withdraw(k) {\n forget(k.cookies, k.patterns);\n if (typeof window === \"undefined\") return;\n try {\n for (const key of k.storage) window.localStorage?.removeItem(key);\n } catch {\n }\n}\nvar acceptAll = () => save({ ...ALL });\nvar rejectAll = () => save({ ...NONE });\n\n// package.json\nvar version2 = \"0.3.66\";\n\n// src/version.ts\nvar VERSION = version2;\n\n// src/core.ts\nvar EVENT_PATH = \"/v1/event\";\nvar DEFAULT_HOST = \"https://api.hanzo.ai\";\nvar BEACON_CONTENT_TYPE = \"text/plain\";\nfunction readEnv(name) {\n try {\n if (typeof process !== \"undefined\" && process.env) return process.env[name] || void 0;\n } catch {\n }\n return void 0;\n}\nfunction appendQuery(url, key, value) {\n return url + (url.includes(\"?\") ? \"&\" : \"?\") + key + \"=\" + encodeURIComponent(value);\n}\nfunction normalizeError2(err) {\n const n = normalizeError(err);\n const frames = framesFromStack(n.stack).slice(-50).map((f) => ({ function: f.function, file: f.filename, line: f.lineno, column: f.colno }));\n return { type: n.name, message: n.message, stack: n.stack, frames };\n}\nvar viewport = () => isBrowser() ? { screen: `${window.screen?.width ?? 0}x${window.screen?.height ?? 0}`, language: navigator.language || \"\" } : {};\nvar isBrowser = () => typeof window !== \"undefined\" && typeof document !== \"undefined\";\nfunction narrowed(e) {\n if (!isBrowser()) return e;\n const now2 = new Set(render(read2()).split(\",\").filter(Boolean));\n const consent = String(e.properties?.consent ?? \"\").split(\",\").filter((k) => now2.has(k)).join(\",\");\n return { ...e, properties: { ...e.properties, consent } };\n}\nfunction serializeBatch(batch) {\n try {\n return JSON.stringify({ batch });\n } catch {\n }\n const parts = [];\n for (const e of batch) {\n try {\n parts.push(JSON.stringify(e));\n } catch {\n try {\n parts.push(JSON.stringify({ ...e, properties: { $unserializable: true } }));\n } catch {\n }\n }\n }\n return parts.length > 0 ? '{\"batch\":[' + parts.join(\",\") + \"]}\" : null;\n}\nvar DefaultTransport = class {\n send(url, body, opts) {\n if (opts.beacon && isBrowser() && typeof navigator.sendBeacon === \"function\") {\n const beaconUrl = opts.ingestKey ? appendQuery(url, \"ingest_key\", opts.ingestKey) : url;\n try {\n const queued = navigator.sendBeacon(\n beaconUrl,\n new Blob([body], { type: BEACON_CONTENT_TYPE })\n );\n if (queued) return;\n if (opts.debug) console.warn(\"[event] beacon refused, falling back to fetch\");\n } catch {\n }\n }\n if (typeof fetch !== \"function\") return;\n const simple = opts.ingestKey !== void 0 && opts.token === void 0 && opts.contentType === void 0;\n const headers = {\n \"Content-Type\": simple ? BEACON_CONTENT_TYPE : opts.contentType ?? \"application/json\"\n };\n const bearer = simple ? void 0 : opts.token ?? opts.ingestKey;\n if (bearer) headers.Authorization = `Bearer ${bearer}`;\n void fetch(opts.ingestKey ? appendQuery(url, \"ingest_key\", opts.ingestKey) : url, {\n method: \"POST\",\n headers,\n body,\n keepalive: true,\n credentials: simple ? \"omit\" : \"include\"\n }).then((res) => {\n if (!res.ok && opts.debug) {\n console.warn(\"[event] ingest rejected\", res.status, url.split(\"?\")[0]);\n }\n }).catch((e) => {\n if (opts.debug) console.warn(\"[event] ingest failed\", url.split(\"?\")[0], e);\n });\n }\n};\nvar Analytics = class {\n constructor(config) {\n this.queue = [];\n this.timer = null;\n this.attribution = { utm: {} };\n this.cohort = {};\n this.started = false;\n /** Guards against an error thrown *inside* the error path re-entering it. */\n this.reentrant = false;\n this.cfg = {\n host: DEFAULT_HOST,\n batchSize: 20,\n flushIntervalMs: 5e3,\n enabled: true,\n captureErrors: true,\n ...config,\n // The publishable key resolves from ONE live source, never a literal baked\n // beside the code. Most specific first:\n // 1. an explicit `ingestKey` in config;\n // 2. NEXT_PUBLIC_PUBLISHABLE_KEY, the inlined build-time env the fleet\n // carries end to end — KMS `deploy/PUBLISHABLE_KEY` -> the PUBLISHABLE_KEY\n // build-arg -> the NEXT_PUBLIC_ prefix Next inlines.\n //\n // 3. the org that owns the HOST this page is served from (`org.ts`).\n //\n // Step 3 fires only when a surface configured NOTHING, so it never overrides\n // the KMS chain above — it replaces going dark with reporting to the right\n // brand. That is what a static export needs: `output: export` inlines no env,\n // so before this the only way to report was to commit a key literal, and the\n // fleet grew one copy per site of a value with a single source.\n //\n // A surface no brand claims still has no key, and the edge REFUSES an\n // unattributed event (401 `ingest_key_required`) — the reserved `$public`\n // tenant that once caught keyless beacons is retired, and anonymous ingest is\n // refused at every edge on every brand host. So there is no quiet fallback to\n // rely on: an event lands in the org a credential names, or it does not land.\n ingestKey: config.ingestKey ?? readEnv(\"NEXT_PUBLIC_PUBLISHABLE_KEY\") ?? keyForPage()\n };\n this.transport = config.transport ?? new DefaultTransport();\n }\n /** adopt gives this client a credential it does not have. The key belongs to\n * the stream, not to whichever caller happened to ask for the handle first,\n * so a later caller carrying one hands it over. Present fields are never overwritten: the first caller's key stays. */\n adopt(config) {\n if (config.ingestKey && !this.cfg.ingestKey) this.cfg.ingestKey = config.ingestKey;\n if (config.getToken && !this.cfg.getToken) this.cfg.getToken = config.getToken;\n }\n /** init is idempotent and browser-only for its side effects: take up what the page\n * arrived with, register the unload flush, and (unless opted out) auto-capture\n * unhandled errors. Safe to call from a React effect on every render. */\n init() {\n if (this.started || !this.cfg.enabled) return;\n this.started = true;\n if (!isBrowser()) return;\n const linked = readLink(window.location.search);\n const clean = stripLink(window.location.href);\n if (clean !== void 0) {\n try {\n window.history.replaceState(window.history.state, \"\", clean);\n } catch {\n }\n }\n this.settle(linked, parseAttribution(window.location.search, document.referrer));\n honour();\n const flushHidden = () => {\n if (document.visibilityState === \"hidden\") this.flush(true);\n };\n window.addEventListener(\"visibilitychange\", flushHidden);\n window.addEventListener(\"pagehide\", () => this.flush(true));\n if (this.cfg.captureErrors) {\n window.addEventListener(\"error\", (e) => {\n this.captureError(e.error ?? e.message, { handled: false });\n });\n window.addEventListener(\"unhandledrejection\", (e) => {\n this.captureError(e.reason, { handled: false });\n });\n }\n }\n /** settle takes up what the page arrived with: the link's identity, the first\n * touch, the last touch and the cohort. */\n settle(linked, landing) {\n if (linked.anonId) adoptAnonId(linked.anonId);\n if (linked.sessionId) adoptSession(linked.sessionId);\n const first = linked.firstTouch && !getFirstTouch() ? setFirstTouchOnce(linked.firstTouch) : void 0;\n this.attribution = first ?? (hasAttribution(landing) ? setFirstTouchOnce(landing) : getFirstTouch() ?? landing);\n if (landing.utm.source || landing.utm.campaign) setLastTouch(landing.utm);\n this.lastUtm = getLastTouch();\n this.cohort = mergeCohort({\n channel: this.attribution.channel ?? deriveChannel(this.attribution),\n refCode: this.attribution.refCode\n });\n }\n /** link returns `url` carrying this visitor's anonymous id, session and first\n * touch when the destination is a Hanzo-owned host, so the journey continues\n * across the hop. Any other URL comes back unchanged. */\n link(url) {\n if (!isBrowser()) return url;\n if (!this.started) this.init();\n return linkUrl(\n url,\n { anonId: anonId(), sessionId: sessionId(), firstTouch: this.attribution },\n window.location.hostname,\n window.location.href\n );\n }\n /** authorize decorates an OAuth authorize URL for the redirect to IAM and flushes\n * what is queued, because the page is about to unload. Assign the result to\n * `location`. */\n authorize(url) {\n const out = this.link(url);\n this.flush(true);\n return out;\n }\n /** identify binds the current visitor to a stable person id (post-login). */\n identify(personId, traits) {\n this.personId = personId;\n this.enqueue(\"identify\", void 0, { properties: traits });\n }\n /** group associates the visitor with an org/team (analytics grouping, not the\n * server tenant — the server still derives tenant from the session). */\n group(groupId, traits) {\n this.enqueue(\"group\", void 0, { groupId, properties: traits });\n }\n /** pageview records a $pageview for the current (or given) location, once per\n * view. A view is the path plus the full location, so a query or hash change\n * is a new one and a repeat call for the same place is not. */\n pageview(path, properties) {\n const p = path ?? (isBrowser() ? window.location.pathname : void 0);\n const view = (p ?? \"\") + \"\\0\" + (isBrowser() ? window.location.href : \"\");\n if (view === this.counted) return;\n this.counted = view;\n this.enqueue(\"pageview\", PAGEVIEW, { path: p, properties: { ...viewport(), ...properties } });\n }\n /** capture records a named product event with optional properties. Commerce\n * fields (productId/quantity/revenue/currency) may be passed for order events,\n * and a location (url/path) for an event about a page the visitor has already\n * left: a page leave is reported after the router moved, and is the page left's. */\n capture(event, properties, fields) {\n this.enqueue(\"event\", event, { properties, ...fields });\n }\n /** captureError reports a caught error, an unhandled rejection, a React render\n * error, or a manual report as ONE event of type 'error' on the one stream.\n * It carries the exception (type, message, frames, stack, handled) and the\n * release, environment, site, product and level that group and scope it, and\n * flushes promptly (a crash may unload the page moments later). Never throws\n * back into the app. */\n captureError(err, context) {\n if (this.reentrant) return;\n this.reentrant = true;\n try {\n const handled = context?.handled ?? true;\n const ex = normalizeError2(err);\n ex.handled = handled;\n this.enqueue(\"error\", void 0, {\n error: ex,\n level: context?.level ?? (handled ? \"error\" : \"fatal\"),\n release: this.cfg.release ?? readEnv(\"NEXT_PUBLIC_HANZO_RELEASE\"),\n environment: this.cfg.environment ?? readEnv(\"NODE_ENV\"),\n site: isBrowser() ? window.location.hostname : void 0,\n properties: context?.properties\n });\n this.flush();\n } catch {\n } finally {\n this.reentrant = false;\n }\n }\n /** setCohort persists cohort dimensions (e.g. signupWeek at signup) so they ride\n * every subsequent event. */\n setCohort(patch) {\n this.cohort = mergeCohort(patch);\n }\n /** flush drains the buffer to the server as ONE batch through the ONE ingest\n * endpoint POST /v1/event, body { batch: [Event…] }. beacon=true selects the\n * unload-safe transport. Auth is orthogonal to the wire:\n *\n * • publishable key set → rides ?ingest_key=pk-… on both sends, keeping each\n * a CORS-simple request that any origin may send.\n * • else a bearer JWT rides Authorization (fetch only — sendBeacon cannot\n * carry a header, so token apps fall back to keepalive fetch on unload).\n * • else a cookie app rides same-origin credentials (beacon carries the\n * cookie fine).\n */\n flush(beacon = false) {\n if (!this.cfg.enabled || this.queue.length === 0) return;\n const batch = this.queue.map(narrowed);\n this.queue = [];\n this.clearTimer();\n if (batch.length === 0) return;\n const token = this.cfg.getToken?.() ?? void 0;\n const key = this.cfg.ingestKey?.trim() || void 0;\n const useBeacon = beacon && !token;\n const body = serializeBatch(batch);\n if (body === null) {\n if (this.cfg.debug) console.debug(\"[event] flush \\u2192 dropped, batch unserializable\");\n return;\n }\n if (this.cfg.debug) console.debug(\"[event] flush \\u2192\", EVENT_PATH, batch.length);\n this.transport.send(this.cfg.host + EVENT_PATH, body, {\n beacon: useBeacon,\n token,\n ingestKey: key,\n debug: this.cfg.debug\n });\n }\n // ── internals ────────────────────────────────────────────────────────────\n enqueue(kind, event, extra) {\n if (!this.cfg.enabled) return;\n if (!this.started) this.init();\n this.queue.push(this.build(kind, event, extra));\n if (this.queue.length >= this.cfg.batchSize) this.flush();\n else this.schedule();\n }\n build(kind, event, extra) {\n const anon = anonId();\n const wire = {\n messageId: hzUuidv7(),\n type: kind,\n event,\n timestamp: (/* @__PURE__ */ new Date()).toISOString(),\n distinctId: this.personId ?? anon,\n anonymousId: anon,\n personId: this.personId,\n sessionId: sessionId(),\n product: this.cfg.product,\n referrer: this.attribution.referrer,\n utm: this.attribution.utm,\n lastUtm: this.lastUtm,\n refCode: this.cohort.refCode ?? this.attribution.refCode,\n channel: this.cohort.channel ?? this.attribution.channel,\n signupWeek: this.cohort.signupWeek,\n // Where the event happened, stamped for every kind rather than only for\n // pageviews. An interaction is reported against the page it happened on,\n // and autocapture ($click/$input/$change) reaches the wire through\n // capture(), which supplies no location — so every click arrived with an\n // empty url and path, and `host`, derived from url, was empty with them.\n // That is unattributable to a page, which is the one thing a heatmap\n // needs. Read here, at the single point every event is built, so it\n // cannot go missing from a call site again.\n //\n // Before `...extra`: pageview() passes an explicit path for route\n // changes that fire before window.location has caught up, and that value\n // has to win over the one read here.\n url: isBrowser() ? window.location.href : void 0,\n path: isBrowser() ? window.location.pathname : void 0,\n library: \"@hanzo/event\",\n libraryVersion: VERSION,\n ...extra\n };\n const capturePII = this.cfg.capturePII ?? false;\n if (wire.url) wire.url = scrubText(withoutFragment(wire.url), capturePII);\n if (wire.path) wire.path = scrubText(withoutFragment(wire.path), capturePII);\n if (wire.referrer) wire.referrer = scrubText(withoutFragment(wire.referrer), capturePII);\n if (internal()) wire.properties = { ...wire.properties, internal: true };\n if (isBrowser()) wire.properties = { ...wire.properties, consent: render(read2()) };\n return wire;\n }\n schedule() {\n if (this.timer || !this.cfg.enabled) return;\n this.timer = setTimeout(() => {\n this.timer = null;\n this.flush();\n }, this.cfg.flushIntervalMs);\n }\n clearTimer() {\n if (this.timer) {\n clearTimeout(this.timer);\n this.timer = null;\n }\n }\n};\nvar CLIENTS = /* @__PURE__ */ Symbol.for(\"hanzo.event.clients.optin\");\nfunction registry() {\n const g2 = globalThis;\n const existing = g2[CLIENTS];\n if (existing) return existing;\n const fresh = /* @__PURE__ */ new Map();\n g2[CLIENTS] = fresh;\n return fresh;\n}\nfunction resetClients() {\n const g2 = globalThis;\n delete g2[CLIENTS];\n}\nfunction createAnalytics(config) {\n if (!isBrowser() || config.enabled === false) return new Analytics(config);\n const key = (config.host ?? DEFAULT_HOST) + \"\\0\" + config.product;\n const clients = registry();\n const existing = clients.get(key);\n if (existing) {\n existing.adopt(config);\n return existing;\n }\n const fresh = new Analytics(config);\n clients.set(key, fresh);\n return fresh;\n}\nvar MAX_VALUE = 4096;\nfunction digest(s) {\n let out = \"\";\n for (const seed of [2166136261, 16777619, 2654435769, 2246822507]) {\n let h = seed >>> 0;\n for (let i = 0; i < s.length; i++) {\n h ^= s.charCodeAt(i);\n h = h + (h << 1) + (h << 4) + (h << 7) + (h << 8) + (h << 24) >>> 0;\n }\n out += h.toString(16).padStart(8, \"0\");\n }\n return out;\n}\nfunction frameOf(f) {\n const source = f.filename ?? \"\";\n const name = f.function ?? \"<anonymous>\";\n const line = f.lineno ?? 0;\n const column = f.colno ?? 0;\n return {\n // Stable per code location, so the same frame groups and re-renders under one\n // key. The '/part' suffix is the product's format for one raw frame expanding\n // into several resolved ones; a browser frame is always part 0.\n raw_id: `${digest(`${source}|${name}|${line}|${column}`)}/0`,\n mangled_name: name,\n source,\n line,\n column,\n in_app: f.in_app ?? false,\n lang: \"javascript\",\n resolved: false,\n resolve_failure: \"no symbol set uploaded for this release\",\n resolved_name: null,\n module: null\n };\n}\nfunction truncate2(s, max) {\n if (s.length <= max) return s;\n let end = max;\n const c = s.charCodeAt(end - 1);\n if (c >= 55296 && c <= 56319) end--;\n return s.slice(0, end);\n}\nfunction exceptionEntry(err, opts) {\n const n = normalizeError(err);\n const frames = framesFromStack(n.stack).slice(-50);\n const entry = {\n id: opts.id,\n type: n.name,\n value: truncate2(n.message, MAX_VALUE),\n mechanism: {\n type: \"generic\",\n handled: opts.handled,\n // An exception the app reported by hand was constructed, not thrown by the\n // runtime at a real call site.\n synthetic: !(err instanceof Error)\n }\n };\n if (frames.length > 0) {\n entry.stacktrace = { type: \"resolved\", frames: frames.map(frameOf) };\n }\n return entry;\n}\nfunction fingerprint(entry) {\n const frames = entry.stacktrace?.frames ?? [];\n const pieces = frames.filter((f) => f.in_app).map((f) => `${f.mangled_name}@${f.source}`);\n return digest([entry.type, ...pieces].join(\"\\n\"));\n}\nfunction exceptionProperties(err, opts) {\n const entry = exceptionEntry(err, opts);\n const frames = entry.stacktrace?.frames ?? [];\n const fp = fingerprint(entry);\n return {\n $exception_list: [entry],\n $exception_fingerprint: fp,\n // Records WHY this fingerprint holds. 'manual' is the honest value: the client\n // supplied the key rather than a server grouper deriving one.\n $exception_fingerprint_record: [{ type: \"manual\" }],\n $exception_type: entry.type,\n $exception_message: entry.value,\n $exception_level: opts.level ?? \"error\",\n $exception_handled: opts.handled,\n $exception_synthetic: entry.mechanism?.synthetic ?? false,\n $exception_types: [entry.type],\n $exception_values: [entry.value],\n $exception_sources: frames.map((f) => f.source).filter((s) => !!s),\n $exception_functions: frames.map((f) => f.resolved_name ?? f.mangled_name).filter((s) => !!s)\n };\n}\n\n// src/touch.ts\nvar CLICK_IDS = [\"gclid\", \"gbraid\", \"wbraid\", \"fbclid\", \"li_fat_id\", \"twclid\", \"ttclid\"];\nvar DAYS = 90;\nvar now = () => Math.floor(Date.now() / 1e3);\nvar rand = () => Math.floor(Math.random() * 2 ** 31);\nfunction capture(c) {\n if (typeof window === \"undefined\") return;\n if (c.marketing) {\n const q = new URLSearchParams(window.location.search);\n const click = {};\n for (const k of CLICK_IDS) {\n const v = q.get(k)?.trim();\n if (v) click[k] = v;\n }\n if (Object.keys(click).length) {\n click.clicked = now();\n set(\"hz_touch\", JSON.stringify(click), DAYS);\n if (click.fbclid) set(\"_fbc\", `fb.1.${Date.now()}.${click.fbclid}`, DAYS);\n }\n if (!get(\"_fbp\")) set(\"_fbp\", `fb.1.${Date.now()}.${rand()}`, DAYS);\n }\n if (c.analytics && !get(\"_ga\") && !get(\"hz_cid\")) set(\"hz_cid\", `${rand()}.${now()}`, 730);\n}\nfunction touch(c) {\n const out = {};\n if (c.marketing) {\n try {\n Object.assign(out, JSON.parse(get(\"hz_touch\") ?? \"{}\"));\n } catch {\n }\n const fbc = get(\"_fbc\");\n const fbp = get(\"_fbp\");\n if (fbc) out.fbc = fbc;\n if (fbp) out.fbp = fbp;\n }\n if (c.analytics) {\n const ga = get(\"_ga\")?.split(\".\");\n const cid = ga && ga.length >= 4 ? ga.slice(-2).join(\".\") : get(\"hz_cid\");\n if (cid) out.cid = cid;\n }\n return out;\n}\nvar page = () => window;\nvar tags = [];\nvar audience = \"person\";\nvar configured = false;\nvar applied = \"\";\nvar options = {};\nvar loaded = /* @__PURE__ */ new Set();\nvar google = \"idle\";\nvar configAnswered = false;\nvar held = [];\nvar leaving = false;\nfunction settled() {\n return configAnswered && google !== \"wait\";\n}\nfunction due() {\n return settled() && !asks();\n}\nfunction flush() {\n if (due() || leaving) held.splice(0).forEach((send) => send());\n}\nfunction ready(limit = 3e3) {\n if (typeof window === \"undefined\") return Promise.resolve();\n const start2 = Date.now();\n const meta2 = () => {\n const fbq = page().fbq;\n return ![...loaded].some((k) => k.startsWith(\"meta:\")) || typeof fbq?.callMethod === \"function\";\n };\n return new Promise((resolve) => {\n const tick = () => {\n if (configured && settled() && meta2() || Date.now() - start2 >= limit) return resolve();\n setTimeout(tick, 100);\n };\n tick();\n });\n}\nfunction script(src, onload, onerror) {\n const s = document.createElement(\"script\");\n s.async = true;\n s.src = src;\n if (onload) s.onload = onload;\n if (onerror) s.onerror = onerror;\n document.head.appendChild(s);\n}\nvar bot = () => audience === \"bot\" || automated();\nvar team = () => audience === \"internal\" || internal();\nfunction gtagStub() {\n const p = page();\n p.dataLayer = p.dataLayer || [];\n if (!p.gtag) {\n p.gtag = function() {\n p.dataLayer.push(arguments);\n };\n }\n return p.gtag;\n}\nvar g = (on) => on ? \"granted\" : \"denied\";\nvar eu = () => policy().mode === \"eu\";\nfunction consentMode(c, first) {\n const gtag = gtagStub();\n if (first) {\n const d = g(!eu());\n gtag(\"consent\", \"default\", {\n analytics_storage: d,\n ad_storage: d,\n ad_user_data: d,\n ad_personalization: d,\n ...eu() ? { wait_for_update: 500 } : {}\n });\n }\n const ads = { ad_storage: g(c.ads), ad_user_data: g(c.ads), ad_personalization: g(c.ads) };\n gtag(\"consent\", \"update\", eu() ? { analytics_storage: g(c.analytics), ...ads } : ads);\n}\nfunction loadGoogle(ids) {\n const gtag = gtagStub();\n const fresh = ids.filter((id) => !loaded.has(id));\n if (!fresh.length) return;\n if (google === \"idle\") {\n google = \"wait\";\n gtag(\"js\", /* @__PURE__ */ new Date());\n const done = (to) => () => {\n if (google !== \"wait\") return;\n google = to;\n flush();\n };\n script(`https://www.googletagmanager.com/gtag/js?id=${encodeURIComponent(fresh[0])}`, done(\"loaded\"), done(\"failed\"));\n setTimeout(done(\"failed\"), 8e3);\n }\n for (const id of fresh) {\n loaded.add(id);\n gtag(\"config\", id, {\n ...options.domains ? { linker: { domains: options.domains } } : {},\n ...team() ? { traffic_type: \"internal\" } : {}\n });\n }\n}\nfunction ldu(c) {\n const p = page();\n if (c.ads) p.fbq(\"dataProcessingOptions\", []);\n else p.fbq(\"dataProcessingOptions\", [\"LDU\"], 0, 0);\n}\nvar reloading = false;\nvar meta = { revoked: false, fetched: false, viewed: false };\nfunction loadMeta(ids, c) {\n const fresh = ids.filter((id) => !loaded.has(`meta:${id}`));\n const p = page();\n if (fresh.length) {\n if (!p.fbq) {\n const n = p.fbq = function(...a) {\n if (n.callMethod) n.callMethod(...a);\n else n.queue.push(a);\n };\n if (!p._fbq) p._fbq = n;\n n.push = n;\n n.loaded = true;\n n.version = \"2.0\";\n n.queue = [];\n }\n if (!loaded.has(\"meta\")) {\n loaded.add(\"meta\");\n if (!c.marketing) {\n p.fbq(\"consent\", \"revoke\");\n meta.revoked = true;\n }\n if (!c.ads) ldu(c);\n }\n for (const id of fresh) {\n p.fbq(\"init\", id);\n loaded.add(`meta:${id}`);\n }\n }\n if (loaded.has(\"meta\") && c.marketing) live();\n}\nfunction live() {\n const p = page();\n if (meta.revoked) {\n if (meta.fetched) p.fbq(\"consent\", \"grant\");\n else if (p.fbq?.queue) p.fbq.queue = p.fbq.queue.filter((a) => !(a[0] === \"consent\" && a[1] === \"revoke\"));\n meta.revoked = false;\n }\n if (!meta.fetched) {\n meta.fetched = true;\n script(\"https://connect.facebook.net/en_US/fbevents.js\");\n }\n if (!meta.viewed) {\n meta.viewed = true;\n p.fbq(\"track\", \"PageView\");\n }\n}\nfunction loadLinkedIn(id) {\n const p = page();\n p._linkedin_data_partner_ids = p._linkedin_data_partner_ids || [];\n p._linkedin_data_partner_ids.push(id);\n if (!p.lintrk) {\n const l = p.lintrk = function(...a) {\n l.q.push(a);\n };\n l.q = [];\n }\n script(\"https://snap.licdn.com/li.lms-analytics/insight.min.js\");\n}\nfunction loadX(id) {\n const p = page();\n if (!p.twq) {\n const s = p.twq = function(...a) {\n if (s.exe) s.exe(...a);\n else s.queue.push(a);\n };\n s.version = \"1.1\";\n s.queue = [];\n script(\"https://static.ads-twitter.com/uwt.js\");\n }\n p.twq(\"config\", id);\n}\nvar TIKTOK_METHODS = [\"page\", \"track\", \"identify\", \"instances\", \"debug\", \"on\", \"off\", \"once\", \"ready\", \"alias\", \"group\", \"enableCookie\", \"disableCookie\"];\nfunction loadTikTok(id) {\n const p = page();\n p.TiktokAnalyticsObject = \"ttq\";\n const q = p.ttq = p.ttq || [];\n if (!q._i) {\n q.methods = TIKTOK_METHODS;\n for (const m of TIKTOK_METHODS) q[m] = (...a) => q.push([m, ...a]);\n q._i = {};\n q._t = {};\n q._o = {};\n q.load = (sdk) => {\n q._i[sdk] = [];\n q._t[sdk] = Date.now();\n script(`https://analytics.tiktok.com/i18n/pixel/events.js?sdkid=${encodeURIComponent(sdk)}&lib=ttq`);\n };\n }\n q.load(id);\n q.page();\n}\nvar NEEDS = {\n ga: \"analytics\",\n gads: \"marketing\",\n meta: \"marketing\",\n linkedin: \"marketing\",\n x: \"marketing\",\n tiktok: \"marketing\"\n};\nvar loads = (t, c) => !policy().refused && (t.type === \"meta\" || t.type === \"ga\" && eu() || Boolean(NEEDS[t.type] && c[NEEDS[t.type]]));\nvar allowed = (t, c) => t.type === \"meta\" ? c.marketing : loads(t, c);\nfunction apply() {\n if (typeof window === \"undefined\" || !configured) return;\n const c = read2();\n const was = applied;\n applied = render(c);\n if (withdrawn(c, was)) return;\n capture(c);\n const on = bot() ? [] : tags.filter((t) => loads(t, c) && (t.type === \"ga\" || !team()));\n const ids = on.filter((t) => t.type === \"ga\" || t.type === \"gads\").map((t) => t.id);\n if (ids.length) {\n if (!loaded.has(\"consent\")) consentMode(c, true);\n loaded.add(\"consent\");\n loadGoogle(ids);\n }\n loadMeta(on.filter((t) => t.type === \"meta\").map((t) => t.id), c);\n for (const t of on) {\n const k = `${t.type}:${t.id}`;\n if (loaded.has(k) || t.type === \"meta\") continue;\n if (t.type === \"linkedin\") loadLinkedIn(t.id);\n else if (t.type === \"x\") loadX(t.id);\n else if (t.type === \"tiktok\") loadTikTok(t.id);\n else continue;\n loaded.add(k);\n }\n flush();\n}\nvar running = (t) => loaded.has(t.type === \"ga\" || t.type === \"gads\" ? t.id : `${t.type}:${t.id}`);\nfunction withdrawn(c, was) {\n const p = page();\n const before = was.split(\",\");\n if (render(c) !== was && loaded.has(\"consent\")) consentMode(c, false);\n if (loaded.has(\"meta\")) {\n if (c.ads !== before.includes(\"ads\")) ldu(c);\n if (!c.marketing && !meta.revoked) {\n p.fbq(\"consent\", \"revoke\");\n meta.revoked = true;\n }\n }\n const gone = tags.filter((t) => t.type !== \"meta\" && running(t) && !loads(t, c));\n if (!gone.length) return false;\n for (const t of gone) if (t.type === \"ga\" || t.type === \"gads\") window[`ga-disable-${t.id}`] = true;\n if (!open() && !reloading) {\n reloading = true;\n setTimeout(() => window.location.reload(), 0);\n }\n return true;\n}\nfunction start(o = {}) {\n if (typeof window === \"undefined\") return () => void 0;\n options = o;\n addEventListener(CONSENT_EVENT, apply);\n const shown = () => {\n if (document.visibilityState !== \"hidden\" && render(read2()) !== applied) apply();\n };\n addEventListener(\"pageshow\", shown);\n addEventListener(\"visibilitychange\", shown);\n addEventListener(\"pagehide\", pagehide);\n if (!configured) {\n configured = true;\n const base = (o.base ?? \"https://api.hanzo.ai\").replace(/\\/$/, \"\");\n const q = new URLSearchParams();\n const host = o.host ?? window.location.hostname;\n const key = o.key ?? siteKey(host);\n if (key) q.set(\"key\", key);\n q.set(\"host\", host);\n const answer = (list) => {\n tags = list;\n configAnswered = true;\n apply();\n };\n const url = `${base}/v1/project/tags?${q}`;\n const bearer = tokenOf(o);\n const get2 = (auth) => fetch(url, auth ? { headers: { Authorization: `Bearer ${auth}` } } : void 0);\n const cap = setTimeout(() => answer([]), 3e3);\n get2(bearer).catch((e) => bearer ? get2() : Promise.reject(e)).then((r) => r.ok ? r.json() : { tags: [] }).then((j) => {\n clearTimeout(cap);\n serve(j.consent);\n if (j.audience === \"bot\" || j.audience === \"internal\") audience = j.audience;\n if (audience === \"internal\" && read2().analytics) mark();\n answer(Array.isArray(j.tags) ? j.tags : []);\n }).catch(() => {\n clearTimeout(cap);\n answer([]);\n });\n }\n return () => {\n removeEventListener(CONSENT_EVENT, apply);\n removeEventListener(\"pagehide\", pagehide);\n };\n}\nfunction tokenOf(o) {\n try {\n return o.token?.() || void 0;\n } catch {\n return void 0;\n }\n}\nfunction pagehide() {\n leaving = true;\n flush();\n}\nfunction reach() {\n const c = read2();\n const to = [];\n for (const t of tags) {\n if (!allowed(t, c)) continue;\n const running2 = t.type === \"ga\" || t.type === \"gads\" ? google === \"loaded\" : loaded.has(`${t.type}:${t.id}`);\n if (running2 && !to.includes(t.type)) to.push(t.type);\n }\n return to.join(\",\");\n}\nvar META_STANDARD = /* @__PURE__ */ new Set([\n \"AddPaymentInfo\",\n \"AddToCart\",\n \"AddToWishlist\",\n \"CompleteRegistration\",\n \"Contact\",\n \"CustomizeProduct\",\n \"Donate\",\n \"FindLocation\",\n \"InitiateCheckout\",\n \"Lead\",\n \"Purchase\",\n \"Schedule\",\n \"Search\",\n \"StartTrial\",\n \"SubmitApplication\",\n \"Subscribe\",\n \"ViewContent\"\n]);\nfunction shape(platform, p) {\n const items = Array.isArray(p.items) ? p.items : [];\n const out = {};\n if (typeof p.value === \"number\") out.value = p.value;\n out.currency = typeof p.currency === \"string\" ? p.currency : \"USD\";\n if (typeof p.search_string === \"string\" && p.search_string && platform !== \"x\") out[platform === \"tiktok\" ? \"query\" : \"search_string\"] = p.search_string;\n if (!items.length) return out;\n if (platform === \"meta\") {\n out.content_type = \"product\";\n out.content_ids = items.map((i) => i.item_id);\n out.contents = items.map((i) => ({ id: i.item_id, quantity: i.quantity ?? 1, item_price: i.price }));\n out.content_name = items[0].item_name;\n out.num_items = items.reduce((n, i) => n + (i.quantity ?? 1), 0);\n } else if (platform === \"tiktok\") {\n out.content_type = \"product\";\n out.contents = items.map((i) => ({ content_id: i.item_id, content_name: i.item_name, quantity: i.quantity ?? 1, price: i.price }));\n } else {\n out.contents = items.map((i) => ({ content_id: i.item_id, content_name: i.item_name, content_price: i.price, num_items: i.quantity ?? 1 }));\n }\n return out;\n}\nfunction unpriced(p) {\n const out = { ...p, value: 0 };\n if (Array.isArray(p.items)) out.items = p.items.map((i) => ({ ...i, price: 0 }));\n return out;\n}\nfunction mirror(name, params, id, to = reach()) {\n const p = page();\n const c = read2();\n const on = new Set(to.split(\",\").filter(Boolean));\n const ga4 = namesOn(name, \"ga4\");\n const test = params.test === true;\n if (test) params = unpriced(params);\n const transaction = typeof params.order_id === \"string\" ? { transaction_id: params.order_id } : {};\n let once = false;\n for (const t of tags) {\n if (!on.has(t.type) || !allowed(t, c) || t.type === \"meta\" && once) continue;\n if (t.type === \"meta\") once = true;\n const rule = t.events?.[name];\n if (t.type === \"ga\") {\n for (const n of ga4) {\n p.gtag?.(\"event\", n, { ...params, ...transaction, event_id: id, send_to: t.id, transport_type: \"beacon\", ...test ? { debug_mode: true } : {} });\n }\n } else if (t.type === \"gads\" && rule) {\n p.gtag?.(\"event\", \"conversion\", {\n send_to: rule,\n value: typeof params.value === \"number\" ? params.value : void 0,\n currency: typeof params.currency === \"string\" ? params.currency : \"USD\",\n ...transaction\n });\n } else if (t.type === \"meta\") {\n for (const n of namesOn(name, \"meta\")) {\n p.fbq?.(META_STANDARD.has(n) ? \"track\" : \"trackCustom\", n, shape(\"meta\", params), { eventID: id });\n }\n } else if (t.type === \"tiktok\") {\n for (const n of namesOn(name, \"tiktok\")) p.ttq?.track?.(n, shape(\"tiktok\", params), { event_id: id });\n } else if (t.type === \"linkedin\" && rule && namesOn(name, \"linkedin\").length) {\n p.lintrk?.(\"track\", { conversion_id: Number(rule) });\n } else if (t.type === \"x\" && rule && namesOn(name, \"x\").length) {\n p.twq?.(\"event\", rule, { ...shape(\"x\", params), conversion_id: id });\n }\n }\n}\nfunction track(stream, name, params = {}, only) {\n if (typeof window === \"undefined\") return;\n if (!leaving && !due()) {\n held.push(() => track(stream, name, params, only));\n return;\n }\n const c = read2();\n const event_id = typeof params.event_id === \"string\" && params.event_id ? params.event_id : hzUuidv7();\n const to = reach();\n mirror(name, params, event_id, to);\n if (only === \"tags\") return;\n stream?.capture(name, {\n ...params,\n ...touch(c),\n event_id,\n consent: render(c),\n tags: to,\n userAgent: navigator.userAgent,\n url: window.location.href\n });\n}\nfunction visit() {\n const c = read2();\n return { ...touch(c), consent: render(c), tags: reach(), userAgent: navigator.userAgent, url: window.location.href };\n}\n\n// src/items.ts\nfunction commerceItem(p) {\n const annual = /^(year|yearly|annual)$/i.test(p.interval);\n return {\n item_id: p.id,\n ...p.name ? { item_name: p.name } : {},\n item_category: p.team ? \"team\" : \"individual\",\n item_variant: annual ? \"annual\" : \"monthly\",\n price: p.price ?? 0,\n quantity: p.quantity ?? 1\n };\n}\nvar worth = (i) => i.price * i.quantity;\n\n// src/goals.ts\nvar GOALS = {\n // Signup: the conversion is signup_completed, along the site signup funnel.\n signup: {\n label: \"Signup\",\n event: EVENTS.SIGNUP_COMPLETED,\n funnelId: \"signup\",\n funnel: eventsOf(\"signup\")\n },\n // Sale: a completed order qualified as a plan purchase (kind=plan).\n sale: {\n label: \"Sale\",\n event: EVENTS.ORDER_COMPLETED,\n funnelId: \"upgrade\",\n funnel: eventsOf(\"upgrade\"),\n filter: { property: \"kind\", equals: \"plan\" }\n },\n // Upgrade intent: a plan click; pricing_viewed is the top of its funnel.\n upgradeIntent: {\n label: \"Upgrade Intent\",\n event: EVENTS.PLAN_CLICKED,\n funnelId: \"upgrade\",\n funnel: eventsOf(\"upgrade\")\n },\n // Activation: the ONE north-star conversion — an account that did the first\n // valuable thing (a successful API call, a live app, a chat answer).\n activation: {\n label: \"Activation\",\n event: EVENTS.FIRST_ACTION,\n funnelId: \"apiActivation\",\n funnel: eventsOf(\"apiActivation\")\n }\n};\nvar COHORTS = {\n signupWeek: { field: \"signup_week\", label: \"Signup week\" },\n channel: { field: \"channel\", label: \"Acquisition channel\" },\n refCode: { field: \"ref_code\", label: \"Referral code\" }\n};\n/*! anon.js — THE anonymous-identity chain. ONE implementation, two distributions.\n *\n * One browser is ONE person on every Hanzo surface, whichever client a page\n * happens to have loaded. There were once three implementations writing TWO keys —\n * `hz_anon_id` and `hz_id` — so the same visitor was several people depending on\n * which snippet the surface shipped.\n *\n * The two call sites:\n * 1. src/storage.ts — the bundled npm client; IMPORTS this file.\n * 2. hanzoai/cloud apps/analytics/tag.js — the tag served at\n * /v1/event.js; vendors this file and its tag.go serves the marked region\n * with the tag as one asset, so cloud holds no second copy either.\n *\n * (2) has no bundler and cannot import anything, which is why the chain lives in a\n * file that is plain ES5 rather than in a .ts: the region between the BEGIN and END\n * markers is COPIED VERBATIM. Keep it ES5, dependency-free, `hz`-prefixed (it is\n * spliced into other people's scopes) and unformatted — a reformat here is a diff\n * against the vendored copy. After editing, resync that copy:\n *\n * curl -fsSL https://unpkg.com/@hanzo/event/src/anon.js -o apps/analytics/anon.js\n */\n\nexport { Analytics, CLICK_IDS, COHORTS, CONSENT_COOKIE, CONSENT_EVENT, CONSENT_FLOOR, CONSENT_VERSION, CONSENT_VERSION_COOKIE, GOALS, LINK_PARAMS, NOTICE_COOKIE, ORG_DOMAIN, ORG_KEY, POLICY_EVENT, RULE_COOKIE, SITE_KEY, VERSION, acceptAll, asks, capture as captureClick, commerceItem, policy as consentPolicy, sheet as consentSheet, createAnalytics, declined, deriveChannel, digest, exceptionEntry, exceptionProperties, fingerprint, framesFromStack, getCohort, getFirstTouch, gpc, hasAttribution, hostOf, isoWeek, keyFor, keyForPage, linkUrl, mirror, notice, noticed, orgOf, parseAttribution, reach, read2 as readConsent, readLink, redactSecrets, refused, rejectAll, render as renderConsent, resetClients, save as saveConsent, scrubPII, scrubText, serve as serveConsent, siteKey, start as startTags, stored as storedConsent, stripLink, ready as tagsReady, touch, track, hzUuidv7 as uuidv7, uuidv7Time, visit, worth };\n//# sourceMappingURL=index.mjs.map\n//# sourceMappingURL=index.mjs.map","/**\n * @license React\n * react-jsx-runtime.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\");\nfunction jsxProd(type, config, maybeKey) {\n var key = null;\n void 0 !== maybeKey && (key = \"\" + maybeKey);\n void 0 !== config.key && (key = \"\" + config.key);\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n config = maybeKey.ref;\n return {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n ref: void 0 !== config ? config : null,\n props: maybeKey\n };\n}\nexports.Fragment = REACT_FRAGMENT_TYPE;\nexports.jsx = jsxProd;\nexports.jsxs = jsxProd;\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","// *0 order matches to *1\nexport const pseudoDescriptorsBase = {\n // order of keys here important! in priority order\n hoverStyle: {\n name: 'hover',\n priority: 2,\n },\n pressStyle: {\n name: 'active',\n stateKey: 'press',\n priority: 3,\n },\n focusVisibleStyle: {\n name: 'focus-visible',\n priority: 4,\n stateKey: 'focusVisible',\n },\n focusStyle: {\n name: 'focus',\n priority: 4,\n },\n focusWithinStyle: {\n name: 'focus-within',\n priority: 4,\n stateKey: 'focusWithin',\n },\n disabledStyle: {\n name: 'disabled',\n priority: 5,\n stateKey: 'disabled',\n },\n};\nexport const pseudoPriorities = {\n hover: pseudoDescriptorsBase.hoverStyle.priority,\n press: pseudoDescriptorsBase.pressStyle.priority,\n focus: pseudoDescriptorsBase.focusStyle.priority,\n focusVisible: pseudoDescriptorsBase.focusVisibleStyle.priority,\n focusWithin: pseudoDescriptorsBase.focusWithinStyle.priority,\n disabled: pseudoDescriptorsBase.disabledStyle.priority,\n};\nexport const pseudoDescriptors = {\n ...pseudoDescriptorsBase,\n enterStyle: {\n name: 'enter',\n selector: '.t_unmounted',\n priority: 4,\n },\n exitStyle: {\n name: 'exit',\n priority: 5,\n },\n};\n// media always above pseudos\nexport const defaultMediaImportance = Object.keys(pseudoDescriptors).length;\n//# sourceMappingURL=pseudoDescriptors.js.map","/**\n * Preserves prop ordering, so that the order most closely matches the last spread objects\n * Useful for having { ...defaultProps, ...props } that ensure props ordering is always kept\n *\n * Honestly this is somehwat backwards logically from Object.assign, reason was that we typically\n * are merging defaultProps, givenProps, but we started using it elsewhere and now its a bit confusing\n * Should look into refactoring this to match common usage\n *\n * Merges sub-objects if they start are pseudo-keys or media-key-like (start with \"$\")\n *\n * Given:\n * mergeProps({ a: 1, b: 2 }, { b: 1, a: 2 })\n * The final key order will be:\n * b, a\n *\n */\nimport { pseudoDescriptors } from './pseudoDescriptors.js';\nexport const mergeProps = (defaultProps, props) => {\n const out = {};\n // in general objects keys are sorted by order of insertion\n // we merge \"defaultProps\" first as they should come first\n // (so Object.keys(finalProps) will list [...defaultPropKeys] first)\n // but we ignore any keys from props, and merge it after, that way\n // final order is [...defaultPropKeys, ...propKeys]\n // ⚠️ keep in sync with mergeComponentProps logic\n for (const key in defaultProps) {\n if (key in props)\n continue;\n out[key] = defaultProps[key];\n }\n for (const key in props) {\n mergeProp(out, defaultProps, props, key);\n }\n return out;\n};\n// merge props but also handles defaultProps + styledContext\nexport const mergeComponentProps = (\n// this is \"a\" in mergeProps\ndefaultProps, contextProps, \n// this is \"b\" in mergeProps\nprops) => {\n let overriddenContext = null;\n if (!defaultProps && !contextProps) {\n return [props, overriddenContext];\n }\n if (defaultProps && !contextProps) {\n return [mergeProps(defaultProps, props), overriddenContext];\n }\n // the only unique case is contextProps, we need to track overrides and do something a bit tricky\n // since we respect prop order for styles, we want to preserve the object key order in overriddenContext\n const out = {};\n // ⚠️ keep in sync with mergeProps logic\n // same logic as mergeProps but tracking overrides!\n for (const key in defaultProps) {\n if (key in props)\n continue;\n out[key] = defaultProps[key];\n }\n // styled context props go after defaultProps but before props\n for (const key in contextProps) {\n if (key in props)\n continue;\n const contextValue = contextProps[key];\n // don't merge undefined context values to preserve inheritance\n if (contextValue !== undefined) {\n out[key] = contextValue;\n }\n }\n for (const key in props) {\n mergeProp(out, defaultProps, props, key);\n if (contextProps && key in contextProps) {\n overriddenContext || (overriddenContext = {});\n overriddenContext[key] = props[key];\n }\n }\n return [out, overriddenContext];\n};\nfunction mergeProp(out, defaultProps, props, key) {\n let val = props[key];\n // one special case - we merge hanzogui style sub-objects\n if (defaultProps &&\n key in defaultProps &&\n (key in pseudoDescriptors || key[0] === '$') &&\n val &&\n typeof val === 'object') {\n const defaultVal = defaultProps[key];\n if (defaultVal && typeof defaultVal === 'object') {\n // use merge props so we prefer the key ordering the the last merged\n val = mergeProps(defaultVal, val);\n }\n }\n out[key] = val;\n}\n//# sourceMappingURL=mergeProps.js.map","export function objectIdentityKey(obj) {\n let k = '';\n for (const key in obj) {\n k += key;\n const arg = obj[key];\n let type = typeof arg;\n if (!arg || (type !== 'object' && type !== 'function')) {\n k += type + arg;\n }\n else if (cache.has(arg)) {\n k += cache.get(arg);\n }\n else {\n let v = Math.random();\n cache.set(arg, v);\n k += v;\n }\n }\n return k;\n}\nconst cache = new WeakMap();\n//# sourceMappingURL=objectIdentityKey.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport React from 'react';\nimport { mergeProps } from './mergeProps.js';\nimport { objectIdentityKey } from './objectIdentityKey.js';\n// use const (not function declaration) to prevent esbuild from hoisting\n// above __esm lazy init - function declarations get hoisted before\n// import_react is initialized, causing undefined.default errors in SSR\nexport const createStyledContext = (defaultValues, namespace = '') => {\n // avoid react compiler - we aren't breaking its rules but it mis-interprets\n // how we change the context value\n 'use no memo';\n // lazy initialization fixes vite ssr hmr - module-level assignments can fail\n // when React is undefined during __esm re-initialization order issues.\n // also React.createContext is optimized oddly by React compiler and our\n // uncommon usage confuses it, so we use dynamic access\n const createReactContext = React[Math.random() ? 'createContext' : 'createContext'];\n const useReactMemo = React[Math.random() ? 'useMemo' : 'useMemo'];\n const useReactContext = React[Math.random() ? 'useContext' : 'useContext'];\n const OGContext = createReactContext(defaultValues);\n const OGProvider = OGContext.Provider;\n const Context = OGContext;\n const scopedContexts = new Map();\n const LastScopeInNamespace = createReactContext(namespace);\n function getOrCreateScopedContext(scope) {\n let ScopedContext = scopedContexts.get(scope);\n if (!ScopedContext) {\n ScopedContext = createReactContext(defaultValues);\n scopedContexts.set(scope, ScopedContext);\n }\n return ScopedContext;\n }\n const getNamespacedScope = (scope) => namespace ? `${namespace}--${scope}` : scope;\n const Provider = ({ children, scope: scopeIn, \n // performance: avoid creating objects\n __disableMergeDefaultValues, ...values }) => {\n const scope = getNamespacedScope(scopeIn);\n const next = useReactMemo(() => {\n if (__disableMergeDefaultValues) {\n // we already merged and want to keep ordering\n return values;\n }\n return mergeProps(defaultValues, values);\n }, [objectIdentityKey(values)]);\n let ScopedProvider = OGProvider;\n if (scope) {\n ScopedProvider = getOrCreateScopedContext(scope).Provider;\n }\n return (_jsx(LastScopeInNamespace.Provider, { value: scope, children: _jsx(ScopedProvider, { value: next, children: children }) }));\n };\n // use consumerComponent just to give a better error message\n const useStyledContext = (scopeIn = '') => {\n const lastScopeInNamespace = useReactContext(LastScopeInNamespace);\n const scope = namespace\n ? scopeIn\n ? getNamespacedScope(scopeIn)\n : lastScopeInNamespace\n : scopeIn;\n const context = scope ? getOrCreateScopedContext(scope) : OGContext;\n const value = useReactContext(context);\n return value;\n };\n // @ts-expect-error we are overriding default provider\n Context.Provider = Provider;\n Context.props = defaultValues;\n Context.context = OGContext;\n Context.useStyledContext = useStyledContext;\n return Context;\n};\n//# sourceMappingURL=createStyledContext.js.map","import { useContext } from 'react';\nimport { createStyledContext } from '../helpers/createStyledContext.js';\nexport const ComponentContext = createStyledContext({\n disableSSR: undefined,\n inText: false,\n language: null,\n animationDriver: null,\n setParentFocusState: null,\n insets: null,\n});\nexport const useConfiguration = () => {\n return useContext(ComponentContext);\n};\n//# sourceMappingURL=ComponentContext.js.map","import { createContext } from 'react';\nexport const GroupContext = createContext(null);\n//# sourceMappingURL=GroupContext.js.map","import { useCallback } from 'react';\nexport function useCreateShallowSetState(setter, debug) {\n // this must be memoized or it ruins performance in components\n return useCallback((stateOrGetState) => {\n setter((prev) => {\n const next = typeof stateOrGetState === 'function' ? stateOrGetState(prev) : stateOrGetState;\n const update = mergeIfNotShallowEqual(prev, next);\n if (process.env.NODE_ENV === 'development') {\n if (debug && update !== prev) {\n console.groupCollapsed(`setStateShallow CHANGE`, '=>', update);\n console.info(`previously`, prev);\n console.trace();\n console.groupEnd();\n if (debug === 'break') {\n // debugger is intentionally here for debugging\n }\n }\n }\n return update;\n });\n }, [setter, debug]);\n}\nexport function mergeIfNotShallowEqual(prev, next) {\n if (!prev || !next || isEqualShallow(prev, next)) {\n if (!prev)\n return next;\n return prev;\n }\n return { ...prev, ...next };\n}\nexport function isEqualShallow(prev, next) {\n for (const key in next) {\n if (prev[key] !== next[key]) {\n return false;\n }\n }\n return true;\n}\n//# sourceMappingURL=index.js.map","import { useEffect, useLayoutEffect } from 'react';\nexport const isWeb = true;\n// RN adds fake window and document so its not simple to get this right\n// check both navigator and location\nexport const isBrowser = typeof navigator !== 'undefined' && typeof location !== 'undefined';\nexport const isServer = isWeb && !isBrowser;\nexport const isClient = isWeb && isBrowser;\n/** @deprecated use isBrowser instead */\nexport const isWindowDefined = isBrowser;\nexport const useIsomorphicLayoutEffect = isServer\n ? useEffect\n : useLayoutEffect;\nexport const isChrome = typeof navigator !== 'undefined' && /Chrome/.test(navigator.userAgent || '');\nexport const isWebTouchable = isClient && ('ontouchstart' in window || navigator.maxTouchPoints > 0);\nexport const isNativeDesktop = false;\nexport const isTouchable = !isWeb || isWebTouchable;\n// set :boolean to avoid inferring type to false\n// On web, isAndroid/isIos are always false in production.\n// TEST_NATIVE_PLATFORM is only set by the test runner (vitest) to simulate native\n// environments (e.g. androidtv, tvos) from a web/jsdom test context.\nexport const isAndroid = process.env.TEST_NATIVE_PLATFORM === 'android' ||\n // Android TV has Platform.OS === 'android' per react-native-tvos\n process.env.TEST_NATIVE_PLATFORM === 'androidtv';\nexport const isIos = process.env.TEST_NATIVE_PLATFORM === 'ios' ||\n // tvOS has Platform.OS === 'ios' per react-native-tvos\n process.env.TEST_NATIVE_PLATFORM === 'tvos';\nexport const supportsDynamicColorIOS = isIos || process.env.GUI_DYNAMIC_COLOR_IOS === '1';\nexport const isTV = process.env.TEST_NATIVE_PLATFORM === 'androidtv' ||\n process.env.TEST_NATIVE_PLATFORM === 'tvos';\n/**\n * Reflects Platform.OS. TV platforms are intentionally NOT separate values:\n * - Android TV has Platform.OS === 'android' (react-native-tvos behavior)\n * - tvOS has Platform.OS === 'ios' (react-native-tvos behavior)\n * Use `isTV` combined with `isAndroid`/`isIos` to detect specific TV platforms.\n */\nexport const currentPlatform = 'web';\n// In web source mode (Vite/webpack without pre-built dist), GUI_TARGET may not be set.\n// Set it here so all process.env.GUI_TARGET runtime checks work correctly.\n// In pre-built dist, the build tool inlines GUI_TARGET as a literal string,\n// making this block dead code (if (!'web') → never executes).\nif (!\"web\") {\n process.env.GUI_TARGET = 'web';\n}\n//# sourceMappingURL=constants.js.map","// the renderer-platform extension point: a custom renderer (e.g. react-native-gpui,\n// which reconciles React into GPUI/Metal) registers ONE driver object at app setup\n// and hanzogui consults it for capabilities the renderer owns better than JS can.\n//\n// first capability: `pseudo` — the renderer resolves hover natively per hitbox\n// (zero latency, no event round-trip) and pushes pseudo-state flips INTO hanzogui,\n// which runs its normal animation-driver/emitter path off them (spring if styled,\n// instant otherwise, zero React commits). this replaces both the per-site\n// `transition=\"0ms\"` requirement and the mouseEnter/mouseLeave hover lane on such\n// renderers. more capabilities (measure, focus, scroll) can slot in over time.\nlet platformDriver = null;\n/** register the renderer platform driver — call once at app setup, before render. */\nexport function setupPlatformDriver(driver) {\n platformDriver = driver;\n}\nexport function getPlatformDriver() {\n return platformDriver;\n}\n//# sourceMappingURL=platformDriver.js.map","export const THEME_NAME_SEPARATOR = '_';\nexport const THEME_CLASSNAME_PREFIX = 't_';\nexport const FONT_DATA_ATTRIBUTE_NAME = 'data-hanzogui-font';\nexport const MISSING_THEME_MESSAGE = process.env.NODE_ENV === 'development'\n ? `Can't find Gui configuration.\n \nMost of the time this is due to having mis-matched versions of Gui dependencies, or bundlers somehow duplicating them.\nFirst step is to ensure every \"hanzogui\" and \"@hanzogui/*\" dependency is on the same version, we have a CLI tool to help: \n\n npx @hanzogui/cli check\n`\n : `Missing theme.`;\n//# sourceMappingURL=constants.js.map","import { isWeb } from '@hanzogui/constants';\nimport { MISSING_THEME_MESSAGE } from './constants/constants.js';\nlet conf;\nlet setConfigCalledByThisInstance = false;\nconst haventCalledErrorMessage = process.env.NODE_ENV === 'development'\n ? `\nHaven't called createGui yet. ${MISSING_THEME_MESSAGE}\n`\n : `❌ Error 001`;\n// helper to get config from module-scoped variable or globalthis fallback\n// this handles vite ssr bundling where multiple copies of hanzogui may exist\nconst getConfigFromGlobalOrLocal = () => {\n if (conf) {\n return conf;\n }\n // fall back to globalthis (for vite ssr bundling scenarios)\n if (globalThis.__hanzoguiConfig) {\n // defer warning - if createGui runs in THIS instance, it's HMR (safe)\n // if it never runs, it's a true duplicate (warn)\n if (process.env.NODE_ENV === 'development' &&\n !globalThis.__hanzoguiHasWarnedGlobalFallback &&\n !globalThis.__hanzoguiPendingCheck) {\n globalThis.__hanzoguiPendingCheck = true;\n setTimeout(() => {\n if (!setConfigCalledByThisInstance &&\n !globalThis.__hanzoguiHasWarnedGlobalFallback) {\n globalThis.__hanzoguiHasWarnedGlobalFallback = true;\n console.warn(`⚠️⚠️⚠️⚠️⚠️\n\nGui: Using global config fallback. This may indicate duplicate hanzogui instances (e.g., from Vite SSR bundling). This is handled automatically, but likely causes issues!\n\n⚠️⚠️⚠️⚠️⚠️`);\n }\n globalThis.__hanzoguiPendingCheck = false;\n }, 500);\n }\n return globalThis.__hanzoguiConfig;\n }\n return null;\n};\nexport const getSetting = (key) => {\n const config = getConfigFromGlobalOrLocal();\n if (process.env.NODE_ENV === 'development') {\n if (!config)\n throw new Error(haventCalledErrorMessage);\n }\n return (config.settings[key] ??\n // @ts-expect-error\n config[key]);\n};\nexport function getStyleCompat() {\n const config = getConfigFromGlobalOrLocal();\n return (config?.settings.styleCompat ?? config?.styleCompat) || 'web';\n}\nexport const setConfig = (next) => {\n setConfigCalledByThisInstance = true;\n conf = next;\n globalThis.__hanzoguiConfig = next;\n};\nexport const setConfigFont = (name, font, fontParsed) => {\n const config = getConfigFromGlobalOrLocal();\n if (process.env.NODE_ENV === 'development') {\n if (!config)\n throw new Error(haventCalledErrorMessage);\n }\n config.fonts[name] = font;\n config.fontsParsed[`$${name}`] = fontParsed;\n};\nexport const getConfig = () => {\n const config = getConfigFromGlobalOrLocal();\n if (!config) {\n throw new Error(process.env.NODE_ENV !== 'production'\n ? `Missing hanzogui config, you either have a duplicate config, or haven't set it up. Be sure createGui is called before rendering. Also, make sure all of your hanzogui dependencies are on the same version (\\`hanzogui\\`, \\`@hanzogui/package-name\\`, etc.) not just in your package.json, but in your lockfile.`\n : 'Err0');\n }\n return config;\n};\nexport const getConfigMaybe = () => {\n return getConfigFromGlobalOrLocal();\n};\nlet tokensMerged;\nexport function setTokens(_) {\n tokensMerged = _;\n}\nexport const getTokens = ({ prefixed, } = {}) => {\n const config = getConfigFromGlobalOrLocal();\n if (process.env.NODE_ENV === 'development') {\n if (!config)\n throw new Error(haventCalledErrorMessage);\n }\n const { tokens, tokensParsed } = config;\n if (prefixed === false)\n return tokens;\n if (prefixed === true)\n return tokensParsed;\n return tokensMerged;\n};\nexport const getTokenObject = (value, group) => {\n const config = getConfigFromGlobalOrLocal();\n return (config.specificTokens[value] ??\n (group\n ? tokensMerged[group]?.[value]\n : tokensMerged[Object.keys(tokensMerged).find((cat) => tokensMerged[cat][value]) || '']?.[value]));\n};\nexport const getToken = (value, group, useVariable = isWeb) => {\n const token = getTokenObject(value, group);\n return useVariable ? token?.variable : token?.val;\n};\nexport const getTokenValue = (value, group) => {\n if (value === 'unset' || value === 'auto')\n return;\n return getToken(value, group, false);\n};\n/**\n * Note: this is the same as `getTokens`\n */\nexport const useTokens = getTokens;\nexport const getThemes = () => getConfigFromGlobalOrLocal().themes;\nexport const updateConfig = (key, value) => {\n // for usage internally only\n const config = getConfigFromGlobalOrLocal();\n if (!config || !Object.prototype.hasOwnProperty.call(config, key)) {\n return;\n }\n Object.assign(config[key], value);\n};\n// searches by value name or token name\nexport const getFont = (name) => {\n const conf = getConfig();\n return (conf.fontsParsed[name] ??\n Object.entries(conf.fontsParsed).find(([k]) => conf.fontsParsed[k]?.family?.['val'] === name)?.[1]);\n};\nexport let devConfig;\nexport function setupDev(conf) {\n if (process.env.NODE_ENV === 'development') {\n devConfig = conf;\n }\n}\n/**\n * Dynamically load an animation driver at runtime.\n * Useful for lazy loading heavier animation drivers after initial page load.\n *\n * @example\n * ```tsx\n * // import loadAnimationDriver from hanzogui\n * // import createAnimations from your preferred driver (e.g. animations-reanimated)\n *\n * const driver = createAnimations({ bouncy: { type: 'spring', damping: 10 } })\n * loadAnimationDriver('spring', driver)\n * ```\n */\nexport function loadAnimationDriver(name, driver) {\n const config = getConfigFromGlobalOrLocal();\n if (!config) {\n if (process.env.NODE_ENV === 'development') {\n console.warn('loadAnimationDriver called before createGui');\n }\n return;\n }\n // Convert single driver to object format if needed\n if (config.animations && !('default' in config.animations)) {\n ;\n config.animations = {\n default: config.animations,\n };\n }\n // Add the new driver\n if (config.animations) {\n ;\n config.animations[name] = driver;\n }\n else {\n ;\n config.animations = {\n default: driver,\n [name]: driver,\n };\n }\n}\n//# sourceMappingURL=config.js.map","function camelToHyphen(str) {\n return str.replace(/[A-Z]/g, (m) => `-${m.toLowerCase()}`).toLowerCase();\n}\nconst cache = new WeakMap();\nexport function mediaObjectToString(query) {\n if (typeof query === 'string') {\n return query;\n }\n if (cache.has(query)) {\n return cache.get(query);\n }\n const res = Object.entries(query)\n .map(([feature, value]) => {\n feature = camelToHyphen(feature);\n if (typeof value === 'string') {\n return `(${feature}: ${value})`;\n }\n if (typeof value === 'number' && /[height|width]$/.test(feature)) {\n value = `${value}px`;\n }\n return `(${feature}: ${value})`;\n })\n .join(' and ');\n cache.set(query, res);\n return res;\n}\n//# sourceMappingURL=mediaObjectToString.js.map","export let mediaState = \n// development only safeguard\nprocess.env.NODE_ENV === 'development'\n ? new Proxy({}, {\n get(target, key) {\n if (typeof key === 'string' &&\n key[0] === '$' &&\n // dont error on $$typeof\n key[1] !== '$') {\n throw new Error(`Access mediaState should not use \"$\": ${key}`);\n }\n return Reflect.get(target, key);\n },\n })\n : {};\nexport const setMediaState = (next) => {\n mediaState = next;\n};\nexport const mediaQueryConfig = {};\nexport const getMedia = () => mediaState;\nexport const mediaKeys = new Set(); // with $ prefix\n//# sourceMappingURL=mediaState.js.map","import { getMedia } from './mediaState.js';\nimport { pseudoPriorities } from './pseudoDescriptors.js';\n// convert kebab-case to camelCase (e.g. \"focus-visible\" -> \"focusVisible\")\nfunction kebabToCamel(str) {\n return str.replace(/-([a-z])/g, (_, c) => c.toUpperCase());\n}\n// validate that a string is a known pseudo selector\nfunction isValidPseudo(str) {\n if (!str)\n return false;\n // pseudoPriorities uses camelCase keys, but parsed candidates may be kebab-case\n return kebabToCamel(str) in pseudoPriorities;\n}\nexport function getGroupPropParts(groupProp) {\n const m = getMedia();\n const [_, name, a, b, c] = groupProp.split('-');\n // check 2-part media key first (e.g. \"max-md\"), then 1-part\n const m2 = a && b ? `${a}-${b}` : '';\n const media = (m2 && m2 in m && m2) || (a && a in m && a) || undefined;\n let pseudoCandidate = media\n ? media === m2\n ? c\n : b\n ? `${b}${c ? `-${c}` : ''}`\n : undefined\n : a\n ? `${a}${b ? `-${b}` : ''}${c ? `-${c}` : ''}`\n : undefined;\n // only treat as pseudo if it's a known pseudo selector\n // otherwise it might be an unrecognized media query\n if (pseudoCandidate && !isValidPseudo(pseudoCandidate)) {\n if (process.env.NODE_ENV === 'development') {\n console.warn(`Unknown group prop part \"${pseudoCandidate}\" in \"${groupProp}\". If this is a media query, ensure it's defined in your hanzogui config.`);\n }\n pseudoCandidate = undefined;\n }\n return { name, pseudo: pseudoCandidate, media };\n}\n//# sourceMappingURL=getGroupPropParts.js.map","import { getSetting } from '../config.js';\nimport { mediaObjectToString } from './mediaObjectToString.js';\nimport { getGroupPropParts } from './getGroupPropParts.js';\n// TODO have this be used by extractMediaStyle in hanzogui static\n// not synced to static/constants for now\nexport const MEDIA_SEP = '_';\nlet prefixes = null;\nlet selectors = null;\n// call this when media config changes to reset cached prefixes/selectors\nexport function resetMediaStyleCache() {\n prefixes = null;\n selectors = null;\n}\nconst groupPseudoToPseudoCSSMap = {\n press: 'active',\n focusVisible: 'focus-visible',\n focusWithin: 'focus-within',\n};\nconst specificities = new Array(12)\n .fill(0)\n .map((_, i) => new Array(i).fill(':root').join(''));\nfunction getThemeOrGroupSelector(name, styleInner, isGroup, groupParts, isTheme = false, precedenceImportancePrefix = '') {\n const selectorStart = styleInner.lastIndexOf(':root') + 5;\n const selectorEnd = styleInner.lastIndexOf('{');\n const selector = styleInner.slice(selectorStart, selectorEnd);\n const precedenceSpace = getSetting('addThemeClassName') !== false && isTheme ? '' : ' ';\n const pseudoSelectorName = groupParts.pseudo\n ? groupPseudoToPseudoCSSMap[groupParts.pseudo] || groupParts.pseudo\n : undefined;\n const pseudoSelector = pseudoSelectorName ? `:${pseudoSelectorName}` : '';\n const presedencePrefix = `:root${precedenceImportancePrefix}${precedenceSpace}`;\n const mediaSelector = `.t_${isGroup ? 'group_' : ''}${name}${pseudoSelector}`;\n return [\n selector,\n `${presedencePrefix}${mediaSelector} ${selector.replaceAll(':root', '')}`,\n ];\n}\nexport const createMediaStyle = (styleObject, mediaKeyIn, mediaQueries, type, negate, priority) => {\n const [property, , identifier, pseudoIn, rules] = styleObject;\n const isTheme = type === 'theme';\n const isPlatform = type === 'platform';\n const isGroup = type === 'group';\n const isNonWindowMedia = isTheme || isPlatform || isGroup;\n const negKey = negate ? '0' : '';\n const ogPrefix = identifier.slice(0, identifier.indexOf('-') + 1);\n const id = `${ogPrefix}${MEDIA_SEP}${mediaKeyIn.replace('-', '')}${negKey}${MEDIA_SEP}`;\n let styleRule = '';\n let groupPriority = '';\n let groupMediaKey;\n let containerName;\n let nextIdentifier = identifier.replace(ogPrefix, id);\n let styleInner = rules\n .map((rule) => rule.replaceAll(identifier, nextIdentifier))\n .join(';');\n let isHover = false;\n if (isNonWindowMedia) {\n let specificity = (priority || 0) + (isGroup || isPlatform ? 1 : 0);\n if (isTheme || isGroup) {\n const groupParts = getGroupPropParts(isTheme ? 'theme-' + mediaKeyIn : mediaKeyIn);\n const { name, media, pseudo } = groupParts;\n groupMediaKey = media;\n if (isGroup) {\n containerName = name;\n }\n if (pseudo === 'press' || pseudoIn === 'active') {\n specificity += 2;\n }\n if (pseudo === 'hover') {\n isHover = true;\n }\n const [selector, nextSelector] = getThemeOrGroupSelector(name, styleInner, isGroup, groupParts, isTheme, specificities[specificity]);\n // const selectors = `${nextSelector}, :root${nextSelector}`\n // add back in the { we used to split\n styleRule = styleInner.replace(selector, nextSelector);\n }\n else {\n const prefix = specificities[specificity];\n // when styleInner is wrapped in @media (eg hover), inject specificity\n // inside the block — `:root@media ...` is invalid CSS\n styleRule =\n prefix && styleInner[0] === '@'\n ? styleInner.replace('{', `{${prefix}`)\n : `${prefix}${styleInner}`;\n }\n }\n if (!isNonWindowMedia || groupMediaKey) {\n // one time cost:\n // TODO MOVE THIS INTO SETUP AREA AND EXPORT IT\n if (!selectors) {\n const mediaKeys = Object.keys(mediaQueries);\n selectors = Object.fromEntries(mediaKeys.map((key) => [key, mediaObjectToString(mediaQueries[key])]));\n prefixes = Object.fromEntries(mediaKeys.map((k, index) => [k, new Array(index + 1).fill(':root').join('')]));\n }\n const mediaKey = groupMediaKey || mediaKeyIn;\n const mediaSelector = selectors[mediaKey];\n const screenStr = negate ? 'not all and ' : '';\n const mediaQuery = `${screenStr}${mediaSelector}`;\n const precedenceImportancePrefix = groupMediaKey ? groupPriority : prefixes[mediaKey];\n const prefix = groupMediaKey ? `@container ${containerName}` : '@media';\n if (groupMediaKey) {\n styleInner = styleRule;\n }\n // combines media queries if they already exist\n if (styleInner.includes(prefix)) {\n // combine\n styleRule = styleInner\n .replace('{', ` and ${mediaQuery} {`)\n // temp bugfix can be better done\n .replace(`and screen and`, `and`);\n }\n else {\n styleRule = `${prefix} ${mediaQuery}{${precedenceImportancePrefix}${styleInner}}`;\n }\n // add @supports for legacy browser support to not break container queries\n if (groupMediaKey) {\n styleRule = `@supports (contain: ${getSetting('webContainerType') || 'inline-size'}) {${styleRule}}`;\n }\n }\n if (isHover) {\n styleRule = `@media (hover:hover){${styleRule}}`;\n }\n return [property, undefined, nextIdentifier, undefined, [styleRule]];\n};\n//# sourceMappingURL=createMediaStyle.js.map","export const matchMedia = (typeof window !== 'undefined' && window.matchMedia) || matchMediaFallback;\nfunction matchMediaFallback(_) {\n return {\n match: (a, b) => false,\n addListener() { },\n removeListener() { },\n matches: false,\n };\n}\nexport function setupMatchMedia(_) {\n // no-op web\n}\n//# sourceMappingURL=matchMedia.js.map","import { isServer, isWeb } from '@hanzogui/constants';\nimport { useEffect, useReducer, useRef } from 'react';\nimport { getSetting } from '../config.js';\nimport { resetMediaStyleCache } from '../helpers/createMediaStyle.js';\nimport { matchMedia } from '../helpers/matchMedia.js';\nimport { mediaObjectToString } from '../helpers/mediaObjectToString.js';\nimport { getMedia, mediaKeys, mediaQueryConfig, setMediaState, } from '../helpers/mediaState.js';\nimport { defaultMediaImportance } from '../helpers/pseudoDescriptors.js';\nconst mediaKeyRegex = /\\$(platform|theme|group)-/;\nexport const isMediaKey = (key) => {\n if (key[0] !== '$')\n return false;\n if (mediaKeys.has(key))\n return true;\n if (mediaKeyRegex.test(key))\n return true;\n return false;\n};\nexport const getMediaKey = (key) => {\n if (key[0] !== '$')\n return false;\n if (mediaKeys.has(key))\n return true;\n const match = key.match(mediaKeyRegex);\n if (match)\n return match[1];\n return false;\n};\n// for SSR capture it at time of startup\nlet initState;\nlet mediaKeysOrdered;\nexport const getMediaKeyImportance = (key) => {\n if (process.env.NODE_ENV === 'development' && key[0] === '$') {\n throw new Error('use short key');\n }\n // + 100 because we set base usedKeys=1, pseudos are 2-N (however many we have)\n // all media go above all pseudos so we need to pad it based on that\n // right now theres 5 pseudos but in the future could be a few more\n return mediaKeysOrdered.indexOf(key) + 100;\n};\nconst dispose = new Set();\nlet mediaVersion = 0;\nexport const configureMedia = (config) => {\n const { media } = config;\n const mediaQueryDefaultActive = getSetting('mediaQueryDefaultActive');\n if (!media)\n return;\n mediaVersion++;\n // reset cached media style prefixes/selectors so they get recalculated with new key order\n resetMediaStyleCache();\n // touch-tracker getter object depends on the current media key set\n resetMediaTouchTracker();\n for (const key in media) {\n getMedia()[key] = mediaQueryDefaultActive?.[key] || false;\n mediaKeys.add(`$${key}`);\n }\n Object.assign(mediaQueryConfig, media);\n initState = { ...getMedia() };\n mediaKeysOrdered = Object.keys(media);\n setupMediaListeners();\n};\nfunction unlisten() {\n dispose.forEach((cb) => cb());\n dispose.clear();\n}\n/**\n * Note: This should *not* set the state on the first render!\n * Because to avoid hydration issues SSR must match the server\n * *and then* re-render with the actual media query state.\n */\nlet setupVersion = -1;\nexport function setupMediaListeners() {\n if (isWeb && isServer)\n return;\n if (process.env.IS_STATIC)\n return;\n // avoid setting up more than once per config\n if (setupVersion === mediaVersion)\n return;\n setupVersion = mediaVersion;\n // hmr, undo existing before re-binding\n unlisten();\n for (const key in mediaQueryConfig) {\n const str = mediaObjectToString(mediaQueryConfig[key]);\n const getMatch = () => matchMedia(str);\n const match = getMatch();\n if (!match) {\n throw new Error('⚠️ No match');\n }\n // react native needs these deprecated apis for now\n match.addListener(update);\n dispose.add(() => {\n match.removeListener(update);\n });\n function update() {\n const next = !!getMatch().matches;\n if (next === getMedia()[key])\n return;\n setMediaState({ ...getMedia(), [key]: next });\n updateMediaListeners();\n }\n update();\n }\n}\nconst listeners = new Set();\nexport function updateMediaListeners() {\n listeners.forEach((cb) => cb(getMedia()));\n}\nconst States = new WeakMap();\nlet touchTrackerProto = null;\nconst refSlot = Symbol('mediaRefSlot');\nfunction buildTouchTrackerProto() {\n const proto = {};\n for (const fullKey of mediaKeys) {\n const key = fullKey[0] === '$' ? fullKey.slice(1) : fullKey;\n proto[key] = {\n enumerable: true,\n configurable: true,\n get() {\n const slot = this[refSlot];\n if (!disableMediaTouch) {\n slot.keys.add(key);\n }\n return slot.proxyTarget[key];\n },\n };\n }\n return Object.create(null, proto);\n}\nfunction getTouchTrackerProto() {\n if (!touchTrackerProto)\n touchTrackerProto = buildTouchTrackerProto();\n return touchTrackerProto;\n}\nfunction resetMediaTouchTracker() {\n touchTrackerProto = null;\n}\nexport function setMediaShouldUpdate(ref, enabled, keys) {\n const cur = States.get(ref);\n if (!cur || cur.enabled !== enabled || keys) {\n States.set(ref, {\n ...cur,\n enabled,\n keys,\n });\n }\n}\nfunction subscribe(subscriber) {\n listeners.add(subscriber);\n return () => {\n listeners.delete(subscriber);\n };\n}\nexport function useMedia(componentContext, debug) {\n 'use no memo';\n const internalRef = useRef(null);\n if (!internalRef.current) {\n const initial = getMedia();\n const r = {\n keys: new Set(),\n lastState: initial,\n renderVersion: 0,\n proxyTarget: initial,\n proxy: undefined,\n getSnapshot: undefined,\n componentContext,\n debug,\n };\n // proxy → Object.create(getterProto) with a Symbol slot. Per-key get is a\n // monomorphic getter call (Hermes-fast) instead of a Proxy trap.\n const tracker = Object.create(getTouchTrackerProto());\n tracker[refSlot] = { proxyTarget: initial, keys: r.keys };\n r.proxy = tracker;\n r.getSnapshot = () => {\n const curKeys = r.componentContext\n ? States.get(r.componentContext)?.keys || r.keys\n : r.keys;\n const { lastState, pendingState } = r;\n if (!curKeys.size) {\n return lastState;\n }\n const ms = getMedia();\n for (const key of curKeys) {\n if (ms[key] !== (pendingState || lastState)[key]) {\n if (process.env.NODE_ENV === 'development' && r.debug) {\n console.warn(`useMedia() ✍️`, key, lastState[key], '=>', ms[key]);\n }\n // in emitter mode (no-rerender) avoid changing state, instead emit\n if (r.componentContext?.mediaEmit) {\n r.componentContext.mediaEmit(ms);\n r.pendingState = ms;\n return lastState;\n }\n r.lastState = ms;\n return ms;\n }\n }\n return lastState;\n };\n internalRef.current = r;\n }\n else {\n // refresh per-render inputs the closures read through the ref\n internalRef.current.componentContext = componentContext;\n internalRef.current.debug = debug;\n }\n const ref = internalRef.current;\n ref.renderVersion++;\n // reset on next render\n if (ref.pendingState) {\n ref.lastState = ref.pendingState;\n ref.pendingState = undefined;\n }\n // clear each render to track only rendered touched keys\n if (ref.keys.size) {\n ref.keys.clear();\n }\n // manual subscription (same shape as useThemeStateSubscribed): same\n // granular bailout via getSnapshot returning the same MediaQueryState ref\n // when none of the component's touched keys changed, but fewer\n // React-internal hook slots on Hermes than useSyncExternalStore.\n const [, forceUpdate] = useReducer(incReducer, 0);\n const state = isServer ? initState : ref.getSnapshot();\n ref.proxyTarget = state;\n ref.proxy[refSlot].proxyTarget = state;\n useEffect(() => {\n const renderVersion = ref.renderVersion;\n const shouldSubscribe = !ref.componentContext || !!States.get(ref.componentContext)?.enabled;\n if (shouldSubscribe) {\n if (!ref.unsubscribe) {\n ref.unsubscribe = subscribe(() => {\n const next = ref.getSnapshot();\n if (next !== ref.proxyTarget) {\n ref.proxyTarget = next;\n ref.proxy[refSlot].proxyTarget = next;\n forceUpdate();\n }\n });\n }\n }\n else if (ref.unsubscribe) {\n ref.unsubscribe();\n ref.unsubscribe = undefined;\n }\n return () => {\n // react runs passive cleanup before the next effect as well as on unmount.\n // a newer render bumps renderVersion before that cleanup, so equality here\n // means this is the final unmount cleanup.\n if (ref.renderVersion === renderVersion) {\n ref.unsubscribe?.();\n ref.unsubscribe = undefined;\n }\n };\n });\n return ref.proxy;\n}\nconst incReducer = (c) => c + 1;\n// PATCH (ours, carried across the transplant): initState is only assigned by\n// configureMedia, which returns early when the config carries no `media`. On a\n// server render neither has happened, so this handed undefined to\n// `new Proxy(state, …)` and every Gui Dialog — which runs useMedia when it\n// renders, open or closed — killed the whole prerender with \"Cannot create proxy\n// with a non-object as target or handler\". Degrade to the (empty) live media\n// state: queries read false on a server that has no viewport, which is the\n// truthful answer, and hydration corrects.\nconst getServerSnapshot = () => initState ?? getMedia();\nlet disableMediaTouch = false;\nexport function _disableMediaTouch(val) {\n disableMediaTouch = val;\n}\nexport function getMediaState(mediaGroups, layout) {\n disableMediaTouch = true;\n let res;\n try {\n res = Object.fromEntries([...mediaGroups].map((mediaKey) => {\n return [mediaKey, mediaKeyMatch(mediaKey, layout)];\n }));\n }\n finally {\n disableMediaTouch = false;\n }\n return res;\n}\nexport const getMediaImportanceIfMoreImportant = (mediaKey, key, styleState, isSizeMedia) => {\n const importance = isSizeMedia\n ? getMediaKeyImportance(mediaKey)\n : defaultMediaImportance;\n const usedKeys = styleState.usedKeys;\n return !usedKeys[key] || importance > usedKeys[key] ? importance : null;\n};\nconst cachedMediaKeyToQuery = {};\nexport function mediaKeyToQuery(key) {\n return (cachedMediaKeyToQuery[key] ||\n (cachedMediaKeyToQuery[key] = mediaObjectToString(mediaQueryConfig[key])));\n}\nexport function mediaKeyMatch(key, dimensions) {\n const mediaQueries = mediaQueryConfig[key];\n const result = Object.keys(mediaQueries).every((query) => {\n const expectedVal = +mediaQueries[query];\n const isMax = query.startsWith('max');\n const isWidth = query.endsWith('Width');\n const givenVal = dimensions[isWidth ? 'width' : 'height'];\n // if not max then min\n return isMax ? givenVal < expectedVal : givenVal > expectedVal;\n });\n return result;\n}\n//# sourceMappingURL=useMedia.js.map","const cache = new Map();\nlet cacheSize = 0;\nexport const simpleHash = (strIn, hashMin = 10) => {\n if (cache.has(strIn)) {\n return cache.get(strIn);\n }\n let str = strIn;\n // remove var()\n if (str[0] === 'v' && str.startsWith('var(')) {\n str = str.slice(6, str.length - 1);\n }\n let hash = 0;\n let valids = '';\n let added = 0;\n const len = str.length;\n for (let i = 0; i < len; i++) {\n if (hashMin !== 'strict' && added <= hashMin) {\n const char = str.charCodeAt(i);\n if (char === 46) {\n valids += '--';\n continue;\n }\n if (isValidCSSCharCode(char)) {\n added++;\n valids += str[i];\n continue;\n }\n }\n hash = hashChar(hash, str[i]);\n }\n const res = valids + (hash ? Math.abs(hash) : '');\n if (cacheSize > 10000) {\n cache.clear();\n cacheSize = 0;\n }\n cache.set(strIn, res);\n cacheSize++;\n return res;\n};\nconst hashChar = (hash, c) => (Math.imul(31, hash) + c.charCodeAt(0)) | 0;\nfunction isValidCSSCharCode(code) {\n return (\n // A-Z\n (code >= 65 && code <= 90) ||\n // a-z\n (code >= 97 && code <= 122) ||\n // _\n code === 95 ||\n // -\n code === 45 ||\n // 0-9\n (code >= 48 && code <= 57));\n}\n//# sourceMappingURL=index.js.map","export function composeEventHandlers(og, next, { checkDefaultPrevented = true } = {}) {\n if (!og || !next) {\n return next || og || undefined;\n }\n return (event) => {\n og?.(event);\n if (!event ||\n !(checkDefaultPrevented &&\n typeof event === 'object' &&\n 'defaultPrevented' in event) ||\n // @ts-ignore\n ('defaultPrevented' in event && !event.defaultPrevented)) {\n return next?.(event);\n }\n };\n}\n//# sourceMappingURL=composeEventHandlers.js.map","// Web-only style props that need to be skipped on native\n// NOTE: backgroundColor is NOT web-only - it works on React Native too!\n// NOTE: RN 0.76+ added: boxShadow, filter (cross-platform, with some Android 12+ only filters)\n// NOTE: RN 0.77+ added: boxSizing, mixBlendMode, isolation, outline* props\n// Track SIZES. A bare number here is a CSS length and must be given a unit:\n// `gridAutoRows={100}` means 100px, and `grid-auto-rows: 100` is a declaration\n// the browser drops for want of one.\nconst gridTracks = {\n gridAutoColumns: true,\n gridAutoRows: true,\n gridTemplateColumns: true,\n gridTemplateRows: true,\n};\n// The rest of grid, where a bare number is never a length. On the placement\n// properties it is a LINE — `gridRow={2}` is line 2, and `grid-row: 2px` is\n// nonsense — and the remainder take keywords or strings only.\nexport const gridUnitless = {\n grid: true,\n gridArea: true,\n gridAutoFlow: true,\n gridColumn: true,\n gridColumnEnd: true,\n gridColumnStart: true,\n gridRow: true,\n gridRowEnd: true,\n gridRowStart: true,\n gridTemplate: true,\n gridTemplateAreas: true,\n // grid's own alignment. alignContent/alignItems/alignSelf and justifyContent\n // are shared with flex and stay in the cross-platform table; these five have\n // no flex meaning at all.\n justifyItems: true,\n justifySelf: true,\n placeContent: true,\n placeItems: true,\n placeSelf: true,\n};\n// CSS grid, entire — and it CROSSES. This used to be the list of properties\n// stripped on native, on the grounds that Yoga's Display enum carried Flex,\n// None and Contents and nothing else, so every one of them would reach a layout\n// pass that could not read it.\n//\n// That is no longer the substrate. hanzoai/yoga carries a grid implementation:\n// `Display::Grid` is in the enum, `yoga/algorithm/grid/` is the algorithm, and\n// the JS bindings expose the track setters (setGridTemplateColumns and the\n// rest). So the properties reach an engine that reads them, and stripping them\n// would be throwing away a layout the platform can now do.\n//\n// Like every other capability note in this package (RN 0.76+ for boxShadow and\n// filter, 0.77+ for boxSizing and outline), this states a BUILD TARGET rather\n// than testing at runtime: a native app has to link that Yoga. Against stock\n// Yoga these properties are unknown and ignored, which is the same outcome\n// stripping them produced — so the floor does not move, only the ceiling.\nexport const gridProps = {\n ...gridTracks,\n ...gridUnitless,\n};\n// web-only discrete (non-animatable) view props.\n//\n// gridProps is NOT here any more — it is cross-platform now (see above), and an\n// entry in this table is dropped on native.\nexport const nonAnimatableWebViewProps = {\n backgroundAttachment: true,\n backgroundBlendMode: true,\n backgroundClip: true,\n backgroundOrigin: true,\n backgroundRepeat: true,\n borderBottomStyle: true,\n borderLeftStyle: true,\n borderRightStyle: true,\n borderTopStyle: true,\n contain: true,\n containerType: true,\n content: true,\n float: true,\n maskBorderMode: true,\n maskBorderRepeat: true,\n maskClip: true,\n maskComposite: true,\n maskMode: true,\n maskOrigin: true,\n maskRepeat: true,\n maskType: true,\n objectFit: true,\n overflowBlock: true,\n overflowInline: true,\n overflowX: true,\n overflowY: true,\n // NOTE: pointerEvents is NOT web-only - it's a core React Native View prop (not a style)\n pointerEvents: true,\n scrollbarWidth: true,\n textWrap: true,\n touchAction: true,\n transformStyle: true,\n willChange: true,\n};\n// web-only discrete (non-animatable) text props\nexport const nonAnimatableWebTextProps = {\n whiteSpace: true,\n wordWrap: true,\n textOverflow: true,\n WebkitBoxOrient: true,\n};\nexport const webOnlyStylePropsView = {\n ...nonAnimatableWebViewProps,\n transition: true,\n backdropFilter: true,\n WebkitBackdropFilter: true,\n background: true,\n borderTop: true,\n borderRight: true,\n borderBottom: true,\n borderLeft: true,\n backgroundPosition: true,\n backgroundSize: true,\n borderImage: true,\n caretColor: true,\n clipPath: true,\n mask: true,\n maskBorder: true,\n maskBorderOutset: true,\n maskBorderSlice: true,\n maskBorderSource: true,\n maskBorderWidth: true,\n maskImage: true,\n maskPosition: true,\n maskSize: true,\n objectPosition: true,\n textEmphasis: true,\n userSelect: true,\n};\nexport const webOnlyStylePropsText = {\n ...nonAnimatableWebTextProps,\n textDecorationDistance: true,\n // cursor: now cross-platform - in stylePropsView\n WebkitLineClamp: true,\n};\n//# sourceMappingURL=webOnlyStyleProps.js.map","import { isAndroid } from '@hanzogui/constants';\nimport { gridProps, gridUnitless, nonAnimatableWebTextProps, nonAnimatableWebViewProps, webOnlyStylePropsText, webOnlyStylePropsView, } from './webOnlyStyleProps.js';\n// generally organizing this so we don't duplicate things so its a bit weird\n// longhands of CSS shorthands - used for specificity boosting on web\n// so that e.g. borderWidth always beats border in the cascade\nexport const cssShorthandLonghands = {\n // border longhands\n borderWidth: true,\n borderStyle: true,\n borderColor: true,\n borderTopWidth: true,\n borderTopStyle: true,\n borderTopColor: true,\n borderRightWidth: true,\n borderRightStyle: true,\n borderRightColor: true,\n borderBottomWidth: true,\n borderBottomStyle: true,\n borderBottomColor: true,\n borderLeftWidth: true,\n borderLeftStyle: true,\n borderLeftColor: true,\n // outline longhands\n outlineWidth: true,\n outlineStyle: true,\n outlineColor: true,\n outlineOffset: true,\n};\nconst textColors = {\n color: true,\n textDecorationColor: true,\n textShadowColor: true,\n};\n// used for propMapping to find the right token category\n// just specificy the least costly, all else go to `space` (most keys - we can exclude)\nexport const tokenCategories = {\n radius: {\n borderRadius: true,\n borderTopLeftRadius: true,\n borderTopRightRadius: true,\n borderBottomLeftRadius: true,\n borderBottomRightRadius: true,\n // logical\n borderStartStartRadius: true,\n borderStartEndRadius: true,\n borderEndStartRadius: true,\n borderEndEndRadius: true,\n },\n size: {\n width: true,\n height: true,\n minWidth: true,\n minHeight: true,\n maxWidth: true,\n maxHeight: true,\n blockSize: true,\n minBlockSize: true,\n maxBlockSize: true,\n inlineSize: true,\n minInlineSize: true,\n maxInlineSize: true,\n },\n zIndex: {\n zIndex: true,\n },\n color: {\n backgroundColor: true,\n borderColor: true,\n borderBlockStartColor: true,\n borderBlockEndColor: true,\n borderBlockColor: true,\n borderBottomColor: true,\n borderInlineColor: true,\n borderInlineStartColor: true,\n borderInlineEndColor: true,\n borderTopColor: true,\n borderLeftColor: true,\n borderRightColor: true,\n borderEndColor: true,\n borderStartColor: true,\n shadowColor: true,\n ...textColors,\n // outlineColor is supported on RN 0.77+ (New Architecture)\n outlineColor: true,\n // caretColor is web-only\n ...(\"web\" === 'web' && {\n caretColor: true,\n }),\n },\n};\n// discrete (non-animatable) view style properties - keyword-based, no interpolation\n// defined above stylePropsView so it can be spread in without duplication\nconst nonAnimatableViewProps = {\n // Grid, on both targets. It sits in the CROSS-PLATFORM table because\n // hanzoai/yoga lays grid out natively — see the note in webOnlyStyleProps.ts.\n // This carries the track sizes as well as the keyword half; `gridUnitless`\n // is spread separately into stylePropsUnitless, which is the table that says\n // a bare number needs no px.\n ...gridProps,\n alignContent: true,\n alignItems: true,\n alignSelf: true,\n backfaceVisibility: true,\n borderCurve: true,\n borderStyle: true,\n borderBlockStyle: true,\n borderBlockEndStyle: true,\n borderBlockStartStyle: true,\n borderInlineStyle: true,\n borderInlineEndStyle: true,\n borderInlineStartStyle: true,\n boxSizing: true,\n cursor: true,\n direction: true,\n display: true,\n flexDirection: true,\n flexWrap: true,\n isolation: true,\n justifyContent: true,\n mixBlendMode: true,\n outlineStyle: true,\n overflow: true,\n position: true,\n};\n// discrete (non-animatable) font properties\nconst nonAnimatableFontProps = {\n fontFamily: true,\n fontStyle: true,\n fontVariant: true,\n textTransform: true,\n};\n// discrete (non-animatable) text-only properties\nconst nonAnimatableTextOnlyProps = {\n textAlign: true,\n textDecorationLine: true,\n textDecorationStyle: true,\n userSelect: true,\n};\n// discrete (non-animatable) unitless properties\nconst nonAnimatableUnitlessProps = {\n WebkitLineClamp: true,\n lineClamp: true,\n};\n// all non-animatable style props combined, used by getSplitStyles to keep\n// these as atomic CSS classNames even for components with animation drivers\nexport const nonAnimatableStyleProps = {\n ...nonAnimatableViewProps,\n ...nonAnimatableFontProps,\n ...nonAnimatableTextOnlyProps,\n ...nonAnimatableUnitlessProps,\n // web-only discrete properties (defined in webOnlyStyleProps.ts)\n ...(\"web\" === 'web' && {\n ...nonAnimatableWebViewProps,\n ...nonAnimatableWebTextProps,\n }),\n};\nexport const stylePropsUnitless = {\n ...nonAnimatableUnitlessProps,\n // Grid's unitless half, on BOTH targets: hanzoai/yoga lays grid out natively,\n // so these are no longer web-only (see webOnlyStyleProps.ts).\n //\n // The track SIZES are deliberately absent — they take lengths, so a bare\n // number on them needs px like any other length.\n ...gridUnitless,\n animationIterationCount: true,\n aspectRatio: true,\n borderImageOutset: true,\n borderImageSlice: true,\n borderImageWidth: true,\n columnCount: true,\n flex: true,\n flexGrow: true,\n flexOrder: true,\n flexPositive: true,\n flexShrink: true,\n flexNegative: true,\n fontWeight: true,\n opacity: true,\n order: true,\n orphans: true,\n tabSize: true,\n widows: true,\n zIndex: true,\n zoom: true,\n scale: true,\n scaleX: true,\n scaleY: true,\n scaleZ: true,\n shadowOpacity: true,\n};\nexport const stylePropsTransform = {\n x: true,\n y: true,\n scale: true,\n perspective: true,\n scaleX: true,\n scaleY: true,\n skewX: true,\n skewY: true,\n matrix: true,\n rotate: true,\n rotateY: true,\n rotateX: true,\n rotateZ: true,\n};\nexport const stylePropsView = {\n ...nonAnimatableViewProps,\n borderBottomEndRadius: true,\n borderBottomStartRadius: true,\n borderBottomWidth: true,\n borderLeftWidth: true,\n borderRightWidth: true,\n borderBlockWidth: true,\n borderBlockEndWidth: true,\n borderBlockStartWidth: true,\n borderInlineWidth: true,\n borderInlineEndWidth: true,\n borderInlineStartWidth: true,\n borderTopEndRadius: true,\n borderTopStartRadius: true,\n borderTopWidth: true,\n borderWidth: true,\n transform: true,\n transformOrigin: true,\n borderEndWidth: true,\n borderStartWidth: true,\n bottom: true,\n end: true,\n flexBasis: true,\n gap: true,\n columnGap: true,\n rowGap: true,\n left: true,\n margin: true,\n marginBlock: true,\n marginBlockEnd: true,\n marginBlockStart: true,\n marginInline: true,\n marginInlineStart: true,\n marginInlineEnd: true,\n marginBottom: true,\n marginEnd: true,\n marginHorizontal: true,\n marginLeft: true,\n marginRight: true,\n marginStart: true,\n marginTop: true,\n marginVertical: true,\n padding: true,\n paddingBottom: true,\n paddingInline: true,\n paddingBlock: true,\n paddingBlockStart: true,\n paddingInlineEnd: true,\n paddingInlineStart: true,\n paddingEnd: true,\n paddingHorizontal: true,\n paddingLeft: true,\n paddingRight: true,\n paddingStart: true,\n paddingTop: true,\n paddingVertical: true,\n right: true,\n start: true,\n top: true,\n inset: true,\n insetBlock: true,\n insetBlockEnd: true,\n insetBlockStart: true,\n insetInline: true,\n insetInlineEnd: true,\n insetInlineStart: true,\n shadowOffset: true,\n shadowRadius: true,\n ...tokenCategories.color,\n ...tokenCategories.radius,\n ...tokenCategories.size,\n ...stylePropsTransform,\n ...stylePropsUnitless,\n ...(isAndroid ? { elevationAndroid: true } : {}),\n boxShadow: true,\n border: true,\n filter: true,\n // RN 0.76+ supports linear-gradient via backgroundImage\n backgroundImage: true,\n // the actual RN 0.76+ prop name (backgroundImage expands to this on native)\n experimental_backgroundImage: true,\n // RN 0.76/0.77+ style props (New Architecture)\n outline: true,\n outlineColor: true,\n outlineOffset: true,\n outlineWidth: true,\n // web-only for convenience - tree-shaken on native\n ...(\"web\" === 'web' ? webOnlyStylePropsView : {}),\n};\nconst stylePropsFont = {\n ...nonAnimatableFontProps,\n fontSize: true,\n fontWeight: true,\n letterSpacing: true,\n lineHeight: true,\n};\nexport const stylePropsTextOnly = {\n ...stylePropsFont,\n ...nonAnimatableTextOnlyProps,\n ...textColors,\n textShadow: true,\n textShadowOffset: true,\n textShadowRadius: true,\n verticalAlign: true,\n // web-only text props - tree-shaken on native\n ...(\"web\" === 'web' ? webOnlyStylePropsText : {}),\n};\nexport const stylePropsText = {\n ...stylePropsView,\n ...stylePropsTextOnly,\n};\nexport const stylePropsAll = stylePropsText;\nexport const validPseudoKeys = {\n enterStyle: true,\n exitStyle: true,\n hoverStyle: true,\n pressStyle: true,\n focusStyle: true,\n disabledStyle: true,\n focusWithinStyle: true,\n // allow some web only ones\n ...(\"web\" === 'web' && {\n focusVisibleStyle: true,\n }),\n};\nexport const validStyles = stylePropsView;\n//# sourceMappingURL=validStyleProps.js.map","const Decorated = Symbol();\nexport const withStaticProperties = (component, staticProps) => {\n // add static properties\n Object.assign(component, staticProps);\n component[Decorated] = true;\n return component;\n};\n//# sourceMappingURL=withStaticProperties.js.map","import { isWeb } from '@hanzogui/constants';\nimport { simpleHash } from '@hanzogui/helpers';\nimport { getConfig } from './config.js';\n/**\n * Should rename this to Token\n * Moving to objects for React Server Components support\n */\nfunction constructCSSVariableName(name) {\n return `var(--${process.env.GUI_CSS_VARIABLE_PREFIX || ''}${name})`;\n}\nexport const createVariable = (props, skipHash = false) => {\n if (!skipHash && isVariable(props))\n return props;\n const { key, name, val } = props;\n return {\n isVar: true,\n key,\n name: skipHash ? name : simpleHash(name, 40),\n val,\n variable: isWeb\n ? skipHash\n ? constructCSSVariableName(name)\n : createCSSVariable(name)\n : '',\n };\n};\n// could do weakmap cache\nexport function variableToString(vrble, getValue = false) {\n if (isVariable(vrble)) {\n if (!getValue && isWeb && vrble.variable) {\n return vrble.variable;\n }\n return `${vrble.val}`;\n }\n return `${vrble || ''}`;\n}\nexport function isVariable(v) {\n return v && typeof v === 'object' && 'isVar' in v;\n}\nexport function getVariable(nameOrVariable, group = 'size') {\n // dynamic color-like\n if (nameOrVariable?.dynamic) {\n return nameOrVariable;\n }\n setDidGetVariableValue(true);\n if (isVariable(nameOrVariable)) {\n return variableToString(nameOrVariable);\n }\n const tokens = getConfig().tokensParsed;\n return variableToString(tokens[group]?.[nameOrVariable] ?? nameOrVariable);\n}\nlet accessed = false;\nexport const setDidGetVariableValue = (val) => (accessed = val);\nexport const didGetVariableValue = () => accessed;\nexport function getVariableValue(v, group) {\n if (isVariable(v)) {\n setDidGetVariableValue(true);\n return v.val;\n }\n if (group) {\n const tokens = getConfig().tokensParsed;\n const token = tokens[group]?.[v];\n if (token) {\n setDidGetVariableValue(true);\n return token.val;\n }\n }\n return v;\n}\nexport function getVariableName(v) {\n if (isVariable(v))\n return v.name;\n return v;\n}\nexport function getVariableVariable(v) {\n if (isVariable(v))\n return v.variable;\n return v;\n}\n// bugfix { space: { 0.5: 10 } } was generating var(--space-0.5) (invalid CSS):\nexport const createCSSVariable = (nameProp, includeVar = true) => {\n if (process.env.NODE_ENV === 'development') {\n if (!nameProp || typeof nameProp !== 'string') {\n throw new Error(`createCSSVariable expected string, got: ${nameProp}`);\n }\n }\n const name = simpleHash(nameProp, 60);\n return includeVar ? constructCSSVariableName(name) : name;\n};\n/**\n * Helper function to mark a token value as needing px units.\n * Usage: px(100) creates a token that will become \"100px\" on web, 100 on native.\n *\n * @param value - The numeric value\n * @returns A special object that indicates this value needs px units\n */\nexport function px(value) {\n return {\n val: value,\n needsPx: true,\n };\n}\n//# sourceMappingURL=createVariable.js.map","import { supportsDynamicColorIOS } from '@hanzogui/constants';\nimport { getConfig, getSetting } from '../config.js';\nimport { getVariable } from '../createVariable.js';\nimport { getDynamicVal } from '../helpers/getDynamicVal.js';\nimport { doesRootSchemeMatchSystem } from './doesRootSchemeMatchSystem.js';\n// only proxy each theme one time, after that we know that renders are sync,\n// so we can just change the focus of the proxied theme and it can be re-used\nconst cache = new Map();\nlet curKeys;\nlet curSchemeKeys;\nlet curProps;\nlet curState;\nconst emptyObject = {};\nexport function getThemeProxied(\n// underscore to prevent accidental usage below\n_props, _state, _keys, _schemeKeys) {\n if (!_state?.theme) {\n return emptyObject;\n }\n curKeys = _keys;\n curSchemeKeys = _schemeKeys;\n curProps = _props;\n curState = _state;\n if (cache.has(curState.theme)) {\n const proxied = cache.get(curState.theme);\n return proxied;\n }\n // first time running on this theme, create:\n // from here on only use current*\n const config = getConfig();\n function track(key, schemeOptimized = false) {\n if (!curKeys)\n return;\n if (!curKeys.current) {\n curKeys.current = new Set();\n }\n curKeys.current.add(key);\n // track scheme-optimized keys separately so we know if a scheme-only\n // change can skip re-render (when all accessed keys use DynamicColorIOS)\n if (schemeOptimized && curSchemeKeys) {\n if (!curSchemeKeys.current) {\n curSchemeKeys.current = new Set();\n }\n curSchemeKeys.current.add(key);\n }\n if (process.env.NODE_ENV === 'development' && curProps.debug) {\n console.info(` 🎨 useTheme() tracking key: ${key} schemeOptimized=${schemeOptimized}`);\n }\n }\n const proxied = Object.fromEntries(Object.entries(_state.theme).flatMap(([key, value]) => {\n const proxied = {\n ...value,\n get val() {\n // when they touch the actual value we only track it if its a variable (web), its ignored!\n if (!globalThis.hanzoguiAvoidTracking) {\n // always track .val - not scheme optimized since they're getting raw value\n track(key, false);\n }\n return value.val;\n },\n get(platform) {\n if (!curState)\n return;\n const outVal = getVariable(value);\n const { name, scheme } = curState;\n if (\"web\" === 'native') {\n // ios can avoid re-rendering for scheme changes (light↔dark) when using DynamicColorIOS.\n // DynamicColorIOS always resolves by the OS appearance, so this is only correct for a\n // subtree that follows the OS scheme. it does NOT work when a <Theme> forces a scheme\n // away from the OS/root — at any depth. `inverses` counts scheme flips from the root, so\n // `inverses === 0` is exactly \"this subtree still follows the OS\". isInverse alone was\n // wrong: a sub-theme keeping its parent's forced scheme (dark_blue under a forced dark,\n // light root) has isInverse=false yet must NOT optimize, or iOS would pick the OS-scheme\n // value (light) instead of the forced dark value.\n const fastSchemeChange = getSetting('fastSchemeChange');\n const rootMatchesSystem = doesRootSchemeMatchSystem();\n const shouldOptimize = scheme &&\n platform !== 'web' &&\n supportsDynamicColorIOS &&\n !curProps.deopt &&\n !curState.inverses &&\n fastSchemeChange &&\n rootMatchesSystem;\n if (process.env.NODE_ENV === 'development' && curProps.debug === 'verbose') {\n console.info(` 🎨 useTheme().get(${key}) theme=${name} scheme=${scheme}`, `\\n shouldOptimize=${shouldOptimize} (dynamicColorIOS=${supportsDynamicColorIOS} deopt=${curProps.deopt} inverses=${curState.inverses} fastScheme=${fastSchemeChange} rootMatch=${rootMatchesSystem})`);\n }\n if (shouldOptimize) {\n const oppositeScheme = scheme === 'dark' ? 'light' : 'dark';\n const oppositeName = name.replace(scheme, oppositeScheme);\n const color = getVariable(config.themes[name]?.[key]);\n const oppositeColor = getVariable(config.themes[oppositeName]?.[key]);\n if (process.env.NODE_ENV === 'development' &&\n curProps.debug === 'verbose') {\n console.info(` 🎨 useTheme().get(${key}) using DynamicColorIOS`, `\\n color=${color} oppositeColor=${oppositeColor}`);\n }\n const dynamicVal = getDynamicVal({\n scheme,\n val: color,\n oppositeVal: oppositeColor,\n });\n // track as scheme-optimized - can skip re-render for scheme-only changes\n track(key, true);\n return dynamicVal;\n }\n if (process.env.NODE_ENV === 'development' && curProps.debug) {\n console.info(` 🎨 useTheme().get(${key}) tracking key (not optimizing)`, `\\n platform=${platform} dynamicColorIOS=${supportsDynamicColorIOS} deopt=${curProps.deopt} fastScheme=${fastSchemeChange}`);\n }\n // not scheme-optimized\n track(key, false);\n }\n return outVal;\n },\n };\n return [\n [key, proxied],\n [`$${key}`, proxied],\n ];\n }));\n cache.set(_state.theme, proxied);\n return proxied;\n}\n//# sourceMappingURL=getThemeProxied.js.map","import { supportsDynamicColorIOS, useIsomorphicLayoutEffect } from '@hanzogui/constants';\nimport { createContext, useContext, useEffect, useId, useReducer, useRef, } from 'react';\nimport { getConfig, getSetting } from '../config.js';\nimport { MISSING_THEME_MESSAGE } from '../constants/constants.js';\nexport const ThemeStateContext = createContext('');\nconst allListeners = new Map();\nconst listenersByParent = {};\nconst HasRenderedOnce = new WeakMap();\nconst HadTheme = new WeakMap();\nconst PendingUpdate = new Map();\n// TODO this will gain memory over time but its not going to be a ton\nconst states = new Map();\nconst localStates = new Map();\nlet shouldForce = false;\nexport const forceUpdateThemes = () => {\n cacheVersion++;\n shouldForce = true;\n allListeners.forEach((cb) => cb());\n shouldForce = false;\n};\nexport const getThemeState = (id) => states.get(id);\nlet cacheVersion = 0;\n// cache for getNewThemeName - invalidated on cacheVersion change\nconst themeNameCache = new Map();\nlet themeNameCacheVer = -1;\nlet themes = null;\nlet rootThemeState = null;\nexport const getRootThemeState = () => rootThemeState;\n// extracts base name without scheme: \"light_red_surface1\" -> \"red_surface1\"\nconst getThemeBaseName = (name) => name.replace(/^(light|dark)_/, '');\n// useReducer-based force-update; cheaper than useSyncExternalStore's internal\n// useState+useLayoutEffect+useEffect+useDebugValue chain on Hermes.\nconst incReducer = (c) => c + 1;\nexport const useThemeState = (props, isRoot = false, keys, schemeKeys, \n// when true, install the propsKey-watching useIsomorphicLayoutEffect that\n// schedules descendant updates via listenersByParent[id]. Only <Theme>\n// providers actually push their themeState.id into ThemeStateContext, so\n// only they can have descendants subscribed under their id. Leaf styled\n// components pass false (the default) and save one hook slot per mount.\n// Stable per call-site (rule of hooks satisfied).\ncascadeOnChange = false) => {\n 'use no memo';\n const { disable } = props;\n const parentId = useContext(ThemeStateContext);\n if (!parentId && !isRoot) {\n throw new Error(process.env.NODE_ENV === 'development'\n ? `${MISSING_THEME_MESSAGE}\n\nLooked for theme${props.name ? ` \"${props.name}\"` : ''}${props.componentName ? ` (component: ${props.componentName})` : ''}, but no parent theme context was found (parentId: ${parentId}).`\n : MISSING_THEME_MESSAGE);\n }\n if (disable) {\n return (states.get(parentId) || {\n id: '',\n name: 'light',\n theme: getConfig().themes.light,\n // inverses: 0,\n });\n }\n // useId keeps theme-provider ids tied to the React tree. A process-wide\n // counter can let children observe a provider context id whose matching\n // states Map entry was never populated in multi-root/native surfaces.\n const id = useId();\n const propsKey = getPropsKey(props);\n // stable ref-bag for render inputs and the optional subscription cleanup.\n // lastSnap caches the last getSnapshot result for the subscription bailout.\n const ref = useRef(null);\n if (!ref.current) {\n ref.current = {\n id,\n parentId,\n props,\n propsKey,\n isRoot,\n keys,\n schemeKeys,\n renderVersion: 0,\n };\n }\n else {\n // refresh latest values for the stable closures to read\n ref.current.props = props;\n ref.current.propsKey = propsKey;\n ref.current.isRoot = isRoot;\n ref.current.keys = keys;\n ref.current.schemeKeys = schemeKeys;\n ref.current.parentId = parentId;\n }\n ref.current.renderVersion++;\n if (process.env.NODE_ENV === 'development' && globalThis.time)\n globalThis.time `theme-prep-uses`;\n // manual subscription replaces useSyncExternalStore: same granular bailout\n // (getSnapshot returning the same ref → React doesn't re-render), fewer\n // React-internal hook slots on Hermes. We don't need tearing prevention\n // here: theme/media updates are event-driven, not transition-driven, and\n // useReducer in normal mode already gives same-tick batching.\n const [, forceUpdate] = useReducer(incReducer, 0);\n const state = getSnapshotImpl(ref.current);\n ref.current.lastSnap = state;\n useEffect(() => {\n const r = ref.current;\n const renderVersion = r.renderVersion;\n // strict-mode dev double-invokes effects: cleanup runs between the two\n // invocations with no render in between, so the \"unchanged renderVersion\n // means unmount\" check below false-positives and deletes this component's\n // registered theme state mid-lifecycle. the registry is only re-populated\n // on this component's next render, so until then children resolve a\n // missing parent and fall back to the root theme state (isNew: true) —\n // which flips getThemedChildren to wrap and re-parents/remounts their\n // hosts, losing focus (keyboard dismiss on first Input tap). per react's\n // strict-mode contract, setup restores whatever cleanup tore down.\n if (r.lastSnap && !states.has(r.id)) {\n states.set(r.id, r.lastSnap);\n localStates.set(r.id, r.lastSnap);\n }\n if (r.unsubscribe && r.subscribedParentId !== r.parentId) {\n cleanupThemeSubscription(r);\n }\n if (shouldSubscribeToTheme(r, cascadeOnChange)) {\n if (!r.unsubscribe) {\n const pid = r.parentId;\n const sid = r.id;\n const cb = () => {\n const next = getSnapshotImpl(r);\n if (next !== r.lastSnap) {\n r.lastSnap = next;\n forceUpdate();\n }\n };\n listenersByParent[pid] = listenersByParent[pid] || new Set();\n listenersByParent[pid].add(sid);\n allListeners.set(sid, () => {\n PendingUpdate.set(sid, shouldForce ? 'force' : true);\n cb();\n });\n r.subscribedParentId = pid;\n r.unsubscribe = () => {\n allListeners.delete(sid);\n listenersByParent[pid]?.delete(sid);\n localStates.delete(sid);\n states.delete(sid);\n PendingUpdate.delete(sid);\n r.unsubscribe = undefined;\n r.subscribedParentId = undefined;\n };\n }\n }\n else if (r.unsubscribe) {\n cleanupThemeSubscription(r);\n }\n return () => {\n // react runs passive cleanup before the next effect as well as on unmount.\n // a newer render bumps renderVersion before that cleanup, so equality here\n // means this is the final unmount cleanup.\n if (r.renderVersion === renderVersion) {\n cleanupThemeState(r);\n }\n };\n });\n if (cascadeOnChange) {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n useIsomorphicLayoutEffect(() => {\n if (!HasRenderedOnce.get(keys)) {\n HasRenderedOnce.set(keys, true);\n return;\n }\n if (!propsKey) {\n if (HadTheme.get(keys)) {\n // we're removing the last theme, make sure to notify\n scheduleUpdate(id);\n }\n HadTheme.set(keys, false);\n return;\n }\n if (process.env.NODE_ENV === 'development' && props.debug === 'verbose') {\n console.warn(` · useTheme(${id}) scheduleUpdate`, propsKey, states.get(id)?.name);\n }\n scheduleUpdate(id);\n HadTheme.set(keys, true);\n }, [keys, propsKey]);\n }\n return state;\n};\nconst shouldSubscribeToTheme = (r, cascadeOnChange) => r.isRoot ||\n cascadeOnChange ||\n hasThemeUpdatingProps(r.props) ||\n !!r.keys.current?.size ||\n !!r.props.needsUpdate?.();\nfunction cleanupThemeSubscription(r) {\n r.unsubscribe?.();\n}\nfunction cleanupThemeState(r) {\n if (r.unsubscribe) {\n cleanupThemeSubscription(r);\n }\n else {\n localStates.delete(r.id);\n states.delete(r.id);\n PendingUpdate.delete(r.id);\n }\n}\nconst getSnapshotImpl = (r) => {\n const { id, parentId, props, propsKey, isRoot, keys, schemeKeys } = r;\n let local = localStates.get(id);\n const parentState = states.get(parentId);\n // fast path: nothing changed since last snapshot\n if (local && !PendingUpdate.has(id)) {\n if (parentState &&\n local._parentName === parentState.name &&\n local._propsKey === propsKey) {\n return local;\n }\n }\n // check if this is a scheme-only change (light↔dark) where DynamicColorIOS handles it\n const isSchemeOnlyChange = \"web\" === 'native' &&\n supportsDynamicColorIOS &&\n getSetting('fastSchemeChange') &&\n local &&\n parentState &&\n local.scheme !== parentState.scheme &&\n getThemeBaseName(local.name) === getThemeBaseName(parentState.name);\n // all tracked keys are scheme-optimized = can skip re-render for scheme changes\n const keysSize = keys?.current?.size ?? 0;\n const schemeKeysSize = schemeKeys?.current?.size ?? 0;\n const allKeysSchemeOptimized = schemeKeysSize === keysSize && keysSize > 0;\n const canSkipForSchemeChange = isSchemeOnlyChange && allKeysSchemeOptimized;\n const needsUpdate = props.passThrough\n ? false\n : isRoot || props.name === 'light' || props.name === 'dark' || props.name === null\n ? true\n : !HasRenderedOnce.get(keys)\n ? true\n : canSkipForSchemeChange\n ? false // skip re-render for scheme-only changes with DynamicColorIOS\n : keys?.current?.size\n ? true\n : props.needsUpdate?.();\n const [rerender, next] = getNextState(local, props, propsKey, isRoot, id, parentId, needsUpdate, PendingUpdate.get(id));\n PendingUpdate.delete(id);\n // we always create a new localState for every component\n // that way we can use it to de-opt and avoid renders granularly\n // we always return the localState object in each component\n // the global state (states) should always be up to date with the latest\n if (!local || rerender) {\n local = { ...next };\n localStates.set(id, local);\n }\n if (process.env.NODE_ENV === 'development' && props.debug === 'verbose') {\n console.groupCollapsed(` ${id} getSnapshot ${rerender}`, local.name, '>', next.name);\n console.info({\n props,\n propsKey,\n isRoot,\n parentId,\n local,\n next,\n needsUpdate,\n isSchemeOnlyChange,\n allKeysSchemeOptimized,\n canSkipForSchemeChange,\n });\n console.groupEnd();\n }\n if (next !== local) {\n Object.assign(local, next);\n local.id = id;\n }\n ;\n local._parentName = parentState?.name;\n local._propsKey = propsKey;\n states.set(id, next);\n return local;\n};\nconst getNextState = (lastState, props, propsKey, isRoot = false, id, parentId, needsUpdate, pendingUpdate) => {\n const { debug } = props;\n const parentState = states.get(parentId);\n if (props.passThrough) {\n return [false, lastState || parentState || { name: '' }];\n }\n if (!themes) {\n themes = getConfig().themes;\n }\n const name = !propsKey && (!lastState || !lastState?.isNew)\n ? null\n : getNewThemeName(parentState?.name, props, pendingUpdate === 'force' ? true : !!needsUpdate);\n const isSameAsParent = parentState && (!name || name === parentState.name);\n const shouldRerender = Boolean(pendingUpdate === 'force' ||\n (needsUpdate && (pendingUpdate || lastState?.name !== parentState?.name)));\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n const message = ` · useTheme(${id}) getNextState => ${name} needsUpdate ${needsUpdate} shouldRerender ${shouldRerender}`;\n if (\"web\" === 'native') {\n console.info(message);\n }\n else {\n console.groupCollapsed(message);\n console.trace({ name, lastState, parentState, props, propsKey, id, isSameAsParent });\n console.groupEnd();\n }\n }\n if (isSameAsParent) {\n if (!shouldRerender && lastState && lastState.name === parentState.name) {\n return [false, lastState];\n }\n return [shouldRerender, { ...parentState, isNew: false }];\n }\n if (!name) {\n // parentState can be transiently missing when a consumer renders in a\n // separate sync flush (a portal/Toast viewport, or a native multi-root\n // surface) before its provider has populated the module-level `states` map.\n // that's recoverable — the next render resolves it — so fall back to the\n // root theme (or a light stub) instead of throwing. the \"no parent context\"\n // throw above still catches a genuinely missing provider. going back to\n // useSyncExternalStore would avoid the race but force every themed node out\n // of concurrent rendering, so we keep the manual store and tolerate the\n // ordering here.\n const next = lastState ??\n parentState ??\n rootThemeState ?? {\n id,\n name: 'light',\n theme: getConfig().themes.light,\n };\n if (shouldRerender) {\n const updated = { ...(parentState || lastState || next) };\n return [true, updated];\n }\n return [false, next];\n }\n const scheme = getScheme(name);\n const parentInverses = parentState?.inverses ?? 0;\n const isInverse = parentState && scheme !== parentState.scheme;\n // cumulative from the root: once any level flips scheme, every descendant is\n // considered inverted vs the OS, even sub-themes that match their immediate\n // parent (dark_blue under dark). gates the DynamicColorIOS optimization below.\n const inverses = parentInverses + (isInverse ? 1 : 0);\n const nextState = {\n id,\n name,\n theme: themes[name],\n scheme,\n parentId,\n parentName: parentState?.name,\n inverses,\n isInverse,\n isNew: true,\n };\n if (isRoot) {\n rootThemeState = nextState;\n }\n if (pendingUpdate !== 'force' && lastState && lastState.name === name) {\n return [false, nextState];\n }\n const shouldAvoidRerender = pendingUpdate !== 'force' &&\n lastState &&\n !needsUpdate &&\n nextState.name === lastState.name;\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.groupCollapsed(` · useTheme(${id}) ⏭️ ${name} shouldAvoidRerender: ${shouldAvoidRerender}`);\n console.info({ lastState, needsUpdate, nextState, pendingUpdate });\n console.groupEnd();\n }\n // we still update the state (not changing identity), that way children can properly resolve the right state\n // but this one wont trigger an update\n if (shouldAvoidRerender) {\n return [false, nextState];\n }\n return [true, nextState];\n};\nfunction scheduleUpdate(id) {\n const queue = [id];\n const visited = new Set();\n while (queue.length) {\n const parent = queue.shift();\n const children = listenersByParent[parent];\n if (children) {\n for (const childId of children) {\n if (!visited.has(childId)) {\n visited.add(childId);\n queue.push(childId);\n }\n }\n }\n }\n visited.forEach((childId) => {\n const cb = allListeners.get(childId);\n cb?.();\n });\n}\nconst validSchemes = {\n light: 'light',\n dark: 'dark',\n};\nfunction getScheme(name) {\n return validSchemes[name.split('_')[0]];\n}\nfunction getNewThemeName(parentName = '', props, forceUpdate = false) {\n const { name, reset } = props;\n const componentName = props.unstyled ? undefined : props.componentName;\n if (name && reset) {\n throw new Error(process.env.NODE_ENV === 'production'\n ? `❌004`\n : 'Cannot reset and set a new name at the same time.');\n }\n // check cache\n const cacheKey = `${parentName}|${name || ''}|${componentName || ''}|${reset ? 1 : 0}|${forceUpdate ? 1 : 0}`;\n if (themeNameCacheVer !== cacheVersion) {\n themeNameCache.clear();\n themeNameCacheVer = cacheVersion;\n }\n else {\n const cached = themeNameCache.get(cacheKey);\n if (cached !== undefined)\n return cached;\n }\n const { themes } = getConfig();\n if (reset) {\n // For reset, we need to go back to the grandparent theme\n // If parentName is just a scheme (like \"dark\" or \"light\"),\n // we should return the opposite scheme or a default\n const isSchemeOnly = parentName === 'light' || parentName === 'dark';\n if (isSchemeOnly) {\n // If parent is just a scheme, go to the opposite scheme\n const result = parentName === 'light' ? 'dark' : 'light';\n themeNameCache.set(cacheKey, result);\n return result;\n }\n // For compound themes like \"dark_blue\", extract the scheme\n const lastPartIndex = parentName.lastIndexOf('_');\n // parentName will have format light_{name} or dark_{name}\n const name = lastPartIndex <= 0 ? parentName : parentName.slice(lastPartIndex);\n const scheme = parentName.slice(0, lastPartIndex);\n const result = themes[name] ? name : scheme;\n themeNameCache.set(cacheKey, result);\n return result;\n }\n const parentParts = parentName.split('_');\n // always remove component theme if it exists, we never sub a component theme\n const lastName = parentParts[parentParts.length - 1];\n if (lastName && lastName[0].toLowerCase() !== lastName[0]) {\n parentParts.pop();\n }\n const subNames = [\n name && componentName ? `${name}_${componentName}` : undefined,\n name,\n componentName,\n ].filter(Boolean);\n let found = null;\n // If name is provided, try it as a standalone theme first (both with and without scheme)\n // This allows explicit theme overrides like:\n // - <Theme name=\"blue\"><Button theme=\"dark_green\"> → finds \"dark_green_Button\"\n // - <Theme name=\"blue\"><Button theme=\"green\"> → finds \"light_green_Button\"\n // - <Theme name=\"blue\"><Button theme=\"green_active\"> → finds \"light_green_active_Button\"\n if (name) {\n // First try the exact name as-is, but only if it already has a scheme prefix\n // This prevents \"green\" from matching before we try \"light_green_Button\"\n const nameHasScheme = getScheme(name);\n if (nameHasScheme) {\n // Name has scheme (like \"dark_green\"), try as-is with priority to component theme\n for (const subName of subNames) {\n if (subName in themes) {\n found = subName;\n break;\n }\n }\n }\n // If not found and name doesn't have a scheme, try adding parent's scheme\n if (!found && !nameHasScheme) {\n const parentScheme = getScheme(parentName);\n if (parentScheme) {\n // Try progressively shorter parent bases to preserve color context\n // For parent \"light_blue_surface1\" + name \"surface3\":\n // Try: light_blue_surface1_surface3, light_blue_surface3, light_surface3\n // This ensures color context (blue) is preserved before falling back to scheme-only\n // Build list of potential bases from most specific to least specific\n const potentialBases = [];\n for (let i = parentParts.length; i >= 1; i--) {\n potentialBases.push(parentParts.slice(0, i).join('_'));\n }\n outer: for (const base of potentialBases) {\n // Try with componentName first, then without\n const candidates = [\n componentName ? `${base}_${name}_${componentName}` : undefined,\n `${base}_${name}`,\n ].filter(Boolean);\n for (const potential of candidates) {\n if (potential in themes) {\n found = potential;\n break outer;\n }\n }\n }\n }\n }\n }\n // If not found, fall back to the original search algorithm combining with parent\n if (!found) {\n // If we're only adding componentName (no explicit name prop), don't backtrack through parent parts\n // This preserves sub-themes like \"light_red_surface1\" when adding Button component\n if (!name && componentName) {\n // Just try adding component to full parent\n const potential = `${parentParts.join('_')}_${componentName}`;\n if (potential in themes) {\n found = potential;\n }\n // If not found, don't add component theme - return null to keep parent theme\n }\n else {\n // Original backtracking search for when explicit name is provided\n const max = parentParts.length;\n for (let i = 0; i <= max; i++) {\n const base = (i === 0 ? parentParts : parentParts.slice(0, -i)).join('_');\n for (const subName of subNames) {\n const potential = base ? `${base}_${subName}` : subName;\n if (potential in themes) {\n found = potential;\n break;\n }\n }\n if (found)\n break;\n }\n }\n }\n if (!forceUpdate &&\n found === parentName &&\n // if its a scheme only sub-theme, we always consider it \"new\" because it likely inverses\n // and we want to avoid reparenting\n !validSchemes[found]) {\n themeNameCache.set(cacheKey, null);\n return null;\n }\n themeNameCache.set(cacheKey, found);\n return found;\n}\nconst getPropsKey = ({ name, reset, forceClassName, componentName }) => `${name || ''}${reset || ''}${forceClassName || ''}${componentName || ''}`;\nexport const hasThemeUpdatingProps = (props) => 'name' in props || 'reset' in props || 'forceClassName' in props;\n//# sourceMappingURL=useThemeState.js.map","import { useRef } from 'react';\nimport { getThemeProxied } from './getThemeProxied.js';\nimport { useThemeState } from './useThemeState.js';\nconst EMPTY = {};\nexport const useTheme = () => {\n 'use no memo';\n const [theme] = useThemeWithState(EMPTY);\n const res = theme;\n return res;\n};\n/**\n * Adds a proxy around themeState that tracks update keys\n */\nexport const useThemeWithState = (props, isRoot = false, \n// <Theme> components push their themeState.id into ThemeStateContext,\n// so their descendants subscribe under this id; <Theme> needs to schedule\n// descendant updates when its propsKey changes. Leaf styled components\n// (createComponent, useProps, useTheme, animation hooks) do NOT push a\n// context — listenersByParent[componentId] is always empty — so the\n// schedule-update effect is a no-op for them and can be skipped to save\n// one hook slot per styled component on mount. Theme.tsx passes true.\nforThemeView = false) => {\n 'use no memo';\n // single useRef holding both keys + schemeKeys; saves one hook slot per\n // component vs separate useRef calls. these still look like MutableRefObject\n // to getThemeProxied which only reads/writes `.current`.\n const bag = useRef(null);\n if (!bag.current) {\n bag.current = {\n keys: { current: null },\n schemeKeys: { current: null },\n };\n }\n const { keys, schemeKeys } = bag.current;\n const themeState = useThemeState(props, isRoot, keys, schemeKeys, forThemeView);\n if (process.env.NODE_ENV === 'development') {\n if (!props.passThrough && !themeState?.theme) {\n if (process.env.GUI_DISABLE_NO_THEME_WARNING !== '1') {\n console.error(`[hanzogui] No theme found, this could be due to an invalid theme name (given theme props ${JSON.stringify(props)}).\\n\\nIf this is intended and you are using Gui without any themes, you can disable this warning by setting the environment variable GUI_DISABLE_NO_THEME_WARNING=1`);\n }\n }\n }\n const themeProxied = props.passThrough\n ? {}\n : getThemeProxied(props, themeState, keys, schemeKeys);\n return [themeProxied, themeState];\n};\n//# sourceMappingURL=useTheme.js.map","// from radix\n// https://raw.githubusercontent.com/radix-ui/primitives/main/packages/react/compose-refs/src/composeRefs.tsx\nimport * as React from 'react';\n/**\n * Set a given ref to a given value\n * This utility takes care of different types of refs: callback refs and RefObject(s)\n */\nexport function setRef(ref, value) {\n if (typeof ref === 'function') {\n ref(value);\n }\n else if (ref) {\n ;\n ref.current = value;\n }\n}\n/**\n * A utility to compose multiple refs together\n * Accepts callback refs and RefObject(s)\n */\nexport function composeRefs(...refs) {\n return (node) => refs.forEach((ref) => setRef(ref, node));\n}\n/**\n * A custom hook that composes multiple refs\n * Accepts callback refs and RefObject(s)\n */\nexport function useComposedRefs(...refs) {\n return React.useCallback(composeRefs(...refs), refs);\n}\n//# sourceMappingURL=compose-refs.js.map","export const defaultComponentState = {\n hover: false,\n press: false,\n pressIn: false,\n focus: false,\n focusVisible: false,\n focusWithin: false,\n unmounted: true,\n disabled: false,\n};\nexport const defaultComponentStateMounted = {\n ...defaultComponentState,\n unmounted: false,\n};\nexport const defaultComponentStateShouldEnter = {\n ...defaultComponentState,\n unmounted: 'should-enter',\n};\n//# sourceMappingURL=defaultComponentState.js.map","/**\n * Web event handling - maps RN-style events to DOM events\n */\nexport function getWebEvents(events, webStyle = true) {\n return {\n onMouseEnter: events.onMouseEnter,\n onMouseLeave: events.onMouseLeave,\n [webStyle ? 'onClick' : 'onPress']: events.onPress,\n onMouseDown: events.onPressIn,\n onMouseUp: events.onPressOut,\n onTouchStart: events.onPressIn,\n onTouchEnd: events.onPressOut,\n onFocus: events.onFocus,\n onBlur: events.onBlur,\n };\n}\n// web doesn't need wrapping - events go directly on element\nexport function wrapWithGestureDetector(content, _gesture, _stateRef, _isHOC, _isCompositeComponent, _hasRealPressEvents) {\n return content;\n}\n// no-op on web, events attached via getWebEvents\nexport function useEvents(_events, _viewProps, _stateRef, _staticConfig, _isHOC, _isInsideNativeMenu, _debugName, _hasRealPressEvents) {\n return null;\n}\n//# sourceMappingURL=eventHandling.js.map","import { getConfig } from '../config.js';\n// merge both default props, styled context props, and default text props\nexport const getDefaultProps = (staticConfig, propsComponentName) => {\n let defaultProps = staticConfig?.defaultProps;\n const conf = getConfig();\n const name = propsComponentName ||\n staticConfig?.componentName ||\n // important: this is how we end up getting the defaultProps we set in createGui\n (staticConfig.isText ? 'Text' : 'View');\n const userDefaultProps = conf?.defaultProps?.[name];\n if (userDefaultProps) {\n // component's staticConfig.defaultProps wins over global config defaults\n defaultProps = defaultProps\n ? { ...userDefaultProps, ...defaultProps }\n : userDefaultProps;\n }\n return defaultProps;\n};\n//# sourceMappingURL=getDefaultProps.js.map","/**\n * Resolves a value that might be an AnimationDriver or a multi-driver config object\n * like { default: motionDriver, css: cssDriver } into an actual AnimationDriver.\n */\nexport function resolveAnimationDriver(driver) {\n if (!driver)\n return null;\n // valid driver\n if (typeof driver.useAnimations === 'function') {\n return driver;\n }\n // multi-driver object - extract default\n if ('default' in driver &&\n typeof driver.default?.useAnimations === 'function') {\n return driver.default;\n }\n return null;\n}\n//# sourceMappingURL=resolveAnimationDriver.js.map","export const defaultOffset = { height: 0, width: 0 };\n//# sourceMappingURL=defaultOffset.js.map","import { defaultOffset } from './defaultOffset.js';\nexport function normalizeShadow({ shadowColor, shadowOffset, shadowOpacity, shadowRadius, }) {\n const { height, width } = shadowOffset || defaultOffset;\n return {\n shadowOffset: {\n width: width || 0,\n height: height || 0,\n },\n shadowRadius: shadowRadius || 0,\n // pass color through as-is, opacity applied via color-mix in getCSSStylesAtomic\n shadowColor: shadowColor,\n // default to 1 if not specified (color-mix will handle the opacity)\n shadowOpacity: shadowOpacity ?? 1,\n };\n}\n//# sourceMappingURL=normalizeShadow.js.map","import { isWeb } from '@hanzogui/constants';\nimport { normalizeShadow } from './normalizeShadow.js';\nexport function fixStyles(style) {\n var _a;\n if (\"web\" === 'web') {\n resolveAxis(style);\n }\n if (\"web\" === 'native') {\n if ('elevationAndroid' in style) {\n // @ts-ignore\n style['elevation'] = style.elevationAndroid;\n // @ts-ignore\n delete style.elevationAndroid;\n }\n }\n // TODO deprecate for web-style shadows\n if (style.shadowRadius != null ||\n style.shadowColor ||\n style.shadowOpacity != null ||\n style.shadowOffset) {\n Object.assign(style, normalizeShadow(style));\n }\n // could be optimized better\n // ensure border style set by default to solid\n for (const key in borderDefaults) {\n if (key in style) {\n style[_a = borderDefaults[key]] || (style[_a] = 'solid');\n }\n }\n}\n/**\n * A stack asked for grid is still a stack.\n *\n * flex-direction is inert under `display: grid`, so a component that names its\n * axis the flex way lays out along grid's default axis instead — which runs the\n * other way, because the two vocabularies invert: flex `row` runs across, grid\n * `row` fills rows and so runs down. An XStack asked for grid came out vertical.\n *\n * That is not an XStack problem. `flexDirection: 'row'` is a base style on\n * seven more components in pkgs/ui — Card, ListItem, RadioGroup, Button,\n * Fieldset, MenuPredefined, Tabs — and on every `styled(View, ...)` an author\n * writes, which is the pattern the docs teach. So the axis is restated here,\n * once, rather than in any component's variant table.\n *\n * Here is also the only place the REST of the style is visible, and that is\n * what makes the restatement safe to skip. Naming tracks or areas is the author\n * describing the grid themselves; forcing column flow on top would push items\n * into implicit tracks — `repeat(3, 1fr)` became six columns, three of them 7px\n * slivers — and transpose named areas into the right geometry with the wrong\n * items in it. Being visible to the whole style is also what makes it\n * order-independent: as a variant, `gridAutoFlow` before `display` and after it\n * gave different layouts.\n *\n * flexWrap bails out for the same reason and a blunter one: grid has no\n * equivalent, and column flow plus wrap does not wrap — it lays an eighth\n * 120px child 360px outside a 600px box. Leaving grid's own row flow gives a\n * single column, which is a degradation you can see rather than one off-screen.\n */\nfunction resolveAxis(style) {\n if (style.display !== 'grid' && style.display !== 'inline-grid')\n return;\n if (style.flexDirection !== 'row' && style.flexDirection !== 'row-reverse')\n return;\n if (style.flexWrap === 'wrap' || style.flexWrap === 'wrap-reverse')\n return;\n if (style.gridAutoFlow != null ||\n style.grid != null ||\n style.gridTemplate != null ||\n style.gridTemplateAreas != null ||\n style.gridTemplateColumns != null ||\n style.gridTemplateRows != null) {\n return;\n }\n style.gridAutoFlow = 'column';\n}\n// native doesn't support specific border edge style\nconst nativeStyle = isWeb ? null : 'borderStyle';\nconst borderDefaults = {\n borderWidth: 'borderStyle',\n borderBottomWidth: nativeStyle || 'borderBottomStyle',\n borderTopWidth: nativeStyle || 'borderTopStyle',\n borderLeftWidth: nativeStyle || 'borderLeftStyle',\n borderRightWidth: nativeStyle || 'borderRightStyle',\n // TODO: need to add borderBlock and borderInline here, but they are alot and might impact performance\n};\n//# sourceMappingURL=expandStyles.js.map","// web: use color-mix for opacity (CSS-native, works with variables and named colors)\n// animation drivers that need rgba handle their own conversion\nimport { normalizeCSSColor, rgba } from '@hanzogui/normalize-css-color';\nexport const normalizeColor = (color, opacity) => {\n if (!color)\n return;\n if (typeof color !== 'string')\n return color;\n if (color === 'transparent') {\n return 'rgba(0, 0, 0, 0)';\n }\n if (typeof opacity === 'number' && opacity < 1) {\n return `color-mix(in srgb, ${color} ${Math.round(opacity * 100)}%, transparent)`;\n }\n return color;\n};\nexport const getRgba = (color) => {\n if (typeof color !== 'string')\n return;\n const colorNum = normalizeCSSColor(color);\n if (colorNum != null) {\n return rgba(colorNum);\n }\n};\n//# sourceMappingURL=normalizeColor.js.map","/**\n * Some parts adapted from react-native-web\n * Copyright (c) Nicolas Gallagher licensed under the MIT license.\n */\nimport { isWeb } from '@hanzogui/constants';\nimport { stylePropsAll, stylePropsUnitless } from '@hanzogui/helpers';\n// only doing this on web on native it accepts pixel values\nconst stylePropsAllPlusTransforms = {\n ...stylePropsAll,\n translateX: true,\n translateY: true,\n};\nexport function normalizeValueWithProperty(value, property = '') {\n if (!isWeb)\n return value;\n if (stylePropsUnitless[property] ||\n (property && !stylePropsAllPlusTransforms[property]) ||\n typeof value === 'boolean') {\n return value;\n }\n if (value && typeof value === 'object') {\n if (typeof value.__getValue === 'function') {\n // resolve Animated.Value objects\n value = value.__getValue();\n }\n else {\n return value;\n }\n }\n let res = value;\n if (typeof value === 'number') {\n res = `${value}px`;\n }\n else if (property) {\n res = `${res}`;\n }\n return res;\n}\n//# sourceMappingURL=normalizeValueWithProperty.js.map","import { normalizeValueWithProperty } from './normalizeValueWithProperty.js';\nexport function transformsToString(transforms) {\n return transforms\n .map(\n // { scale: 2 } => 'scale(2)'\n // { translateX: 20 } => 'translateX(20px)'\n // { matrix: [1,2,3,4,5,6] } => 'matrix(1,2,3,4,5,6)'\n // { perspective: 1000 } => perspective(1000px)\n (transform) => {\n const type = Object.keys(transform)[0];\n const value = transform[type];\n if (type === 'matrix' || type === 'matrix3d') {\n return `${type}(${value.join(',')})`;\n }\n return `${type}(${normalizeValueWithProperty(value, type)})`;\n })\n .join(' ');\n}\n//# sourceMappingURL=transformsToString.js.map","/**\n * Some parts adapted from react-native-web\n * Copyright (c) Nicolas Gallagher licensed under the MIT license.\n */\nimport { cssShorthandLonghands, simpleHash } from '@hanzogui/helpers';\nimport { getConfigMaybe } from '../config.js';\nimport { isMediaKey } from '../hooks/useMedia.js';\nimport { defaultOffset } from './defaultOffset.js';\nimport { normalizeColor } from './normalizeColor.js';\nimport { normalizeValueWithProperty } from './normalizeValueWithProperty.js';\nimport { pseudoDescriptors } from './pseudoDescriptors.js';\nimport { transformsToString } from './transformsToString.js';\n// refactor this file away next...\nexport function getCSSStylesAtomic(style) {\n styleToCSS(style);\n const out = [];\n for (const key in style) {\n if (key === '$$css')\n continue;\n const val = style[key];\n if (key in pseudoDescriptors) {\n if (val) {\n out.push(...getStyleAtomic(val, pseudoDescriptors[key]));\n }\n }\n else if (isMediaKey(key)) {\n for (const subKey in val) {\n const so = getStyleObject(val, subKey);\n if (so) {\n so[0] = key; // set the property to be eg $platform-web so we can use it above\n out.push(so);\n }\n }\n }\n else {\n const so = getStyleObject(style, key);\n if (so) {\n out.push(so);\n }\n }\n }\n return out;\n}\nexport const getStyleAtomic = (style, pseudo) => {\n styleToCSS(style);\n const out = [];\n for (const key in style) {\n const so = getStyleObject(style, key, pseudo);\n if (so) {\n out.push(so);\n }\n }\n return out;\n};\nlet conf = null;\n// this could be cached for performance?\nconst getStyleObject = (style, key, pseudo) => {\n let val = style[key];\n if (val == null)\n return;\n // transform\n if (key === 'transform' && Array.isArray(style.transform)) {\n val = transformsToString(val);\n }\n const value = normalizeValueWithProperty(val, key);\n const hash = simpleHash(typeof value === 'string' ? value : `${value}`);\n const pseudoPrefix = pseudo ? `0${pseudo.name}-` : '';\n conf || (conf = getConfigMaybe());\n const shortProp = conf?.inverseShorthands[key] || key;\n let identifier = `_${shortProp}-${pseudoPrefix}${hash}`;\n if (key === 'pointerEvents' && !pseudo) {\n if (value === 'box-none')\n identifier = '_pe-boxnone';\n else if (value === 'box-only')\n identifier = '_pe-boxonly';\n }\n const rules = createAtomicRules(identifier, key, value, pseudo);\n return [\n // array for performance\n key,\n value,\n identifier,\n pseudo?.name,\n rules,\n ];\n};\nexport function styleToCSS(style) {\n // box-shadow\n const { shadowOffset, shadowRadius, shadowColor, shadowOpacity } = style;\n if (shadowRadius != null ||\n shadowColor ||\n shadowOffset != null ||\n shadowOpacity != null) {\n const offset = shadowOffset || defaultOffset;\n const width = normalizeValueWithProperty(offset.width);\n const height = normalizeValueWithProperty(offset.height);\n const radius = normalizeValueWithProperty(shadowRadius);\n const color = normalizeColor(shadowColor, shadowOpacity);\n if (color) {\n const shadow = `${width} ${height} ${radius} ${color}`;\n style.boxShadow = style.boxShadow ? `${style.boxShadow}, ${shadow}` : shadow;\n }\n delete style.shadowOffset;\n delete style.shadowRadius;\n delete style.shadowColor;\n delete style.shadowOpacity;\n }\n // text-shadow\n const { textShadowColor, textShadowOffset, textShadowRadius } = style;\n if (textShadowColor || textShadowOffset || textShadowRadius) {\n const { height, width } = textShadowOffset || defaultOffset;\n const radius = textShadowRadius || 0;\n const color = normalizeValueWithProperty(textShadowColor, 'textShadowColor');\n if (color && (height !== 0 || width !== 0 || radius !== 0)) {\n const blurRadius = normalizeValueWithProperty(radius);\n const offsetX = normalizeValueWithProperty(width);\n const offsetY = normalizeValueWithProperty(height);\n style.textShadow = `${offsetX} ${offsetY} ${blurRadius} ${color}`;\n }\n delete style.textShadowColor;\n delete style.textShadowOffset;\n delete style.textShadowRadius;\n }\n}\nfunction createDeclarationBlock(style, important = false) {\n let next = '';\n for (const [key, value] of style) {\n next += `${hyphenateStyleName(key)}:${value}${important ? ' !important' : ''};`;\n }\n return `{${next}}`;\n}\nconst hcache = {};\nconst toHyphenLower = (match) => `-${match.toLowerCase()}`;\nconst hyphenateStyleName = (key) => {\n if (key in hcache)\n return hcache[key];\n const val = key.replace(/[A-Z]/g, toHyphenLower);\n hcache[key] = val;\n return val;\n};\n// adding one more :root so we always override react native web styles :/\nconst selectorPriority = (() => {\n const res = {};\n for (const key in pseudoDescriptors) {\n const pseudo = pseudoDescriptors[key];\n res[pseudo.name] = `${[...Array(pseudo.priority)].map(() => ':root').join('')} `;\n }\n return res;\n})();\nfunction createAtomicRules(identifier, property, value, pseudo) {\n const pseudoIdPostfix = pseudo\n ? pseudo.name === 'disabled'\n ? `[aria-disabled]`\n : `:${pseudo.name}`\n : '';\n const pseudoSelector = pseudo?.selector;\n // longhands get .cls.cls for higher specificity over shorthands\n const cls = property in cssShorthandLonghands ? `.${identifier}.${identifier}` : `.${identifier}`;\n let selector = pseudo\n ? pseudoSelector\n ? `${pseudoSelector} ${cls}`\n : `${selectorPriority[pseudo.name]} ${cls}${pseudoIdPostfix}`\n : `:root ${cls}`;\n // enter style on css driver needs both:\n // .t_unmounted .selector\n // .selector.t_unmounted\n if (pseudoSelector === pseudoDescriptors.enterStyle.selector) {\n selector = `${selector}, .${identifier}${pseudoSelector}`;\n }\n const important = !!pseudo;\n let rules = [];\n // Handle non-standard properties and object values that require multiple\n // CSS rules to be created.\n switch (property) {\n // Equivalent to using '::placeholder'\n case 'placeholderTextColor': {\n const block = createDeclarationBlock([\n ['color', value],\n ['opacity', 1],\n ], important);\n rules.push(`${selector}::placeholder${block}`);\n break;\n }\n // all webkit prefixed rules\n case 'backgroundClip':\n case 'userSelect': {\n const propertyCapitalized = `${property[0].toUpperCase()}${property.slice(1)}`;\n const webkitProperty = `Webkit${propertyCapitalized}`;\n const block = createDeclarationBlock([\n [property, value],\n [webkitProperty, value],\n ], important);\n rules.push(`${selector}${block}`);\n break;\n }\n // Polyfill for additional 'pointer-events' values\n case 'pointerEvents': {\n let finalValue = value;\n if (value === 'auto' || value === 'box-only') {\n finalValue = 'auto';\n }\n else if (value === 'none' || value === 'box-none') {\n finalValue = 'none';\n }\n const block = createDeclarationBlock([['pointerEvents', finalValue]], true);\n rules.push(`${selector}${block}`);\n break;\n }\n default: {\n const block = createDeclarationBlock([[property, value]], important);\n rules.push(`${selector}${block}`);\n break;\n }\n }\n // hover styles need to be conditional\n // perhaps this can be generalized but for now lets just shortcut\n // and hardcode for hover styles, if we need to later we can\n // WEIRD SYNTAX, SEE:\n // https://stackoverflow.com/questions/40532204/media-query-for-devices-supporting-hover\n if (pseudo?.name === 'hover') {\n rules = rules.map((r) => `@media (hover) {${r}}`);\n }\n return rules;\n}\n//# sourceMappingURL=getCSSStylesAtomic.js.map","import { StyleObjectIdentifier, StyleObjectRules } from '@hanzogui/helpers';\nimport { createVariable } from '../createVariable.js';\n// only cache hanzogui styles\n// TODO merge totalSelectorsInserted and allSelectors?\nconst scannedCache = new WeakMap();\nconst totalSelectorsInserted = new Map();\nconst allSelectors = {};\nconst allRules = {};\nexport const getAllSelectors = () => allSelectors;\nexport const getAllRules = () => {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n // Sort by identifier to ensure deterministic CSS output order\n const sortedKeys = Object.keys(allRules).sort();\n return sortedKeys.map((key) => allRules[key]);\n }\n return [];\n};\n// once react 19 onyl supported we can remove most of this\n// gets existing ones (client side)\n// takes ~0.1ms for a fairly large page\n// used now for three things:\n// 1. debugging at dev time\n// 2. avoid duplicate insert styles at runtime\n// 3. used now for merging transforms atomically\n// multiple sheets could have the same ids so we have to count\nlet lastScannedSheets = null;\nexport function scanAllSheets(collectThemes = false, tokens) {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n if (process.env.NODE_ENV === 'test')\n return;\n if (\"web\" !== 'web')\n return;\n let themes;\n const sheets = document.styleSheets || [];\n const prev = lastScannedSheets;\n const current = new Set(sheets);\n for (const sheet of current) {\n if (sheet) {\n const out = updateSheetStyles(sheet, false, collectThemes, tokens);\n if (out) {\n themes = out;\n }\n }\n }\n lastScannedSheets = current;\n if (prev) {\n for (const sheet of prev) {\n if (sheet && !current.has(sheet)) {\n updateSheetStyles(sheet, true);\n }\n }\n }\n return themes;\n }\n}\nfunction trackInsertedStyle(id) {\n const next = (totalSelectorsInserted.get(id) || 0) + 1;\n totalSelectorsInserted.set(id, next);\n return next;\n}\nconst bailAfterEnv = process.env.GUI_BAIL_AFTER_SCANNING_X_CSS_RULES;\nconst bailAfter = bailAfterEnv ? +bailAfterEnv : 8000;\nfunction updateSheetStyles(sheet, remove = false, collectThemes = false, tokens) {\n // avoid errors on cross origin sheets\n // https://stackoverflow.com/questions/49993633/uncaught-domexception-failed-to-read-the-cssrules-property\n let rules;\n try {\n rules = sheet.cssRules;\n if (!rules) {\n return;\n }\n }\n catch {\n return;\n }\n const firstSelector = getGuiSelector(rules[0], collectThemes)?.[0];\n const lastSelector = getGuiSelector(rules[rules.length - 1], collectThemes)?.[0];\n const cacheKey = `${rules.length}${firstSelector}${lastSelector}`;\n const lastScanned = scannedCache.get(sheet);\n if (!remove) {\n // avoid re-scanning\n if (lastScanned === cacheKey) {\n return;\n }\n }\n const len = rules.length;\n let fails = 0;\n let dedupedThemes;\n // because end-users can add their own css like .t_dark { --something: #000 }\n // and this actually entirely breaks scanning, we need to ensure we can handle multiple\n // themes, so track that here. also, css processing utils could cause this too\n const nameToTheme = {};\n for (let i = 0; i < len; i++) {\n const rule = rules[i];\n if (!(rule instanceof CSSStyleRule))\n continue;\n const response = getGuiSelector(rule, collectThemes);\n if (response) {\n // reset to 0 on any success as eg every other theme scan we get empty\n fails = 0;\n }\n else {\n fails++;\n if (fails > bailAfter) {\n // conservatively bail out of non-hanzogui sheets\n return;\n }\n continue;\n }\n const [identifier, cssRule, isTheme] = response;\n if (isTheme) {\n const deduped = addThemesFromCSS(cssRule, tokens);\n if (deduped) {\n for (const name of deduped.names) {\n if (nameToTheme[name]) {\n Object.apply(nameToTheme[name], deduped.theme);\n deduped.names = deduped.names.filter((x) => x !== name);\n }\n else {\n nameToTheme[name] = deduped.theme;\n }\n }\n dedupedThemes || (dedupedThemes = []);\n dedupedThemes.push(deduped);\n }\n continue;\n }\n }\n scannedCache.set(sheet, cacheKey);\n return dedupedThemes;\n}\nlet colorVarToVal;\nlet rootComputedStyle = null;\nfunction addThemesFromCSS(cssStyleRule, tokens) {\n const selectors = cssStyleRule.selectorText.split(',');\n if (!selectors.length)\n return;\n if (tokens?.color && !colorVarToVal) {\n colorVarToVal = {};\n for (const key in tokens.color) {\n const token = tokens.color[key];\n if (token) {\n colorVarToVal[token.name] = token.val;\n }\n }\n }\n const rulesWithBraces = (cssStyleRule.cssText || '').slice(cssStyleRule.selectorText.length + 2, -1);\n const rules = rulesWithBraces.split(';');\n // get theme object parsed\n const values = {};\n // build values first\n for (const rule of rules) {\n const sepI = rule.indexOf(':');\n if (sepI === -1)\n continue;\n const varIndex = rule.indexOf('--');\n let key = rule.slice(varIndex === -1 ? 0 : varIndex + 2, sepI);\n if (process.env.GUI_CSS_VARIABLE_PREFIX) {\n key = key.replace(process.env.GUI_CSS_VARIABLE_PREFIX, '');\n }\n const val = rule.slice(sepI + 2);\n let value;\n if (val[0] === 'v' && val.startsWith('var(')) {\n // var()\n const varName = val.slice(6, -1);\n const tokenVal = colorVarToVal?.[varName];\n // either hydrate it from tokens directly or from computed style on body if no token\n if (tokenVal) {\n value = tokenVal;\n }\n else {\n rootComputedStyle || (rootComputedStyle = getComputedStyle(document.body));\n value = rootComputedStyle.getPropertyValue('--' + varName);\n }\n }\n else {\n value = val;\n }\n values[key] = createVariable({\n key,\n name: key,\n val: value,\n }, true);\n }\n const names = new Set();\n // loop selectors and build deduped\n for (const selector of selectors) {\n if (selector === ' .tm_xxt')\n continue;\n const lastThemeSelectorIndex = selector.lastIndexOf('.t_');\n const name = selector.slice(lastThemeSelectorIndex).slice(3);\n const [schemeChar] = selector[lastThemeSelectorIndex - 5];\n const scheme = schemeChar === 'd' ? 'dark' : schemeChar === 'i' ? 'light' : '';\n const themeName = scheme && scheme !== name ? `${scheme}_${name}` : name;\n if (!themeName || themeName === 'light_dark' || themeName === 'dark_light') {\n continue;\n }\n names.add(themeName);\n }\n return {\n names: [...names],\n theme: values,\n };\n}\nconst hanzoguiSelectorRegex = /\\.tm_xxt/;\nfunction getGuiSelector(rule, collectThemes = false) {\n if (rule instanceof CSSStyleRule) {\n const text = rule.selectorText;\n // only matches t_ starting selector chains\n if (text[0] === ':' && text[1] === 'r' && hanzoguiSelectorRegex.test(text)) {\n const id = getIdentifierFromGuiSelector(\n // next.js minifies it so its in front\n text.replace(hanzoguiSelectorRegex, ''));\n return collectThemes ? [id, rule, true] : [id, rule];\n }\n }\n else if (rule instanceof CSSMediaRule) {\n // hanzogui only ever inserts 1 rule per media\n if (rule.cssRules.length > 1)\n return;\n return getGuiSelector(rule.cssRules[0]);\n }\n}\nconst getIdentifierFromGuiSelector = (selector) => {\n const dotIndex = selector.indexOf(':');\n if (dotIndex > -1) {\n return selector.slice(7, dotIndex);\n }\n return selector.slice(7);\n};\nlet sheet = null;\nlet trackAllRules = true;\nexport function stopAccumulatingRules() {\n trackAllRules = false;\n}\nexport function updateRules(identifier, rules) {\n if (trackAllRules) {\n allRules[identifier] = rules.join(' ');\n }\n return true;\n}\nlet nonce = '';\nexport function setNonce(_) {\n nonce = _;\n}\nexport function insertStyleRules(rulesToInsert) {\n if (\"web\" !== 'web')\n return;\n if (!sheet && document.head) {\n const styleTag = document.createElement('style');\n styleTag.id = '_hanzogui-styles';\n if (nonce) {\n styleTag.nonce = nonce;\n }\n sheet = document.head.appendChild(styleTag).sheet;\n }\n if (!sheet)\n return;\n for (const key in rulesToInsert) {\n const styleObject = rulesToInsert[key];\n const identifier = styleObject[StyleObjectIdentifier];\n if (!shouldInsertStyleRules(identifier)) {\n continue;\n }\n const rules = styleObject[StyleObjectRules];\n allSelectors[identifier] = rules.join('\\n');\n trackInsertedStyle(identifier);\n updateRules(identifier, rules);\n try {\n for (const rule of rules) {\n sheet.insertRule(rule, sheet.cssRules.length);\n }\n }\n catch (err) {\n if (process.env.NODE_ENV === 'production') {\n console.error(`Error inserting style rule`, rules);\n }\n // in dev throw to show error clearly\n }\n }\n}\n// The way browser or next.js work you end up with CSS being removed *after* the new CSS loads for the upcoming page\n// this causes many bugs. We defaulted to \"2\" here for safety, meaning we sacrificed some performance\n// setting GUI_INSERT_SELECTOR_TRIES=1 will be faster so long as you are concatting your CSS together\nconst maxToInsert = process.env.GUI_INSERT_SELECTOR_TRIES\n ? +process.env.GUI_INSERT_SELECTOR_TRIES\n : 1;\nexport function shouldInsertStyleRules(identifier) {\n if (process.env.IS_STATIC === 'is_static') {\n return true;\n }\n const total = totalSelectorsInserted.get(identifier) || 0;\n if (process.env.NODE_ENV === 'development') {\n if (total > +(process.env.GUI_STYLE_INSERTION_WARNING_LIMIT || 10)) {\n console.warn(`Warning: inserting many CSS rules, you may be animating something and generating many CSS insertions, which can degrade performance. Instead, try using the \"disableClassName\" property on elements that change styles often. To disable this warning set GUI_STYLE_INSERTION_WARNING_LIMIT from 50000 to something higher`);\n }\n }\n // note we are being conservative allowing duplicates\n return total < maxToInsert;\n}\n//# sourceMappingURL=insertStyleRule.js.map","import { currentPlatform, isAndroid, isIos, isTV } from '@hanzogui/constants';\n/**\n * Returns the specificity bump for a platform media key so that more specific\n * platform selectors reliably override more general ones regardless of the order\n * props are declared.\n *\n * Cascade (low → high importance):\n * $platform-native / $platform-web → bump 0 (widest)\n * $platform-android / $platform-ios → bump 1 (OS-specific)\n * $platform-tv → bump 2 (TV subset of Android/iOS)\n * $platform-androidtv / $platform-tvos → bump 3 (most specific)\n *\n * @param mediaKeyShort - Platform media key without the leading '$' (e.g. 'platform-tv', 'platform-androidtv')\n */\nexport function getPlatformSpecificityBump(mediaKeyShort) {\n if (mediaKeyShort === 'platform-androidtv' || mediaKeyShort === 'platform-tvos')\n return 3;\n if (mediaKeyShort === 'platform-tv')\n return 2;\n if (mediaKeyShort === 'platform-android' || mediaKeyShort === 'platform-ios')\n return 1;\n return 0;\n}\nexport function isActivePlatform(key) {\n if (!key.startsWith('$platform')) {\n return true;\n }\n const platform = key.slice(10);\n return (\n // exact platform match (web, ios, android)\n platform === currentPlatform ||\n // native matches all non-web platforms (iOS, Android, tvOS, Android TV)\n (platform === 'native' && currentPlatform !== 'web') ||\n // GUI_TARGET fallback (web or native build target)\n platform === \"web\" ||\n // tv matches both Android TV and tvOS\n (platform === 'tv' && isTV) ||\n // androidtv matches Android TV specifically\n (platform === 'androidtv' && isAndroid && isTV) ||\n // tvos matches tvOS specifically\n (platform === 'tvos' && isIos && isTV));\n}\n//# sourceMappingURL=isActivePlatform.js.map","export function isActiveTheme(key, activeThemeName) {\n if (!key.startsWith('$theme-'))\n return;\n return key.slice(7).startsWith(activeThemeName);\n}\n//# sourceMappingURL=isActiveTheme.js.map","/**\n * Some parts adapted from react-native-web\n * Copyright (c) Nicolas Gallagher licensed under the MIT license.\n */\nimport { isAndroid, isWeb } from '@hanzogui/constants';\nimport { getStyleCompat } from '../config.js';\nimport { parseBorderShorthand } from './parseBorderShorthand.js';\nimport { parseOutlineShorthand } from './parseOutlineShorthand.js';\nconst neg1Flex = [\n ['flexGrow', 0],\n ['flexShrink', 1],\n ['flexBasis', 'auto'],\n];\nfunction expandFlex(value, compat) {\n if (typeof value === 'string') {\n return [['flex', value]];\n }\n if (typeof value !== 'number') {\n return;\n }\n if (value === -1) {\n return neg1Flex;\n }\n switch (compat) {\n case 'legacy':\n return [\n ['flexGrow', value],\n ['flexShrink', 1],\n ['flexBasis', 'auto'],\n ];\n case 'react-native':\n if (value > 0) {\n return [\n ['flexGrow', value],\n ['flexShrink', 0],\n ['flexBasis', 0],\n ];\n }\n if (value === 0) {\n return [\n ['flexGrow', 0],\n ['flexShrink', 0],\n ['flexBasis', 'auto'],\n ];\n }\n return [\n ['flexGrow', 0],\n ['flexShrink', -value],\n ['flexBasis', 'auto'],\n ];\n case 'web':\n if (value < 0) {\n return [['flex', value]];\n }\n return [\n ['flexGrow', value],\n ['flexShrink', 1],\n ['flexBasis', 0],\n ];\n }\n}\nexport function expandStyle(key, value, styleCompat = getStyleCompat()) {\n if (\"web\" === 'web') {\n if (key === 'flex') {\n return expandFlex(value, styleCompat);\n }\n switch (key) {\n case 'writingDirection': {\n return [['direction', value]];\n }\n // some safari-based browsers seem not to support without -webkit prefix\n case 'backdropFilter': {\n return [\n ['backdropFilter', value],\n ['WebkitBackdropFilter', value],\n ];\n }\n }\n }\n if (\"web\" === 'native') {\n if (isAndroid && key === 'elevationAndroid') {\n return [['elevation', value]];\n }\n // native-only value transforms\n switch (key) {\n case 'objectFit': {\n const resizeMode = resizeModeMap[value] || 'cover';\n return [['resizeMode', resizeMode]];\n }\n case 'verticalAlign': {\n return [['textAlignVertical', verticalAlignMap[value] || 'auto']];\n }\n case 'position': {\n // position: fixed|sticky -> absolute on native\n if (value === 'fixed' || value === 'sticky') {\n return [['position', 'absolute']];\n }\n return;\n }\n case 'display': {\n // `grid` CROSSES now. It used to be rewritten to flex here, because\n // Yoga's Display enum carried Flex, None and Contents and nothing else\n // — so a grid arriving on native could only be laid out by the flex\n // properties the element already had. That bought a one-dimensional\n // stack and lost everything else about the layout.\n //\n // hanzoai/yoga has `Display::Grid` and a grid algorithm under\n // yoga/algorithm/grid, so the value now reaches an engine that reads\n // it, and the track and placement properties travel with it — gridProps\n // moved to the cross-platform table in @hanzogui/helpers for the same\n // reason.\n //\n // `inline-grid` still folds to `grid`: native has no inline formatting\n // context for a box to participate in, so the inline half has nothing\n // to mean there, while the grid half now does.\n if (value === 'inline-grid') {\n return [['display', 'grid']];\n }\n // list-item crosses the same way and for the same reason: native has no\n // marker box, and a bare <li> there already laid out as a flex column.\n // Left untouched it warns in dev and lays out as flex regardless, so the\n // degradation is identical and only the warning would be new.\n if (value === 'list-item') {\n return [['display', 'flex']];\n }\n return;\n }\n case 'backgroundImage': {\n // RN 0.76+ uses experimental_backgroundImage\n // value may be a parsed array (from parseNativeStyle) or a plain string\n return [['experimental_backgroundImage', value]];\n }\n case 'border': {\n // parse border shorthand string to individual properties\n // on native, only supports a single border (all sides)\n if (typeof value === 'string') {\n const parsed = parseBorderShorthand(value);\n if (parsed) {\n return parsed;\n }\n }\n return;\n }\n case 'outline': {\n if (typeof value === 'string') {\n const parsed = parseOutlineShorthand(value);\n if (parsed) {\n return parsed;\n }\n }\n return;\n }\n }\n // native-only logical expansions (RTL-aware inline props output RN-style\n // names like marginStart/borderEndColor that aren't valid CSS on web)\n if (key in nativeInlineExpansions) {\n return nativeInlineExpansions[key].map((k) => [k, value]);\n }\n }\n // universal logical expansions — applied on both targets so atomic CSS\n // generates one class per longhand. Otherwise `inset: 0` becomes a single\n // `_inset-0px` class controlling four sub-properties, which silently breaks\n // dedup/override against `top`/`left`/etc.\n if (key in universalExpansions) {\n return universalExpansions[key].map((k) => [k, value]);\n }\n if (key in EXPANSIONS) {\n return EXPANSIONS[key].map((k) => [k, value]);\n }\n}\n// native value transforms\nconst resizeModeMap = {\n fill: 'stretch',\n none: 'center',\n 'scale-down': 'contain',\n contain: 'contain',\n cover: 'cover',\n};\nconst verticalAlignMap = {\n top: 'top',\n middle: 'center',\n bottom: 'bottom',\n auto: 'auto',\n};\n// shared expansions\nconst all = ['Top', 'Right', 'Bottom', 'Left'];\nconst horiz = ['Right', 'Left'];\nconst vert = ['Top', 'Bottom'];\nconst xy = ['X', 'Y'];\nconst EXPANSIONS = {\n borderColor: ['TopColor', 'RightColor', 'BottomColor', 'LeftColor'],\n borderRadius: [\n 'TopLeftRadius',\n 'TopRightRadius',\n 'BottomRightRadius',\n 'BottomLeftRadius',\n ],\n borderWidth: ['TopWidth', 'RightWidth', 'BottomWidth', 'LeftWidth'],\n margin: all,\n marginHorizontal: horiz,\n marginVertical: vert,\n padding: all,\n paddingHorizontal: horiz,\n paddingVertical: vert,\n ...(isWeb && {\n // react-native only supports borderStyle\n borderStyle: ['TopStyle', 'RightStyle', 'BottomStyle', 'LeftStyle'],\n // react-native doesn't support X / Y\n overflow: xy,\n overscrollBehavior: xy,\n }),\n};\nfor (const parent in EXPANSIONS) {\n const prefix = parent.slice(0, /[A-Z]/.exec(parent)?.index ?? parent.length);\n EXPANSIONS[parent] = EXPANSIONS[parent].map((k) => `${prefix}${k}`);\n}\n// Logical expansions whose targets are physical longhands valid on both\n// targets. Applied unconditionally so atomic CSS stays one-class-per-longhand:\n// without this, `inset: 0` emits `_inset-0px` (one class, four sub-properties)\n// and silently breaks dedup/override against `top`/`left`/etc.\nconst universalExpansions = {\n // inset\n inset: ['top', 'right', 'bottom', 'left'],\n insetBlock: ['top', 'bottom'],\n insetBlockStart: ['top'],\n insetBlockEnd: ['bottom'],\n // block-axis margin/padding\n marginBlock: ['marginTop', 'marginBottom'],\n marginBlockStart: ['marginTop'],\n marginBlockEnd: ['marginBottom'],\n paddingBlock: ['paddingTop', 'paddingBottom'],\n paddingBlockStart: ['paddingTop'],\n paddingBlockEnd: ['paddingBottom'],\n // block-axis border\n borderBlockColor: ['borderTopColor', 'borderBottomColor'],\n borderBlockWidth: ['borderTopWidth', 'borderBottomWidth'],\n borderBlockStyle: ['borderTopStyle', 'borderBottomStyle'],\n borderBlockStartColor: ['borderTopColor'],\n borderBlockEndColor: ['borderBottomColor'],\n borderBlockStartWidth: ['borderTopWidth'],\n borderBlockEndWidth: ['borderBottomWidth'],\n borderBlockStartStyle: ['borderTopStyle'],\n borderBlockEndStyle: ['borderBottomStyle'],\n // logical sizing → physical width/height\n minBlockSize: ['minHeight'],\n maxBlockSize: ['maxHeight'],\n minInlineSize: ['minWidth'],\n maxInlineSize: ['maxWidth'],\n blockSize: ['height'],\n inlineSize: ['width'],\n};\n// Inline-axis logical expansions are native-only: their targets are RN-style\n// RTL-aware names (marginStart/borderEndColor/etc.) which web's CSS hyphenator\n// would emit as invalid CSS. On web these props pass through as native CSS\n// logical properties, which the browser handles RTL-aware.\nconst nativeInlineExpansions = {\n borderInlineColor: ['borderEndColor', 'borderStartColor'],\n borderInlineWidth: ['borderEndWidth', 'borderStartWidth'],\n borderInlineStyle: ['borderEndStyle', 'borderStartStyle'],\n borderInlineStartColor: ['borderStartColor'],\n borderInlineEndColor: ['borderEndColor'],\n borderInlineStartWidth: ['borderStartWidth'],\n borderInlineEndWidth: ['borderEndWidth'],\n borderInlineStartStyle: ['borderStartStyle'],\n borderInlineEndStyle: ['borderEndStyle'],\n marginInline: ['marginEnd', 'marginStart'],\n marginInlineStart: ['marginStart'],\n marginInlineEnd: ['marginEnd'],\n paddingInline: ['paddingEnd', 'paddingStart'],\n paddingInlineStart: ['paddingStart'],\n paddingInlineEnd: ['paddingEnd'],\n insetInlineStart: ['left'],\n insetInlineEnd: ['right'],\n};\n//# sourceMappingURL=expandStyle.js.map","import { getSetting } from '../config.js';\nimport { getVariableValue } from '../createVariable.js';\nconst cache = new WeakMap();\nexport const getVariantExtras = (styleState) => {\n const cached = cache.get(styleState);\n if (cached?.props === styleState.props) {\n return cached.value;\n }\n const { props, conf, context, theme, styleProps } = styleState;\n const styledContext = styleProps.styledContext;\n let fonts = conf.fontsParsed;\n if (context?.language) {\n fonts = getFontsForLanguage(conf.fontsParsed, context.language);\n }\n const next = {\n fonts,\n tokens: conf.tokensParsed,\n theme,\n context: styledContext,\n get fontFamily() {\n return (getVariableValue(styleState.fontFamily || styleState.props.fontFamily) ||\n props.fontFamily ||\n getVariableValue(getSetting('defaultFont')));\n },\n get font() {\n return (fonts[this.fontFamily] ||\n (!props.fontFamily || props.fontFamily[0] === '$'\n ? fonts[getSetting('defaultFont') || '']\n : undefined));\n },\n props,\n };\n cache.set(styleState, { props, value: next });\n return next;\n};\nconst fontLanguageCache = new WeakMap();\nexport function getFontsForLanguage(fonts, language) {\n if (fontLanguageCache.has(language)) {\n return fontLanguageCache.get(language);\n }\n const next = {\n ...fonts,\n ...Object.fromEntries(Object.entries(language).flatMap(([name, lang]) => {\n if (lang === 'default') {\n return [];\n }\n const langKey = `$${name}_${lang}`;\n return [[`$${name}`, fonts[langKey]]];\n })),\n };\n fontLanguageCache.set(language, next);\n return next;\n}\n//# sourceMappingURL=getVariantExtras.js.map","import { tokenCategories } from '@hanzogui/helpers';\nimport { getConfig } from '../config.js';\nimport { isVariable } from '../createVariable.js';\nimport { getFontsForLanguage } from './getVariantExtras.js';\nimport { normalizeColor } from './normalizeColor.js';\nconst fontShorthand = {\n fontSize: 'size',\n fontWeight: 'weight',\n};\nlet didLogMissingToken = false;\nconst colorKeys = tokenCategories.color;\n// flat reverse-lookup: tokenCategoryByKey[propName] → category name.\n// replaces an O(categories) for-in scan at the hot path below that\n// iterates every category on every `$token` prop resolve. a sootsim\n// scroll profile of Uniswap spent material worker CPU walking five\n// categories per prop per render — one `key in tokenCategoryByKey`\n// lookup collapses that to O(1). tokenCategories is module-constant so\n// it's safe to flatten once at module init.\nconst tokenCategoryByKey = {};\nfor (const _cat in tokenCategories) {\n for (const _k in tokenCategories[_cat]) {\n tokenCategoryByKey[_k] = _cat;\n }\n}\n// mutable state for font family tracking across propMapper\nlet _lastFontFamilyToken = null;\nexport function getLastFontFamilyToken() {\n return _lastFontFamilyToken;\n}\nexport function setLastFontFamilyToken(value) {\n _lastFontFamilyToken = value;\n}\nexport const getTokenForKey = (key, value, styleProps, styleState) => {\n let resolveAs = styleProps.resolveValues || 'none';\n if (resolveAs === 'none') {\n return value;\n }\n // parse opacity modifier: $token/50 → base token + 50% opacity\n // only for color-related style properties\n let opacityModifier;\n if (key in colorKeys) {\n const slashIdx = value.indexOf('/');\n if (slashIdx > 0) {\n const raw = value.slice(slashIdx + 1);\n // reject empty string after slash ($color/) to avoid Number(\"\") === 0\n if (raw.length > 0) {\n const num = Number(raw);\n if (!Number.isNaN(num)) {\n opacityModifier = Math.max(0, Math.min(1, num / 100));\n value = value.slice(0, slashIdx);\n }\n }\n }\n }\n const { theme, conf = getConfig(), context, fontFamily, staticConfig } = styleState;\n const themeValue = theme ? theme[value] || theme[value.slice(1)] : undefined;\n const tokensParsed = conf.tokensParsed;\n let valOrVar;\n let hasSet = false;\n const customTokenAccept = staticConfig?.accept?.[key];\n if (customTokenAccept) {\n const val = themeValue ?? tokensParsed[customTokenAccept]?.[value];\n if (val != null) {\n resolveAs = 'value'; // always resolve custom tokens as values\n valOrVar = val;\n hasSet = true;\n }\n }\n if (themeValue) {\n if (resolveAs === 'except-theme') {\n return value;\n }\n valOrVar = themeValue;\n if (process.env.NODE_ENV === 'development' && styleState.debug === 'verbose') {\n globalThis.hanzoguiAvoidTracking = true;\n console.info(` - resolving ${key} to theme value ${value} resolveAs ${resolveAs}`, valOrVar);\n globalThis.hanzoguiAvoidTracking = false;\n }\n hasSet = true;\n }\n else {\n if (value in conf.specificTokens) {\n hasSet = true;\n valOrVar = conf.specificTokens[value];\n }\n else {\n switch (key) {\n case 'fontFamily': {\n const fontsParsed = context?.language\n ? getFontsForLanguage(conf.fontsParsed, context.language)\n : conf.fontsParsed;\n valOrVar = fontsParsed[value]?.family || value;\n setLastFontFamilyToken(value);\n hasSet = true;\n break;\n }\n case 'fontSize':\n case 'lineHeight':\n case 'letterSpacing':\n case 'fontWeight': {\n const fam = fontFamily || conf.defaultFontToken;\n if (fam) {\n const fontsParsed = context?.language\n ? getFontsForLanguage(conf.fontsParsed, context.language)\n : conf.fontsParsed;\n const font = fontsParsed[fam] || fontsParsed[conf.defaultFontToken];\n valOrVar = font?.[fontShorthand[key] || key]?.[value] || value;\n hasSet = true;\n }\n break;\n }\n }\n const cat = tokenCategoryByKey[key];\n if (cat !== undefined) {\n const res = tokensParsed[cat]?.[value];\n if (res != null) {\n valOrVar = res;\n hasSet = true;\n }\n else {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.GUI_DISABLE_MISSING_TOKEN_LOG !== '1') {\n if (!didLogMissingToken) {\n didLogMissingToken = true;\n console.groupCollapsed(`[hanzogui] Warning: missing token ${key} in category ${cat} - ${value} (open for details)`);\n console.info(`Note: this could just be due to you not setting all the theme tokens Gui expects, which is harmless, but\n it also often can be because you have a duplicated Gui in your bundle, which can cause tricky bugs.`);\n console.info(`To see if you have duplicated dependencies, in Chrome DevTools hit CMD+P and type GuiProvider.\n If you see both a .cjs and a .mjs entry, it's duplicated.`);\n console.info(`You can debug that issue by opening the .mjs and .cjs files and setting a breakpoint at the top of each.`);\n console.info(`We only log this warning one time as it's sometimes harmless, to disable this log entirely set process.env.GUI_DISABLE_MISSING_TOKEN_LOG=1.`);\n console.groupEnd();\n }\n }\n }\n }\n }\n }\n if (!hasSet) {\n const spaceVar = tokensParsed.space[value];\n if (spaceVar != null) {\n valOrVar = spaceVar;\n hasSet = true;\n }\n }\n }\n if (hasSet) {\n let out = resolveVariableValue(key, valOrVar, resolveAs);\n // apply opacity modifier via color-mix (web) or rgba (native)\n if (opacityModifier !== undefined && opacityModifier < 1) {\n out = normalizeColor(String(out), opacityModifier) ?? out;\n }\n if (process.env.NODE_ENV === 'development' && styleState.debug === 'verbose') {\n globalThis.hanzoguiAvoidTracking = true;\n console.info(`resolved`, resolveAs, valOrVar, out);\n globalThis.hanzoguiAvoidTracking = false;\n }\n return out;\n }\n // they didn't define this token don't return anything, we could warn?\n if (process.env.NODE_ENV === 'development' && styleState.debug === 'verbose') {\n console.warn(`Warning: no token found for ${key}, omitting`);\n }\n};\nexport function resolveVariableValue(key, valOrVar, resolveValues) {\n if (resolveValues === 'none') {\n return valOrVar;\n }\n if (isVariable(valOrVar)) {\n if (resolveValues === 'value') {\n return valOrVar.val;\n }\n // @ts-expect-error this is fine until we can type better\n const get = valOrVar?.get;\n // shadowColor doesn't support dynamic style\n if (\"web\" !== 'native' || key !== 'shadowColor') {\n if (typeof get === 'function') {\n const resolveDynamicFor = resolveValues === 'web' ? 'web' : undefined;\n return get(resolveDynamicFor);\n }\n }\n return \"web\" === 'native' ? valOrVar.val : valOrVar.variable;\n }\n return valOrVar;\n}\n//# sourceMappingURL=getTokenForKey.js.map","export const isObj = (x) => x && !Array.isArray(x) && typeof x === 'object';\n//# sourceMappingURL=isObj.js.map","// stores raw style values before token and unit normalization\nexport const styleOriginalValues = new WeakMap();\n//# sourceMappingURL=styleOriginalValues.js.map","import { expandStyle } from './expandStyle.js';\nimport { fixStyles } from './expandStyles.js';\nimport { isObj } from './isObj.js';\nimport { normalizeValueWithProperty } from './normalizeValueWithProperty.js';\nimport { pseudoDescriptors } from './pseudoDescriptors.js';\nimport { styleOriginalValues } from './styleOriginalValues.js';\n/**\n * This is what you want to run before Object.assign() a style onto another.\n * It does the following:\n * 1. Shorthands into longhands, px = paddingHorizontal\n * 2. Expands flex, borderColor and other properties that can expand into sub-parts\n * 3. Normalizes all sub pseudo-media-etc styles\n */\nexport function normalizeStyle(style, disableNormalize = false) {\n const res = {};\n const originalValues = styleOriginalValues.get(style);\n let nextOriginalValues;\n for (let key in style) {\n const prop = style[key];\n if (prop == null)\n continue;\n const originalValue = originalValues?.[key];\n if (key in pseudoDescriptors ||\n // this should capture all parent-based styles like media, group, etc\n (key[0] === '$' && isObj(prop))) {\n res[key] = normalizeStyle(prop, disableNormalize);\n if (originalValue !== undefined) {\n nextOriginalValues || (nextOriginalValues = {});\n nextOriginalValues[key] = originalValue;\n }\n continue;\n }\n const value = disableNormalize ? prop : normalizeValueWithProperty(prop, key);\n // expand react-native shorthands\n const out = expandStyle(key, value);\n if (out) {\n for (const [nextKey, nextValue] of out) {\n res[nextKey] = nextValue;\n if (originalValue !== undefined) {\n nextOriginalValues || (nextOriginalValues = {});\n nextOriginalValues[nextKey] = originalValue;\n }\n }\n }\n else {\n res[key] = value;\n if (originalValue !== undefined) {\n nextOriginalValues || (nextOriginalValues = {});\n nextOriginalValues[key] = originalValue;\n }\n }\n }\n fixStyles(res);\n if (nextOriginalValues) {\n styleOriginalValues.set(res, nextOriginalValues);\n }\n return res;\n}\n//# sourceMappingURL=normalizeStyle.js.map","import { getTokenForKey } from './getTokenForKey.js';\n// includes the optional `/NN` opacity-modifier suffix ($color9/50) so\n// getTokenForKey receives it and can apply the alpha — without it the token\n// resolves but the bare `/50` is left behind in the CSS string, which makes\n// the whole declaration invalid\nconst tokenPattern = /(\\$[\\w.-]+(?:\\/[\\d.]+)?)/g;\n/**\n * web: resolves embedded $tokens in compound CSS strings via simple regex replacement.\n */\nexport function platformResolveValue(_key, value, styleProps, styleState) {\n return value.replace(tokenPattern, (t) => {\n let r = getTokenForKey('size', t, styleProps, styleState);\n if (r == null) {\n r = getTokenForKey('color', t, styleProps, styleState);\n }\n return r != null ? String(r) : t;\n });\n}\n//# sourceMappingURL=platformResolveValue.js.map","import { platformResolveValue } from './platformResolveValue.js';\nconst compoundKeys = {\n boxShadow: true,\n textShadow: true,\n filter: true,\n backgroundImage: true,\n border: true,\n outline: true,\n};\n/**\n * resolves embedded $tokens in compound CSS string values like\n * boxShadow, textShadow, filter, backgroundImage, border, outline.\n *\n * returns the original value unchanged if no resolution is needed.\n */\nexport function resolveCompoundTokens(key, value, styleProps, styleState) {\n if (!value.includes('$'))\n return value;\n if (!compoundKeys[key])\n return value;\n return platformResolveValue(key, value, styleProps, styleState);\n}\n//# sourceMappingURL=resolveCompoundTokens.js.map","/**\n * Resolves rem values on web platforms.\n * On web, browsers handle rem natively, so we just return the value as-is.\n *\n * @param value - A string value containing rem units\n * @returns The same string value (browsers handle rem natively)\n */\nexport function resolveRem(value) {\n return value;\n}\n/**\n * Checks if a value is a rem string\n */\nexport function isRemValue(value) {\n return typeof value === 'string' && value.includes('rem');\n}\n//# sourceMappingURL=resolveRem.js.map","/**\n * Native-only props that should be skipped on web (both dev and prod)\n */\nexport const nativeOnlyProps = {\n accessibilityElementsHidden: 1,\n accessibilityIgnoresInvertColors: 1,\n accessibilityLanguage: 1,\n adjustsFontSizeToFit: 1,\n allowFontScaling: 1,\n android_hyphenationFrequency: 1,\n dataDetectorType: 1,\n dynamicTypeRamp: 1,\n elevationAndroid: 1,\n ellipsizeMode: 1,\n hapticFeedback: 1,\n hapticStyle: 1,\n hitSlop: 1,\n importantForAccessibility: 1,\n lineBreakStrategyIOS: 1,\n maxFontSizeMultiplier: 1,\n minimumFontScale: 1,\n needsOffscreenAlphaCompositing: 1,\n nextFocusDown: 1,\n nextFocusForward: 1,\n nextFocusLeft: 1,\n nextFocusRight: 1,\n nextFocusUp: 1,\n onAccessibilityAction: 1,\n onAccessibilityEscape: 1,\n onAccessibilityTap: 1,\n onMagicTap: 1,\n onTextLayout: 1,\n pressRetentionOffset: 1,\n selectionColor: 1,\n shouldRasterizeIOS: 1,\n suppressHighlighting: 1,\n textBreakStrategy: 1,\n};\n//# sourceMappingURL=nativeOnlyProps.js.map","import { nativeOnlyProps } from './nativeOnlyProps.js';\nimport { webPropsToSkip } from './webPropsToSkip.js';\n/**\n * These are props that dont pass down below Gui styled components\n */\nexport const skipProps = {\n untilMeasured: 1,\n transition: 1,\n space: 1,\n animateOnly: 1,\n animatedBy: 1,\n disableClassName: 1,\n debug: 1,\n componentName: 1,\n disableOptimization: 1,\n render: 1,\n style: 1, // handled after loop so pseudos set usedKeys and override it if necessary\n group: 1,\n animatePresence: 1,\n};\nif (process.env.NODE_ENV === 'test') {\n skipProps['data-test-renders'] = 1;\n}\n// Skip web-only props on native\nif (\"web\" === 'native') {\n Object.assign(skipProps, webPropsToSkip);\n}\n// Skip native-only props on web\nif (\"web\" === 'web') {\n Object.assign(skipProps, nativeOnlyProps);\n}\n//# sourceMappingURL=skipProps.js.map","import { isAndroid } from '@hanzogui/constants';\nimport { getVariableValue, isVariable } from '../createVariable.js';\nimport { expandStyle } from './expandStyle.js';\nimport { getLastFontFamilyToken, getTokenForKey, resolveVariableValue, setLastFontFamilyToken, } from './getTokenForKey.js';\nimport { getVariantExtras } from './getVariantExtras.js';\nimport { isObj } from './isObj.js';\nimport { normalizeStyle } from './normalizeStyle.js';\nimport { parseNativeStyle } from './parseNativeStyle.js';\nimport { pseudoDescriptors } from './pseudoDescriptors.js';\nimport { resolveCompoundTokens } from './resolveCompoundTokens.js';\nimport { isRemValue, resolveRem } from './resolveRem.js';\nimport { skipProps } from './skipProps.js';\nimport { styleOriginalValues } from './styleOriginalValues.js';\nexport { getTokenForKey } from './getTokenForKey.js';\nexport const propMapper = (key, value, styleState, disabled, map) => {\n if (disabled) {\n return map(key, value);\n }\n setLastFontFamilyToken(null);\n if (!(\"web\" === 'native' && isAndroid)) {\n // this shouldnt be necessary and handled in the outer loop\n if (key === 'elevationAndroid')\n return;\n }\n const { conf, styleProps, staticConfig } = styleState;\n const { variants } = staticConfig;\n // \"unset\" is a CSS-wide keyword: valid CSS on web, but React Native\n // style props reject it (e.g. aspectRatio throws \"must be a number, a\n // ratio string or `auto`\"). On native, clear anything an earlier prop or\n // styled default already merged for this key — matching web, where unset\n // resets toward initial — then drop the value so RN never sees it.\n if (\"web\" === 'native' && value === 'unset') {\n const expandedKey = (!styleProps.disableExpandShorthands && conf.shorthands[key]) || key;\n const expanded = styleProps.noExpand\n ? null\n : expandStyle(expandedKey, value, conf.settings.styleCompat || 'web');\n if (styleState.style) {\n if (expanded) {\n for (const [nkey] of expanded) {\n delete styleState.style[nkey];\n }\n }\n else {\n delete styleState.style[expandedKey];\n }\n }\n return;\n }\n if (!styleProps.noExpand) {\n if (variants && key in variants) {\n const variantValue = resolveVariants(key, value, styleProps, styleState, '');\n if (variantValue) {\n variantValue.forEach(([key, value, originalValue]) => {\n map(key, value, originalValue);\n });\n return;\n }\n }\n }\n // handle shorthands\n if (!styleProps.disableExpandShorthands) {\n if (key in conf.shorthands) {\n key = conf.shorthands[key];\n }\n }\n // Capture original value before resolution (for context prop tracking)\n const originalValue = value;\n if (value != null) {\n if (typeof value === 'string') {\n if (value[0] === '$') {\n value = getTokenForKey(key, value, styleProps, styleState);\n }\n else {\n const resolved = resolveCompoundTokens(key, value, styleProps, styleState);\n value =\n resolved !== value ? resolved : isRemValue(value) ? resolveRem(value) : value;\n }\n }\n else if (isVariable(value)) {\n value = resolveVariableValue(key, value, styleProps.resolveValues);\n }\n else if (isRemValue(value)) {\n value = resolveRem(value);\n }\n }\n // on native, parse string backgroundImage/boxShadow/textShadow to RN object format\n // this handles both token-resolved strings and plain strings without tokens\n if (\"web\" === 'native' &&\n value != null &&\n typeof value === 'string' &&\n (key === 'backgroundImage' || key === 'boxShadow' || key === 'textShadow')) {\n const parsed = parseNativeStyle(key, value);\n if (parsed) {\n // textShadow returns [key, value] pairs to expand into separate properties\n if (key === 'textShadow' && Array.isArray(parsed) && Array.isArray(parsed[0])) {\n for (const [nkey, nvalue] of parsed) {\n map(nkey, nvalue, originalValue);\n }\n return;\n }\n value = parsed;\n }\n }\n if (value != null) {\n const fontToken = getLastFontFamilyToken();\n if (key === 'fontFamily' && fontToken) {\n styleState.fontFamily = fontToken;\n }\n const expanded = styleProps.noExpand\n ? null\n : expandStyle(key, value, conf.settings.styleCompat || 'web');\n if (expanded) {\n const max = expanded.length;\n for (let i = 0; i < max; i++) {\n const [nkey, nvalue, noriginalValue] = expanded[i];\n map(nkey, nvalue, noriginalValue ?? originalValue);\n }\n }\n else {\n map(key, value, originalValue);\n }\n }\n};\nconst resolveVariants = (key, value, styleProps, styleState, parentVariantKey) => {\n const { staticConfig, conf, debug } = styleState;\n const { variants } = staticConfig;\n if (!variants)\n return;\n let variantValue = getVariantDefinition(variants[key], value, conf, styleState);\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.groupCollapsed(`♦️♦️♦️ resolve variant ${key}`);\n console.info({\n key,\n value,\n variantValue,\n variants,\n });\n console.groupEnd();\n }\n if (!variantValue) {\n // variant at key exists, but no matching variant\n // disabling warnings, its fine to pass through, could re-enable later somehoiw\n if (process.env.GUI_WARN_ON_MISSING_VARIANT === '1') {\n // don't warn on missing booleans\n if (typeof value !== 'boolean') {\n const name = staticConfig.componentName || '[UnnamedComponent]';\n console.warn(`No variant found: ${name} has variant \"${key}\", but no matching value \"${value}\"`);\n }\n }\n return;\n }\n if (typeof variantValue === 'function') {\n const fn = variantValue;\n const extras = getVariantExtras(styleState);\n variantValue = fn(value, extras);\n if (process.env.NODE_ENV === 'development' &&\n debug === 'verbose' &&\n \"web\" !== 'native') {\n console.groupCollapsed(' expanded functional variant', key);\n console.info({ fn, variantValue, extras });\n console.groupEnd();\n }\n }\n let fontFamilyResult;\n if (isObj(variantValue)) {\n const fontFamilyUpdate = variantValue.fontFamily || variantValue[conf.inverseShorthands.fontFamily];\n if (fontFamilyUpdate) {\n fontFamilyResult = getFontFamilyFromNameOrVariable(fontFamilyUpdate, conf);\n styleState.fontFamily = fontFamilyResult;\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.info(` updating font family`, fontFamilyResult);\n }\n }\n variantValue = resolveTokensAndVariants(key, variantValue, styleProps, styleState, parentVariantKey);\n }\n if (variantValue) {\n const expanded = normalizeStyle(variantValue, !!styleProps.noNormalize);\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.info(` expanding styles from `, variantValue, `to`, expanded);\n }\n const next = Object.entries(expanded);\n const originalValues = styleOriginalValues.get(expanded);\n // store any changed font family (only support variables for now)\n if (fontFamilyResult && fontFamilyResult[0] === '$') {\n setLastFontFamilyToken(getVariableValue(fontFamilyResult));\n }\n return next.map(([key, value]) => [key, value, originalValues?.[key]]);\n }\n};\n// handles finding and resolving the fontFamily to the token name\n// this is used as `font_[name]` in className for nice css variable support\nexport function getFontFamilyFromNameOrVariable(input, conf) {\n if (isVariable(input)) {\n const val = variableToFontNameCache.get(input);\n if (val)\n return val;\n for (const key in conf.fontsParsed) {\n const familyVariable = conf.fontsParsed[key].family;\n if (isVariable(familyVariable)) {\n variableToFontNameCache.set(familyVariable, key);\n if (familyVariable === input) {\n return key;\n }\n }\n }\n }\n else if (typeof input === 'string') {\n if (input[0] === '$') {\n return input;\n }\n }\n}\nconst variableToFontNameCache = new WeakMap();\nconst resolveTokensAndVariants = (key, // we dont use key assume value is object instead\nvalue, styleProps, styleState, parentVariantKey) => {\n const { conf, staticConfig, debug, theme } = styleState;\n const { variants } = staticConfig;\n const res = {};\n let originalValues;\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.info(` - resolveTokensAndVariants`, key, value);\n }\n for (const _key in value) {\n const subKey = conf.shorthands[_key] || _key;\n const val = value[_key];\n if (!styleProps.noSkip && subKey in skipProps) {\n continue;\n }\n originalValues || (originalValues = {});\n originalValues[subKey] = val;\n // Track context overrides for any key that's in context props (issues #3670, #3676)\n // Store the ORIGINAL token value (like '$8') before resolution so that\n // children's functional variants can look up token values\n if (staticConfig) {\n const contextProps = staticConfig.context?.props || staticConfig.parentStaticConfig?.context?.props;\n if (contextProps && subKey in contextProps) {\n styleState.overriddenContextProps || (styleState.overriddenContextProps = {});\n styleState.overriddenContextProps[subKey] = val;\n // Also track the original token value separately\n styleState.originalContextPropValues || (styleState.originalContextPropValues = {});\n styleState.originalContextPropValues[subKey] = val;\n }\n }\n if (styleProps.noExpand) {\n res[subKey] = val;\n }\n else {\n if (variants && subKey in variants) {\n // avoids infinite loop if variant is matching a style prop\n // eg: { variants: { flex: { true: { flex: 2 } } } }\n if (parentVariantKey && parentVariantKey === key) {\n res[subKey] =\n val[0] === '$' ? getTokenForKey(subKey, val, styleProps, styleState) : val;\n }\n else {\n const variantOut = resolveVariants(subKey, val, styleProps, styleState, key);\n // apply, merging sub-styles\n if (variantOut) {\n for (const [key, val, originalVal] of variantOut) {\n if (val == null)\n continue;\n if (key in pseudoDescriptors) {\n res[key] ?? (res[key] = {});\n Object.assign(res[key], val);\n const subOriginalValues = styleOriginalValues.get(val);\n if (subOriginalValues) {\n styleOriginalValues.set(res[key], {\n ...styleOriginalValues.get(res[key]),\n ...subOriginalValues,\n });\n }\n }\n else {\n res[key] = val;\n if (originalVal !== undefined) {\n originalValues || (originalValues = {});\n originalValues[key] = originalVal;\n }\n }\n }\n }\n }\n continue;\n }\n }\n if (isVariable(val)) {\n res[subKey] = resolveVariableValue(subKey, val, styleProps.resolveValues);\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.info(`variable`, subKey, res[subKey]);\n }\n continue;\n }\n if (typeof val === 'string') {\n const fVal = val[0] === '$'\n ? getTokenForKey(subKey, val, styleProps, styleState)\n : resolveCompoundTokens(subKey, val, styleProps, styleState);\n res[subKey] = fVal === val && isRemValue(val) ? resolveRem(val) : fVal;\n continue;\n }\n if (isObj(val)) {\n const subObject = resolveTokensAndVariants(subKey, val, styleProps, styleState, key);\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.info(`object`, subKey, subObject);\n }\n // sub-objects: media queries, pseudos, shadowOffset\n res[subKey] ?? (res[subKey] = {});\n Object.assign(res[subKey], subObject);\n const subOriginalValues = styleOriginalValues.get(subObject);\n if (subOriginalValues) {\n styleOriginalValues.set(res[subKey], {\n ...styleOriginalValues.get(res[subKey]),\n ...subOriginalValues,\n });\n }\n }\n else {\n // nullish values cant be tokens, need no extra parsing\n res[subKey] = val;\n }\n if (process.env.NODE_ENV === 'development') {\n if (debug) {\n if (res[subKey]?.[0] === '$') {\n console.warn(`⚠️ Missing token in theme ${theme.name}:`, subKey, res[subKey], theme);\n }\n }\n }\n }\n if (originalValues) {\n styleOriginalValues.set(res, originalValues);\n }\n return res;\n};\nconst tokenCats = ['size', 'color', 'radius', 'space', 'zIndex'].map((name) => ({\n name,\n spreadName: `...${name}`,\n}));\n// goes through specificity finding best matching variant function\nfunction getVariantDefinition(variant, value, conf, { theme }) {\n if (!variant)\n return;\n if (typeof variant === 'function') {\n return variant;\n }\n const exact = variant[value];\n if (exact) {\n return exact;\n }\n if (value != null) {\n const { tokensParsed } = conf;\n for (const { name, spreadName } of tokenCats) {\n if (spreadName in variant) {\n // check tokens first\n if (name in tokensParsed && value in tokensParsed[name]) {\n return variant[spreadName];\n }\n // or check theme (only color lives in theme, others are in tokens)\n if (name === 'color' && theme && typeof value === 'string' && value[0] === '$') {\n const themeKey = value.slice(1);\n if (themeKey in theme) {\n return variant[spreadName];\n }\n }\n }\n }\n const fontSizeVariant = variant['...fontSize'];\n if (fontSizeVariant && conf.fontSizeTokens.has(value)) {\n return fontSizeVariant;\n }\n }\n // fallback to catch all | size\n return variant[`:${typeof value}`] || variant['...'];\n}\n//# sourceMappingURL=propMapper.js.map","export const sortString = (a, b) => (a < b ? -1 : a > b ? 1 : 0);\n//# sourceMappingURL=sortString.js.map","import { getPlatformDriver, isAndroid, isClient, isWeb, supportsDynamicColorIOS, useIsomorphicLayoutEffect, } from '@hanzogui/constants';\nimport { StyleObjectIdentifier, StyleObjectProperty, StyleObjectPseudo, StyleObjectRules, nonAnimatableStyleProps, stylePropsText, stylePropsTransform, tokenCategories, validPseudoKeys, validStyles as validStylesView, } from '@hanzogui/helpers';\nimport React from 'react';\nimport { getConfig, getFont, getSetting } from '../config.js';\nimport { isDevTools } from '../constants/isDevTools.js';\nimport { getMediaImportanceIfMoreImportant, getMediaKey, getMediaKeyImportance, mediaKeyMatch, } from '../hooks/useMedia.js';\nimport { mediaState as globalMediaState, mediaQueryConfig } from './mediaState.js';\nimport { createMediaStyle } from './createMediaStyle.js';\nimport { fixStyles } from './expandStyles.js';\nimport { getCSSStylesAtomic, getStyleAtomic, styleToCSS } from './getCSSStylesAtomic.js';\nimport { getDefaultProps } from './getDefaultProps.js';\nimport { extractValueFromDynamic, getDynamicVal, getOppositeScheme, isColorStyleKey, } from './getDynamicVal.js';\nimport { getGroupPropParts } from './getGroupPropParts.js';\nimport { insertStyleRules, shouldInsertStyleRules, updateRules, } from './insertStyleRule.js';\nimport { isActivePlatform, getPlatformSpecificityBump } from './isActivePlatform.js';\nimport { isActiveTheme } from './isActiveTheme.js';\nimport { log } from './log.js';\nimport { normalizeValueWithProperty } from './normalizeValueWithProperty.js';\nimport { propMapper } from './propMapper.js';\nimport { pseudoDescriptors, pseudoPriorities, defaultMediaImportance, } from './pseudoDescriptors.js';\nimport { skipProps } from './skipProps.js';\nimport { sortString } from './sortString.js';\nimport { styleOriginalValues } from './styleOriginalValues.js';\nimport { setStyleTokenProvenance } from './styleProvenance.js';\nimport { transformsToString } from './transformsToString.js';\nexport { styleOriginalValues };\nexport { getStyleTokenProvenance, STYLE_TOKEN_PROVENANCE_KEY } from './styleProvenance.js';\nconst shouldTrackStyleTokenProvenance = process.env.NODE_ENV === 'development' &&\n process.env.GUI_ENABLE_STYLE_TOKEN_PROVENANCE === '1';\nlet conf;\nexport const PROP_SPLIT = '-';\n// Normalize group keys like $group-press to $group-true-press when the group name\n// doesn't exist in context (defaults to the unnamed 'true' group)\nfunction normalizeGroupKey(key, groupContext) {\n const parts = key.split('-');\n const plen = parts.length;\n if (\n // check if its actually a simple group selector to avoid breaking selectors\n plen === 2 ||\n (plen === 3 && pseudoPriorities[parts[parts.length - 1]])) {\n const name = parts[1];\n if (name !== 'true' && groupContext && !groupContext[name]) {\n return key.replace('$group-', '$group-true-');\n }\n }\n return key;\n}\n// if you need and easier way to test performance, you can do something like this\n// add this early return somewhere in this file and you can see roughly where it slows down:\n// return {\n// space,\n// hasMedia,\n// fontFamily: styleState.fontFamily,\n// viewProps: {\n// children: props.children,\n// },\n// style: {\n// borderColor: props.borderColor,\n// borderWidth: props.borderWidth,\n// padding: props.padding,\n// },\n// pseudos,\n// classNames,\n// rulesToInsert,\n// dynamicThemeAccess,\n// }\nfunction isValidStyleKey(key, validStyles, accept) {\n return key in validStyles ? true : accept && key in accept;\n}\nfunction shouldSkipNativeHoverProp(key, isMedia) {\n if (\"web\" !== 'native')\n return false;\n if (getPlatformDriver()?.pseudo)\n return false;\n if (key === 'hoverStyle')\n return true;\n if (isMedia === 'group') {\n return getGroupPropParts(key.slice(1)).pseudo === 'hover';\n }\n return false;\n}\nexport const getSplitStyles = (props, staticConfig, theme, themeName, componentState, styleProps, parentSplitStyles, componentContext, groupContext, elementType, startedUnhydrated, debug, animationDriver) => {\n conf = conf || getConfig();\n // use passed animationDriver or fall back to context/config\n const driver = animationDriver ||\n componentContext?.animationDriver ||\n conf.animations;\n if (props.passThrough) {\n return null;\n }\n // a bit icky, we need no normalize but not fully\n if (isWeb &&\n styleProps.isAnimated &&\n driver?.isReactNative &&\n !styleProps.noNormalize) {\n styleProps.noNormalize = 'values';\n }\n const { shorthands } = conf;\n const { isHOC, isText, isInput, variants, isReactNative, inlineProps, inlineWhenUnflattened, parentStaticConfig, acceptsClassName, } = staticConfig;\n const viewProps = {};\n const mediaState = styleProps.mediaState || globalMediaState;\n const shouldDoClasses = acceptsClassName && isWeb && !styleProps.noClass;\n const rulesToInsert = \"web\" === 'native' ? undefined : {};\n const classNames = {};\n let space = props.space;\n let pseudos = null;\n let hasMedia = false;\n let dynamicThemeAccess;\n let pseudoGroups;\n let mediaGroups;\n let className = props.className || ''; // existing classNames\n let mediaStylesSeen = 0;\n const validStyles = staticConfig.validStyles ||\n (staticConfig.isText || staticConfig.isInput ? stylePropsText : validStylesView);\n if (process.env.NODE_ENV === 'development' &&\n (debug === 'profile' || globalThis.time)) {\n // @ts-expect-error\n time `split-styles-setup`;\n }\n /**\n * Not the biggest fan of creating an object but it is a nice API\n */\n const styleState = {\n classNames,\n conf,\n props,\n styleProps,\n componentState,\n staticConfig,\n style: null,\n theme,\n usedKeys: {},\n viewProps,\n context: componentContext,\n debug,\n // resolved animation driver (respects animatedBy prop)\n animationDriver: driver,\n };\n // only used by compiler\n if (process.env.IS_STATIC === 'is_static') {\n const { fallbackProps } = styleProps;\n if (fallbackProps) {\n styleState.props = new Proxy(props, {\n get(_, key, val) {\n if (!Reflect.has(props, key)) {\n return Reflect.get(fallbackProps, key);\n }\n return Reflect.get(props, key);\n },\n });\n }\n }\n if (process.env.NODE_ENV === 'development' &&\n (debug === 'profile' || globalThis.time)) {\n // @ts-expect-error\n time `style-state`;\n }\n if (process.env.NODE_ENV === 'development' && debug === 'verbose' && isClient) {\n if (isDevTools) {\n console.groupCollapsed('🔹 getSplitStyles 👇');\n log({\n props,\n staticConfig,\n shouldDoClasses,\n styleProps,\n rulesToInsert,\n componentState,\n styleState,\n theme: { ...theme },\n });\n }\n }\n const { asChild } = props;\n const { accept } = staticConfig;\n const { noSkip, disableExpandShorthands, noExpand, styledContext } = styleProps;\n const { webContainerType } = conf.settings;\n const parentVariants = parentStaticConfig?.variants;\n for (const keyOg in props) {\n let keyInit = keyOg;\n let valInit = props[keyInit];\n if (keyInit === 'children') {\n viewProps[keyInit] = valInit;\n continue;\n }\n // native: data-* attributes never become native props (they're stripped\n // further down anyway), and the compiler-emitted data-disable-theme/-media\n // flags are already consumed in createComponent. skip them before any per-prop\n // work so they don't pay the isValidStyleKey + handling cost on the hot path.\n if (\"web\" === 'native' &&\n keyInit[0] === 'd' &&\n keyInit.startsWith('data-')) {\n continue;\n }\n if (process.env.NODE_ENV === 'development' &&\n (debug === 'profile' || globalThis.time)) {\n // @ts-expect-error\n time `before-prop-${keyInit}`;\n }\n if (process.env.NODE_ENV === 'test' && keyInit === 'jestAnimatedStyle') {\n continue;\n }\n // for custom accept sub-styles\n if (accept) {\n const accepted = accept[keyInit];\n if ((accepted === 'style' || accepted === 'textStyle') &&\n valInit &&\n typeof valInit === 'object') {\n viewProps[keyInit] = getSubStyle(styleState, keyInit, valInit, styleProps.noClass);\n continue;\n }\n }\n // normalize shorthands up front\n if (!disableExpandShorthands) {\n if (keyInit in shorthands) {\n keyInit = shorthands[keyInit];\n }\n }\n if (keyInit === 'className')\n continue; // handled above first\n // when asChild, skip default props - they shouldn't be passed down to children\n if (asChild) {\n const defaults = getDefaultProps(staticConfig);\n if (defaults) {\n // check both original key and expanded key (after shorthand expansion)\n const defaultVal = defaults[keyOg] ?? defaults[keyInit];\n if (defaultVal !== undefined && valInit === defaultVal) {\n continue;\n }\n }\n }\n // keyInit === 'style' is handled in skipProps\n if (keyInit in skipProps && !noSkip && !isHOC) {\n if (keyInit === 'group') {\n if (\"web\" === 'web') {\n // add container style\n const identifier = `t_group_${valInit}`;\n const containerType = webContainerType || 'inline-size';\n const containerCSS = [\n 'container',\n undefined,\n identifier,\n undefined,\n [\n `.${identifier} { container-name: ${valInit}; container-type: ${containerType}; }`,\n ],\n ];\n addStyleToInsertRules(rulesToInsert, containerCSS);\n }\n }\n if (keyInit === 'transition' && typeof valInit === 'string') {\n const animationConfig = driver?.animations?.[valInit];\n if (animationConfig &&\n driver?.outputStyle === 'css' &&\n process.env.IS_STATIC === 'is_static') {\n // css output needs no runtime component: lower its named transition\n // to ordinary css so the compiler can keep flattening.\n valInit = `all ${animationConfig}`;\n }\n else if (animationConfig) {\n continue;\n }\n // unknown names are raw CSS transition values and pass through.\n }\n else {\n continue;\n }\n }\n let isValidStyleKeyInit = isValidStyleKey(keyInit, validStyles, accept);\n // this is all for partially optimized (not flattened)... maybe worth removing?\n if (\"web\" === 'web') {\n // react-native-web ignores data-* attributes, fixes passing them to animated views\n if (staticConfig.isReactNative && keyInit.startsWith('data-')) {\n keyInit = keyInit.replace('data-', '');\n viewProps['dataSet'] || (viewProps['dataSet'] = {});\n viewProps['dataSet'][keyInit] = valInit;\n continue;\n }\n }\n if (\"web\" === 'native') {\n if (!isValidStyleKeyInit) {\n if (!isAndroid) {\n // only works in android\n if (keyInit === 'elevationAndroid')\n continue;\n }\n // map userSelect to native prop\n if (keyInit === 'userSelect') {\n keyInit = 'selectable';\n valInit = valInit !== 'none';\n }\n else if (keyInit.startsWith('data-')) {\n continue;\n }\n }\n }\n if (\"web\" === 'web') {\n if (!noExpand) {\n /**\n * Copying in the accessibility/prop handling from react-native-web here\n * Keeps it in a single loop, avoids dup de-structuring to avoid bundle size\n */\n if (keyInit === 'disabled' && valInit === true) {\n viewProps['aria-disabled'] = true;\n // isInput: Input/TextArea wrap the real <input>/<textarea> in a styleable, so\n // elementType is the wrapper here - forward disabled down or it never reaches it\n if (isInput ||\n elementType === 'button' ||\n elementType === 'form' ||\n elementType === 'input' ||\n elementType === 'select' ||\n elementType === 'textarea') {\n viewProps.disabled = true;\n }\n if (!variants?.disabled) {\n continue;\n }\n }\n if (keyInit === 'testID') {\n if (isReactNative) {\n viewProps.testID = valInit;\n }\n else {\n viewProps['data-testid'] = valInit;\n // also keep testID when using RN animation driver (Animated.View\n // from react-native-web only forwards testID, not data-testid)\n if (styleProps.isAnimated && driver?.isReactNative) {\n viewProps.testID = valInit;\n }\n }\n continue;\n }\n if (keyInit === 'id') {\n viewProps.id = valInit;\n continue;\n }\n }\n }\n /**\n * There's (some) reason to this madness: we want to allow returning media/pseudo from variants\n * Say you have a variant hoverable: { true: { hoverStyle: {} } }\n * We run propMapper first to expand variant, then we run the inner loop and look again\n * for if there's a pseudo/media returned from it.\n */\n let isVariant = !isValidStyleKeyInit && variants && keyInit in variants;\n const isStyleLikeKey = isValidStyleKeyInit || isVariant;\n let isPseudo = keyInit in validPseudoKeys;\n let isMedia = !isStyleLikeKey && !isPseudo ? getMediaKey(keyInit) : false;\n let isMediaOrPseudo = Boolean(isMedia || isPseudo);\n if (isMediaOrPseudo && isMedia === 'group') {\n keyInit = normalizeGroupKey(keyInit, groupContext);\n }\n const isStyleProp = isValidStyleKeyInit || isMediaOrPseudo || (isVariant && !noExpand);\n if (shouldSkipNativeHoverProp(keyInit, isMedia)) {\n continue;\n }\n if (isStyleProp && (asChild === 'except-style' || asChild === 'except-style-web')) {\n continue;\n }\n const shouldPassProp = (!isStyleProp && isHOC) ||\n // is in parent variants\n (isHOC && parentVariants && keyInit in parentVariants) ||\n inlineProps?.has(keyInit);\n const parentVariant = parentVariants?.[keyInit];\n const isHOCShouldPassThrough = Boolean(isHOC &&\n (isValidStyleKeyInit || isMediaOrPseudo || parentVariant || keyInit in skipProps));\n const shouldPassThrough = shouldPassProp || isHOCShouldPassThrough;\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n // console.groupEnd() // react native was not nesting right\n console.groupCollapsed(` 🔑 ${keyOg}${keyInit !== keyOg ? ` (shorthand for ${keyInit})` : ''} ${shouldPassThrough ? '(pass)' : ''}`);\n log({ isVariant, valInit, shouldPassProp });\n if (isClient) {\n log({\n variants,\n variant: variants?.[keyInit],\n isVariant,\n isHOCShouldPassThrough,\n usedKeys: { ...styleState.usedKeys },\n parentStaticConfig,\n });\n }\n }\n if (shouldPassThrough) {\n // // TODO bring this back but probably improve it?\n // if (isPseudo) {\n // // this is a lot... but we need to track sub-keys so we don't override them in future things that aren't passed down\n // // like our own variants that aren't in parent\n // const pseudoStyleObject = getSubStyle(\n // styleState,\n // keyInit,\n // valInit,\n // fontFamily,\n // true,\n // state.noClass\n // )\n // const descriptor = pseudoDescriptors[keyInit]\n // for (const key in pseudoStyleObject) {\n // debugger\n // }\n // }\n passDownProp(viewProps, keyInit, valInit, isMediaOrPseudo);\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.groupEnd();\n }\n // if it's a variant here, we have a two layer variant...\n // aka styled(Input, { unstyled: true, variants: { unstyled: {} } })\n // which now has it's own unstyled + the child unstyled...\n // so *don't* skip applying the styles if its different from the parent one\n if (!isVariant) {\n continue;\n }\n }\n // after shouldPassThrough\n if (!noSkip) {\n if (keyInit in skipProps &&\n !(keyInit === 'transition' &&\n typeof valInit === 'string' &&\n !driver?.animations?.[valInit])) {\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.groupEnd();\n }\n continue;\n }\n }\n // we sort of have to update fontFamily all the time: before variants run, after each variant\n if (isText || isInput) {\n if (valInit &&\n (keyInit === 'fontFamily' || keyInit === shorthands['fontFamily']) &&\n valInit in conf.fontsParsed) {\n styleState.fontFamily = valInit;\n }\n }\n const disablePropMap = isMediaOrPseudo || !isStyleLikeKey;\n propMapper(keyInit, valInit, styleState, disablePropMap, (key, val, originalVal) => {\n const isStyledContextProp = styledContext && key in styledContext;\n if (!isHOC && disablePropMap && !isStyledContextProp && !isMediaOrPseudo) {\n viewProps[key] = val;\n return;\n }\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.groupCollapsed(' 💠 expanded', keyInit, '=>', key);\n log(val);\n console.groupEnd();\n }\n if (val == null)\n return;\n if (\"web\" === 'native') {\n if (key === 'pointerEvents') {\n viewProps[key] = val;\n return;\n }\n }\n if ((!isHOC && isValidStyleKey(key, validStyles, accept)) ||\n (\"web\" === 'native' && isAndroid && key === 'elevation')) {\n mergeStyle(styleState, key, val, 1, false, originalVal);\n return;\n }\n // re-run with expanded key\n isPseudo = key in validPseudoKeys;\n isMedia = isPseudo ? false : getMediaKey(key);\n isMediaOrPseudo = Boolean(isMedia || isPseudo);\n isVariant = variants && key in variants;\n // handle group key transformation for variant-expanded keys (issue #3613)\n if (isMedia === 'group') {\n key = normalizeGroupKey(key, groupContext);\n }\n if (shouldSkipNativeHoverProp(key, isMedia)) {\n return;\n }\n if (inlineProps?.has(key) ||\n (process.env.IS_STATIC === 'is_static' && inlineWhenUnflattened?.has(key))) {\n viewProps[key] = props[key] ?? val;\n }\n // have to run this logic again here because expansions may need to be passed down\n // see StyledButtonVariantPseudoMerge test\n const shouldPassThrough = (styleProps.noExpand && isPseudo) ||\n (isHOC && (isMediaOrPseudo || parentStaticConfig?.variants?.[keyInit]));\n if (shouldPassThrough) {\n passDownProp(viewProps, key, val, isMediaOrPseudo);\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.groupCollapsed(` - passing down prop ${key}`);\n log({ val, after: { ...viewProps[key] } });\n console.groupEnd();\n }\n return;\n }\n if (isPseudo) {\n if (!val)\n return;\n // TODO can avoid processing this if !shouldDoClasses + state is off\n // (note: can't because we need to set defaults on enter/exit or else enforce that they should)\n const pseudoStyleObject = getSubStyle(styleState, key, val, styleProps.noClass && !(process.env.IS_STATIC === 'is_static'));\n if (!shouldDoClasses || process.env.IS_STATIC === 'is_static') {\n pseudos || (pseudos = {});\n pseudos[key] || (pseudos[key] = {});\n // if compiler we can just set this and continue on our way\n if (process.env.IS_STATIC === 'is_static') {\n Object.assign(pseudos[key], pseudoStyleObject);\n return;\n }\n }\n const descriptor = pseudoDescriptors[key];\n const isEnter = key === 'enterStyle';\n const isExit = key === 'exitStyle';\n // don't continue here on isEnter && !state.unmounted because we need to merge defaults\n if (!descriptor) {\n return;\n }\n // on server only generate classes for enterStyle\n if (shouldDoClasses && !isExit) {\n const pseudoStyles = getStyleAtomic(pseudoStyleObject, descriptor);\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.info('pseudo:', key, pseudoStyleObject, pseudoStyles);\n }\n for (const psuedoStyle of pseudoStyles) {\n const fullKey = `${psuedoStyle[StyleObjectProperty]}${PROP_SPLIT}${descriptor.name}`;\n addStyleToInsertRules(rulesToInsert, psuedoStyle);\n classNames[fullKey] = psuedoStyle[StyleObjectIdentifier];\n }\n }\n if (!shouldDoClasses || isExit || isEnter) {\n // we don't skip this if disabled because we need to animate to default states that aren't even set:\n // so if we have <Stack enterStyle={{ opacity: 0 }} />\n // we need to animate from 0 => 1 once enter is finished\n // see the if (isDisabled) block below which loops through animatableDefaults\n const descriptorKey = descriptor.stateKey || descriptor.name;\n let isDisabled = componentState[descriptorKey] === false;\n if (isExit) {\n isDisabled = !styleProps.isExiting;\n }\n if (isEnter && componentState.unmounted === false) {\n isDisabled = true;\n }\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n console.groupCollapsed('pseudo', key, { isDisabled });\n log({ pseudoStyleObject, isDisabled, descriptor, componentState });\n console.groupEnd();\n }\n const importance = descriptor.priority;\n const pseudoOriginalValues = styleOriginalValues.get(pseudoStyleObject);\n for (const pkey in pseudoStyleObject) {\n const val = pseudoStyleObject[pkey];\n // when disabled ensure the default value is set for future animations to align\n if (isDisabled) {\n applyDefaultStyle(pkey, styleState);\n }\n else {\n const curImportance = styleState.usedKeys[pkey] || 0;\n const shouldMerge = importance >= curImportance;\n if (shouldMerge) {\n if (process.env.IS_STATIC === 'is_static') {\n pseudos || (pseudos = {});\n pseudos[key] || (pseudos[key] = {});\n pseudos[key][pkey] = val;\n }\n mergeStyle(styleState, pkey, val, importance, false, pseudoOriginalValues?.[pkey]);\n }\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n log(' subKey', pkey, shouldMerge, {\n importance,\n curImportance,\n pkey,\n val,\n });\n }\n }\n }\n // set this after the loop over pseudoStyleObject so it applies before setting usedKeys\n if (!isDisabled) {\n // mark usedKeys based on pseudoStyleObject\n for (const key in val) {\n const k = shorthands[key] || key;\n styleState.usedKeys[k] = Math.max(importance, styleState.usedKeys[k] || 0);\n }\n }\n }\n return;\n }\n // media\n if (isMedia) {\n if (!val)\n return;\n // for some reason 'space' in val upsetting next ssr during prod build\n // technically i guess this also will not apply if 0 space which makes sense?\n const mediaKeyShort = key.slice(isMedia == 'theme' ? 7 : 1);\n hasMedia || (hasMedia = true);\n const hasSpace = val['space'];\n if (hasSpace || !shouldDoClasses || styleProps.willBeAnimated) {\n if (!hasMedia || typeof hasMedia === 'boolean') {\n hasMedia = new Set();\n }\n hasMedia.add(mediaKeyShort);\n }\n // can bail early\n if (isMedia === 'platform') {\n if (!isActivePlatform(key)) {\n return;\n }\n }\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n log(` 📺 ${key}`, {\n key,\n val,\n props,\n shouldDoClasses,\n acceptsClassName,\n componentState,\n mediaState,\n });\n }\n const priority = mediaStylesSeen;\n mediaStylesSeen += 1;\n // for theme media ($theme-light, $theme-dark), generate CSS classes for proper SSR\n // when noClass is set (inline animation drivers), de-opt to inline styles so the\n if (shouldDoClasses) {\n const mediaStyle = getSubStyle(styleState, key, val, false);\n const mediaStyles = getCSSStylesAtomic(mediaStyle);\n for (const style of mediaStyles) {\n // handle nested media:\n // for now we're doing weird stuff, getCSSStylesAtomic will put the\n // $platform-web into property so we can check it here\n const property = style[StyleObjectProperty];\n const isSubStyle = property[0] === '$';\n if (isSubStyle && !isActivePlatform(property)) {\n continue;\n }\n const out = createMediaStyle(style, mediaKeyShort, mediaQueryConfig, isMedia, false, priority);\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n log(`📺 media style:`, out);\n }\n // this is imperfect it should be fixed further down, we mess up property when dealing with\n // media-sub-style, like $sm={{ $platform-web: {} }}\n // property is just $platform-web, it should br $platform-web-bg, so we add extra info from style\n // but that info includes the value too\n const subKey = isSubStyle ? style[2] : '';\n const fullKey = `${style[StyleObjectProperty]}${subKey}${PROP_SPLIT}${mediaKeyShort}${style[StyleObjectPseudo] || ''}`;\n addStyleToInsertRules(rulesToInsert, out);\n classNames[fullKey] = out[StyleObjectIdentifier];\n }\n }\n else {\n const isThemeMedia = isMedia === 'theme';\n const isGroupMedia = isMedia === 'group';\n const isPlatformMedia = isMedia === 'platform';\n if (!isThemeMedia && !isPlatformMedia && !isGroupMedia) {\n if (!mediaState[mediaKeyShort]) {\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n log(` 📺 ❌ DISABLED ${mediaKeyShort}`);\n }\n return;\n }\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n log(` 📺 ✅ ENABLED ${mediaKeyShort}`);\n }\n }\n const mediaStyle = getSubStyle(styleState, key, val, true);\n let importanceBump = 0;\n if (isThemeMedia) {\n if (\"web\" === 'native' &&\n supportsDynamicColorIOS &&\n getSetting('fastSchemeChange')) {\n // iOS will use https://reactnative.dev/docs/dynamiccolorios\n // so need to predefine the dynamic color before merging the styles\n // for example: <StyledYStack $theme-dark={{borderColor: '$red10'}} $theme-light={{borderColor: '$green10'}}> => {borderColor: {dynamic: {dark: '$red10', light: '$green10'}}}\n styleState.style || (styleState.style = {});\n const scheme = mediaKeyShort;\n const oppositeScheme = getOppositeScheme(mediaKeyShort);\n const themeOriginalValues = styleOriginalValues.get(mediaStyle);\n const isCurrentScheme = themeName === scheme || themeName.startsWith(scheme);\n for (const subKey in mediaStyle) {\n const val = extractValueFromDynamic(mediaStyle[subKey], scheme);\n const existing = styleState.style[subKey];\n // Only color properties support DynamicColorIOS - non-color properties\n // like opacity, dimensions, etc. will crash if wrapped with {dynamic: {...}}\n // See: https://github.com/hanzoai/gui/issues/3096\n // See: https://github.com/hanzoai/gui/issues/2980\n if (!isColorStyleKey(subKey)) {\n // non-color properties require re-render to update\n dynamicThemeAccess = true;\n // only apply if this is the current theme\n if (isCurrentScheme) {\n // update mediaStyle so the later merge loop uses correct value\n mediaStyle[subKey] = val;\n }\n else {\n // remove from mediaStyle so it doesn't get merged with wrong theme's value\n delete mediaStyle[subKey];\n }\n continue;\n }\n // if there's already a dynamic object from the other theme pseudo prop,\n // merge directly to avoid importance conflicts between $theme-dark and $theme-light\n if (existing?.dynamic) {\n existing.dynamic[scheme] = val;\n mediaStyle[subKey] = existing;\n }\n else {\n const oppositeVal = extractValueFromDynamic(existing, oppositeScheme);\n mediaStyle[subKey] = getDynamicVal({\n scheme,\n val,\n oppositeVal,\n });\n mergeStyle(styleState, subKey, mediaStyle[subKey], priority, false, themeOriginalValues?.[subKey]);\n }\n }\n }\n else {\n // non-ios or no fastschemechange - need re-renders for theme changes\n dynamicThemeAccess = true;\n if (!(themeName === mediaKeyShort || themeName.startsWith(mediaKeyShort))) {\n return;\n }\n }\n }\n else if (isGroupMedia) {\n const groupInfo = getGroupPropParts(mediaKeyShort);\n const groupName = groupInfo.name;\n // $group-x\n const groupState = groupContext?.[groupName]?.state;\n const groupPseudoKey = groupInfo.pseudo;\n const groupMediaKey = groupInfo.media;\n if (\"web\" === 'native' && groupPseudoKey === 'hover') {\n return;\n }\n if (!groupState) {\n if (process.env.NODE_ENV === 'development' && debug) {\n log(`No parent with group prop, skipping styles: ${groupName}`);\n }\n // we still want to indicate we should listen! this is how subscribeToGroupContext knows to run\n pseudoGroups || (pseudoGroups = new Set());\n return;\n }\n const componentGroupState = componentState.group?.[groupName];\n if (groupMediaKey) {\n mediaGroups || (mediaGroups = new Set());\n mediaGroups.add(groupMediaKey);\n const mediaState = componentGroupState?.media;\n let isActive = mediaState?.[groupMediaKey];\n // use parent styles if width and height hardcoded we can do an inline media match and avoid double render\n if (!mediaState && groupState.layout) {\n isActive = mediaKeyMatch(groupMediaKey, groupState.layout);\n }\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n log(` 🏘️ GROUP media ${groupMediaKey} active? ${isActive}`, {\n ...mediaState,\n usedKeys: { ...styleState.usedKeys },\n });\n }\n if (!isActive) {\n // ensure we set the defaults so animations work\n for (const pkey in mediaStyle) {\n applyDefaultStyle(pkey, styleState);\n }\n return;\n }\n importanceBump = 2;\n }\n if (groupPseudoKey) {\n pseudoGroups || (pseudoGroups = new Set());\n pseudoGroups.add(groupName);\n const componentGroupPseudoState = (componentGroupState ||\n // fallback to context initially\n groupContext?.[groupName].state)?.pseudo;\n const isActive = componentGroupPseudoState?.[groupPseudoKey];\n const priority = pseudoPriorities[groupPseudoKey];\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n log(` 🏘️ GROUP pseudo ${groupMediaKey} active? ${isActive}, priority ${priority}`, {\n componentGroupPseudoState: { ...componentGroupPseudoState },\n usedKeys: { ...styleState.usedKeys },\n });\n }\n if (!isActive) {\n // ensure we set the defaults so animations work\n for (const pkey in mediaStyle) {\n applyDefaultStyle(pkey, styleState);\n }\n return;\n }\n importanceBump = priority;\n }\n }\n else if (isPlatformMedia) {\n // Platform styles use specificity-based importance bumps so that more\n // specific platform selectors reliably win over broader ones regardless\n // of prop declaration order (e.g. $platform-tv always overrides\n // $platform-native for the same property, even if tv is listed first).\n importanceBump = getPlatformSpecificityBump(mediaKeyShort);\n }\n const mediaOriginalValues = styleOriginalValues.get(mediaStyle);\n // extract transition from group pseudo styles (e.g., $group-scenario4-hover.transition)\n if (isGroupMedia && mediaStyle.transition) {\n styleState.pseudoTransitions || (styleState.pseudoTransitions = {});\n styleState.pseudoTransitions[`$${mediaKeyShort}`] = mediaStyle.transition;\n }\n function mergeMediaStyle(key, val, originalVal) {\n // on native, non-style keys from media queries (like numberOfLines)\n // need to go to viewProps, not style\n if (\"web\" === 'native') {\n if (!isValidStyleKey(key, validStyles, accept)) {\n viewProps[key] = val;\n return;\n }\n }\n styleState.style || (styleState.style = {});\n const didMerge = mergeMediaByImportance(styleState, mediaKeyShort, key, val, mediaState[mediaKeyShort], importanceBump, debug, originalVal);\n if (didMerge && key === 'fontFamily') {\n styleState.fontFamily = mediaStyle.fontFamily;\n }\n }\n for (const subKey in mediaStyle) {\n if (subKey === 'space') {\n continue;\n }\n if (subKey[0] === '$') {\n const subMediaType = getMediaKey(subKey);\n if (subMediaType === 'platform') {\n if (!isActivePlatform(subKey))\n continue;\n }\n else if (subMediaType === 'theme') {\n if (!isActiveTheme(subKey, themeName))\n continue;\n }\n else if (subMediaType === true) {\n // regular media query nested inside platform/theme/media\n const subKeyShort = subKey.slice(1);\n if (!mediaState[subKeyShort])\n continue;\n }\n const nestedVal = mediaStyle[subKey];\n const subOriginalValues = styleOriginalValues.get(nestedVal);\n // Nested styles are more specific than their outer context because\n // they require both conditions to be true. Calculate an importance\n // that is the sum of both the outer and inner importances so that:\n // 1) nested always beats non-nested\n // 2) $xs={{ $platform-android: ... }} and\n // $platform-android={{ $xs: ... }} produce identical importance\n // (last-declared wins for the same property)\n const isSizeMediaKey = !!mediaState[mediaKeyShort];\n const outerBase = isSizeMediaKey\n ? getMediaKeyImportance(mediaKeyShort)\n : defaultMediaImportance;\n let innerBase;\n if (subMediaType === 'platform') {\n innerBase =\n defaultMediaImportance + getPlatformSpecificityBump(subKey.slice(1));\n }\n else if (subMediaType === true) {\n innerBase = getMediaKeyImportance(subKey.slice(1));\n }\n else {\n innerBase = defaultMediaImportance;\n }\n const nestedImportance = outerBase + importanceBump + innerBase + 1;\n for (const subSubKey in nestedVal) {\n // expand shorthands, getSubStyle doesn't expand keys\n // inside nested $ objects (they pass through propMapper as-is)\n const expandedKey = shorthands[subSubKey] || subSubKey;\n const { usedKeys } = styleState;\n if (usedKeys[expandedKey] && usedKeys[expandedKey] > nestedImportance) {\n continue;\n }\n styleState.style || (styleState.style = {});\n mergeStyle(styleState, expandedKey, nestedVal[subSubKey], nestedImportance, false, subOriginalValues?.[subSubKey]);\n if (expandedKey === 'fontFamily') {\n styleState.fontFamily = nestedVal[subSubKey];\n }\n }\n }\n else {\n mergeMediaStyle(subKey, mediaStyle[subKey], mediaOriginalValues?.[subKey]);\n }\n }\n }\n return; // end media\n }\n // pass to view props\n if (!isVariant) {\n if (isStyledContextProp) {\n return;\n }\n viewProps[key] = val;\n }\n });\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n try {\n log(` ✔️ expand complete`, keyInit);\n log('style', { ...styleState.style });\n log('viewProps', { ...viewProps });\n log('transforms', { ...styleState.flatTransforms });\n }\n catch {\n // RN can run into PayloadTooLargeError: request entity too large\n }\n console.groupEnd();\n }\n } // end prop loop\n if (process.env.NODE_ENV === 'development' &&\n (debug === 'profile' || globalThis.time)) {\n // @ts-expect-error\n time `split-styles-propsend`;\n }\n // style prop after:\n const avoidNormalize = styleProps.noNormalize === false;\n if (!avoidNormalize) {\n if (styleState.style) {\n fixStyles(styleState.style);\n if (!styleProps.noExpand && !styleProps.noMergeStyle) {\n // shouldn't this be better? but breaks some tests weirdly, need to check\n if (isWeb && (isReactNative ? driver?.inputStyle !== 'css' : true)) {\n styleToCSS(styleState.style);\n }\n }\n }\n // these are only the flat transforms\n // always do this at the very end to preserve the order strictly (animations, origin)\n // and allow proper merging of all pseudos before applying\n if (styleState.flatTransforms) {\n // we need to match the order for animations to work because it needs consistent order\n // was thinking of having something like `state.prevTransformsOrder = ['y', 'x', ...]\n // but if we just handle it here its not a big cost and avoids having stateful things\n // so the strategy is: always sort by a consistent order, until you run into a \"duplicate\"\n // because you can have something like:\n // [{ translateX: 0 }, { scale: 1 }, { translateX: 10 }]\n // so basically we sort until we get to a duplicate... we could sort even smarter but\n // this should work for most (all?) of our cases since the order preservation really only needs to apply\n // to the \"flat\" transform props\n styleState.style || (styleState.style = {});\n mergeFlatTransforms(styleState.style, styleState.flatTransforms);\n }\n // add in defaults if not set:\n if (parentSplitStyles) {\n if (\"web\" === 'web') {\n if (shouldDoClasses) {\n for (const key in parentSplitStyles.classNames) {\n const val = parentSplitStyles.classNames[key];\n if ((styleState.style && key in styleState.style) || key in classNames)\n continue;\n classNames[key] = val;\n }\n }\n }\n if (!shouldDoClasses) {\n for (const key in parentSplitStyles.style) {\n if (key in classNames || (styleState.style && key in styleState.style))\n continue;\n styleState.style || (styleState.style = {});\n styleState.style[key] = parentSplitStyles.style[key];\n }\n }\n }\n }\n // Button for example uses disableClassName: true but renders to a 'button' element, so needs this\n if (\"web\" === 'web') {\n const shouldStringifyTransforms = !styleProps.noNormalize &&\n !staticConfig.isReactNative &&\n !staticConfig.isHOC &&\n (!styleProps.isAnimated || driver?.inputStyle === 'css');\n if (shouldStringifyTransforms && Array.isArray(styleState.style?.transform)) {\n styleState.style.transform = transformsToString(styleState.style.transform);\n }\n }\n if (\"web\" === 'web') {\n if (!styleProps.noMergeStyle && styleState.style && shouldDoClasses) {\n let retainedStyles;\n let shouldRetain = false;\n if (styleState.style['$$css']) {\n // avoid re-processing for rnw\n }\n else {\n const atomic = getCSSStylesAtomic(styleState.style);\n for (const atomicStyle of atomic) {\n const [key, value, identifier] = atomicStyle;\n const isAnimatedAndTransitionOnly = styleProps.isAnimated &&\n styleProps.noClass &&\n props.animateOnly?.includes(key);\n // animateOnly properties should always use className on server and initial\n // client render to avoid hydration mismatch (server has isAnimated=false but\n // client has isAnimated=true for CSS driver, causing different style output)\n const nonAnimatedTransitionOnly = !isAnimatedAndTransitionOnly &&\n !styleProps.isAnimated &&\n isClient &&\n driver?.outputStyle === 'css' &&\n props.animateOnly?.includes(key);\n if (isAnimatedAndTransitionOnly) {\n retainedStyles || (retainedStyles = {});\n retainedStyles[key] = styleState.style[key];\n }\n else if (nonAnimatedTransitionOnly) {\n retainedStyles || (retainedStyles = {});\n retainedStyles[key] = value;\n shouldRetain = true;\n }\n else {\n addStyleToInsertRules(rulesToInsert, atomicStyle);\n classNames[key] = identifier;\n }\n }\n if (process.env.NODE_ENV === 'development' && props.debug === 'verbose') {\n // console.groupEnd() // ensure group ended from loop above\n console.groupCollapsed(`🔹 getSplitStyles final style object`);\n console.info(styleState.style);\n console.info(`retainedStyles`, retainedStyles);\n console.groupEnd();\n }\n if (shouldRetain || !(process.env.IS_STATIC === 'is_static')) {\n styleState.style = retainedStyles || {};\n }\n }\n }\n // when noClass is true (inline animation driver) extract non-animatable\n // base styles to atomic CSS classNames so the driver doesn't manage them\n // skip for RNW animation drivers since their AnimatedView doesn't forward classNames\n if (!styleProps.noMergeStyle &&\n styleState.style &&\n !shouldDoClasses &&\n styleProps.isAnimated &&\n !driver?.isReactNative) {\n if (!styleState.style['$$css']) {\n const toConvert = {};\n let hasProps = false;\n const animateOnly = props.animateOnly;\n for (const key in styleState.style) {\n if (key in nonAnimatableStyleProps) {\n toConvert[key] = styleState.style[key];\n delete styleState.style[key];\n hasProps = true;\n }\n }\n if (hasProps) {\n const atomic = getCSSStylesAtomic(toConvert);\n for (const atomicStyle of atomic) {\n addStyleToInsertRules(rulesToInsert, atomicStyle);\n classNames[atomicStyle[StyleObjectProperty]] =\n atomicStyle[StyleObjectIdentifier];\n }\n }\n }\n }\n }\n // merge after the prop loop - and always keep it on style dont turn into className except if RN gives us\n const styleProp = props.style;\n if (!styleProps.noMergeStyle && styleProp) {\n if (isHOC) {\n viewProps.style = normalizeStyle(styleProp);\n }\n else {\n const isArray = Array.isArray(styleProp);\n const len = isArray ? styleProp.length : 1;\n for (let i = 0; i < len; i++) {\n const style = isArray ? styleProp[i] : styleProp;\n if (style) {\n if (style['$$css']) {\n Object.assign(styleState.classNames, style);\n }\n else {\n styleState.style || (styleState.style = {});\n const normalized = normalizeStyle(style);\n Object.assign(styleState.style, normalized);\n if (shouldTrackStyleTokenProvenance) {\n // the literal style prop is merged last and wins: carry its own\n // token provenance forward, and clear a prior token wherever it\n // supplies a literal (e.g. style={{ color: '#fff' }} over\n // color=\"$color9\" must stay a literal).\n const styleOriginals = styleOriginalValues.get(normalized);\n for (const k in normalized) {\n recordStyleTokenProvenance(styleState, k, styleOriginals?.[k]);\n }\n }\n }\n }\n }\n }\n }\n // native: swap out the right family based on weight/style\n if (\"web\" === 'native') {\n // set accessible when tabIndex is 0 (issue #3350)\n if (viewProps.tabIndex === 0) {\n viewProps.accessible ?? (viewProps.accessible = true);\n }\n const style = styleState.style;\n if (style?.fontFamily) {\n const faceInfo = getFont(style.fontFamily)?.face;\n if (faceInfo) {\n const overrideFace = faceInfo[style.fontWeight]?.[style.fontStyle || 'normal']?.val;\n if (overrideFace) {\n style.fontFamily = overrideFace;\n styleState.fontFamily = overrideFace;\n // If we pass both font family (e.g. InterBold) and a font weight (e.g. 900), android gets confused and just shows the default font, so we remove these:\n delete style.fontWeight;\n delete style.fontStyle;\n }\n }\n if (process.env.NODE_ENV === 'development' && debug && debug !== 'profile') {\n log(`Found fontFamily native: ${style.fontFamily}`, faceInfo);\n }\n }\n }\n if (process.env.NODE_ENV === 'development' &&\n (debug === 'profile' || globalThis.time)) {\n // @ts-expect-error\n time `split-styles-pre-result`;\n }\n // stamp exact token provenance onto the final winning style object. on native\n // (and non-className web) this is the same identity assigned to viewProps.style,\n // so a consumer inspecting the host node's style can recover the token + theme\n // behind each resolved value without any enumerable-key or RN-output change.\n if (shouldTrackStyleTokenProvenance && styleState.style && styleState.tokenProvenance) {\n const provenance = {};\n let hasProvenance = false;\n for (const key in styleState.tokenProvenance) {\n provenance[key] = { token: styleState.tokenProvenance[key], theme: themeName };\n hasProvenance = true;\n }\n if (hasProvenance) {\n setStyleTokenProvenance(styleState.style, provenance);\n }\n }\n const result = {\n hasMedia,\n fontFamily: styleState.fontFamily,\n viewProps,\n style: styleState.style,\n pseudos,\n classNames,\n rulesToInsert,\n dynamicThemeAccess,\n pseudoGroups,\n mediaGroups,\n overriddenContextProps: styleState.overriddenContextProps,\n pseudoTransitions: styleState.pseudoTransitions,\n };\n const asChildExceptStyleLike = asChild === 'except-style' || asChild === 'except-style-web';\n if (!styleProps.noMergeStyle) {\n if (!asChildExceptStyleLike) {\n const style = styleState.style;\n if (\"web\" === 'web') {\n // merge className and style back into viewProps:\n // only emit font class if fontFamily was explicitly in props (not from defaults)\n let fontFamily = isText || isInput ? styleState.fontFamily : null;\n if (fontFamily && fontFamily[0] === '$') {\n fontFamily = fontFamily.slice(1);\n }\n const fontFamilyClassName = fontFamily ? `font_${fontFamily}` : '';\n const groupClassName = props.group ? `t_group_${props.group}` : '';\n const componentNameFinal = props.componentName || staticConfig.componentName;\n const componentNameClassName = props.asChild || !componentNameFinal || componentNameFinal === 'Text'\n ? ''\n : `is_${componentNameFinal}`;\n let classList = [];\n if (componentNameClassName)\n classList.push(componentNameClassName);\n // is_View gets base flex styles + font reset, is_Text gets base text styles\n if (!isText)\n classList.push('is_View');\n else\n classList.push('is_Text');\n if (fontFamilyClassName)\n classList.push(fontFamilyClassName);\n if (classNames)\n classList.push(Object.values(classNames).join(' '));\n if (groupClassName)\n classList.push(groupClassName);\n if (props.className)\n classList.push(props.className);\n const finalClassName = classList.join(' ');\n // use $$css for RNW components OR when animated with RNW driver\n // (driver's AnimatedView doesn't forward className)\n const needsCssStyles = isReactNative || (styleProps.isAnimated && driver?.isReactNative);\n if (styleProps.isAnimated && driver?.inputStyle === 'css') {\n // CSS animation driver uses className directly\n viewProps.className = finalClassName;\n if (style) {\n viewProps.style = style;\n }\n }\n else if (needsCssStyles) {\n // RNW or RNW-animated: apply classNames via $$css\n let cnStyles;\n for (const name of finalClassName.split(' ')) {\n cnStyles || (cnStyles = { $$css: true });\n cnStyles[name] = name;\n }\n viewProps.style = cnStyles\n ? [...(Array.isArray(style) ? style : [style]), cnStyles]\n : [style];\n }\n else {\n // regular web: use className directly\n if (finalClassName) {\n viewProps.className = finalClassName;\n }\n if (style) {\n viewProps.style = style;\n }\n }\n }\n else {\n if (style) {\n // native assign styles\n viewProps.style = style;\n }\n }\n }\n }\n if (process.env.NODE_ENV === 'development' && debug === 'verbose') {\n if (isClient && isDevTools) {\n // end collapsed log above\n console.groupEnd();\n console.groupCollapsed('🔹 getSplitStyles ===>');\n try {\n // prettier-ignore\n const logs = {\n ...result,\n className,\n componentState,\n viewProps,\n rulesToInsert,\n parentSplitStyles,\n };\n for (const key in logs) {\n log(key, logs[key]);\n }\n }\n catch {\n // RN can run into PayloadTooLargeError: request entity too large\n }\n console.groupEnd();\n }\n }\n if (process.env.NODE_ENV === 'development' &&\n (debug === 'profile' || globalThis.time)) {\n // @ts-expect-error\n time `split-styles-done`;\n }\n return result;\n};\nfunction mergeFlatTransforms(target, flatTransforms) {\n Object.entries(flatTransforms)\n .sort(([a], [b]) => sortString(a, b))\n .forEach(([key, val]) => {\n mergeTransform(target, key, val, true);\n });\n}\nfunction mergeStyle(styleState, key, val, importance, disableNormalize = false, originalVal) {\n const { viewProps, styleProps, staticConfig, usedKeys } = styleState;\n const existingImportance = usedKeys[key] || 0;\n if (existingImportance > importance) {\n return;\n }\n // track context overrides for pseudo/media styles (issues #3670, #3676)\n // when a style sets a key that's in context props, update overriddenContextProps\n // so it propagates to children. use the original token value (like '$8')\n // instead of the resolved CSS variable (like 'var(--t-space-8)')\n // so children's functional variants can look up token values.\n const contextProps = staticConfig.context?.props || staticConfig.parentStaticConfig?.context?.props;\n if (contextProps && key in contextProps) {\n styleState.overriddenContextProps || (styleState.overriddenContextProps = {});\n // Priority: 1) originalVal from propMapper, 2) tracked original from variant resolution, 3) val\n const originalFromState = styleState.originalContextPropValues?.[key];\n styleState.overriddenContextProps[key] = originalVal ?? originalFromState ?? val;\n }\n if (key in stylePropsTransform) {\n styleState.flatTransforms || (styleState.flatTransforms = {});\n usedKeys[key] = importance;\n styleState.flatTransforms[key] = val;\n }\n else {\n const shouldNormalize = isWeb && !disableNormalize && !styleProps.noNormalize;\n const out = shouldNormalize ? normalizeValueWithProperty(val, key) : val;\n if (\n // accept is for props not styles\n staticConfig.accept &&\n key in staticConfig.accept) {\n viewProps[key] = out;\n }\n else {\n styleState.style || (styleState.style = {});\n usedKeys[key] = importance;\n styleState.style[key] =\n // if you dont do this you'll be passing props.transform arrays directly here and then mutating them\n // if theres any flatTransforms later, causing issues (mutating props is bad, in strict mode styles get borked)\n key === 'transform' && Array.isArray(out) ? [...out] : out;\n if (shouldTrackStyleTokenProvenance) {\n // dev-tools token provenance: this write is the current winner for `key`\n // (importance-gated above), so record the token that produced it, or clear\n // a prior token when a literal wins, keeping literal-over-token exact.\n recordStyleTokenProvenance(styleState, key, originalVal);\n }\n }\n }\n}\n// track which token produced the winning value for a style key so the final\n// style object can expose exact provenance. only the base (painted) style is\n// tracked — pseudo/media writes flow through mergeStyle at their real importance,\n// and a literal override clears any earlier token for that key.\nfunction recordStyleTokenProvenance(styleState, key, originalVal) {\n if (typeof originalVal === 'string' && originalVal[0] === '$') {\n ;\n (styleState.tokenProvenance || (styleState.tokenProvenance = {}))[key] = originalVal;\n }\n else if (styleState.tokenProvenance && key in styleState.tokenProvenance) {\n delete styleState.tokenProvenance[key];\n }\n}\nexport const getSubStyle = (styleState, subKey, styleIn, avoidMergeTransform) => {\n const { staticConfig, conf, styleProps } = styleState;\n const styleOut = {};\n let originalValues;\n const styleInOriginalValues = styleOriginalValues.get(styleIn);\n const parentProps = styleState.props;\n styleState.props = { ...parentProps, ...styleIn };\n try {\n for (let key in styleIn) {\n const val = styleIn[key];\n key = conf.shorthands[key] || key;\n // extract transition from pseudo-style props (e.g., hoverStyle.transition)\n // store it separately for animation drivers to use for enter/exit timing\n if (key === 'transition') {\n styleState.pseudoTransitions || (styleState.pseudoTransitions = {});\n styleState.pseudoTransitions[subKey] = val;\n // for CSS driver, also add transition to CSS output so native CSS transitions work\n // group styles ($group-*) need !important to override inline base transition\n const driver = styleState.animationDriver;\n if (driver?.outputStyle === 'css') {\n const animationConfig = driver.animations?.[val];\n if (animationConfig) {\n const important = subKey[0] === '$' ? ' !important' : '';\n styleOut['transition'] = `all ${animationConfig}${important}`;\n }\n }\n // not a known animation name, pass through as raw CSS\n if (!styleOut['transition'] &&\n typeof val === 'string' &&\n !driver?.animations?.[val]) {\n styleOut['transition'] = val;\n }\n continue;\n }\n const shouldSkip = !staticConfig.isHOC && key in skipProps && !styleProps.noSkip;\n if (shouldSkip) {\n continue;\n }\n propMapper(key, val, styleState, false, (skey, sval, originalVal) => {\n // track original values for context prop propagation\n const trackedOriginalVal = styleInOriginalValues?.[skey] ?? originalVal;\n if (trackedOriginalVal !== undefined) {\n originalValues || (originalValues = {});\n originalValues[skey] = trackedOriginalVal;\n }\n // pseudo inside media\n if (skey in validPseudoKeys) {\n sval = getSubStyle(styleState, skey, sval, avoidMergeTransform);\n }\n if (!avoidMergeTransform && skey in stylePropsTransform) {\n mergeTransform(styleOut, skey, sval);\n }\n else {\n styleOut[skey] = styleProps.noNormalize\n ? sval\n : normalizeValueWithProperty(sval, key);\n }\n });\n }\n }\n finally {\n styleState.props = parentProps;\n }\n if (!avoidMergeTransform) {\n const parentTransform = styleState.style?.transform;\n const flatTransforms = styleState.flatTransforms;\n const styleOutTransform = styleOut.transform;\n if (Array.isArray(styleOutTransform) && styleOutTransform.length) {\n // Inline conflict check - faster than building lookup object for small arrays\n const len = styleOutTransform.length;\n if (Array.isArray(parentTransform)) {\n const merged = [];\n outer: for (let i = 0; i < parentTransform.length; i++) {\n const pt = parentTransform[i];\n for (const pk in pt) {\n for (let j = 0; j < len; j++) {\n for (const sk in styleOutTransform[j]) {\n if (pk === sk)\n continue outer;\n break;\n }\n }\n merged.push(pt);\n break;\n }\n }\n for (let i = 0; i < len; i++)\n merged.push(styleOutTransform[i]);\n styleOut.transform = merged;\n }\n if (flatTransforms) {\n outer: for (const fk in flatTransforms) {\n const ck = fk === 'x' ? 'translateX' : fk === 'y' ? 'translateY' : fk;\n for (let j = 0; j < len; j++) {\n for (const sk in styleOutTransform[j]) {\n if (ck === sk)\n continue outer;\n break;\n }\n }\n mergeTransform(styleOut, fk, flatTransforms[fk]);\n }\n }\n }\n else if (flatTransforms) {\n mergeFlatTransforms(styleOut, flatTransforms);\n }\n }\n if (!styleProps.noNormalize) {\n fixStyles(styleOut);\n }\n // Store original values in WeakMap instead of on the object itself\n if (originalValues && Object.keys(originalValues).length) {\n styleOriginalValues.set(styleOut, originalValues);\n }\n return styleOut;\n};\n// on native no need to insert any css\nconst useInsertEffectCompat = isWeb\n ? React.useInsertionEffect || useIsomorphicLayoutEffect\n : () => { };\n// perf: ...args a bit expensive on native\nexport const useSplitStyles = (a, b, c, d, e, f, g, h, i, j, k, l, m) => {\n 'use no memo';\n const res = getSplitStyles(a, b, c, d, e, f, g, h, i, j, k, l, m);\n if (\"web\" !== 'native') {\n useInsertEffectCompat(() => {\n if (res) {\n insertStyleRules(res.rulesToInsert);\n }\n }, [res?.rulesToInsert]);\n }\n return res;\n};\nfunction addStyleToInsertRules(rulesToInsert, styleObject) {\n if (\"web\" === 'web') {\n const identifier = styleObject[StyleObjectIdentifier];\n if (shouldInsertStyleRules(identifier)) {\n updateRules(identifier, styleObject[StyleObjectRules]);\n rulesToInsert[identifier] = styleObject;\n }\n }\n}\nconst defaultColor = process.env.GUI_DEFAULT_COLOR || 'rgba(0,0,0,0)';\nconst animatableDefaults = {\n ...Object.fromEntries(Object.entries(tokenCategories.color).map(([k, v]) => [k, defaultColor])),\n opacity: 1,\n scale: 1,\n scaleX: 1,\n scaleY: 1,\n rotate: '0deg',\n rotateX: '0deg',\n rotateY: '0deg',\n rotateZ: '0deg',\n skewX: '0deg',\n skewY: '0deg',\n x: 0,\n y: 0,\n borderRadius: 0,\n};\nconst mergeTransform = (obj, key, val, backwards = false) => {\n if (typeof obj.transform === 'string') {\n return;\n }\n obj.transform || (obj.transform = []);\n obj.transform[backwards ? 'unshift' : 'push']({\n [mapTransformKeys[key] || key]: val,\n });\n};\nconst mapTransformKeys = {\n x: 'translateX',\n y: 'translateY',\n};\nfunction passDownProp(viewProps, key, val, shouldMergeObject = false) {\n if (shouldMergeObject) {\n const next = {\n ...viewProps[key],\n ...val,\n };\n // need to re-insert it at current position\n delete viewProps[key];\n viewProps[key] = next;\n }\n else {\n viewProps[key] = val;\n }\n}\nfunction mergeMediaByImportance(styleState, mediaKey, key, value, isSizeMedia, importanceBump, debugProp, originalVal) {\n const usedKeys = styleState.usedKeys;\n let importance = getMediaImportanceIfMoreImportant(mediaKey, key, styleState, isSizeMedia);\n if (importanceBump) {\n // With a specificity bump, the effective importance is always\n // defaultMediaImportance + bump. This lets higher-specificity styles\n // (e.g. $platform-tv > $platform-native) override lower-specificity ones\n // regardless of prop declaration order, even when getMediaImportanceIfMoreImportant\n // returns null (meaning the same base importance was already applied).\n //\n // We must re-check `usedKeys[key]` here (rather than relying on the null\n // returned by getMediaImportanceIfMoreImportant) because that function only\n // compares against `defaultMediaImportance`, which equals our base before\n // the bump. We need to compare against the *bumped* value to correctly\n // allow a more-specific style to win.\n const bumpedImportance = defaultMediaImportance + importanceBump;\n importance =\n !usedKeys[key] || bumpedImportance > usedKeys[key] ? bumpedImportance : null;\n }\n if (process.env.NODE_ENV === 'development' && debugProp === 'verbose') {\n log(`mergeMediaByImportance ${key} importance usedKey ${usedKeys[key]} next ${importance}`);\n }\n if (importance === null) {\n return false;\n }\n if (key in pseudoDescriptors) {\n const descriptor = pseudoDescriptors[key];\n const descriptorKey = descriptor.stateKey || descriptor.name;\n const isDisabled = styleState.componentState[descriptorKey] === false;\n if (isDisabled) {\n return false;\n }\n // For pseudo inside media, value is an object with subkeys\n const pseudoOriginalValues = styleOriginalValues.get(value);\n for (const subKey in value) {\n mergeStyle(styleState, subKey, value[subKey], importance, false, pseudoOriginalValues?.[subKey]);\n }\n }\n else {\n mergeStyle(styleState, key, value, importance, false, originalVal);\n }\n return true;\n}\nfunction normalizeStyle(style) {\n const out = {};\n for (const key in style) {\n const val = style[key];\n if (key in stylePropsTransform) {\n mergeTransform(out, key, val);\n }\n else {\n out[key] = normalizeValueWithProperty(val, key);\n }\n }\n if (isWeb && Array.isArray(out.transform)) {\n out.transform = transformsToString(out.transform);\n }\n fixStyles(out);\n return out;\n}\nfunction applyDefaultStyle(pkey, styleState) {\n const defaultValues = animatableDefaults[pkey];\n if (defaultValues != null &&\n !(pkey in styleState.usedKeys) &&\n (!styleState.style || !(pkey in styleState.style))) {\n mergeStyle(styleState, pkey, defaultValues, 1);\n }\n}\n//# sourceMappingURL=getSplitStyles.js.map","import { composeRefs } from '@hanzogui/compose-refs';\nimport { composeEventHandlers } from '@hanzogui/helpers';\nconst isEventHandler = /^on[A-Z]/;\n/**\n * Merges props with special handling for style, className, ref, and event handlers.\n * Used by Slot and render prop implementations.\n *\n * @param base - Base props (typically from parent/slot)\n * @param overlay - Props to merge on top (typically from child/element)\n * @returns Merged props object (mutates and returns base for perf)\n */\nexport function mergeSlotStyleProps(base, overlay) {\n for (const key in overlay) {\n const baseVal = base[key];\n const overlayVal = overlay[key];\n if (overlayVal === undefined)\n continue;\n if (key === 'style') {\n base.style =\n baseVal && overlayVal ? { ...baseVal, ...overlayVal } : overlayVal || baseVal;\n }\n else if (key === 'className') {\n base.className =\n baseVal && overlayVal ? `${baseVal} ${overlayVal}` : overlayVal || baseVal;\n }\n else if (key === 'ref') {\n base.ref =\n baseVal && overlayVal ? composeRefs(baseVal, overlayVal) : overlayVal || baseVal;\n }\n else if (isEventHandler.test(key) &&\n typeof baseVal === 'function' &&\n typeof overlayVal === 'function') {\n base[key] = composeEventHandlers(baseVal, overlayVal);\n }\n else {\n // overlay wins for regular props\n base[key] = overlayVal;\n }\n }\n return base;\n}\n//# sourceMappingURL=mergeSlotStyleProps.js.map","import { mergeSlotStyleProps } from './mergeSlotStyleProps.js';\n/**\n * Merges props from a render element with viewProps from Gui.\n * viewProps takes precedence, elementProps provides fallbacks.\n * Style/className are merged, refs and event handlers are composed.\n */\nexport function mergeRenderElementProps(elementProps, viewProps, children) {\n // elementProps as base, viewProps as overlay (viewProps wins)\n const merged = mergeSlotStyleProps({ ...elementProps }, viewProps);\n merged.children = children;\n return merged;\n}\n//# sourceMappingURL=mergeRenderElementProps.js.map","/**\n * Web pointer events - no-op, pointer events work natively on web\n *\n * For drag scenarios, users should call e.target.setPointerCapture(e.pointerId)\n * in their onPointerDown handler to receive move events outside element bounds.\n */\nexport function usePointerEvents(_props, _viewProps) {\n // pointer events pass through directly on web\n}\n//# sourceMappingURL=pointerEvents.js.map","/**\n * Resolves the effective transition based on pseudo state changes.\n * When entering a pseudo state (e.g., hover), use that pseudo's transition.\n * When exiting (returning to base), use the base transition.\n *\n * CSS-like semantics:\n * - Enter hover: Uses hover's transition (fast snap)\n * - Exit hover: Uses base transition (slow fade)\n */\nexport function resolveEffectivePseudoTransition(prev, next, pseudoTransitions, baseTransition) {\n if (!pseudoTransitions) {\n return baseTransition;\n }\n // treat undefined prev as all-false so first interaction detects entering\n const prevState = prev || { hover: false, press: false, focus: false, groups: {} };\n // check which pseudo states are being entered (priority: press > hover > focus)\n if (next.press && !prevState.press && pseudoTransitions.pressStyle) {\n return pseudoTransitions.pressStyle;\n }\n if (next.hover && !prevState.hover && pseudoTransitions.hoverStyle) {\n return pseudoTransitions.hoverStyle;\n }\n if (next.focus && !prevState.focus && pseudoTransitions.focusStyle) {\n return pseudoTransitions.focusStyle;\n }\n // check group pseudo transitions (e.g., $group-scenario4-hover)\n for (const key in pseudoTransitions) {\n if (key.startsWith('$group-')) {\n // parse $group-{name}-{pseudo} format\n const match = key.match(/^\\$group-(.+)-(hover|press|focus)$/);\n if (!match)\n continue;\n const groupName = match[1];\n const pseudoType = match[2];\n // get current and previous group pseudo state\n const nextGroupPseudo = next.group?.[groupName]?.pseudo;\n const prevGroupPseudo = prevState.groups?.[groupName];\n // check if entering this group pseudo state\n if (nextGroupPseudo?.[pseudoType] && !prevGroupPseudo?.[pseudoType]) {\n return pseudoTransitions[key];\n }\n }\n }\n // exiting uses base transition\n return baseTransition;\n}\n/**\n * Extracts pseudo state from GuiComponentState for storage in prevPseudoState\n */\nexport function extractPseudoState(state) {\n const groups = {};\n if (state.group) {\n for (const groupName in state.group) {\n const pseudo = state.group[groupName]?.pseudo;\n if (pseudo) {\n groups[groupName] = {\n hover: pseudo.hover,\n press: pseudo.press,\n focus: pseudo.focus,\n };\n }\n }\n }\n return {\n hover: state.hover,\n press: state.press,\n focus: state.focus,\n groups,\n };\n}\n//# sourceMappingURL=pseudoTransitions.js.map","export const hooks = {};\n// internal hooks setup\nexport function setupHooks(next) {\n Object.assign(hooks, next);\n}\n//# sourceMappingURL=setupHooks.js.map","import { hooks } from '../setupHooks.js';\nexport const setElementProps = (node) => {\n hooks.setElementProps?.(node);\n};\n//# sourceMappingURL=setElementProps.js.map","import { mergeIfNotShallowEqual } from '@hanzogui/is-equal-shallow';\nimport { getMediaState } from '../hooks/useMedia.js';\nexport const subscribeToContextGroup = (props) => {\n const { pseudoGroups, mediaGroups, groupContext } = props;\n if (pseudoGroups || mediaGroups) {\n if (process.env.NODE_ENV === 'development' && !groupContext) {\n console.debug(`No context group found`);\n }\n const disposables = new Set();\n if (pseudoGroups) {\n for (const name of pseudoGroups) {\n disposables.add(createGroupListener(name, props));\n }\n }\n if (mediaGroups) {\n for (const name of mediaGroups) {\n disposables.add(createGroupListener(name, props));\n }\n }\n return () => {\n disposables.forEach((d) => d());\n };\n }\n};\nconst createGroupListener = (name, { setStateShallow, pseudoGroups, mediaGroups, groupContext, }) => {\n const parent = groupContext?.[name];\n if (!parent) {\n return () => { };\n }\n const dispose = parent.subscribe(({ layout, pseudo }) => {\n setStateShallow((prev) => {\n let didChange = false;\n const group = prev.group?.[name] || {\n pseudo: {},\n media: {},\n };\n if (pseudo && pseudoGroups?.has(name)) {\n group.pseudo || (group.pseudo = {});\n const next = mergeIfNotShallowEqual(group.pseudo, pseudo);\n if (next !== group.pseudo) {\n Object.assign(group.pseudo, pseudo);\n didChange = true;\n }\n }\n else if (layout && mediaGroups) {\n group.media || (group.media = {});\n const mediaState = getMediaState(mediaGroups, layout);\n const next = mergeIfNotShallowEqual(group.media, mediaState);\n if (next !== group.media) {\n Object.assign(group.media, next);\n didChange = true;\n }\n }\n if (didChange) {\n return {\n group: {\n ...prev.group,\n [name]: group,\n },\n };\n }\n return prev;\n });\n });\n return () => {\n dispose();\n // we no longer have any active group, need to remove state so the style updates\n setStateShallow({\n group: {},\n });\n };\n};\n//# sourceMappingURL=subscribeToContextGroup.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { createContext, useContext } from 'react';\nexport const ClientOnlyContext = createContext(false);\nexport const ClientOnly = ({ children, enabled, }) => {\n const existingValue = useContext(ClientOnlyContext);\n return (_jsx(ClientOnlyContext.Provider, { value: enabled ?? existingValue, children: children }));\n};\n//# sourceMappingURL=ClientOnly.js.map","import * as React from 'react';\nimport { ClientOnlyContext } from './ClientOnly.js';\nexport { ClientOnly, ClientOnlyContext } from './ClientOnly.js';\nexport const useIsClientOnly = () => {\n return React.useContext(ClientOnlyContext);\n};\nexport function useDidFinishSSR() {\n const clientOnly = React.useContext(ClientOnlyContext);\n if (clientOnly || \"web\" === 'native') {\n return true;\n }\n return React.useSyncExternalStore(subscribe, () => true, () => false);\n}\nconst subscribe = () => () => { };\nexport function useClientValue(value) {\n const done = useDidFinishSSR();\n // @ts-expect-error this is fine but started to error in ts latest\n return !done ? undefined : typeof value === 'function' ? value() : value;\n}\n//# sourceMappingURL=index.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { isWeb } from '@hanzogui/constants';\nimport React, { Children, cloneElement, forwardRef, isValidElement, useRef } from 'react';\nimport { variableToString } from '../createVariable.js';\nimport { useThemeWithState } from '../hooks/useTheme.js';\nimport { getThemeState, hasThemeUpdatingProps, ThemeStateContext, } from '../hooks/useThemeState.js';\nimport { ThemeDebug } from './ThemeDebug.js';\nexport const Theme = forwardRef(function Theme(props, ref) {\n 'use no memo';\n // @ts-expect-error only for internal views\n if (props.disable) {\n return props.children;\n }\n const { passThrough } = props;\n const isRoot = !!props['_isRoot'];\n // pass forThemeView=true so the descendant-cascade effect is installed —\n // <Theme> pushes themeState.id into ThemeStateContext, so children subscribe\n // under this id and need to be notified when our propsKey changes.\n const [_, themeState] = useThemeWithState(props, isRoot, true);\n const disableDirectChildTheme = props['disable-child-theme'];\n let finalChildren = disableDirectChildTheme\n ? Children.map(props.children, (child) => passThrough || !isValidElement(child)\n ? child\n : cloneElement(child, { ['data-disable-theme']: true }))\n : props.children;\n if (ref) {\n try {\n React.Children.only(finalChildren);\n // TODO deprecate react 18 and then avoid clone here and just pass prop\n finalChildren = cloneElement(finalChildren, { ref });\n }\n catch {\n //ok\n }\n }\n const stateRef = useRef({\n hasEverThemed: false,\n });\n return getThemedChildren(themeState, finalChildren, props, isRoot, stateRef, passThrough);\n});\nTheme['avoidForwardRef'] = true;\nexport function getThemedChildren(themeState, children, props, isRoot = false, stateRef, passThrough = false) {\n const { shallow, forceClassName } = props;\n // always be true if ever themed so we avoid re-parenting\n const state = stateRef.current;\n let hasEverThemed = state.hasEverThemed;\n let shouldRenderChildrenWithTheme = hasEverThemed || themeState.isNew || isRoot || hasThemeUpdatingProps(props);\n if (process.env.NODE_ENV === 'development' && props.debug === 'visualize') {\n children = (_jsx(ThemeDebug, { themeState: themeState, themeProps: props, children: children }));\n }\n if (!shouldRenderChildrenWithTheme) {\n return children;\n }\n // from here on out we have to be careful not to re-parent\n children = (_jsx(ThemeStateContext.Provider, { value: themeState.id, children: children }));\n const { isInverse, name } = themeState;\n const requiresExtraWrapper = isInverse || forceClassName;\n // it only ever progresses from false => true => 'wrapped'\n if (!state.hasEverThemed) {\n state.hasEverThemed = true;\n }\n if (requiresExtraWrapper ||\n // if the theme is exactly dark or light, its likely to change between dark/light\n // and that would require wrapping which would re-parent, so to avoid re-parenting do this\n themeState.name === 'dark' ||\n themeState.name === 'light') {\n state.hasEverThemed = 'wrapped';\n }\n // each children of these children wont get the theme\n if (shallow) {\n if (!themeState.parentId) {\n // they are doing shallow but didnt change actually change a theme theme?\n }\n else {\n const parentState = getThemeState(themeState.isNew ? themeState.id : themeState.parentId);\n if (!parentState)\n throw new Error(`‼️010`);\n children = Children.toArray(children).map((child) => {\n return isValidElement(child)\n ? passThrough\n ? child\n : cloneElement(child, undefined, _jsx(Theme, { name: parentState.name, children: child.props.children }))\n : child;\n });\n }\n }\n if (process.env.NODE_ENV === 'development') {\n if (!passThrough && props.debug) {\n console.warn(` getThemedChildren`, {\n requiresExtraWrapper,\n forceClassName,\n themeState,\n state,\n themeSpanProps: getThemeClassNameAndColor(themeState, props, isRoot),\n });\n }\n }\n // this has to be after a few of the above items so it properly sets context (even if shallow set)\n if (forceClassName === false) {\n return children;\n }\n if (isWeb) {\n const baseStyle = props.contain ? inertContainedStyle : inertStyle;\n const { className = '', color } = passThrough\n ? {}\n : getThemeClassNameAndColor(themeState, props, isRoot);\n children = (_jsx(\"span\", { className: `${className} is_Theme`, style: passThrough ? baseStyle : { color, ...baseStyle }, children: children }));\n // to prevent tree structure changes always render this if inverse is true or false\n if (state.hasEverThemed === 'wrapped') {\n // but still calculate if we need the classnames\n const className = requiresExtraWrapper\n ? `${name.startsWith('light') ? 't_light' : name.startsWith('dark') ? 't_dark' : ''} _dsp_contents`\n : `_dsp_contents`;\n children = _jsx(\"span\", { className: className, children: children });\n }\n return children;\n }\n return children;\n}\nconst inertStyle = {\n display: 'contents',\n};\nconst inertContainedStyle = {\n display: 'contents',\n contain: 'strict',\n};\nconst empty = { className: '', color: undefined };\nfunction getThemeClassNameAndColor(themeState, props, isRoot = false) {\n if (!themeState.isNew && !props.forceClassName) {\n return empty;\n }\n // in order to provide currentColor, set color by default\n const themeColor = themeState?.theme && themeState.isNew ? variableToString(themeState.theme.color) : '';\n const style = themeColor\n ? {\n color: themeColor,\n }\n : undefined;\n const themeClassName = themeState.name.replace(schemePrefix, '');\n // Build full hierarchy of theme classes for CSS variable inheritance\n // Examples:\n // - \"red_surface1\" → \"t_red t_red_surface1\"\n // - \"green_active_Button\" → \"t_green t_green_active t_green_active_Button\"\n const themeNameParts = themeClassName.split('_');\n let themeClasses = `t_${themeClassName}`;\n if (themeNameParts.length > 1) {\n // Build full hierarchy for all multi-part themes (sub-themes, component themes, etc.)\n // This enables CSS variable inheritance through all levels\n const hierarchyClasses = [];\n for (let i = 1; i <= themeNameParts.length; i++) {\n hierarchyClasses.push(`t_${themeNameParts.slice(0, i).join('_')}`);\n }\n themeClasses = hierarchyClasses.join(' ');\n }\n const className = `${isRoot ? '' : 't_sub_theme'} ${themeClasses}`;\n return { color: themeColor, className };\n}\nconst schemePrefix = /^(dark|light)_/;\n//# sourceMappingURL=Theme.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport React from 'react';\nimport { Theme } from '../views/Theme.js';\nimport { getDefaultProps } from './getDefaultProps.js';\nexport function themeable(Component, staticConfig, optimize = false) {\n const withThemeComponent = React.forwardRef(function WithTheme(props, ref) {\n 'use no memo';\n const userDefaults = getDefaultProps(staticConfig, props.componentName);\n const defaultTheme = userDefaults?.theme;\n const defaultResetTheme = userDefaults?.themeReset;\n const { theme, componentName, themeReset, ...rest } = props;\n let overriddenContextProps;\n const context = staticConfig?.context;\n if (context) {\n for (const key in context.props) {\n const val = props[key];\n if (val !== undefined) {\n overriddenContextProps = overriddenContextProps || {};\n overriddenContextProps[key] = val;\n }\n }\n }\n const element = (_jsx(Component, { ref: ref, ...rest, \"data-disable-theme\": true }));\n // we filter out the props here, why?\n // Theme internally avoids wrapping <span /> unless 'theme' in props\n // reason for this is to avoid wrapping every single component with span\n // *if* ever it themes once, it leaves the span, to avoid reparenting\n // its expected if users want to avoid re-parenting, they keep the theme prop\n // and just set it to null. but we need to \"respect\" that here by filtering\n // one example of a bug caused by not doing this is in <Select native> on web\n // where it renders to an <option />, and then Theme would wrap a <span /> in that\n // which is not allowed in HTML and causes hydration errors / logs\n let filteredProps = null;\n const compName = componentName || staticConfig?.componentName;\n if (compName) {\n filteredProps = filteredProps || {};\n filteredProps.componentName = compName;\n }\n if ('debug' in props) {\n filteredProps = filteredProps || {};\n filteredProps.debug = props.debug;\n }\n if ('theme' in props || defaultTheme) {\n filteredProps = filteredProps || {};\n filteredProps.name = 'theme' in props ? props.theme : defaultTheme;\n }\n if ('themeReset' in props || defaultResetTheme) {\n filteredProps = filteredProps || {};\n filteredProps.reset = 'themeReset' in props ? themeReset : defaultResetTheme;\n }\n if (optimize && !filteredProps) {\n // optimize by avoiding theme! this can re-parent but we should just document that to avoid performance\n // in cases where you remove/add themes, just keep a theme={x ? '' : null} pattern\n return element;\n }\n let contents = (_jsx(Theme, { \"disable-child-theme\": true, ...filteredProps, children: element }));\n if (context) {\n const Provider = context.Provider;\n const contextValue = React.useContext(context);\n contents = (_jsx(Provider, { ...contextValue, ...overriddenContextProps, children: contents }));\n }\n return contents;\n });\n const withTheme = withThemeComponent;\n withTheme.displayName = `Themed(${Component?.displayName || Component?.name || 'Anonymous'})`;\n return withTheme;\n}\n//# sourceMappingURL=themeable.js.map","import { Fragment as _Fragment, jsx as _jsx } from \"react/jsx-runtime\";\nimport { StyleObjectIdentifier, StyleObjectRules } from '@hanzogui/helpers';\n// turns out this is pretty slow, creating a bunch of extra tags...\nconst styleTagCache = new Map();\nlet clearStyleTagCacheQueued = false;\nfunction queueStyleTagCacheClear() {\n if (clearStyleTagCacheQueued)\n return;\n clearStyleTagCacheQueued = true;\n queueMicrotask(() => {\n styleTagCache.clear();\n clearStyleTagCacheQueued = false;\n });\n}\nfunction getCachedStyleTag(styleObject) {\n const identifier = styleObject[StyleObjectIdentifier];\n const rules = styleObject[StyleObjectRules];\n const cached = styleTagCache.get(identifier);\n if (cached &&\n cached.len === rules.length &&\n cached.first === rules[0] &&\n cached.last === rules[rules.length - 1]) {\n return cached.element;\n }\n const element = (_jsx(\"style\", { \n // @ts-ignore\n href: `t_${identifier}`, \n // @ts-ignore\n precedence: \"default\", \n // we remove after first render in favor of inserting to a global stylesheet (faster)\n suppressHydrationWarning: true, children: rules.join('\\n') }, identifier));\n styleTagCache.set(identifier, {\n element,\n len: rules.length,\n first: rules[0],\n last: rules[rules.length - 1],\n });\n return element;\n}\nexport function getStyleTags(styles) {\n if (\"web\" !== 'native') {\n if (styles.length) {\n queueStyleTagCacheClear();\n return _jsx(_Fragment, { children: styles.map(getCachedStyleTag) });\n }\n }\n}\n//# sourceMappingURL=wrapStyleTags.js.map","import { getPlatformDriver, isServer, isWeb } from '@hanzogui/constants';\nimport { mergeIfNotShallowEqual } from '@hanzogui/is-equal-shallow';\nimport { useDidFinishSSR, useIsClientOnly } from '@hanzogui/use-did-finish-ssr';\nimport { useRef, useState } from 'react';\nimport { getSetting } from '../config.js';\nimport { defaultComponentState, defaultComponentStateMounted, defaultComponentStateShouldEnter, } from '../defaultComponentState.js';\nimport { isObj } from '../helpers/isObj.js';\nimport { log } from '../helpers/log.js';\nexport const useComponentState = (props, animationDriver, staticConfig, config) => {\n 'use no memo';\n const isHydrated = useDidFinishSSR();\n const needsHydration = !useIsClientOnly();\n const useAnimations = animationDriver?.isStub\n ? undefined\n : animationDriver?.useAnimations;\n const { isHOC } = staticConfig;\n const stateRef = useRef(\n // performance: avoid creating object every render\n undefined);\n if (!stateRef.current) {\n stateRef.current = {\n startedUnhydrated: needsHydration && !isHydrated,\n };\n }\n // after we get states mount we need to turn off isAnimated for server side\n const hasAnimationProp = Boolean((!isHOC && 'transition' in props) ||\n (props.style && hasAnimatedStyleValue(props.style)));\n const inputStyle = animationDriver?.inputStyle ?? 'css';\n const outputStyle = animationDriver?.outputStyle ?? 'css';\n const curStateRef = stateRef.current;\n if (!needsHydration && hasAnimationProp) {\n curStateRef.hasAnimated = true;\n }\n // a renderer platform driver with native pseudo states (react-native-gpui)\n // makes ANY component with runtime pseudo styles ride the animation-driver\n // emitter path — no per-site transition/animation prop required. the flip is\n // driver-sourced (hover) or event-sourced (press/focus) but either way applies\n // through the emitter with zero React commits; with no transition declared it\n // resolves instant (see createComponent's effectiveTransition default).\n const platformPseudo = Boolean(!isHOC &&\n useAnimations &&\n animationDriver?.avoidReRenders &&\n getPlatformDriver()?.pseudo &&\n ('hoverStyle' in props || 'pressStyle' in props || 'focusStyle' in props));\n const willBeAnimatedClient = (() => {\n const next = !!((hasAnimationProp || platformPseudo) && !isHOC && useAnimations);\n return Boolean(next || curStateRef.hasAnimated);\n })();\n const willBeAnimated = !isServer && willBeAnimatedClient;\n // once animated, always animated to preserve hooks / vdom structure\n if (willBeAnimated && !curStateRef.hasAnimated) {\n curStateRef.hasAnimated = true;\n }\n const { disableClassName } = props;\n // HOOK\n const presence = (!isHOC &&\n willBeAnimated &&\n props['animatePresence'] !== false &&\n animationDriver?.usePresence?.()) ||\n null;\n const presenceState = presence?.[2];\n const isExiting = presenceState?.isPresent === false;\n const isEntering = presenceState?.isPresent === true && presenceState.initial !== false;\n const hasEnterStyle = !!props.enterStyle;\n const hasAnimationThatNeedsHydrate = hasAnimationProp &&\n !isHydrated &&\n (animationDriver?.isReactNative || inputStyle !== 'css');\n const canImmediatelyEnter = hasEnterStyle || isEntering;\n // this can be conditional because its only ever needed with animations\n const shouldEnter = !isHOC &&\n (hasEnterStyle ||\n isEntering ||\n hasAnimationThatNeedsHydrate ||\n // disableClassName doesnt work server side, only client, so needs hydrate\n // this is just for a better ux, supports css variables for light/dark, media queries, etc\n disableClassName);\n // two stage enter: because we switch from css driver to spring driver\n // - first render: render to match server with css driver\n // - second render: state.unmounted = should-enter, still rendering the initial,\n // non-entered state but now with the spring animation driver\n const initialState = shouldEnter\n ? // on the very first render we switch all spring animation drivers to css rendering\n // this is because we need to use css variables, which they don't support to do proper SSR\n // without flickers of the wrong colors.\n // but once we do that initial hydration and we are in client side rendering mode,\n // we can avoid the extra re-render on mount\n canImmediatelyEnter\n ? defaultComponentStateShouldEnter\n : defaultComponentState\n : defaultComponentStateMounted;\n // will be nice to deprecate half of these:\n const disabled = isDisabled(props);\n if (disabled != null) {\n initialState.disabled = disabled;\n }\n // HOOK\n const states = useState(initialState);\n const state = props.forceStyle ? { ...states[0], [props.forceStyle]: true } : states[0];\n const setState = states[1];\n // apply states we never updated from avoiding re-renders in animation driver\n // unsafe yea yea\n // if (stateRef.current.nextComponentState) {\n // Object.assign(state, stateRef.current.nextComponentState)\n // }\n // only web server + initial client render run this when not hydrated:\n let isAnimated = willBeAnimated;\n if (isWeb && hasAnimationThatNeedsHydrate && !staticConfig.isHOC && !isHydrated) {\n isAnimated = false;\n curStateRef.willHydrate = true;\n }\n // immediately update disabled state and reset component state\n if (disabled !== state.disabled) {\n // if disabled remove all press/focus/hover states\n if (disabled) {\n Object.assign(state, defaultComponentStateMounted);\n }\n state.disabled = disabled;\n setState((_) => ({ ...state }));\n }\n const groupName = props.group;\n // hoisted shallow-set closure: created once per component instance and\n // reused every render. drops the useCallback hook that useCreateShallowSetState\n // would otherwise add. setState from useState is stable per instance so we\n // can safely capture it. debug is read off stateRef at call time.\n //\n // important: this lives on `baseSetStateShallow`, not `setStateShallow`.\n // createComponent's avoidReRenders path overwrites `stateRef.current.setStateShallow`\n // with an emitter wrapper and captures this base as its real-re-render escape hatch.\n // if the base shared the `setStateShallow` field, on the 2nd+ render this hook would\n // read back the wrapper, the wrapper's escape hatch would point at itself, and a real\n // re-render (e.g. unmounted 'should-enter' -> false) would never reach React, leaving\n // enter animations stuck at opacity 0.\n if (!stateRef.current.baseSetStateShallow) {\n const r = stateRef.current;\n r.baseSetStateShallow = (stateOrGetState) => {\n setState((prev) => {\n const next = typeof stateOrGetState === 'function' ? stateOrGetState(prev) : stateOrGetState;\n const update = mergeIfNotShallowEqual(prev, next);\n if (process.env.NODE_ENV === 'development') {\n const dbg = r.__debug;\n if (dbg && update !== prev) {\n console.groupCollapsed(`setStateShallow CHANGE`, '=>', update);\n console.info(`previously`, prev);\n console.trace();\n console.groupEnd();\n }\n }\n return update;\n });\n };\n }\n if (process.env.NODE_ENV === 'development') {\n ;\n stateRef.current.__debug = props.debug;\n }\n const setStateShallow = stateRef.current.baseSetStateShallow;\n if (process.env.NODE_ENV === 'development' && globalThis.time)\n globalThis.time `state-useCreateShallowSetState`;\n // set enter/exit variants onto our new props object\n if (presenceState && isAnimated && isHydrated && staticConfig.variants) {\n if (process.env.NODE_ENV === 'development' && props.debug === 'verbose') {\n console.warn(`has presenceState ${JSON.stringify(presenceState)}`);\n }\n const { enterVariant, exitVariant, enterExitVariant, custom } = presenceState;\n if (isObj(custom)) {\n Object.assign(props, custom);\n }\n const exv = exitVariant ?? enterExitVariant;\n const env = enterVariant ?? enterExitVariant;\n if (state.unmounted && env && staticConfig.variants[env]) {\n if (process.env.NODE_ENV === 'development' && props.debug === 'verbose') {\n console.warn(`Animating presence ENTER \"${env}\"`);\n }\n props[env] = true;\n }\n else if (isExiting && exv) {\n if (process.env.NODE_ENV === 'development' && props.debug === 'verbose') {\n console.warn(`Animating presence EXIT \"${exv}\"`);\n }\n props[exv] = exitVariant !== enterExitVariant;\n }\n }\n let noClass = !isWeb || !!props.forceStyle;\n if (!isHydrated) {\n noClass = false;\n }\n else {\n // on server for SSR and animation compat added the && isHydrated but perhaps we want\n // disableClassName=\"until-hydrated\" to be more straightforward\n // see issue if not, Button sets disableClassName to true <Button transition=\"\" /> with\n // the react-native driver errors because it tries to animate var(--color) to rbga(..)\n // no matter what if fully unmounted or on the server we use className\n // only once we hydrate do we switch to spring animation drivers or disableClassName etc\n if (isWeb && isHydrated) {\n const isAnimatedAndHydrated = isAnimated && isHydrated;\n const isClassNameDisabled = !staticConfig.acceptsClassName && (getSetting('disableSSR') || !state.unmounted);\n const isDisabledManually = disableClassName && !state.unmounted;\n if (\n // Only disable className for animation drivers that output inline styles (not css)\n (isAnimatedAndHydrated && outputStyle !== 'css') ||\n isDisabledManually ||\n isClassNameDisabled) {\n noClass = true;\n if (process.env.NODE_ENV === 'development' && props.debug === 'verbose') {\n log(`avoiding className`, {\n isAnimatedAndHydrated,\n isDisabledManually,\n isClassNameDisabled,\n });\n }\n }\n }\n }\n return {\n startedUnhydrated: curStateRef.startedUnhydrated,\n curStateRef,\n disabled,\n groupName,\n hasAnimationProp,\n hasEnterStyle,\n isAnimated,\n isExiting,\n isHydrated,\n presence,\n presenceState,\n setState,\n setStateShallow,\n noClass,\n state,\n stateRef,\n inputStyle,\n outputStyle,\n willBeAnimated,\n willBeAnimatedClient,\n platformPseudo,\n };\n};\nfunction hasAnimatedStyleValue(style) {\n return Object.keys(style).some((k) => {\n const val = style[k];\n return val && typeof val === 'object' && '_animation' in val;\n });\n}\nconst isDisabled = (props) => {\n return (props.disabled ||\n props.passThrough ||\n props.accessibilityState?.disabled ||\n props['aria-disabled'] ||\n props.accessibilityDisabled ||\n false);\n};\n//# sourceMappingURL=useComponentState.js.map","import { Fragment as _Fragment, jsx as _jsx } from \"react/jsx-runtime\";\n// via radix\nimport { composeRefs } from '@hanzogui/compose-refs';\nimport { isWeb } from '@hanzogui/constants';\nimport { Children, cloneElement, forwardRef, isValidElement, memo } from 'react';\nimport { mergeSlotStyleProps } from '../helpers/mergeSlotStyleProps.js';\nexport const Slot = memo(forwardRef(function Slot(props, forwardedRef) {\n const { children, ...slotProps } = props;\n if (isValidElement(children)) {\n const mergedProps = mergeSlotProps(children, slotProps);\n return cloneElement(children, children.type['avoidForwardRef']\n ? mergedProps\n : {\n ...mergedProps,\n ref: composeRefs(forwardedRef, children.props.ref),\n });\n }\n return Children.count(children) > 1 ? Children.only(null) : null;\n}));\n/* -------------------------------------------------------------------------------------------------\n * Slottable\n * -----------------------------------------------------------------------------------------------*/\nexport const Slottable = ({ children }) => {\n return _jsx(_Fragment, { children: children });\n};\nSlottable['displayName'] = 'Slottable';\n/* ---------------------------------------------------------------------------------------------- */\nconst pressMap = isWeb\n ? {\n onPress: 'onClick',\n onPressOut: 'onMouseUp',\n onPressIn: 'onMouseDown',\n }\n : {};\nfunction mergeSlotProps(child, slotProps) {\n const childProps = child.props;\n const isHTMLChild = typeof child.type === 'string';\n // convert RN press events to web events for HTML children\n if (isHTMLChild) {\n for (const key in pressMap) {\n if (key in slotProps) {\n slotProps[pressMap[key]] = slotProps[key];\n delete slotProps[key];\n }\n }\n }\n // merge slot props with child props (child wins via overlay)\n const merged = mergeSlotStyleProps(slotProps, childProps);\n // convert child's RN press events to web events after merge\n if (isHTMLChild) {\n for (const key in pressMap) {\n if (key in merged) {\n merged[pressMap[key]] = merged[key];\n delete merged[key];\n }\n }\n }\n return merged;\n}\n//# sourceMappingURL=Slot.js.map","import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { composeRefs } from '@hanzogui/compose-refs';\nimport { getPlatformDriver, isAndroid, isClient, isNativeDesktop, isServer, isWeb, useIsomorphicLayoutEffect, } from '@hanzogui/constants';\nimport { NativeMenuContext } from '@hanzogui/native';\nimport { composeEventHandlers } from '@hanzogui/helpers';\nimport { isEqualShallow } from '@hanzogui/is-equal-shallow';\nimport React, { useMemo } from 'react';\nimport { devConfig, getConfig } from './config.js';\nimport { isDevTools } from './constants/isDevTools.js';\nimport { ComponentContext } from './contexts/ComponentContext.js';\nimport { GroupContext } from './contexts/GroupContext.js';\nimport { didGetVariableValue, setDidGetVariableValue } from './createVariable.js';\nimport { defaultComponentStateMounted } from './defaultComponentState.js';\nimport { getWebEvents, useEvents, wrapWithGestureDetector } from './eventHandling.js';\nimport { getDefaultProps } from './helpers/getDefaultProps.js';\nimport { resolveAnimationDriver } from './helpers/resolveAnimationDriver.js';\nimport { getSplitStyles, useSplitStyles } from './helpers/getSplitStyles.js';\nimport { log } from './helpers/log.js';\nimport { mergeComponentProps } from './helpers/mergeProps.js';\nimport { mergeRenderElementProps } from './helpers/mergeRenderElementProps.js';\nimport { objectIdentityKey } from './helpers/objectIdentityKey.js';\nimport { usePointerEvents } from './helpers/pointerEvents.js';\nimport { extractPseudoState, resolveEffectivePseudoTransition, } from './helpers/pseudoTransitions.js';\nimport { setElementProps } from './helpers/setElementProps.js';\nimport { subscribeToContextGroup } from './helpers/subscribeToContextGroup.js';\nimport { themeable } from './helpers/themeable.js';\nimport { getStyleTags } from './helpers/wrapStyleTags.js';\nimport { useComponentState } from './hooks/useComponentState.js';\nimport { setMediaShouldUpdate, useMedia } from './hooks/useMedia.js';\nimport { useThemeWithState } from './hooks/useTheme.js';\nimport { hooks } from './setupHooks.js';\nimport { Slot } from './views/Slot.js';\nimport { getThemedChildren } from './views/Theme.js';\n// data-slot: a neutral, standard structural annotation for zero-config analytics.\n// Mirrors shadcn's convention — the component's name, kebab-cased — so a tracker\n// like track.js's `annotate` can capture DOM structure with no per-app config.\n// Only named components carry one (base View/Text/Stack have no componentName),\n// matching shadcn's \"named primitives only\" rule.\n// Memoized: names come from the fixed set of styled() definitions, so each is\n// kebab-cased once — the render path is then an O(1) hit with no per-render regex.\n// PATCH (ours, carried across the transplant): upstream has no equivalent.\nconst dataSlotCache = new Map();\nconst dataSlotFor = (name) => {\n let slot = dataSlotCache.get(name);\n if (slot === undefined) {\n slot = name\n .replace(/([A-Z]+)([A-Z][a-z])/g, '$1-$2')\n .replace(/([a-z0-9])([A-Z])/g, '$1-$2')\n .toLowerCase();\n dataSlotCache.set(name, slot);\n }\n return slot;\n};\n/**\n * All things that need one-time setup after createGui is called\n */\nlet time;\nlet debugKeyListeners;\nlet startVisualizer;\nexport const componentSetStates = new Set();\nconst avoidReRenderKeys = new Set([\n 'hover',\n 'press',\n 'pressIn',\n 'group',\n 'focus',\n 'focusWithin',\n 'media',\n 'group',\n]);\nconst groupPseudoKeys = [\n 'disabled',\n 'hover',\n 'press',\n 'pressIn',\n 'focus',\n 'focusVisible',\n 'focusWithin',\n];\nif (\"web\" !== 'native' && typeof window !== 'undefined') {\n const cancelPresses = () => {\n // clear all press downs\n componentSetStates.forEach((setState) => setState((prev) => {\n if (prev.press || prev.pressIn) {\n return {\n ...prev,\n press: false,\n pressIn: false,\n };\n }\n return prev;\n }));\n componentSetStates.clear();\n };\n const cancelTouches = () => {\n // clear press and hover on touch end - hover may have been set\n // via synthetic mouseenter event triggered by touch\n componentSetStates.forEach((setState) => setState((prev) => {\n if (prev.press || prev.pressIn || prev.hover) {\n return {\n ...prev,\n press: false,\n pressIn: false,\n hover: false,\n };\n }\n return prev;\n }));\n componentSetStates.clear();\n };\n addEventListener('mouseup', cancelPresses);\n addEventListener('touchend', cancelTouches);\n addEventListener('touchcancel', cancelTouches);\n // hold option to see debug visualization\n if (process.env.NODE_ENV === 'development') {\n startVisualizer = () => {\n const devVisualizerConfig = devConfig?.visualizer;\n if (devVisualizerConfig && !globalThis.__hanzoguiDevVisualizer) {\n globalThis.__hanzoguiDevVisualizer = true;\n debugKeyListeners = new Set();\n let tm;\n let isShowing = false;\n let resizeListener = null;\n const options = {\n key: 'Alt',\n delay: 800,\n ...(typeof devVisualizerConfig === 'object' ? devVisualizerConfig : {}),\n };\n function show(val) {\n clearTimeout(tm);\n isShowing = val;\n debugKeyListeners?.forEach((l) => l(val));\n // Remove resize listener when hiding\n if (!val && resizeListener) {\n window.removeEventListener('resize', resizeListener);\n resizeListener = null;\n }\n }\n function cancelShow() {\n clearTimeout(tm);\n if (resizeListener) {\n window.removeEventListener('resize', resizeListener);\n resizeListener = null;\n }\n }\n window.addEventListener('blur', () => {\n show(false);\n });\n window.addEventListener('keydown', ({ key, metaKey, defaultPrevented }) => {\n clearTimeout(tm); // always clear so we dont trigger on chords\n if (defaultPrevented)\n return;\n if (metaKey)\n return;\n if (key === options.key) {\n // Add resize listener immediately when Alt is pressed\n if (!resizeListener) {\n resizeListener = () => cancelShow();\n window.addEventListener('resize', resizeListener);\n }\n tm = setTimeout(() => {\n show(true);\n }, options.delay);\n }\n });\n window.addEventListener('keyup', ({ defaultPrevented }) => {\n if (defaultPrevented)\n return;\n cancelShow();\n // any key can clear it\n if (isShowing) {\n show(false);\n }\n });\n }\n };\n }\n}\n/**\n * Only on native do we need the actual underlying View/Text\n * On the web we avoid react-native dep altogether.\n */\nlet BaseText;\nlet BaseView;\nlet hasSetupBaseViews = false;\nconst lastInteractionWasKeyboard = { value: false };\nconst lastInteractionWasTouch = { value: false };\nif (isWeb && typeof document !== 'undefined') {\n document.addEventListener('keydown', () => {\n if (!lastInteractionWasKeyboard.value) {\n lastInteractionWasKeyboard.value = true;\n }\n });\n document.addEventListener('mousedown', () => {\n if (lastInteractionWasKeyboard.value) {\n lastInteractionWasKeyboard.value = false;\n }\n });\n document.addEventListener('mousemove', () => {\n if (lastInteractionWasKeyboard.value) {\n lastInteractionWasKeyboard.value = false;\n }\n // Real mouse movement clears touch flag\n lastInteractionWasTouch.value = false;\n });\n document.addEventListener('touchstart', () => {\n lastInteractionWasTouch.value = true;\n });\n // Don't reset on touchend - mouseenter fires after touchend\n // and we need to still detect it as a touch interaction.\n // Mouse move will reset it when there's real mouse activity.\n}\nexport function createComponent(staticConfig) {\n let config = null;\n const { Component, isText, isHOC } = staticConfig;\n const component = React.forwardRef((propsIn, forwardedRef) => {\n 'use no memo';\n config = config || getConfig();\n const internalID = process.env.NODE_ENV === 'development' ? React.useId() : '';\n if (process.env.NODE_ENV === 'development') {\n if (startVisualizer) {\n startVisualizer();\n startVisualizer = undefined;\n }\n }\n if (\"web\" === 'native') {\n // todo this could be moved to a cleaner location\n if (!hasSetupBaseViews) {\n hasSetupBaseViews = true;\n const baseViews = hooks.getBaseViews?.();\n if (baseViews) {\n BaseText = baseViews.Text;\n BaseView = baseViews.View;\n }\n }\n }\n // test only\n if (process.env.NODE_ENV === 'test') {\n const testRenderCount = propsIn['data-test-renders'];\n if (testRenderCount &&\n typeof testRenderCount === 'object' &&\n !Object.isFrozen(testRenderCount)) {\n testRenderCount.current = testRenderCount.current ?? 0;\n testRenderCount.current += 1;\n }\n }\n // set variants through context\n // order is after default props but before props\n const { context, isReactNative } = staticConfig;\n const debugProp = propsIn['debug'];\n const styledContextValue = context\n ? React.useContext(context)\n : undefined;\n let overriddenContextProps = null;\n const componentContext = React.useContext(ComponentContext);\n const hasTextAncestor = !!(isWeb && isText ? componentContext.inText : false);\n // On Android, skip RNGH GestureDetector inside native menus (zeego) and use\n // direct press events instead — GestureDetector consumes touches before they\n // reach MenuView's native handler, preventing the menu from opening\n // NativeMenuContext only affects Android RNGH press arbitration inside zeego\n // menus (see eventHandling.native.ts:182). isAndroid is constant for the whole\n // app run, so on iOS we skip this context read for every component — the branch\n // never flips at runtime, so hook order stays stable (rules-of-hooks safe).\n const isInsideNativeMenu = \"web\" === 'native' && isAndroid\n ? // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useContext(NativeMenuContext)\n : false;\n if (!process.env.GUI_IS_CORE_NODE &&\n process.env.NODE_ENV === 'development' &&\n debugProp === 'profile' &&\n !time) {\n const timer = require('@hanzogui/timer').timer();\n time = timer.start();\n globalThis['time'] = time;\n }\n // pick up globalThis.time if set externally (e.g. by a profiling harness)\n if (process.env.NODE_ENV === 'development' && !time && globalThis.time) {\n time = globalThis.time;\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `non-hanzogui time (ignore)`;\n // React inserts default props after your props for some reason...\n // order important so we do loops, you can't just spread because JS does weird things\n let props = propsIn;\n const componentName = props.componentName || staticConfig.componentName;\n // merge both default props and styled context props - ensure order is preserved\n const defaultProps = getDefaultProps(staticConfig, props.componentName);\n // merge styled context props over defaults, ensure order is preserved\n const [nextProps, overrides] = mergeComponentProps(defaultProps, styledContextValue, propsIn);\n props = nextProps;\n overriddenContextProps = overrides;\n if (process.env.NODE_ENV === 'development' && isClient) {\n React.useEffect(() => {\n let node;\n let overlay = null;\n const remove = () => {\n if (overlay) {\n try {\n overlay.parentNode?.removeChild(overlay);\n overlay = null;\n }\n catch {\n // may have unmounted\n }\n }\n };\n const debugVisualizerHandler = (show = false) => {\n node = stateRef.current.host;\n if (!node)\n return;\n if (show) {\n if (!overlay) {\n overlay = document.createElement('span');\n overlay.style.inset = '0px';\n overlay.style.zIndex = '1000000';\n overlay.style.position = 'absolute';\n overlay.style.borderColor = 'red';\n overlay.style.borderWidth = '1px';\n overlay.style.borderStyle = 'dotted';\n }\n const dataAt = node.getAttribute('data-at') || '';\n const dataIn = node.getAttribute('data-in') || '';\n const tooltip = document.createElement('span');\n tooltip.style.position = 'absolute';\n tooltip.style.top = '0px';\n tooltip.style.left = '0px';\n tooltip.style.padding = '3px';\n tooltip.style.background = 'rgba(0,0,0,0.75)';\n tooltip.style.color = 'rgba(255,255,255,1)';\n tooltip.style.fontSize = '12px';\n tooltip.style.lineHeight = '12px';\n tooltip.style.fontFamily = 'monospace';\n tooltip.innerText = `${componentName || ''} ${dataAt} ${dataIn}`.trim();\n overlay.appendChild(tooltip);\n node.appendChild(overlay);\n }\n else {\n remove();\n }\n };\n debugKeyListeners = debugKeyListeners || new Set();\n debugKeyListeners.add(debugVisualizerHandler);\n return () => {\n remove();\n debugKeyListeners?.delete(debugVisualizerHandler);\n };\n }, [componentName]);\n }\n const groupContextParent = React.useContext(GroupContext);\n // Get animation driver - either from animatedBy prop lookup or context/config fallback\n const animationDriver = (() => {\n if (props.animatedBy && config) {\n // check animationDrivers for multi-driver config\n if (config.animationDrivers) {\n return (config.animationDrivers[props.animatedBy] ??\n config.animations);\n }\n // single driver config - only 'default' makes sense\n return props.animatedBy === 'default' ? config.animations : null;\n }\n // fall back to context driver, then config.animations\n // resolveAnimationDriver validates it's a real driver (not a raw multi-driver object)\n return (resolveAnimationDriver(componentContext.animationDriver) ??\n resolveAnimationDriver(config?.animations) ??\n null);\n })();\n const useAnimations = animationDriver?.useAnimations;\n const componentState = useComponentState(props, animationDriver?.isStub ? null : animationDriver, staticConfig, config);\n const { disabled, groupName, hasAnimationProp, hasEnterStyle, isAnimated, isExiting, isHydrated, presence, presenceState, setState, noClass, state, stateRef, inputStyle, outputStyle, willBeAnimated, willBeAnimatedClient, platformPseudo, startedUnhydrated, } = componentState;\n if (animationDriver?.avoidReRenders) {\n // post-commit reconciliation of `nextState` with the committed React state.\n // `nextState` is the source of truth for the fast `setStateShallow` path; it\n // must stay populated until React actually commits the corresponding update,\n // otherwise a follow-up update in the same JS task would read a stale closure\n // `state` and bail on a false shallow-equal. once committed state matches\n // `nextState`, clear it. if they diverge (animated components' fast path never\n // calls into React), flush via componentState.setStateShallow here.\n useIsomorphicLayoutEffect(() => {\n // first: refresh the emitter latch while a self pseudo is active. the driver\n // keeps the last-emitted snapshot latched across re-renders (so an unrelated\n // render doesn't snap a hovered style back to base), but a render can change\n // the styles that FEED the pseudo merge — e.g. a row becoming active removes\n // its hoverStyle while still hovered — and the stale snapshot would keep\n // painting over the new base (hover-beats-active-during-scrub).\n // `updateStyleListener` is rebuilt each render over fresh props/state and\n // reads `nextState || state`, so re-invoking it re-emits the correct merged\n // style: identical values when the render was truly unrelated (no visual\n // change), fresh values when it wasn't. gate on the last-EMITTED pseudo state\n // (prevPseudoState), not React state — React state can lag the emitter by a\n // commit, and a stale-true `state.hover` here would resurrect a hover the\n // emitter already cleared. this must run BEFORE the nextState flush below so\n // the re-emit still sees the freshest pseudo state.\n const emitted = stateRef.current.prevPseudoState;\n if (emitted && (emitted.hover || emitted.press || emitted.focus)) {\n stateRef.current.updateStyleListener?.();\n }\n const pendingState = stateRef.current.nextState;\n if (!pendingState)\n return;\n stateRef.current.nextState = undefined;\n if (!isEqualShallow(state, pendingState)) {\n componentState.setStateShallow(pendingState);\n }\n });\n }\n // renderer-driven pseudo states (setupPlatformDriver): the platform resolves\n // hover natively per hitbox and pushes flips here, replacing the\n // mouseEnter/mouseLeave lane on such renderers. the flip applies through the\n // same setStateShallow the event handlers use — under the (driver-opened)\n // avoidReRenders gate that's the emitter path: zero React commits, animated\n // per the declared transition or instant by default. press stays on the\n // responder event path (it must fire onPress anyway); the driver only owns\n // the hover trigger for now.\n useIsomorphicLayoutEffect(() => {\n if (!platformPseudo || props.disabled)\n return;\n const pseudoDriver = getPlatformDriver()?.pseudo;\n const host = stateRef.current.host;\n if (!pseudoDriver || !host)\n return;\n return pseudoDriver.subscribe(host, ({ hovered }) => {\n stateRef.current.setStateShallow?.({ hover: hovered });\n });\n }, [platformPseudo, props.disabled]);\n // create new context with groups, or else sublings will grab the same one\n const allGroupContexts = useMemo(() => {\n if (!groupName || props.passThrough) {\n return groupContextParent;\n }\n const listeners = new Set();\n stateRef.current.group?.listeners?.clear();\n stateRef.current.group = {\n listeners,\n emit(state) {\n listeners.forEach((l) => l(state));\n },\n subscribe(cb) {\n listeners.add(cb);\n if (listeners.size === 1) {\n setStateShallow({ hasDynGroupChildren: true });\n }\n return () => {\n listeners.delete(cb);\n if (listeners.size === 0) {\n setStateShallow({ hasDynGroupChildren: false });\n }\n };\n },\n };\n return {\n ...groupContextParent,\n [groupName]: {\n state: {\n pseudo: defaultComponentStateMounted,\n },\n subscribe: (listener) => {\n const dispose = stateRef.current.group?.subscribe(listener);\n return () => {\n dispose?.();\n };\n },\n },\n };\n }, [stateRef, groupName, groupContextParent]);\n // if our animation driver supports avoidReRenders, we'll replace this below with\n // a version that essentially uses an internall emitter rather than setting state\n // but still stores the current state and applies if it it needs to during render\n let setStateShallow = componentState.setStateShallow;\n if (process.env.NODE_ENV === 'development' && time)\n time `use-state`;\n // web-only - string-style not valid for native\n const renderProp = props.render;\n const isRenderString = !Component || typeof Component === 'string';\n // default to render prop, fallback to component (when both strings)\n const element = isWeb\n ? isRenderString\n ? renderProp || Component\n : Component\n : Component;\n const BaseTextComponent = BaseText || element || 'span';\n const BaseViewComponent = BaseView || element || (hasTextAncestor ? 'span' : 'div');\n const BaseComponent = isText ? BaseTextComponent : BaseViewComponent;\n let elementType = BaseComponent;\n const isAnimatedCustomComponent = animationDriver && isAnimated && animationDriver.needsCustomComponent;\n if (isAnimatedCustomComponent) {\n elementType = animationDriver[isText ? 'Text' : 'View'] || elementType;\n }\n // internal use only\n const disableThemeProp = \"web\" === 'native' ? false : props['data-disable-theme'];\n const disableTheme = disableThemeProp || isHOC;\n if (process.env.NODE_ENV === 'development' && time)\n time `theme-props`;\n const themeStateProps = {\n componentName,\n disable: disableTheme,\n shallow: props.themeShallow,\n debug: debugProp,\n unstyled: props.unstyled,\n };\n // this is set conditionally if existing in props because we wrap children with\n // a span if they ever set one of these, so avoid wrapping all children with span\n if ('theme' in props) {\n themeStateProps.name = props.theme;\n }\n // Always set needsUpdate callback so it can check the ref's latest value\n // This ensures components with $theme-dark/$theme-light re-render on theme change\n // even when using raw colors (not tokens) since isListeningToTheme is set after useSplitStyles\n themeStateProps.needsUpdate = () => !!stateRef.current.isListeningToTheme;\n // on native we optimize theme changes if fastSchemeChange is enabled, otherwise deopt\n if (\"web\" === 'native') {\n themeStateProps.deopt = willBeAnimated;\n }\n if (process.env.NODE_ENV === 'development') {\n if (debugProp && debugProp !== 'profile') {\n const name = `${componentName ||\n Component?.displayName ||\n Component?.name ||\n '[Unnamed Component]'}`;\n const type = (hasEnterStyle ? '(hasEnter)' : ' ') +\n (isAnimated ? '(animated)' : ' ') +\n (isReactNative ? '(rnw)' : ' ') +\n (noClass ? '(noClass)' : ' ') +\n (state.press || state.pressIn ? '(PRESSED)' : ' ') +\n (state.hover ? '(HOVERED)' : ' ') +\n (state.focus ? '(FOCUSED)' : ' ') +\n (state.focusWithin ? '(WITHIN FOCUSED)' : ' ') +\n (presenceState?.isPresent === false ? '(EXIT)' : '');\n const dataIs = propsIn['data-is'] || '';\n const banner = `<${name} /> ${internalID} ${dataIs ? ` ${dataIs}` : ''} ${type.trim()} (hydrated: ${isHydrated}) (unmounted: ${state.unmounted})`;\n const ch = propsIn.children;\n let childLog = typeof ch === 'string' ? (ch.length > 4 ? ch.slice(0, 4) + '...' : ch) : '';\n if (childLog.length) {\n childLog = `(children: ${childLog})`;\n }\n if (isWeb) {\n console.info(`%c ${banner}`, 'background: green; color: white;');\n if (isServer) {\n log({ noClass, isAnimated, isWeb, inputStyle });\n }\n else {\n // if strict mode or something messes with our nesting this fixes:\n console.groupEnd();\n console.groupCollapsed(`${childLog} [inspect props, state, context 👇]`);\n log('props in:', propsIn);\n log('final props:', props, Object.keys(props));\n log({ state, staticConfig, elementType, themeStateProps });\n log({\n context,\n overriddenContextProps,\n componentContext,\n });\n log({ presence, isAnimated, isHOC, hasAnimationProp, useAnimations });\n console.groupEnd();\n }\n }\n else {\n console.info(`\\n\\n------------------------------\\n${banner}\\n------------------------------\\n`);\n log(`children:`, props.children);\n log({ overriddenContextProps, styledContextValue });\n log({ noClass, isAnimated, isWeb, inputStyle });\n }\n }\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `pre-theme-media`;\n const [theme, themeState] = useThemeWithState(themeStateProps);\n if (process.env.NODE_ENV === 'development' && time)\n time `theme`;\n elementType = element || elementType;\n const isStringElement = typeof elementType === 'string';\n const mediaState = useMedia(componentContext, debugProp);\n setDidGetVariableValue(false);\n if (process.env.NODE_ENV === 'development' && time)\n time `media`;\n const resolveValues = \n // if HOC + mounted + has animation prop, resolve as value so it passes non-variable to child\n (isAnimated && inputStyle !== 'css') ||\n (isHOC && state.unmounted == false && hasAnimationProp)\n ? 'value'\n : 'auto';\n const styleProps = {\n mediaState,\n noClass,\n resolveValues,\n isExiting,\n isAnimated,\n willBeAnimated,\n styledContext: styledContextValue,\n };\n const themeName = themeState?.name || '';\n if (process.env.NODE_ENV === 'development' && time)\n time `split-styles-prepare`;\n const splitStyles = useSplitStyles(props, staticConfig, theme, themeName, state, styleProps, null, componentContext, allGroupContexts, elementType, startedUnhydrated, debugProp, animationDriver);\n const isPassthrough = !splitStyles;\n // splitStyles === null === passThrough\n // Merge style-resolved context overrides (issues #3670, #3676)\n // When styles set values that are also context keys (from variants, pseudos, media, etc),\n // we need to add them to overriddenContextProps so they propagate to children\n // Use either the component's own context or its parent's context (for styled() inheritance)\n let contextForOverride = staticConfig.context;\n if (splitStyles?.overriddenContextProps) {\n const contextForProps = staticConfig.context || staticConfig.parentStaticConfig?.context;\n if (contextForProps) {\n for (const key in splitStyles.overriddenContextProps) {\n overriddenContextProps = overriddenContextProps || {};\n overriddenContextProps[key] = splitStyles.overriddenContextProps[key];\n }\n // Use parent's context if this component doesn't have its own\n if (!staticConfig.context) {\n contextForOverride = contextForProps;\n }\n }\n }\n const groupContext = groupName ? allGroupContexts?.[groupName] || null : null;\n // one tiny mutation 🙏 get width/height optimistically from raw values if possible\n // if set hardcoded it avoids extra renders\n if (!isPassthrough &&\n groupContext &&\n // avoids onLayout if we don't need it\n props.containerType !== 'normal') {\n const groupState = groupContext?.state;\n if (groupState && groupState.layout === undefined) {\n if (splitStyles.style?.width || splitStyles.style?.height) {\n groupState.layout = {\n width: fromPx(splitStyles.style.width),\n height: fromPx(splitStyles.style.height),\n };\n }\n }\n }\n // avoids re-rendering if animation driver supports it\n // TODO believe we need to set some sort of \"pendingState\" in case it re-renders\n // CRITICAL: Skip avoidReRenders for components with enter/exit transitions\n // The exit state comes from AnimatePresence context, not local state, so\n // updateStyleListener can fire before the component re-renders with the new\n // presence value, causing wrong animation timing (e.g., using enter timing for exit)\n const hasEnterExitTransition = props.transition &&\n typeof props.transition === 'object' &&\n !Array.isArray(props.transition) &&\n ('enter' in props.transition || 'exit' in props.transition);\n if (!isPassthrough &&\n (hasAnimationProp || groupName || platformPseudo) &&\n animationDriver?.avoidReRenders &&\n !hasEnterExitTransition) {\n const ogSetStateShallow = setStateShallow;\n stateRef.current.updateStyleListener = () => {\n const useStyleListener = stateRef.current.useStyleListener;\n // if no animation driver is listening for style updates, fall back to normal re-render\n // this happens when a component has group prop but no transition/animation prop.\n // keep nextState populated until React actually commits the update — clearing it\n // here lets a subsequent setStateShallow in the same JS task (e.g. press-out\n // right after press-in) compare against a stale closure `state` and bail out,\n // losing the update. the post-commit layoutEffect below clears nextState once\n // React state has caught up.\n if (!useStyleListener) {\n const pendingState = stateRef.current.nextState;\n if (pendingState) {\n ogSetStateShallow(pendingState);\n }\n return;\n }\n const updatedState = stateRef.current.nextState || state;\n const mediaState = stateRef.current.nextMedia;\n const nextStyles = getSplitStyles(props, staticConfig, theme, themeName, updatedState, mediaState ? { ...styleProps, mediaState } : styleProps, null, componentContext, allGroupContexts, elementType, startedUnhydrated, debugProp, animationDriver);\n // compute effective transition based on entering/exiting pseudo states\n const effectiveTransition = resolveEffectivePseudoTransition(stateRef.current.prevPseudoState, updatedState, nextStyles?.pseudoTransitions, \n // platform-pseudo with no declared transition = instant (CSS :hover semantics)\n props.transition ?? (platformPseudo ? '0ms' : undefined));\n // update prev state for next comparison (includes group states)\n stateRef.current.prevPseudoState = extractPseudoState(updatedState);\n // a self pseudo being active means the emitted style is a transient hover/press/focus\n // override (it's not in React state under avoidReRenders), so the worklet must keep it\n // latched across incidental re-renders; when none is active this is the base and renders\n // own it again.\n const hasActivePseudo = Boolean(updatedState.hover ||\n updatedState.press ||\n updatedState.pressIn ||\n updatedState.focus ||\n updatedState.focusWithin);\n useStyleListener((nextStyles?.style || {}), effectiveTransition, hasActivePseudo);\n };\n function updateGroupListeners() {\n const updatedState = stateRef.current.nextState;\n if (groupContext) {\n const { group, hasDynGroupChildren, unmounted, transition, ...childrenGroupState } = updatedState;\n notifyGroupSubscribers(groupContext, stateRef.current.group || null, childrenGroupState);\n }\n }\n // don't change this ever or else you break ComponentContext and cause re-rendering\n // use a Set of listeners so multiple components can register\n componentContext.mediaEmitListeners =\n componentContext.mediaEmitListeners || new Set();\n // only register once per component instance\n if (!stateRef.current.mediaEmitCleanup) {\n const updateListener = (next) => {\n stateRef.current.nextMedia = next;\n stateRef.current.updateStyleListener?.();\n };\n componentContext.mediaEmitListeners.add(updateListener);\n stateRef.current.mediaEmitCleanup = () => {\n componentContext.mediaEmitListeners?.delete(updateListener);\n };\n }\n componentContext.mediaEmit =\n componentContext.mediaEmit ||\n ((next) => {\n // notify all registered components\n for (const listener of componentContext.mediaEmitListeners) {\n listener(next);\n }\n });\n stateRef.current.setStateShallow = (nextOrGetNext) => {\n const prev = stateRef.current.nextState || state;\n const next = typeof nextOrGetNext === 'function' ? nextOrGetNext(prev) : nextOrGetNext;\n if (next === prev || isEqualShallow(prev, next)) {\n return;\n }\n // one thing we have to handle here and where it gets a bit more complex is group styles\n const canAvoidReRender = Object.keys(next).every((key) => avoidReRenderKeys.has(key));\n const updatedState = {\n ...prev,\n ...next,\n };\n stateRef.current.nextState = updatedState;\n if (canAvoidReRender) {\n if (process.env.NODE_ENV === 'development' &&\n debugProp &&\n debugProp !== 'profile') {\n console.groupCollapsed(`[⚡️] avoid setState`, componentName, next, {\n updatedState,\n props,\n });\n console.info(stateRef.current.host);\n console.groupEnd();\n }\n updateGroupListeners();\n stateRef.current.updateStyleListener?.();\n }\n else {\n if (process.env.NODE_ENV === 'development' &&\n debugProp &&\n debugProp !== 'profile') {\n console.info(`[🐌] re-render`, { canAvoidReRender, next });\n }\n ogSetStateShallow(next);\n }\n };\n // needs to capture latest props (it's called from memoized `events`)\n setStateShallow = (state) => {\n stateRef.current.setStateShallow?.(state);\n };\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `split-styles`;\n // hide strategy will set this opacity = 0 until measured\n if (splitStyles) {\n if (props.group &&\n props.untilMeasured === 'hide' &&\n !stateRef.current.hasMeasured) {\n splitStyles.style = splitStyles.style || {};\n splitStyles.style.opacity = 0;\n }\n if (splitStyles.dynamicThemeAccess != null) {\n stateRef.current.isListeningToTheme = splitStyles.dynamicThemeAccess;\n }\n }\n // only listen for changes if we are using raw theme values or media space, or dynamic media (native)\n // array = space media breakpoints\n const hasRuntimeMediaKeys = splitStyles?.hasMedia && splitStyles.hasMedia !== true;\n const shouldListenForMedia = didGetVariableValue() ||\n hasRuntimeMediaKeys ||\n (noClass && splitStyles?.hasMedia === true);\n const mediaListeningKeys = hasRuntimeMediaKeys\n ? splitStyles.hasMedia\n : null;\n if (process.env.NODE_ENV === 'development' && debugProp === 'verbose') {\n console.info(`useMedia() createComponent`, shouldListenForMedia, mediaListeningKeys);\n }\n setMediaShouldUpdate(componentContext, shouldListenForMedia, mediaListeningKeys);\n const { viewProps: viewPropsIn, pseudos, style: splitStylesStyle, classNames, pseudoGroups, mediaGroups, } = splitStyles || {};\n const propsWithAnimation = props;\n const { asChild, children, themeShallow, spaceDirection: _spaceDirection, onPress, onLongPress, onPressIn, onPressOut, onHoverIn, onHoverOut, onMouseUp, onMouseDown, onMouseEnter, onMouseLeave, onFocus, onBlur, onDidAnimate, separator, \n // ignore from here on out\n passThrough, forceStyle: _forceStyle, \n // @ts-ignore for next/link compat etc\n onClick, theme: _themeProp, ...nonGuiProps } = viewPropsIn || {};\n // these can ultimately be for DOM, react-native-web views, or animated views\n // so the type is pretty loose\n let viewProps = nonGuiProps;\n if (props.forceStyle) {\n viewProps.forceStyle = props.forceStyle;\n }\n if (isHOC) {\n if (typeof _themeProp !== 'undefined') {\n viewProps.theme = _themeProp;\n }\n if (typeof passThrough !== 'undefined') {\n viewProps.passThrough = passThrough;\n }\n }\n // once you set animation prop don't remove it, you can set to undefined/false\n // reason is animations are heavy - no way around it, and must be run inline here (🙅 loading as a sub-component)\n let animationStyles;\n const shouldUseAnimation = \n // if it supports css vars we run it on server too to get matching initial style\n (inputStyle === 'css' ? willBeAnimatedClient : willBeAnimated) &&\n useAnimations &&\n !isHOC;\n let animatedRef;\n if (shouldUseAnimation) {\n const useStyleEmitter = animationDriver?.avoidReRenders\n ? (listener) => {\n stateRef.current.useStyleListener = listener;\n }\n : undefined;\n // compute effective transition once here (single source of truth)\n // avoidReRenders path also computes this in updateStyleListener\n const effectiveTransition = resolveEffectivePseudoTransition(stateRef.current.prevPseudoState, state, splitStyles?.pseudoTransitions, \n // platform-pseudo with no declared transition = instant (CSS :hover semantics)\n props.transition ?? (platformPseudo ? '0ms' : undefined));\n // add effectiveTransition to splitStyles for drivers to consume\n if (splitStyles) {\n splitStyles.effectiveTransition = effectiveTransition;\n }\n // update prev state for next comparison (needed for non-avoidReRenders drivers like CSS)\n // avoidReRenders path also updates this in updateStyleListener\n stateRef.current.prevPseudoState = extractPseudoState(state);\n const animations = useAnimations({\n props: propsWithAnimation,\n // clone style to prevent animation driver mutations from leaking to viewProps\n // during SSR/pre-hydration (CSS driver mutates style.transition in place)\n style: isHydrated ? splitStylesStyle || {} : { ...splitStylesStyle },\n // @ts-ignore\n styleState: splitStyles,\n useStyleEmitter,\n presence,\n componentState: state,\n styleProps,\n theme,\n themeName,\n pseudos: pseudos || null,\n staticConfig,\n stateRef,\n onDidAnimate,\n });\n if (animations) {\n if (animations.ref) {\n // @ts-ignore\n animatedRef = animations.ref;\n }\n if (isHydrated && animations) {\n animationStyles = animations.style;\n viewProps.style = animationStyles;\n if (animations.className) {\n viewProps.className = `${state.unmounted === 'should-enter' ? 't_unmounted ' : ''}${viewProps.className || ''} ${animations.className}`;\n }\n }\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `animations`;\n }\n if (process.env.NODE_ENV === 'development' && props.untilMeasured && !props.group) {\n console.warn(`You set the untilMeasured prop without setting group. This doesn't work, be sure to set untilMeasured on the parent that sets group, not the children that use the $group- prop.\\n\\nIf you meant to do this, you can disable this warning - either change untilMeasured and group at the same time, or do group={conditional ? 'name' : undefined}`);\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `destructure`;\n if (!isPassthrough &&\n groupContext && // avoids onLayout if we don't need it\n props.containerType !== 'normal') {\n nonGuiProps.onLayout = composeEventHandlers(nonGuiProps.onLayout, (e) => {\n // one off update here\n const layout = e.nativeEvent.layout;\n groupContext.state.layout = layout;\n stateRef.current.group?.emit({\n layout,\n });\n // force re-render if measure strategy is hide\n if (!stateRef.current.hasMeasured && props.untilMeasured === 'hide') {\n setState((prev) => ({ ...prev }));\n }\n stateRef.current.hasMeasured = true;\n });\n }\n viewProps =\n hooks.usePropsTransform?.(elementType, nonGuiProps, stateRef, stateRef.current.willHydrate) || nonGuiProps;\n if (!stateRef.current.composedRef) {\n stateRef.current.composedRef = composeRefs((x) => (stateRef.current.host = x), forwardedRef, setElementProps, animatedRef);\n }\n viewProps.ref = stateRef.current.composedRef;\n // handle pointer events (native: maps to touch events, web: no-op)\n usePointerEvents(props, viewProps);\n if (process.env.NODE_ENV === 'development') {\n if (!isReactNative && !isText && isWeb && !isHOC) {\n React.Children.toArray(props.children).forEach((item) => {\n // allow newlines because why not its annoying with mdx\n if (typeof item === 'string' && item !== '\\n') {\n console.error(`Unexpected text node: ${item}. A text node cannot be a child of a <${staticConfig.componentName || propsIn.tag || 'View'}>.`, props);\n }\n });\n }\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `events-hooks`;\n const unPress = () => {\n setStateShallow({ press: false, pressIn: false });\n };\n if (process.env.NODE_ENV === 'development' && isWeb) {\n useIsomorphicLayoutEffect(() => {\n if (debugProp === 'verbose') {\n function cssStyleDeclarationToObject(style) {\n const styleObject = {};\n for (let i = 0; i < style.length; i++) {\n let prop = style[i];\n styleObject[prop] = style.getPropertyValue(prop);\n }\n return styleObject;\n }\n const computed = stateRef.current.host\n ? cssStyleDeclarationToObject(getComputedStyle(stateRef.current.host))\n : {};\n console.groupCollapsed(`Rendered > (opacity: ${computed.opacity})`);\n console.warn(stateRef.current.host);\n console.warn(computed);\n console.groupEnd();\n }\n });\n }\n // Animation enter state machine: true -> 'should-enter' -> false\n // Stage 1: Set 'should-enter' synchronously before paint to apply enterStyle classes\n // Stage 2: After browser paint, set false to trigger CSS transition\n //\n // CRITICAL: useEffect does NOT guarantee post-paint execution!\n // See: https://thoughtspile.github.io/2021/11/15/unintentional-layout-effect/\n // When layoutEffect updates state → re-render before paint → useEffect flushes pre-paint\n // Solution: Double RAF ensures browser has actually painted before we transition\n useIsomorphicLayoutEffect(() => {\n if (state.unmounted === true && hasEnterStyle) {\n setStateShallow({ unmounted: 'should-enter' });\n return;\n }\n if (state.unmounted) {\n // For CSS transitions, we need browser to paint enterStyle before removing it.\n // Double RAF guarantees paint: first RAF schedules after current frame,\n // second RAF schedules after that frame completes (including paint).\n if (inputStyle === 'css') {\n let cancelled = false;\n requestAnimationFrame(() => {\n if (cancelled)\n return;\n requestAnimationFrame(() => {\n if (cancelled)\n return;\n setStateShallow({ unmounted: false });\n });\n });\n return () => {\n cancelled = true;\n };\n }\n // Non-CSS drivers handle their own animation timing\n setStateShallow({ unmounted: false });\n }\n return () => {\n componentSetStates.delete(setState);\n stateRef.current.mediaEmitCleanup?.();\n };\n }, [state.unmounted, inputStyle]);\n useIsomorphicLayoutEffect(() => {\n if (disabled)\n return;\n if (!pseudoGroups && !mediaGroups)\n return;\n if (!allGroupContexts)\n return;\n return subscribeToContextGroup({\n groupContext: allGroupContexts,\n setStateShallow,\n mediaGroups,\n pseudoGroups,\n });\n }, [\n allGroupContexts,\n disabled,\n pseudoGroups ? objectIdentityKey(pseudoGroups) : 0,\n mediaGroups ? objectIdentityKey(mediaGroups) : 0,\n ]);\n const groupEmitter = stateRef.current.group;\n useIsomorphicLayoutEffect(() => {\n if (!groupContext || !groupEmitter)\n return;\n notifyGroupSubscribers(groupContext, groupEmitter, state);\n }, [groupContext, groupEmitter, state]);\n // if its a group its gotta listen for pseudos to emit them to children\n const runtimePressStyle = !disabled && noClass && pseudos?.pressStyle;\n const runtimeFocusStyle = !disabled && noClass && pseudos?.focusStyle;\n const runtimeFocusVisibleStyle = !disabled && noClass && pseudos?.focusVisibleStyle;\n const attachFocus = Boolean(runtimePressStyle ||\n runtimeFocusStyle ||\n runtimeFocusVisibleStyle ||\n onFocus ||\n onBlur ||\n !!componentContext.setParentFocusState);\n const hasDynamicGroupChildren = Boolean(groupName && state.hasDynGroupChildren);\n const attachPress = Boolean(hasDynamicGroupChildren ||\n runtimePressStyle ||\n onPress ||\n onPressOut ||\n onPressIn ||\n onMouseDown ||\n onMouseUp ||\n onLongPress ||\n onClick ||\n pseudos?.focusVisibleStyle);\n const runtimeHoverStyle = !disabled && noClass && pseudos?.hoverStyle;\n // with a platform pseudo driver the hover STATE is driver-sourced; only keep\n // the JS hover listeners when something else needs them (dynamic group\n // children, or the user's own onMouseEnter/Leave handlers below).\n const needsHoverState = Boolean(hasDynamicGroupChildren || (runtimeHoverStyle && !platformPseudo));\n const attachHover = (isWeb || isNativeDesktop) &&\n !!(hasDynamicGroupChildren || needsHoverState || onMouseEnter || onMouseLeave);\n // check presence rather than value to prevent reparenting bugs\n // allows for onPress={x ? function : undefined} without re-ordering dom\n const shouldAttach = !disabled &&\n !props.asChild &&\n Boolean(attachFocus ||\n attachPress ||\n attachHover ||\n runtimePressStyle ||\n runtimeHoverStyle ||\n runtimeFocusStyle);\n const needsPressState = Boolean(hasDynamicGroupChildren || runtimePressStyle);\n if (process.env.NODE_ENV === 'development' && time)\n time `events-setup`;\n if (process.env.NODE_ENV === 'development' && debugProp === 'verbose') {\n log(`🪩 events()`, {\n runtimeFocusStyle,\n runtimePressStyle,\n runtimeHoverStyle,\n runtimeFocusVisibleStyle,\n attachPress,\n attachFocus,\n attachHover,\n shouldAttach,\n needsHoverState,\n pseudos,\n });\n }\n const events = shouldAttach\n ? {\n onPressOut: attachPress\n ? (e) => {\n unPress();\n onPressOut?.(e);\n onMouseUp?.(e);\n }\n : undefined,\n ...((attachHover || attachPress) && {\n onMouseEnter: (e) => {\n const next = {};\n // Don't set hover on touch devices - touch triggers mouseenter\n // but there's no corresponding mouseleave on touch end\n if (needsHoverState && !lastInteractionWasTouch.value) {\n next.hover = true;\n }\n if (needsPressState) {\n if (state.pressIn) {\n next.press = true;\n }\n }\n setStateShallow(next);\n onHoverIn?.(e);\n onMouseEnter?.(e);\n },\n onMouseLeave: (e) => {\n const next = {};\n if (needsHoverState) {\n next.hover = false;\n }\n if (needsPressState) {\n next.press = false;\n next.pressIn = false;\n }\n setStateShallow(next);\n onHoverOut?.(e);\n onMouseLeave?.(e);\n },\n }),\n onPressIn: attachPress\n ? (e) => {\n if (needsPressState) {\n setStateShallow({\n press: true,\n pressIn: true,\n });\n }\n onPressIn?.(e);\n onMouseDown?.(e);\n if (isWeb) {\n componentSetStates.add(setState);\n }\n }\n : undefined,\n onPress: attachPress\n ? (e) => {\n unPress();\n if (\"web\" === 'web') {\n // @ts-ignore\n onClick?.(e);\n // matches RN pressable behavior - only when an explicit press\n // handler is set, so pressStyle alone doesn't swallow clicks\n if (onPress || onClick) {\n e.stopPropagation();\n }\n }\n onPress?.(e);\n if (\"web\" === 'web') {\n onLongPress?.(e);\n }\n }\n : undefined,\n ...(\"web\" === 'native' &&\n attachPress &&\n onLongPress && {\n onLongPress: (e) => {\n unPress();\n onLongPress?.(e);\n },\n }),\n ...(attachFocus && {\n onFocus: (e) => {\n const next = {};\n if (componentContext.setParentFocusState) {\n componentContext.setParentFocusState({ focusWithin: true });\n next.focusWithin = true;\n }\n if (pseudos?.focusVisibleStyle) {\n if (lastInteractionWasKeyboard.value) {\n next.focusVisible = true;\n }\n else {\n next.focus = true;\n }\n }\n else {\n next.focus = true;\n }\n setStateShallow(next);\n onFocus?.(e);\n },\n onBlur: (e) => {\n if (componentContext.setParentFocusState) {\n componentContext.setParentFocusState({ focusWithin: false });\n }\n setStateShallow({\n focus: false,\n focusVisible: false,\n focusWithin: false,\n });\n onBlur?.(e);\n },\n }),\n }\n : null;\n if (\"web\" === 'native' && events && !asChild) {\n // replicating TouchableWithoutFeedback\n Object.assign(events, {\n cancelable: !viewProps.rejectResponderTermination,\n disabled: disabled,\n hitSlop: viewProps.hitSlop,\n delayLongPress: viewProps.delayLongPress,\n delayPressIn: viewProps.delayPressIn,\n delayPressOut: viewProps.delayPressOut,\n focusable: viewProps.focusable ?? true,\n minPressDuration: 0,\n });\n }\n if (\"web\" === 'web' && events && !isReactNative) {\n Object.assign(viewProps, getWebEvents(events));\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `events`;\n if (process.env.NODE_ENV === 'development' && debugProp === 'verbose') {\n log(`events`, { events, attachHover, attachPress });\n }\n const propsWithHref = props;\n const propsInWithHref = propsIn;\n const pressDebugDetail = props.testID ??\n propsIn.testID ??\n props.accessibilityLabel ??\n propsIn.accessibilityLabel ??\n (typeof propsWithHref.href === 'string' ? propsWithHref.href : null) ??\n (typeof propsInWithHref.href === 'string' ? propsInWithHref.href : null);\n const pressDebugName = [componentName, pressDebugDetail].filter(Boolean).join(':') || null;\n // EVENTS native - handles focus/blur, input special cases, and RNGH press handling\n // Skip gesture setup for HOC components - they may return null which crashes GestureDetector\n // hasRealPressEvents distinguishes user-provided handlers from events.onPress\n // synthesized for pressStyle alone — only the former should claim the responder.\n const hasRealPressEvents = !!(onPress || onPressIn || onPressOut || onLongPress);\n const pressGesture = \"web\" === 'native'\n ? useEvents(events, viewProps, stateRef, staticConfig, isHOC, isInsideNativeMenu, pressDebugName, hasRealPressEvents)\n : null;\n if (process.env.NODE_ENV === 'development' && time)\n time `hooks`;\n if (asChild) {\n elementType = Slot;\n // on native this is already merged into viewProps in useEvents\n if (\"web\" === 'web') {\n const webStyleEvents = asChild === 'web' || asChild === 'except-style-web';\n const passEvents = getWebEvents({\n onPress,\n onLongPress,\n onPressIn,\n onPressOut,\n onMouseUp,\n onMouseDown,\n onMouseEnter,\n onMouseLeave,\n }, webStyleEvents);\n Object.assign(viewProps, passEvents);\n }\n else {\n Object.assign(viewProps, { onPress, onLongPress });\n }\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `spaced-as-child`;\n // Stamp a neutral, standard structural annotation (data-slot) on the web host\n // node so analytics can self-describe with zero app config. Named components\n // only; overridable — passing your own `data-slot` (any value) opts out.\n // No-op on native (isWeb compiles to false there). asChild flows via Slot,\n // which merges viewProps onto the child host, so it is covered too.\n if (isWeb && componentName && !('data-slot' in viewProps)) {\n viewProps['data-slot'] = dataSlotFor(componentName);\n }\n let content;\n if (isPassthrough) {\n // avoid re-parenting but avoid layout changes\n content = React.createElement(BaseComponent, {\n style: {\n display: 'contents',\n },\n }, propsIn.children);\n }\n else {\n // here elementType is either the custom animated driver view, or base view\n if (hooks.useChildren) {\n // ONLY native:\n content = hooks.useChildren(elementType, content || children, viewProps);\n }\n const isRenderPropString = typeof renderProp === 'string';\n // this ONLY handles the case where render is NOT a string\n // either direct JSX, or a function that returns JSX, we always clone\n if (renderProp && !isRenderPropString) {\n const out = getCustomRender(renderProp, content || children, viewProps, componentState);\n if (out) {\n viewProps = out.viewProps;\n elementType = out.elementType;\n }\n }\n if (!content) {\n // web-only, handle render === string passing to custom animated component\n if (isRenderPropString) {\n viewProps.render === renderProp;\n }\n content = React.createElement(elementType, viewProps, content || children);\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `use-children`;\n }\n // wrap with GestureDetector for RNGH press handling (native only, no-op on web)\n // Skip for HOC and composite components - they pass press events to inner component instead\n if (\"web\" === 'native') {\n const isCompositeComponent = !isHOC && Component && typeof Component !== 'string';\n content = wrapWithGestureDetector(content, pressGesture, stateRef, isHOC, isCompositeComponent, hasRealPressEvents);\n }\n // needs to reset the presence state for nested children\n // Use the resolved animationDriver (handles multi-driver config)\n const ResetPresence = animationDriver?.ResetPresence;\n const needsReset = Boolean(\n // not when passing down to child\n !asChild &&\n // not when passThrough\n splitStyles &&\n // not when HOC\n !isHOC &&\n ResetPresence &&\n willBeAnimated &&\n (hasEnterStyle || presenceState));\n // avoid re-parenting\n const hasEverReset = stateRef.current.hasEverResetPresence;\n if (needsReset && !hasEverReset) {\n stateRef.current.hasEverResetPresence = true;\n }\n const renderReset = needsReset || hasEverReset;\n if (renderReset && ResetPresence) {\n content = _jsx(ResetPresence, { disabled: !needsReset, children: content });\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `create-element`;\n if ('focusWithinStyle' in propsIn || pseudos?.focusWithinStyle) {\n content = (_jsx(ComponentContext.Provider, { ...componentContext, setParentFocusState: setStateShallow, children: content }));\n }\n if ('group' in props) {\n content = (_jsx(GroupContext.Provider, { value: allGroupContexts, children: content }));\n }\n // Text components set inText context for children so nested Text can inherit styles\n if (\"web\" === 'web' && !asChild && isText && !hasTextAncestor) {\n content = (_jsx(ComponentContext.Provider, { ...componentContext, inText: true, children: content }));\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `group-context`;\n content =\n disableTheme || !splitStyles\n ? content\n : getThemedChildren(themeState, content, themeStateProps, false, stateRef);\n if (process.env.NODE_ENV === 'development' && time)\n time `themed-children`;\n if (\"web\" === 'web') {\n if (isReactNative && !asChild) {\n content = (_jsx(\"span\", { className: \"_dsp_contents\", ...(!isPassthrough && isHydrated && events && getWebEvents(events)), children: content }));\n }\n }\n if (overriddenContextProps && contextForOverride) {\n const Provider = contextForOverride.Provider;\n // make sure we re-order styled context keys based on how we pass them here:\n for (const key in styledContextValue) {\n if (!(key in overriddenContextProps)) {\n overriddenContextProps[key] = styledContextValue[key];\n }\n }\n content = (_jsx(Provider, { __disableMergeDefaultValues: true, ...overriddenContextProps, children: content }));\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `context-override`;\n // SSR style support - for non compiled styles we render them inline until client takes over\n // on client we then switch over to our global sheet insert, because rendering inline is expensive\n if (\"web\" === 'web' && startedUnhydrated && splitStyles) {\n content = (_jsxs(_Fragment, { children: [content, !isHydrated ? getStyleTags(Object.values(splitStyles.rulesToInsert)) : null] }));\n }\n if (process.env.NODE_ENV === 'development' && time)\n time `style-tags`;\n if (process.env.NODE_ENV === 'development') {\n if (debugProp && debugProp !== 'profile') {\n const element = typeof elementType === 'string' ? elementType : 'Component';\n const title = `render <${element} /> (${internalID}) with props`;\n if (!isWeb || !isClient) {\n log(title);\n log(`state: `, state);\n if (isDevTools) {\n log('viewProps', viewProps);\n }\n log(`final styles:`);\n for (const key in splitStylesStyle) {\n log(key, splitStylesStyle[key]);\n }\n }\n else {\n console.groupCollapsed(title);\n try {\n log('viewProps', viewProps);\n log('children', content);\n if (typeof window !== 'undefined') {\n log({\n propsIn,\n props,\n attachPress,\n animationStyles,\n classNames,\n content,\n elementType,\n events,\n isAnimated,\n hasRuntimeMediaKeys,\n isStringElement,\n mediaListeningKeys,\n pseudos,\n shouldAttach,\n noClass,\n shouldListenForMedia,\n splitStyles,\n splitStylesStyle,\n state,\n stateRef,\n staticConfig,\n styleProps,\n themeState,\n viewProps,\n willBeAnimated,\n startedUnhydrated,\n });\n }\n }\n catch {\n // RN can run into PayloadTooLargeError: request entity too large\n }\n finally {\n console.groupEnd();\n }\n }\n if (debugProp === 'break') {\n // debugger intentionally here for debugging\n }\n }\n }\n if (process.env.NODE_ENV === 'development' && time) {\n time `rest`;\n if (!globalThis['willPrint']) {\n globalThis['willPrint'] = true;\n setTimeout(() => {\n delete globalThis['willPrint'];\n time.print();\n time = null;\n }, 50);\n }\n }\n return content;\n });\n function notifyGroupSubscribers(groupContext, groupEmitter, pseudo) {\n if (!groupContext || !groupEmitter) {\n return;\n }\n const prevPseudo = groupContext.state.pseudo;\n const shouldReplacePseudo = !prevPseudo ||\n // old/default state objects carry non-pseudo fields; replace once instead\n // of mutating the shared defaultComponentStateMounted object\n 'unmounted' in prevPseudo ||\n 'group' in prevPseudo ||\n 'hasDynGroupChildren' in prevPseudo ||\n 'transition' in prevPseudo;\n const nextPseudo = shouldReplacePseudo ? {} : prevPseudo;\n let didChange = shouldReplacePseudo;\n for (let i = 0; i < groupPseudoKeys.length; i++) {\n const key = groupPseudoKeys[i];\n const value = pseudo[key];\n if (nextPseudo[key] !== value) {\n nextPseudo[key] = value;\n didChange = true;\n }\n else if (didChange) {\n nextPseudo[key] = value;\n }\n }\n if (!didChange) {\n return;\n }\n groupContext.state.pseudo = nextPseudo;\n groupEmitter.emit(groupContext.state);\n }\n // let hasLogged = false\n if (staticConfig.componentName) {\n component.displayName = staticConfig.componentName;\n }\n let res = component;\n // we now have avoid re-renders in many more cases so imo this is way more worth it\n // Text/Button/string taking components\n // + react compiler can memoize children too\n res = React.memo(res);\n res.staticConfig = staticConfig;\n function extendStyledConfig(extended) {\n return {\n ...staticConfig,\n ...extended,\n neverFlatten: true,\n isHOC: true,\n isStyledHOC: false,\n };\n }\n function styleable(Component, options) {\n const skipForwardRef = typeof Component === 'function' && Component.length === 1;\n let out = skipForwardRef ? Component : React.forwardRef(Component);\n const extendedConfig = extendStyledConfig(options?.staticConfig);\n out = options?.disableTheme ? out : themeable(out, extendedConfig, true);\n if (extendedConfig.memo || process.env.GUI_MEMOIZE_STYLEABLE) {\n out = React.memo(out);\n }\n out.staticConfig = extendedConfig;\n out.styleable = styleable;\n return out;\n }\n res.styleable = styleable;\n return res;\n}\nconst fromPx = (val) => {\n if (typeof val === 'number')\n return val;\n if (typeof val === 'string')\n return +val.replace('px', '');\n return 0;\n};\n// handles all render logic - returns a new component\nconst getCustomRender = (renderProp, content, viewProps, state) => {\n // Handle render prop variants: function, JSX element, or string\n if (typeof renderProp === 'function') {\n // Render function: full control with props and state\n const out = renderProp(viewProps, state);\n renderProp = getRenderElementForPlatform(out);\n }\n if (renderProp) {\n if (typeof renderProp === 'object' && React.isValidElement(renderProp)) {\n // JSX element: clone with merged props\n const renderElement = getRenderElementForPlatform(renderProp);\n if (renderElement) {\n const elementProps = renderProp.props;\n const mergedProps = elementProps\n ? mergeRenderElementProps(elementProps, viewProps, content)\n : viewProps;\n return {\n elementType: renderProp.type,\n viewProps: mergedProps,\n };\n }\n }\n }\n};\n// avoid passing web-only elements to native\nfunction getRenderElementForPlatform(potential) {\n if (\"web\" === 'native') {\n if (isHTMLElement(potential)) {\n return;\n }\n }\n return potential;\n}\nfunction isHTMLElement(el) {\n return typeof el['type'] === 'string' && el['type'][0] === el['type'][0].toLowerCase();\n}\n//# sourceMappingURL=createComponent.js.map","import { createCSSVariable, getVariableValue } from '../createVariable.js';\nexport const registerCSSVariable = (v) => {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n tokensValueToVariable.set(getVariableValue(v), v);\n }\n};\nexport const variableToCSS = (v, unitless = false) => {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n return `--${process.env.GUI_CSS_VARIABLE_PREFIX || ''}${createCSSVariable(v.name, false)}:${!unitless && typeof v.val === 'number' ? `${v.val}px` : v.val}`;\n }\n return '';\n};\nexport const tokensValueToVariable = new Map();\n// auto-generated vars for theme values not in tokens\nlet autoVarId = 0;\nexport const autoVariables = [];\nexport const getOrCreateVariable = (val) => {\n if (tokensValueToVariable.has(val)) {\n return tokensValueToVariable.get(val);\n }\n const name = `t${autoVarId++}`;\n const variable = `var(--${name})`;\n const v = { val, name, variable };\n tokensValueToVariable.set(val, v);\n autoVariables.push(v);\n return v;\n};\n// For mutated themes (runtime theme changes like in /theme builder)\n// Uses same 't' prefix but starts at 10000 to avoid conflicts with SSR-generated vars\nlet mutatedVarId = 10000;\nexport const mutatedAutoVariables = [];\nconst mutatedTokensValueToVariable = new Map();\nexport const getOrCreateMutatedVariable = (val) => {\n if (mutatedTokensValueToVariable.has(val)) {\n return mutatedTokensValueToVariable.get(val);\n }\n const name = `t${mutatedVarId++}`;\n const variable = `var(--${name})`;\n const v = { val, name, variable };\n mutatedTokensValueToVariable.set(val, v);\n mutatedAutoVariables.push(v);\n return v;\n};\n//# sourceMappingURL=registerCSSVariable.js.map","import { simpleHash } from '@hanzogui/helpers';\nimport { getSetting } from '../config.js';\nimport { THEME_CLASSNAME_PREFIX } from '../constants/constants.js';\nimport { variableToString } from '../createVariable.js';\nimport { getOrCreateVariable, getOrCreateMutatedVariable } from './registerCSSVariable.js';\nimport { sortString } from './sortString.js';\nconst darkLight = ['dark', 'light'];\nconst lightDark = ['light', 'dark'];\nexport function getThemeCSSRules(props) {\n if (process.env.GUI_DID_OUTPUT_CSS) {\n // empty - CSS already extracted at build time\n }\n else if (\"web\" === 'native') {\n // no CSS on native\n }\n else if (!process.env.GUI_DOES_SSR_CSS ||\n process.env.GUI_DOES_SSR_CSS === 'mutates-themes' ||\n process.env.GUI_DOES_SSR_CSS === 'false') {\n const cssRuleSets = [];\n const { config, themeName, theme, names } = props;\n // special case for SSR\n const hasDarkLight = props.hasDarkLight ??\n (config.themes && ('light' in config.themes || 'dark' in config.themes));\n const CNP = `.${THEME_CLASSNAME_PREFIX}`;\n let vars = '';\n const variableCreator = props.useMutatedVariables\n ? getOrCreateMutatedVariable\n : getOrCreateVariable;\n for (const themeKey in theme) {\n const variable = theme[themeKey];\n const value = variableCreator(variable.val).variable;\n // Hash themeKey in case it has invalid chars too\n vars += `--${process.env.GUI_CSS_VARIABLE_PREFIX || ''}${simpleHash(themeKey, 40)}:${value};`;\n }\n const isDarkBase = themeName === 'dark';\n const isLightBase = themeName === 'light';\n const baseSelectors = names.map((name) => `${CNP}${name}`);\n const selectorsSet = new Set(isDarkBase || isLightBase ? baseSelectors : []);\n // since we dont specify dark/light in classnames we have to do an awkward specificity war\n // hardcoded to support 2 levels of nesting (e.g. light > dark or dark > light)\n if (hasDarkLight) {\n const maxDepth = 2;\n for (const subName of names) {\n const isDark = isDarkBase || subName.startsWith('dark_');\n const isLight = !isDark && (isLightBase || subName.startsWith('light_'));\n if (!(isDark || isLight)) {\n // neither light nor dark subtheme, just generate one selector with :root:root which\n // will override all :root light/dark selectors generated below\n selectorsSet.add(`${CNP}${subName}`);\n continue;\n }\n const childSelector = `${CNP}${subName.replace(/^(dark|light)_/, '')}`;\n const order = isDark ? darkLight : lightDark;\n const [stronger, weaker] = order;\n const numSelectors = Math.round(maxDepth * 1.5);\n for (let depth = 0; depth < numSelectors; depth++) {\n const isOdd = depth % 2 === 1;\n if (isOdd && depth < 3) {\n continue;\n }\n const parents = new Array(depth + 1).fill(0).map((_, idx) => {\n return `${CNP}${idx % 2 === 0 ? stronger : weaker}`;\n });\n let parentSelectors = parents.length > 1 ? parents.slice(1) : parents;\n if (isOdd) {\n const [_first, second, ...rest] = parentSelectors;\n parentSelectors = [second, ...rest, second];\n }\n const lastParentSelector = parentSelectors[parentSelectors.length - 1];\n const nextChildSelector = childSelector === lastParentSelector ? '' : childSelector;\n // for light/dark/light:\n const parentSelectorString = parentSelectors.join(' ');\n selectorsSet.add(`${parentSelectorString} ${nextChildSelector}`);\n }\n }\n }\n const selectors = [...selectorsSet].sort(sortString);\n // only do our :root attach if it's not light/dark - not support sub themes on root saves a lot of effort/size\n const selectorsString = selectors\n .map((x) => {\n const addTo = getSetting('addThemeClassName');\n const isOnRoot = isBaseTheme(x) && (addTo === 'html' || addTo === 'body');\n if (!isOnRoot)\n return `:root ${x}`;\n return `${addTo === 'body' ? 'body' : ':root'}${x}`;\n })\n .join(', ') + `, .tm_xxt`;\n const css = `${selectorsString} {${vars}}`;\n cssRuleSets.push(css);\n if (getSetting('shouldAddPrefersColorThemes')) {\n const isDark = themeName.startsWith('dark');\n const baseName = isDark ? 'dark' : 'light';\n const lessSpecificSelectors = selectors\n .map((x) => {\n if (x == darkSelector || x === lightSelector)\n return `:root`;\n if ((isDark && x.startsWith(lightSelector)) ||\n (!isDark && x.startsWith(darkSelector))) {\n return;\n }\n return x.replace(/^\\.t_(dark|light) /, '').trim();\n })\n .filter(Boolean)\n .join(', ');\n // only emit body background/color for base themes, not every sub-theme\n const isBase = !themeName.includes('_');\n let bodyRulesString = '';\n if (isBase) {\n const bgString = theme.background\n ? `background:${variableToString(theme.background)};`\n : '';\n const fgString = theme.color ? `color:${variableToString(theme.color)}` : '';\n bodyRulesString = bgString || fgString ? `body{${bgString}${fgString}}\\n ` : '';\n }\n const themeRules = `${lessSpecificSelectors} {${vars}}`;\n const prefersMediaSelectors = `@media(prefers-color-scheme:${baseName}){\n ${bodyRulesString}${themeRules}\n }`;\n cssRuleSets.push(prefersMediaSelectors);\n }\n const selectionStyles = getSetting('selectionStyles');\n if (selectionStyles) {\n const rules = selectionStyles(theme);\n if (rules) {\n const selectionSelectors = baseSelectors.map((s) => `${s} ::selection`).join(', ');\n const styles = Object.entries(rules)\n .flatMap(([k, v]) => v\n ? `${k === 'backgroundColor' ? 'background' : k}:${variableToString(v)}`\n : [])\n .join(';');\n if (styles) {\n const css = `${selectionSelectors}{${styles}}`;\n cssRuleSets.push(css);\n }\n }\n }\n return cssRuleSets;\n }\n return [];\n}\nconst darkSelector = '.t_dark';\nconst lightSelector = '.t_light';\nconst isBaseTheme = (x) => x === darkSelector ||\n x === lightSelector ||\n x.startsWith('.t_dark ') ||\n x.startsWith('.t_light ');\n//# sourceMappingURL=getThemeCSSRules.js.map","const themesRaw = {};\n// this seems expensive but its necessary to do two loops unless we want to refactor a variety of things again\n// not *too* much work but not a big cost doing the two loops\nexport function proxyThemesToParents(dedupedThemes) {\n // fill it in so we can look it up next\n for (const { names, theme } of dedupedThemes) {\n for (const name of names) {\n themesRaw[name] = theme;\n }\n }\n const themes = {};\n // now go back and re-fill it in\n // we do have to call this once per non-duplicated theme!\n // because they could have different parent chains\n // despite being the same theme\n for (const { names, theme } of dedupedThemes) {\n for (const themeName of names) {\n const proxiedTheme = proxyThemeToParents(themeName, theme);\n themes[themeName] = proxiedTheme;\n }\n }\n return themes;\n}\nexport function proxyThemeToParents(themeName, theme) {\n const out = {};\n const cur = [];\n // if theme is dark_blue_alt1_Button\n // this will be the parent names in order: ['dark', 'dark_blue', 'dark_blue_alt1\"]\n const parents = themeName\n .split('_')\n .slice(0, -1)\n .map((part) => {\n cur.push(part);\n return cur.join('_');\n });\n for (const parent of parents) {\n Object.assign(out, themesRaw[parent]);\n }\n Object.assign(out, theme);\n return out;\n}\n//# sourceMappingURL=proxyThemeToParents.js.map","import { createVariable, isVariable } from '../createVariable.js';\n// mutates, freeze after\n// shared by createGui so extracted here\nexport function ensureThemeVariable(theme, key) {\n const val = theme[key];\n if (!isVariable(val)) {\n theme[key] = createVariable({\n key,\n name: key,\n val,\n });\n }\n else {\n if (val.name !== key) {\n // rename to theme name\n theme[key] = createVariable({\n key: val.name,\n name: key,\n val: val.val,\n });\n }\n }\n}\n//# sourceMappingURL=themes.js.map","import { isWeb } from '@hanzogui/constants';\nimport { simpleHash } from '@hanzogui/helpers';\nimport { createVariable, isVariable } from './createVariable.js';\nconst cache = new WeakMap();\n// recursive...\nexport const createVariables = (tokens, parentPath = '', isFont = false) => {\n if (cache.has(tokens))\n return tokens;\n const res = {};\n let i = 0;\n for (let keyIn in tokens) {\n i++;\n const val = tokens[keyIn];\n const isPrefixed = keyIn[0] === '$';\n const keyWithPrefix = isPrefixed ? keyIn : `$${keyIn}`;\n const key = isPrefixed ? keyWithPrefix.slice(1) : keyIn;\n if (isVariable(val)) {\n res[key] = val;\n continue;\n }\n const niceKey = simpleHash(key, 1000);\n const name = parentPath && parentPath !== 't-color' ? `${parentPath}-${niceKey}` : `c-${niceKey}`;\n // Handle px() helper objects\n if (val && typeof val === 'object' && 'needsPx' in val && 'val' in val) {\n const finalValue = createVariable({\n val: val.val,\n name,\n key: keyWithPrefix,\n });\n // Only set needsPx flag on web platform, avoid on native\n if (isWeb) {\n finalValue.needsPx = val.needsPx;\n }\n res[key] = finalValue;\n continue;\n }\n if (val && typeof val === 'object') {\n // recurse\n res[key] = createVariables(tokens[key], name, false /* note: don't pass isFont down, we want to avoid it past the first level */);\n continue;\n }\n const finalValue = isVariable(val)\n ? val\n : createVariable({ val, name, key: keyWithPrefix });\n res[key] = finalValue;\n }\n cache.set(res, true);\n return res;\n};\n//# sourceMappingURL=createVariables.js.map","const noAnimationDriver = (method) => {\n console.warn(`No animation driver configured. To use ${method}, you must pass \\`animations\\` to createGui. See: https://hanzogui.dev/docs/core/animations`);\n};\nconst createEmptyAnimationDriver = () => ({\n isReactNative: false,\n inputStyle: 'css',\n outputStyle: 'css',\n isStub: true,\n animations: {},\n useAnimations: () => noAnimationDriver('animations'),\n usePresence: () => noAnimationDriver('usePresence'),\n ResetPresence: () => noAnimationDriver('ResetPresence'),\n useAnimatedNumber: () => noAnimationDriver('useAnimatedNumber'),\n useAnimatedNumberStyle: () => noAnimationDriver('useAnimatedNumberStyle'),\n useAnimatedNumbersStyle: () => noAnimationDriver('useAnimatedNumbersStyle'),\n useAnimatedNumberReaction: () => noAnimationDriver('useAnimatedNumberReaction'),\n});\nexport const defaultAnimationDriver = createEmptyAnimationDriver();\n//# sourceMappingURL=defaultAnimationDriver.js.map","import { isWeb } from '@hanzogui/constants';\nimport { getVariableVariable, isVariable } from '../createVariable.js';\nimport { autoVariables, registerCSSVariable, variableToCSS, } from './registerCSSVariable.js';\nimport { getThemeCSSRules } from './getThemeCSSRules.js';\nimport { getAllRules } from './insertStyleRule.js';\n// helper to get font property CSS declarations\nfunction getFontPropertyDeclarations(fontParsed, tokenKey = '$true') {\n const props = ['font-family: var(--f-family)'];\n const getVarRef = (obj) => {\n const val = obj?.[tokenKey];\n if (isVariable(val)) {\n return getVariableVariable(val);\n }\n return undefined;\n };\n const letterSpacing = getVarRef(fontParsed.letterSpacing);\n if (letterSpacing)\n props.push(`letter-spacing: ${letterSpacing}`);\n const lineHeight = getVarRef(fontParsed.lineHeight);\n if (lineHeight)\n props.push(`line-height: ${lineHeight}`);\n const fontStyle = getVarRef(fontParsed.style);\n if (fontStyle)\n props.push(`font-style: ${fontStyle}`);\n const fontWeight = getVarRef(fontParsed.weight);\n if (fontWeight)\n props.push(`font-weight: ${fontWeight}`);\n return props;\n}\nexport { getFontPropertyDeclarations };\n/**\n * Generates CSS for tokens - registers CSS variables and builds declaration strings\n */\nexport function createTokenCSS(tokens, shouldTokenCategoryHaveUnits) {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n const declarations = [];\n const sortedTokenKeys = Object.keys(tokens).sort();\n for (const key of sortedTokenKeys) {\n const sortedSubKeys = Object.keys(tokens[key]).sort();\n for (const skey of sortedSubKeys) {\n const variable = tokens[key][skey];\n if (isWeb) {\n registerCSSVariable(variable);\n const variableNeedsPx = variable.needsPx === true;\n const categoryNeedsPx = shouldTokenCategoryHaveUnits(key);\n const shouldBeUnitless = !(variableNeedsPx || categoryNeedsPx);\n declarations.push(variableToCSS(variable, shouldBeUnitless));\n }\n }\n }\n return declarations;\n }\n return [];\n}\n/**\n * Generates CSS for fonts\n */\nexport function createFontCSS(fontsParsed, registerFontVariables) {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n const fontDeclarations = {};\n if (!fontsParsed)\n return fontDeclarations;\n const sortedFontKeys = Object.keys(fontsParsed).sort();\n for (const key of sortedFontKeys) {\n const fontParsed = fontsParsed[key];\n const [name, language] = key.includes('_') ? key.split('_') : [key];\n const fontVars = registerFontVariables(fontParsed);\n fontDeclarations[key] = {\n name: name.slice(1),\n declarations: fontVars,\n language,\n fontParsed,\n };\n }\n return fontDeclarations;\n }\n return {};\n}\n/**\n * Builds CSS rulesets from declarations\n */\nexport function buildCSSRuleSets(declarations, fontDeclarations, defaultFontToken = '$true') {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n const cssRuleSets = [];\n const sep = ' ';\n function declarationsToRuleSet(decs, selector = '') {\n return `:root${selector} {${sep}${[...decs].join(`;${sep}`)}\\n}`;\n }\n // non-font tokens\n if (declarations.length) {\n cssRuleSets.push(declarationsToRuleSet(declarations));\n }\n // fonts - each font_* sets CSS variables\n const fontSelectors = [];\n const sortedFontDeclarationKeys = Object.keys(fontDeclarations).sort();\n for (const key of sortedFontDeclarationKeys) {\n const { name, declarations, language = 'default' } = fontDeclarations[key];\n const fontSelector = `.font_${name}`;\n fontSelectors.push(fontSelector);\n const langSelector = `:root .t_lang-${name}-${language} ${fontSelector}`;\n const selectors = language === 'default' ? ` ${fontSelector}, ${langSelector}` : langSelector;\n const specificRuleSet = declarationsToRuleSet(declarations, selectors);\n cssRuleSets.push(specificRuleSet);\n }\n // shared rule: all font_* classes + is_View apply font properties\n // this resets fonts on Views like React Native does\n if (fontSelectors.length) {\n const firstFont = fontDeclarations[sortedFontDeclarationKeys[0]];\n if (firstFont?.fontParsed) {\n const fontProps = getFontPropertyDeclarations(firstFont.fontParsed, defaultFontToken);\n const sharedSelectors = [...fontSelectors, '.is_View'].join(', ');\n cssRuleSets.push(`${sharedSelectors} {${fontProps.join('; ')}}`);\n }\n }\n return cssRuleSets;\n }\n return [];\n}\n/**\n * Generates theme CSS rules\n */\nexport function createThemeCSS(dedupedThemes, configIn) {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n let themeRuleSets = [];\n if (isWeb) {\n for (const { names, theme } of dedupedThemes) {\n const nextRules = getThemeCSSRules({\n config: configIn,\n themeName: names[0],\n names,\n theme,\n });\n themeRuleSets = [...themeRuleSets, ...nextRules];\n }\n }\n return themeRuleSets;\n }\n return [];\n}\n/**\n * Gets all generated CSS - design system + runtime styles\n */\nexport function getCSS(themeConfig, opts = {}, lastIndex) {\n if (!process.env.GUI_DID_OUTPUT_CSS && \"web\" === 'web') {\n const { separator = '\\n', sinceLastCall, exclude } = opts;\n if (sinceLastCall && lastIndex.value >= 0) {\n const rules = getAllRules();\n const newRules = rules.slice(lastIndex.value);\n lastIndex.value = rules.length;\n return newRules.join(separator);\n }\n lastIndex.value = 0;\n const runtimeStyles = getAllRules().join(separator);\n if (exclude === 'design-system') {\n return runtimeStyles;\n }\n const themeRules = exclude ? '' : themeConfig.getThemeRulesSets().join(separator);\n // auto-generated vars from theme values not in tokens\n const autoVarCSS = autoVariables.length\n ? `:root{${autoVariables.map((v) => `--${v.name}:${v.val}`).join(';')}}`\n : '';\n // notes:\n // @scope (.is_Text) to (.is_View) - inherit text styles in nested Text without View boundary\n // display: inline breaks css transform styles\n // !important or else random css easily overrides, the prop is absolute (local-first styling)\n const hideScrollBarsCSS = `._hsb-x::-webkit-scrollbar:horizontal { display: none !important; }\n._hsb-y::-webkit-scrollbar:vertical { display: none !important; }\n._hsb-x { scrollbar-width: none !important; }\n._hsb-y { scrollbar-width: none !important; }`;\n const pointerEventsCSS = `:root ._pe-boxonly>* {pointer-events:none;}\n:root ._pe-boxnone>* {pointer-events:auto;}`;\n const designSystem = `._ovs-contain {overscroll-behavior:contain;}\n.t_unmounted .is_View, .t_unmounted .is_Text { transition: none !important; }\n.is_View { display: flex; align-items: stretch; flex-direction: column; flex-basis: auto; box-sizing: border-box; min-height: 0; min-width: 0; flex-shrink: 0; }\n.is_Text { display: inline; box-sizing: border-box; word-wrap: break-word; white-space: pre-wrap; margin: 0; }\n@scope (.is_Text) to (.is_View) { .is_Text { white-space: inherit; word-wrap: inherit; } }\n._dsp_contents {display:contents;}\n._no_backdrop::backdrop {display: none;}\n.is_Input::selection, .is_TextArea::selection {background-color: var(--t_selectionColor);}\n.is_Input::placeholder, .is_TextArea::placeholder {color: var(--t_placeholderColor);}\n${pointerEventsCSS}\n${hideScrollBarsCSS}\n${autoVarCSS}\n${themeConfig.cssRuleSets.join(separator)}`;\n return `${designSystem}\n${themeRules}\n${runtimeStyles}`;\n }\n return '';\n}\n//# sourceMappingURL=createDesignSystem.js.map","import { setConfigFont } from './config.js';\nimport { FONT_DATA_ATTRIBUTE_NAME } from './constants/constants.js';\nimport { createFont } from './createFont.js';\nimport { createVariables } from './createVariables.js';\nimport { registerCSSVariable, variableToCSS } from './helpers/registerCSSVariable.js';\n/**\n * Runtime dynamic insert font\n */\nexport function insertFont(name, fontIn) {\n const font = createFont(fontIn);\n const tokened = createVariables(font, name);\n const parsed = parseFont(tokened);\n if (\"web\" === 'web' && typeof document !== 'undefined') {\n const fontVars = registerFontVariables(parsed);\n const styleElement = document.querySelector(`style[${FONT_DATA_ATTRIBUTE_NAME}=\"${name}\"]`) ||\n document.createElement('style');\n styleElement.innerText = `:root .font_${name} {${fontVars.join(';')}}`;\n styleElement.setAttribute(FONT_DATA_ATTRIBUTE_NAME, name);\n document.head.appendChild(styleElement);\n }\n setConfigFont(name, tokened, parsed);\n return parsed;\n}\nexport const updateFont = insertFont;\nexport function parseFont(definition) {\n const parsed = {};\n for (const attrKey in definition) {\n const attr = definition[attrKey];\n if (attrKey === 'family' || attrKey === 'face') {\n parsed[attrKey] = attr;\n }\n else {\n parsed[attrKey] = {};\n for (const key in attr) {\n let val = attr[key];\n // is a theme reference\n if (val.val?.[0] === '$') {\n val = val.val;\n }\n parsed[attrKey][`$${key}`] = val;\n }\n }\n }\n return parsed;\n}\nexport function registerFontVariables(parsedFont) {\n if (!process.env.GUI_DID_OUTPUT_CSS) {\n const response = [];\n for (const fkey in parsedFont) {\n if (fkey === 'face')\n continue;\n if (fkey === 'family') {\n const val = parsedFont[fkey];\n registerCSSVariable(val);\n response.push(variableToCSS(val));\n }\n else {\n for (const fskey in parsedFont[fkey]) {\n const fval = parsedFont[fkey][fskey];\n if (typeof fval === 'string') {\n // no need to add its a theme reference like \"$borderColor\"\n }\n else {\n const val = parsedFont[fkey][fskey];\n registerCSSVariable(val);\n response.push(variableToCSS(val));\n }\n }\n }\n }\n return response;\n }\n return [];\n}\n//# sourceMappingURL=insertFont.js.map","import { getConfigMaybe, setConfig, setTokens } from './config.js';\nimport { createVariables } from './createVariables.js';\nimport { defaultAnimationDriver } from './helpers/defaultAnimationDriver.js';\nimport { resolveAnimationDriver } from './helpers/resolveAnimationDriver.js';\nimport { buildCSSRuleSets, createFontCSS, createThemeCSS, createTokenCSS, getCSS as getCSSHelper, } from './helpers/createDesignSystem.js';\nimport { scanAllSheets } from './helpers/insertStyleRule.js';\nimport { proxyThemesToParents } from './helpers/proxyThemeToParents.js';\nimport { ensureThemeVariable } from './helpers/themes.js';\nimport { configureMedia } from './hooks/useMedia.js';\nimport { parseFont, registerFontVariables } from './insertFont.js';\nimport { Gui } from './Gui.js';\n/**\n * Determines if a token category should have px units added.\n * Following the principle: only add px to predefined categories that need them.\n * Custom categories default to unitless.\n */\nfunction shouldTokenCategoryHaveUnits(category) {\n // From TokenCategories type: 'color' | 'space' | 'size' | 'radius' | 'zIndex'\n // These are the only predefined categories that should get px units\n const UNIT_CATEGORIES = new Set(['size', 'space', 'radius']);\n // Only add px to predefined dimensional categories\n // Custom categories (like 'opacity', 'customWidth') default to unitless\n return UNIT_CATEGORIES.has(category);\n}\n// code optimizers were causing issues by not calling both of these as esbuild had compiled them\n// pulling them into a single initializeGuiConfig to prevent that\nfunction initializeGuiConfig(config) {\n setConfig(config);\n configureMedia(config);\n}\nexport function createGui(configIn) {\n // if config already exists (e.g., from another copy of hanzogui in vite ssr), reuse it\n const existingConfig = getConfigMaybe();\n if (existingConfig) {\n // merge it and re-run since this new instance may add config\n // or maybe a test case\n configIn = { ...existingConfig, ...configIn };\n }\n // ensure variables\n const tokensParsed = {};\n const tokens = createVariables(configIn.tokens || {});\n if (configIn.tokens) {\n // faster lookups\n const tokensMerged = {};\n for (const cat in tokens) {\n tokensParsed[cat] = {};\n tokensMerged[cat] = {};\n const tokenCat = tokens[cat];\n for (const key in tokenCat) {\n const val = tokenCat[key];\n const prefixedKey = `$${key}`;\n tokensParsed[cat][prefixedKey] = val;\n tokensMerged[cat][prefixedKey] = val;\n tokensMerged[cat][key] = val;\n }\n }\n setTokens(tokensMerged);\n }\n let foundThemes;\n if (configIn.themes) {\n const noThemes = Object.keys(configIn.themes).length === 0;\n if (noThemes && !process.env.GUI_DID_OUTPUT_CSS) {\n foundThemes = scanAllSheets(noThemes, tokensParsed);\n }\n }\n let fontSizeTokens = null;\n let fontsParsed;\n if (configIn.fonts) {\n const fontTokens = Object.fromEntries(Object.entries(configIn.fonts).map(([k, v]) => {\n return [k, createVariables(v, 'f', true)];\n }));\n fontsParsed = (() => {\n const res = {};\n for (const familyName in fontTokens) {\n const font = fontTokens[familyName];\n const fontParsed = parseFont(font);\n res[`$${familyName}`] = fontParsed;\n if (!fontSizeTokens && fontParsed.size) {\n fontSizeTokens = new Set(Object.keys(fontParsed.size));\n }\n }\n return res;\n })();\n }\n const specificTokens = {};\n const themeConfig = (() => {\n // populate specificTokens (needed for runtime)\n const sortedTokenKeys = Object.keys(tokens).sort();\n for (const key of sortedTokenKeys) {\n const sortedSubKeys = Object.keys(tokens[key]).sort();\n for (const skey of sortedSubKeys) {\n const variable = tokens[key][skey];\n specificTokens[`$${key}.${skey}`] = variable;\n if (process.env.NODE_ENV === 'development') {\n if (typeof variable === 'undefined') {\n throw new Error(`No value for tokens.${key}.${skey}:\\n${JSON.stringify(variable, null, 2)}`);\n }\n }\n }\n }\n // CSS generation (tree-shaken when GUI_DID_OUTPUT_CSS is set)\n const declarations = createTokenCSS(tokens, shouldTokenCategoryHaveUnits);\n const fontDeclarations = createFontCSS(fontsParsed, registerFontVariables);\n const cssRuleSets = buildCSSRuleSets(declarations, fontDeclarations);\n const themesIn = configIn.themes;\n const dedupedThemes = foundThemes ?? getThemesDeduped(themesIn, tokens.color);\n const themes = proxyThemesToParents(dedupedThemes);\n return {\n themes,\n cssRuleSets,\n getThemeRulesSets() {\n return createThemeCSS(dedupedThemes, configIn);\n },\n };\n })();\n // Keep track of user-provided shorthands separately\n const userShorthands = configIn.shorthands || {};\n // Merge built-in shorthands with user shorthands (user takes precedence)\n const shorthands = { ...builtinShorthands, ...userShorthands };\n const lastCSSIndex = { value: -1 };\n const getCSS = (opts = {}) => {\n return getCSSHelper(themeConfig, opts, lastCSSIndex);\n };\n const getNewCSS = (opts) => getCSS({ ...opts, sinceLastCall: true });\n const defaultFontSetting = configIn.settings?.defaultFont;\n const defaultFont = (() => {\n let val = defaultFontSetting;\n if (val?.[0] === '$') {\n val = val.slice(1);\n }\n return val;\n })();\n const defaultPositionSetting = configIn.settings?.defaultPosition || 'static';\n const defaultProps = configIn.defaultProps || {};\n // apply defaultPosition via defaultProps when not static\n if (\"web\" === 'web' && defaultPositionSetting !== 'static') {\n defaultProps.View = {\n ...defaultProps.View,\n position: defaultPositionSetting,\n };\n }\n // ensure prefixed with $\n const defaultFontToken = defaultFont ? `$${defaultFont}` : '';\n // Text inherits font from root via CSS, no need for default fontFamily\n // only explicit fontFamily prop should add font_* class\n // normalize multi-driver animation config to default driver\n // supports format: { default: motionDriver, css: cssDriver }\n // stores full config in animationDrivers for component-level selection via animatedBy\n const inputAnimations = configIn.animations;\n const resolvedDriver = resolveAnimationDriver(inputAnimations);\n // multi-driver when resolveAnimationDriver extracted .default (returned different ref)\n const isMultiDriver = resolvedDriver !== null && resolvedDriver !== inputAnimations;\n const resolvedAnimations = resolvedDriver ?? inputAnimations;\n const animationDrivers = isMultiDriver\n ? inputAnimations\n : undefined;\n const config = {\n fonts: {},\n onlyAllowShorthands: false,\n fontLanguages: [],\n media: {},\n ...configIn,\n // normalized animations (resolved from multi-driver format if needed)\n animations: resolvedAnimations ?? defaultAnimationDriver,\n animationDrivers,\n defaultProps,\n settings: {\n webContainerType: 'inline-size',\n ...configIn.settings,\n },\n tokens: tokens,\n // vite made this into a function if it wasn't set\n shorthands,\n userShorthands,\n inverseShorthands: shorthands\n ? Object.fromEntries(Object.entries(shorthands).map(([k, v]) => [v, k]))\n : {},\n themes: themeConfig.themes,\n fontsParsed: fontsParsed || {},\n themeConfig,\n tokensParsed: tokensParsed,\n parsed: true,\n getNewCSS,\n getCSS,\n defaultFont,\n fontSizeTokens: fontSizeTokens || new Set(),\n specificTokens,\n defaultFontToken,\n // const tokens = [...getToken(tokens.size[0])]\n // .spacer-sm + ._dsp_contents._dsp-sm-hidden { margin-left: -var(--${}) }\n };\n initializeGuiConfig(config);\n if (process.env.NODE_ENV !== 'development') {\n return config;\n }\n if (process.env.DEBUG?.startsWith('hanzogui')) {\n console.info('Gui config:', config);\n }\n if (!globalThis['Gui']) {\n globalThis['Gui'] = Gui;\n }\n return config;\n}\n// dedupes the themes if given them via JS config\nfunction getThemesDeduped(themes, colorTokens) {\n const dedupedThemes = [];\n const existing = new Map();\n // Sort theme names for deterministic CSS output order\n const sortedThemeNames = Object.keys(themes).sort();\n // first, de-dupe and parse them\n for (const themeName of sortedThemeNames) {\n // forces us to separate the dark/light themes (otherwise we generate bad t_light prefix selectors)\n const darkOrLightSpecificPrefix = themeName.startsWith('dark')\n ? 'dark'\n : themeName.startsWith('light')\n ? 'light'\n : '';\n const rawTheme = themes[themeName];\n // dont force referential equality but may need something more consistent than JSON.stringify\n // separate between dark/light\n const key = darkOrLightSpecificPrefix + JSON.stringify(rawTheme);\n // if existing, avoid\n if (existing.has(key)) {\n const e = existing.get(key);\n e.names.push(themeName);\n continue;\n }\n // ensure each theme object unique for dedupe\n // is ThemeParsed because we call ensureThemeVariable\n // color tokens are spread first as fallbacks, theme values take precedence\n const theme = { ...colorTokens, ...rawTheme };\n // parse into variables\n for (const key in theme) {\n // make sure properly names theme variables\n ensureThemeVariable(theme, key);\n }\n // set deduped\n const deduped = {\n names: [themeName],\n theme,\n };\n dedupedThemes.push(deduped);\n existing.set(key, deduped);\n }\n return dedupedThemes;\n}\n// Built-in shorthands used internally for short classname generation\nconst builtinShorthands = {\n bblr: 'borderBottomLeftRadius',\n bbrr: 'borderBottomRightRadius',\n bbs: 'borderBottomStyle',\n bls: 'borderLeftStyle',\n brc: 'borderRightColor',\n brs: 'borderRightStyle',\n brw: 'borderRightWidth',\n bs: 'borderStyle',\n btc: 'borderTopColor',\n btlr: 'borderTopLeftRadius',\n btrr: 'borderTopRightRadius',\n bts: 'borderTopStyle',\n btw: 'borderTopWidth',\n bw: 'borderWidth',\n bxs: 'boxSizing',\n bxsh: 'boxShadow',\n col: 'color',\n cur: 'cursor',\n dsp: 'display',\n fb: 'flexBasis',\n fd: 'flexDirection',\n ff: 'fontFamily',\n fs: 'fontSize',\n fst: 'fontStyle',\n fw: 'fontWeight',\n fwr: 'flexWrap',\n // height: 'h',\n lh: 'lineHeight',\n ls: 'letterSpacing',\n o: 'opacity',\n ov: 'overflow',\n ox: 'overflowX',\n oy: 'overflowY',\n pe: 'pointerEvents',\n pos: 'position',\n td: 'textDecorationLine',\n tr: 'transform',\n tt: 'textTransform',\n va: 'verticalAlign',\n wb: 'wordBreak',\n // width: 'w',\n ws: 'whiteSpace',\n ww: 'wordWrap',\n};\n//# sourceMappingURL=createGui.js.map","const ReactNativeStaticConfigs = new WeakMap();\nexport function getReactNativeConfig(Component) {\n if (!Component)\n return;\n if (\"web\" === 'native') {\n if (Component.propTypes?.onTextInput || Component.propTypes?.onChangeText) {\n return RNConfigs.TextInput;\n }\n if (Component.getSizeWithHeaders) {\n return RNConfigs.Image;\n }\n if (Component.propTypes?.textBreakStrategy) {\n return RNConfigs.Text;\n }\n // can optimize plain View or Text to not be react native specific\n // can assume everything else is react native on native\n return RNConfigs.default;\n }\n if (Component.getSize && Component.prefetch) {\n return RNConfigs.Image;\n }\n if (Component.displayName === 'Text' && Component.render) {\n return RNConfigs.Text;\n }\n if (Component.render &&\n (Component.displayName === 'ScrollView' || Component.displayName === 'View')) {\n return RNConfigs.default;\n }\n if (Component.State?.blurTextInput) {\n return RNConfigs.TextInput;\n }\n return ReactNativeStaticConfigs.get(Component);\n}\nconst RNConfigs = {\n Image: {\n isReactNative: true,\n inlineProps: new Set(['src', 'width', 'height']),\n },\n Text: {\n isReactNative: true,\n isText: true,\n },\n TextInput: {\n isReactNative: true,\n isInput: true,\n isText: true,\n },\n default: {\n isReactNative: true,\n },\n};\n//# sourceMappingURL=setupReactNative.js.map","// deep merge variants\n// except for functions which override any parents\nexport const mergeVariants = (parentVariants, ourVariants, level = 0) => {\n const variants = {};\n for (const key in ourVariants) {\n const parentVariant = parentVariants?.[key];\n const ourVariant = ourVariants[key];\n if (!parentVariant || typeof ourVariant === 'function') {\n variants[key] = ourVariant;\n }\n else if (parentVariant && !ourVariant) {\n variants[key] = parentVariant[key];\n }\n else {\n if (level === 0) {\n variants[key] = mergeVariants(parentVariant, ourVariant, level + 1);\n }\n else {\n variants[key] = {\n ...parentVariant,\n ...ourVariant,\n };\n }\n }\n }\n return {\n ...parentVariants,\n ...variants,\n };\n};\n//# sourceMappingURL=mergeVariants.js.map","import { createComponent } from './createComponent.js';\nimport { mergeVariants } from './helpers/mergeVariants.js';\nimport { getReactNativeConfig } from './setupReactNative.js';\n// runtime check for text-like elements\nconst textLikeElements = new Set([\n 'a',\n 'abbr',\n 'b',\n 'bdi',\n 'bdo',\n 'cite',\n 'code',\n 'data',\n 'del',\n 'dfn',\n 'em',\n 'i',\n 'ins',\n 'kbd',\n 'label',\n 'mark',\n 'q',\n 's',\n 'samp',\n 'small',\n 'span',\n 'strong',\n 'sub',\n 'sup',\n 'time',\n 'u',\n 'var',\n]);\n/**\n * styledHtml() for HTML element tags like 'a', 'button', 'div', etc.\n * Automatically provides element-specific props (href for anchors, type for buttons, etc.)\n *\n * @example\n * const StyledAnchor = styledHtml('a', {\n * color: '$blue10',\n * textDecorationLine: 'underline',\n * })\n * // StyledAnchor now accepts `href` prop with proper typing\n * <StyledAnchor href=\"/path\">Link</StyledAnchor>\n */\nexport function styledHtml(tag, options) {\n const isText = textLikeElements.has(tag);\n const { variants, name, defaultVariants, context, ...defaultProps } = options || {};\n const conf = {\n Component: tag,\n variants: variants,\n defaultProps: defaultProps,\n defaultVariants,\n componentName: name,\n isReactNative: false,\n isText,\n acceptsClassName: true,\n context,\n };\n if (defaultProps['children'] || context) {\n conf.neverFlatten = true;\n }\n const component = createComponent(conf);\n return component;\n}\n/**\n * styled() for creating Gui components from other components.\n */\nfunction styled(ComponentIn, \n// this should be Partial<GetProps<ParentComponent>> but causes excessively deep type issues\noptions, config) {\n // do type stuff at top for easier readability\n // validate not using a variant over an existing valid style\n if (process.env.NODE_ENV !== 'production') {\n if (!ComponentIn) {\n throw new Error(`No component given to styled()`);\n }\n }\n const parentStaticConfig = ComponentIn['staticConfig'];\n const isPlainStyledComponent = !!parentStaticConfig &&\n !(parentStaticConfig.isReactNative || parentStaticConfig.isHOC);\n const isNonStyledHOC = parentStaticConfig?.isHOC && !parentStaticConfig?.isStyledHOC;\n let Component = isNonStyledHOC || isPlainStyledComponent\n ? ComponentIn\n : parentStaticConfig?.Component || ComponentIn;\n const reactNativeConfig = !parentStaticConfig\n ? getReactNativeConfig(Component)\n : undefined;\n const isReactNative = Boolean(reactNativeConfig || config?.isReactNative || parentStaticConfig?.isReactNative);\n const staticConfigProps = (() => {\n let { variants, name, defaultVariants, context, ...defaultProps } = options || {};\n let parentDefaultVariants;\n let parentDefaultProps;\n if (parentStaticConfig) {\n const avoid = parentStaticConfig.isHOC && !parentStaticConfig.isStyledHOC;\n if (!avoid) {\n const pdp = parentStaticConfig.defaultProps;\n // apply parent props only if not already defined, they are lesser specificity\n for (const key in pdp) {\n const val = pdp[key];\n if (parentStaticConfig.defaultVariants) {\n if (key in parentStaticConfig.defaultVariants) {\n // ensure we don't add it if its also in our default variants so we keep the order!\n if (!defaultVariants || !(key in defaultVariants)) {\n parentDefaultVariants || (parentDefaultVariants = {});\n parentDefaultVariants[key] = val;\n }\n }\n }\n if (!(key in defaultProps) && (!defaultVariants || !(key in defaultVariants))) {\n parentDefaultProps || (parentDefaultProps = {});\n parentDefaultProps[key] = pdp[key];\n }\n }\n if (parentStaticConfig.variants) {\n // @ts-expect-error\n variants = mergeVariants(parentStaticConfig.variants, variants);\n }\n }\n }\n // applies everything in the right order! order is important\n if (parentDefaultProps || defaultVariants || parentDefaultVariants) {\n defaultProps = {\n ...parentDefaultProps,\n ...parentDefaultVariants,\n ...defaultProps,\n ...defaultVariants,\n };\n }\n if (parentStaticConfig?.isHOC) {\n // if HOC we map name => componentName as we have a difference in how we name prop vs styled() there\n if (name) {\n // @ts-ignore\n defaultProps.componentName = name;\n }\n }\n const isText = Boolean(config?.isText || parentStaticConfig?.isText);\n const acceptsClassName = config?.acceptsClassName ??\n (isPlainStyledComponent ||\n isReactNative ||\n (parentStaticConfig?.isHOC && parentStaticConfig?.acceptsClassName));\n const conf = {\n ...parentStaticConfig,\n ...config,\n ...(!isPlainStyledComponent && {\n Component,\n }),\n // @ts-expect-error\n variants,\n defaultProps,\n defaultVariants,\n componentName: name || parentStaticConfig?.componentName,\n isReactNative,\n isText,\n acceptsClassName,\n context,\n ...reactNativeConfig,\n isStyledHOC: Boolean(parentStaticConfig?.isHOC),\n parentStaticConfig,\n };\n // bail on non className views as well\n if (defaultProps['children'] || !acceptsClassName || context) {\n conf.neverFlatten = true;\n }\n return conf;\n })();\n const component = createComponent(staticConfigProps || {});\n for (const key in ComponentIn) {\n // dont inherit propTypes\n if (key === 'propTypes')\n continue;\n if (key in component)\n continue;\n // @ts-expect-error assigning static properties over\n component[key] = ComponentIn[key];\n }\n return component;\n}\n// use a proxy to make styled.a(), styled.div() etc work\nconst styledExport = new Proxy(styled, {\n get(target, prop) {\n if (prop in target) {\n return target[prop];\n }\n // return factory for HTML elements\n return (options) => styledHtml(prop, options);\n },\n});\nexport { styledExport as styled };\n//# sourceMappingURL=styled.js.map","import { validStyles } from '@hanzogui/helpers';\nimport { createComponent } from '../createComponent.js';\nexport const View = createComponent({\n acceptsClassName: true,\n validStyles,\n});\n//# sourceMappingURL=View.js.map","import { useIsomorphicLayoutEffect } from '@hanzogui/constants';\nimport React from 'react';\nimport { getConfig } from '../config.js';\nimport { ComponentContext } from '../contexts/ComponentContext.js';\nimport { GroupContext } from '../contexts/GroupContext.js';\nimport { useSplitStyles } from '../helpers/getSplitStyles.js';\nimport { subscribeToContextGroup } from '../helpers/subscribeToContextGroup.js';\nimport { View } from '../views/View.js';\nimport { useComponentState } from './useComponentState.js';\nimport { mediaState } from '../helpers/mediaState.js';\nimport { useMedia } from './useMedia.js';\nimport { useThemeWithState } from './useTheme.js';\n/**\n * Returns props and style as a single object, expanding and merging shorthands and media queries.\n *\n * Use sparingly, it will loop props and trigger re-render on all media queries you access.\n *\n * */\nexport function useProps(props, opts) {\n const [propsOut, styleOut] = usePropsAndStyle(props, {\n ...opts,\n noExpand: true,\n noNormalize: true,\n resolveValues: 'none',\n });\n return {\n ...propsOut,\n ...styleOut,\n };\n}\n/**\n * Returns only style values fully resolved and flattened with merged media queries and shorthands with all theme and token values resolved.\n *\n * Use sparingly, it will loop props and trigger re-render on all media queries you access.\n *\n * */\nexport function useStyle(props, opts) {\n return usePropsAndStyle(props, opts)[1] || {};\n}\n/**\n * Returns [props, styles, theme, media] fully resolved and flattened with merged media queries and shorthands with all theme and token values resolved.\n *\n * Use sparingly, it will loop props and trigger re-render on all media queries you access.\n *\n * */\nexport function usePropsAndStyle(props, opts) {\n const staticConfig = opts?.forComponent?.staticConfig ?? View.staticConfig;\n const [theme, themeState] = useThemeWithState({\n componentName: staticConfig.componentName,\n name: 'theme' in props ? props.theme : undefined,\n needsUpdate() {\n return true;\n },\n });\n const componentContext = React.useContext(ComponentContext);\n const groupContext = React.useContext(GroupContext);\n const { state, disabled, setStateShallow } = useComponentState(props, componentContext.animationDriver, staticConfig, getConfig());\n const mediaStateNow = opts?.noMedia\n ? // not safe to use mediaState but really marginal to hit this\n mediaState\n : useMedia();\n const splitStyles = useSplitStyles(props, staticConfig, theme, themeState?.name || '', state, {\n isAnimated: false,\n mediaState: mediaStateNow,\n noSkip: true,\n noMergeStyle: true,\n noClass: true,\n resolveValues: 'auto',\n ...opts,\n }, null, componentContext, groupContext);\n const { mediaGroups, pseudoGroups } = splitStyles || {};\n useIsomorphicLayoutEffect(() => {\n if (disabled) {\n return;\n }\n if (state.unmounted) {\n setStateShallow({ unmounted: false });\n return;\n }\n if (groupContext) {\n return subscribeToContextGroup({\n groupContext,\n setStateShallow,\n mediaGroups,\n pseudoGroups,\n });\n }\n }, [\n disabled,\n groupContext,\n pseudoGroups ? Object.keys([...pseudoGroups]).join('') : 0,\n mediaGroups ? Object.keys([...mediaGroups]).join('') : 0,\n ]);\n return [\n splitStyles?.viewProps || {},\n splitStyles?.style || {},\n theme,\n mediaState,\n ];\n}\n//# sourceMappingURL=useProps.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport React from 'react';\nimport { getConfig } from '../config.js';\nimport { Theme } from './Theme.js';\nlet defaultFontClass = '';\n/**\n * Applies default font class and CSS variable inheritance via display:contents.\n * Used by GuiProvider at the root and by portals to re-establish font scope.\n * Pass trackMount to also handle the t_unmounted class for CSS animation gating.\n */\nexport function GuiRoot({ children, theme, isRootRoot, passThrough, style, }) {\n const [mounted, setMounted] = React.useState(!isRootRoot);\n React.useEffect(() => {\n if (!mounted) {\n setMounted(true);\n }\n }, []);\n // cache the font class name\n if (!defaultFontClass) {\n const config = getConfig();\n const defaultFont = config.defaultFont;\n if (defaultFont) {\n defaultFontClass = `font_${defaultFont}`;\n }\n }\n const contents = (_jsx(\"span\", { style: style, \n // font_body (or default font) sets all font properties via shared CSS rule\n className: `_dsp_contents ${mounted ? '' : 't_unmounted'} ${defaultFontClass}`, children: children }));\n // at root, ThemeProvider already applied theme - skip re-wrapping\n // for portals/modals, we re-thread the theme so each root gets the right className setup\n if (isRootRoot) {\n return contents;\n }\n return (_jsx(Theme, { passThrough: passThrough, contain: true, forceClassName: true, name: theme, children: contents }));\n}\n//# sourceMappingURL=GuiRoot.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useIsomorphicLayoutEffect } from '@hanzogui/constants';\nimport { useId } from 'react';\nimport { getSetting } from '../config.js';\nimport { THEME_CLASSNAME_PREFIX } from '../constants/constants.js';\nimport { Theme } from './Theme.js';\nexport const ThemeProvider = (props) => {\n 'use no memo';\n const addThemeClassName = getSetting('addThemeClassName');\n // ensure theme is attached to root body node as well to work with modals by default\n if (\"web\" === 'web') {\n useIsomorphicLayoutEffect(() => {\n if (addThemeClassName === false)\n return;\n const cn = `${THEME_CLASSNAME_PREFIX}${props.defaultTheme}`;\n const target = getSetting('addThemeClassName') === 'html'\n ? document.documentElement\n : document.body;\n target.classList.add(cn);\n return () => {\n target.classList.remove(cn);\n };\n }, [props.defaultTheme, addThemeClassName]);\n }\n // we completely disable the className here if its set to any value, 'root', 'body', or false\n // because in all cases we are putting the classname elsewhere\n // if its undefined, then the default behavior applies and we use the className here\n const forceClassName = addThemeClassName === undefined;\n return (_jsx(Theme, { className: props.className, name: props.defaultTheme, forceClassName: forceClassName, \n // @ts-expect-error\n _isRoot: useId, children: props.children }));\n};\n//# sourceMappingURL=ThemeProvider.js.map","import { Fragment as _Fragment, jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useIsomorphicLayoutEffect } from '@hanzogui/constants';\nimport { ClientOnly } from '@hanzogui/use-did-finish-ssr';\nimport React, { useEffect } from 'react';\nimport { getSetting } from '../config.js';\nimport { ComponentContext } from '../contexts/ComponentContext.js';\nimport { stopAccumulatingRules } from '../helpers/insertStyleRule.js';\nimport { updateMediaListeners } from '../hooks/useMedia.js';\nimport { resolveAnimationDriver } from '../helpers/resolveAnimationDriver.js';\nimport { GuiRoot } from './GuiRoot.js';\nimport { ThemeProvider } from './ThemeProvider.js';\n// cache first theme key per config to avoid Object.keys allocation on every render\nlet _cachedFirstKey;\nlet _cachedConfig;\nfunction firstThemeKey(config) {\n if (config !== _cachedConfig) {\n _cachedConfig = config;\n _cachedFirstKey = config?.themes ? Object.keys(config.themes)[0] : undefined;\n }\n return _cachedFirstKey;\n}\nexport function GuiProvider({ children, disableInjectCSS, config, className, defaultTheme: defaultThemeProp, reset, insets, }) {\n // fall back to first theme when defaultTheme is null/undefined\n // (e.g. useColorScheme() returns null on first render in RN 0.83+)\n const defaultTheme = defaultThemeProp || firstThemeKey(config) || 'light';\n useIsomorphicLayoutEffect(() => {\n stopAccumulatingRules();\n updateMediaListeners();\n }, []);\n const memoizedInsets = React.useMemo(() => insets, [insets?.top, insets?.right, insets?.bottom, insets?.left]);\n // Get the default animation driver from config\n // config.animations is already normalized to the default driver in createGui\n // resolveAnimationDriver handles edge cases where raw multi-driver object leaks through\n const defaultAnimationDriver = React.useMemo(() => resolveAnimationDriver(config?.animations), [config?.animations]);\n useEffect(() => {\n defaultAnimationDriver?.onMount?.();\n }, []);\n let contents = (_jsx(ComponentContext.Provider, { animationDriver: defaultAnimationDriver, insets: memoizedInsets, children: _jsx(ThemeProvider, { defaultTheme: defaultTheme, reset: reset, className: className, children: _jsx(GuiRoot, { theme: defaultTheme, isRootRoot: true, children: children }) }) }));\n if (getSetting('disableSSR')) {\n // never changes so conditional render fine, no re-parenting risk\n contents = _jsx(ClientOnly, { enabled: true, children: contents });\n }\n return (_jsxs(_Fragment, { children: [contents, \"web\" !== 'native' && config && !disableInjectCSS && (_jsx(\"style\", { \n // react 19 feature to hoist style tags to header:\n // https://react.dev/reference/react-dom/components/style\n // @ts-ignore\n precedence: \"default\", href: \"hanzogui-css\", children: config.getCSS() }, \"hanzogui-css\"))] }));\n}\n//# sourceMappingURL=GuiProvider.js.map","import { stylePropsTextOnly, validStyles } from '@hanzogui/helpers';\nimport { createComponent } from '../createComponent.js';\nconst ellipsisStyle = \"web\" === 'web'\n ? {\n maxWidth: '100%',\n overflow: 'hidden',\n textOverflow: 'ellipsis',\n whiteSpace: 'nowrap',\n }\n : {\n numberOfLines: 1,\n lineBreakMode: 'clip',\n };\nexport const Text = createComponent({\n componentName: 'Text',\n acceptsClassName: true,\n isText: true,\n defaultProps: \"web\" === 'web'\n ? undefined\n : {\n suppressHighlighting: true,\n },\n inlineWhenUnflattened: new Set(['fontFamily']),\n inlineProps: new Set(['maxFontSizeMultiplier']),\n variants: {\n ...(\"web\" === 'web' && {\n numberOfLines: {\n 1: ellipsisStyle,\n ':number': (numberOfLines) => numberOfLines >= 1\n ? {\n maxWidth: '100%',\n WebkitLineClamp: numberOfLines,\n WebkitBoxOrient: 'vertical',\n display: '-webkit-box',\n overflow: 'hidden',\n }\n : null,\n },\n }),\n ellipsis: {\n true: ellipsisStyle,\n },\n },\n validStyles: {\n ...validStyles,\n ...stylePropsTextOnly,\n },\n});\n//# sourceMappingURL=Text.js.map","import * as React from 'react';\n// useInsertionEffect ensures the ref is updated before any useLayoutEffect\n// reads the returned callback — fixes a React 19 timing issue where a\n// consumer's useLayoutEffect could fire before this ref update, causing stale\n// values. Falls back to useLayoutEffect for React < 18.3. No SSR branch: SSR\n// doesn't run layout effects, so the non-SSR path is correct everywhere.\nconst useIsomorphicInsertionEffect = React.useInsertionEffect || React.useLayoutEffect;\n// keeps a reference to the current value easily\nexport function useGet(currentValue, initialValue, forwardToFunction) {\n const curRef = React.useRef(initialValue ?? currentValue);\n useIsomorphicInsertionEffect(() => {\n curRef.current = currentValue;\n });\n return React.useCallback(forwardToFunction\n ? (...args) => curRef.current?.apply(null, args)\n : () => curRef.current, []);\n}\n//# sourceMappingURL=useGet.js.map","import { useGet } from './useGet.js';\nexport function useEvent(callback) {\n return useGet(callback, defaultValue, true);\n}\nconst defaultValue = () => {\n throw new Error('Cannot call an event handler while rendering.');\n};\n//# sourceMappingURL=useEvent.js.map","// web-only use platform:\nexport const matchMedia = globalThis['matchMedia'];\n//# sourceMappingURL=matchMedia.js.map","import { setupMatchMedia } from '@hanzogui/web';\nimport { matchMedia } from './matchMedia.js';\n/**\n * @deprecated you no longer need to call createMedia or import @hanzogui/react-native-media-driver at all.\n * Gui now automatically handles setting this up, you can just pass a plain object to createGui.\n */\nexport function createMedia(media) {\n // this should ideally return a diff object that is then passed to createGui\n // but works for now we dont really support swapping out media drivers\n setupMatchMedia(matchMedia);\n return media;\n}\n//# sourceMappingURL=createMedia.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useIsomorphicLayoutEffect } from '@hanzogui/constants';\nimport { createContext, useContext, useId } from 'react';\nconst LayoutHandlers = new WeakMap();\nconst LayoutDisableKey = new WeakMap();\nconst Nodes = new Set();\nconst IntersectionState = new WeakMap();\n// feature flag to enable pre-transform dimension reporting (matches RN behavior)\n// can be set via env var at build time or runtime global for testing\n// see: https://github.com/hanzoai/gui/pull/2329\nconst usePretransformDimensions = () => globalThis.__GUI_ONLAYOUT_PRETRANSFORM === true ||\n process.env.GUI_ONLAYOUT_PRETRANSFORM === '1';\nlet _debugLayout;\nfunction isDebugLayout() {\n if (_debugLayout === undefined) {\n _debugLayout =\n typeof window !== 'undefined' &&\n new URLSearchParams(window.location.search).has('__tamaDebugLayout');\n }\n return _debugLayout;\n}\n// separating to avoid all re-rendering\nconst DisableLayoutContextValues = {};\nconst DisableLayoutContextKey = createContext('');\nconst ENABLE = \"web\" === 'web' && typeof IntersectionObserver !== 'undefined';\n// internal testing - advanced helper to turn off layout measurement for extra performance\n// TODO document!\n// TODO could add frame skip control here\nexport const LayoutMeasurementController = ({ disable, children, }) => {\n const id = useId();\n useIsomorphicLayoutEffect(() => {\n DisableLayoutContextValues[id] = disable;\n }, [disable, id]);\n return (_jsx(DisableLayoutContextKey.Provider, { value: id, children: children }));\n};\n// Single persistent IntersectionObserver for visibility tracking\nlet globalIntersectionObserver = null;\nlet strategy = 'async';\nexport function setOnLayoutStrategy(state) {\n strategy = state;\n}\nconst NodeRectCache = new WeakMap();\n// prevent thrashing during first hydration (somewhat, streaming gets trickier)\nlet avoidUpdates = true;\nconst queuedUpdates = new Map();\nexport function enable() {\n if (avoidUpdates) {\n avoidUpdates = false;\n if (queuedUpdates) {\n queuedUpdates.forEach((cb) => cb());\n queuedUpdates.clear();\n }\n }\n}\nfunction startGlobalObservers() {\n if (!ENABLE || globalIntersectionObserver)\n return;\n globalIntersectionObserver = new IntersectionObserver((entries) => {\n for (let i = 0; i < entries.length; i++) {\n const entry = entries[i];\n const node = entry.target;\n if (IntersectionState.get(node) !== entry.isIntersecting) {\n IntersectionState.set(node, entry.isIntersecting);\n }\n }\n }, {\n threshold: 0,\n });\n}\n// optimization: inline rect comparison to avoid function call overhead on hot path\nfunction rectsEqual(a, b) {\n return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;\n}\nif (ENABLE) {\n const BoundingRects = new WeakMap();\n // optimization: persistent IO for rect fetching, reused across cycles\n let rectFetchObserver = null;\n let rectFetchResolve = null;\n let rectFetchStartTime = 0;\n let lastCallbackDelay = 0;\n function ensureRectFetchObserver() {\n if (rectFetchObserver)\n return rectFetchObserver;\n rectFetchObserver = new IntersectionObserver((entries) => {\n lastCallbackDelay = Math.round(performance.now() - rectFetchStartTime);\n // store all rects\n for (let i = 0; i < entries.length; i++) {\n BoundingRects.set(entries[i].target, entries[i].boundingClientRect);\n }\n if (process.env.NODE_ENV === 'development' &&\n isDebugLayout() &&\n lastCallbackDelay > 50) {\n console.warn('[onLayout-io-delay]', lastCallbackDelay + 'ms', entries.length, 'entries');\n }\n if (rectFetchResolve) {\n rectFetchResolve(true);\n rectFetchResolve = null;\n }\n }, {\n threshold: 0,\n });\n return rectFetchObserver;\n }\n async function updateLayoutIfChanged(node) {\n const onLayout = LayoutHandlers.get(node);\n if (typeof onLayout !== 'function')\n return;\n const parentNode = node.parentElement;\n if (!parentNode)\n return;\n let nodeRect;\n let parentRect;\n // respect the strategy contract\n if (strategy === 'async') {\n nodeRect = BoundingRects.get(node);\n parentRect = BoundingRects.get(parentNode);\n if (!nodeRect || !parentRect) {\n return;\n }\n }\n else {\n nodeRect = node.getBoundingClientRect();\n parentRect = parentNode.getBoundingClientRect();\n }\n emitLayoutIfChanged(node, parentNode, nodeRect, parentRect);\n }\n const rAF = typeof requestAnimationFrame !== 'undefined' ? requestAnimationFrame : undefined;\n // adaptive frame skipping with backoff\n const userSkipVal = process.env.GUI_LAYOUT_FRAME_SKIP;\n const BASE_SKIP_FRAMES = userSkipVal ? +userSkipVal : 10;\n const MAX_SKIP_FRAMES = 20;\n let skipFrames = BASE_SKIP_FRAMES;\n let frameCount = 0;\n async function layoutOnAnimationFrame() {\n // skip frames based on adaptive rate\n if (frameCount++ % skipFrames !== 0) {\n rAF ? rAF(layoutOnAnimationFrame) : setTimeout(layoutOnAnimationFrame, 16);\n return;\n }\n // reset frame count to avoid overflow\n if (frameCount >= Number.MAX_SAFE_INTEGER) {\n frameCount = 0;\n }\n if (strategy !== 'off') {\n const visibleNodes = [];\n // optimization: deduplicate parent observations\n const parentsToObserve = new Set();\n // collect visible nodes and their unique parents\n for (const node of Nodes) {\n const parentElement = node.parentElement;\n if (!(parentElement instanceof HTMLElement)) {\n cleanupNode(node);\n continue;\n }\n const disableKey = LayoutDisableKey.get(node);\n if (disableKey && DisableLayoutContextValues[disableKey] === true)\n continue;\n if (IntersectionState.get(node) === false)\n continue;\n visibleNodes.push(node);\n parentsToObserve.add(parentElement);\n }\n if (visibleNodes.length > 0) {\n const io = ensureRectFetchObserver();\n rectFetchStartTime = performance.now();\n // observe all nodes\n for (let i = 0; i < visibleNodes.length; i++) {\n io.observe(visibleNodes[i]);\n }\n // optimization: observe unique parents only (not N times for N children)\n for (const parent of parentsToObserve) {\n io.observe(parent);\n }\n // wait for callback\n await new Promise((res) => {\n rectFetchResolve = res;\n });\n // unobserve all to reset for next cycle\n for (let i = 0; i < visibleNodes.length; i++) {\n io.unobserve(visibleNodes[i]);\n }\n for (const parent of parentsToObserve) {\n io.unobserve(parent);\n }\n // adaptive backoff: if IO was slow, skip more frames next cycle\n if (lastCallbackDelay > 50) {\n skipFrames = Math.min(skipFrames + 2, MAX_SKIP_FRAMES);\n }\n else if (lastCallbackDelay < 20) {\n // recover back to base rate when things are fast\n skipFrames = Math.max(skipFrames - 1, BASE_SKIP_FRAMES);\n }\n // process updates\n for (let i = 0; i < visibleNodes.length; i++) {\n updateLayoutIfChanged(visibleNodes[i]);\n }\n }\n }\n // schedule next frame\n rAF ? rAF(layoutOnAnimationFrame) : setTimeout(layoutOnAnimationFrame, 16);\n }\n layoutOnAnimationFrame();\n}\nexport const getElementLayoutEvent = (nodeRect, parentRect, node) => {\n return {\n nativeEvent: {\n layout: getRelativeDimensions(nodeRect, parentRect, node),\n target: nodeRect,\n },\n timeStamp: Date.now(),\n };\n};\n/**\n * get pre-transform dimensions for a node.\n * uses offsetWidth/offsetHeight which report CSS layout dimensions\n * unaffected by transforms - this matches React Native's onLayout behavior.\n *\n * see: https://github.com/hanzoai/gui/pull/2329\n */\nconst getPreTransformDimensions = (node) => {\n return {\n width: node.offsetWidth,\n height: node.offsetHeight,\n };\n};\nconst getRelativeDimensions = (a, b, aNode) => {\n const { left, top } = a;\n const x = left - b.left;\n const y = top - b.top;\n // get pre-transform dimensions when flag is enabled and node is available\n const { width, height } = usePretransformDimensions() && aNode\n ? getPreTransformDimensions(aNode)\n : { width: a.width, height: a.height };\n return { x, y, width, height, pageX: a.left, pageY: a.top };\n};\nfunction emitLayoutIfChanged(node, parentNode, nodeRect, parentRect) {\n const onLayout = LayoutHandlers.get(node);\n if (typeof onLayout !== 'function')\n return;\n const cachedRect = NodeRectCache.get(node);\n const cachedParentRect = NodeRectCache.get(parentNode);\n const nodeChanged = !cachedRect || !rectsEqual(cachedRect, nodeRect);\n const parentChanged = !cachedParentRect || !rectsEqual(cachedParentRect, parentRect);\n if (!nodeChanged && !parentChanged)\n return;\n NodeRectCache.set(node, nodeRect);\n NodeRectCache.set(parentNode, parentRect);\n const event = getElementLayoutEvent(nodeRect, parentRect, node);\n if (process.env.NODE_ENV === 'development' && isDebugLayout()) {\n console.log('[useElementLayout] change', {\n tag: node.tagName,\n id: node.id || undefined,\n className: (node.className || '').slice(0, 60) || undefined,\n layout: event.nativeEvent.layout,\n first: !cachedRect,\n });\n }\n if (avoidUpdates) {\n queuedUpdates.set(node, () => onLayout(event));\n }\n else {\n onLayout(event);\n }\n}\nfunction observeLayoutNode(node, disableKey) {\n Nodes.add(node);\n if (disableKey) {\n LayoutDisableKey.set(node, disableKey);\n }\n else {\n LayoutDisableKey.delete(node);\n }\n startGlobalObservers();\n if (globalIntersectionObserver) {\n globalIntersectionObserver.observe(node);\n IntersectionState.set(node, true);\n }\n}\n// register an arbitrary DOM element into the measurement loop without React lifecycle\nexport function registerLayoutNode(node, onChange, disableKey) {\n LayoutHandlers.set(node, onChange);\n observeLayoutNode(node, disableKey);\n return () => cleanupNode(node);\n}\nfunction cleanupNode(node) {\n Nodes.delete(node);\n LayoutHandlers.delete(node);\n LayoutDisableKey.delete(node);\n NodeRectCache.delete(node);\n IntersectionState.delete(node);\n if (globalIntersectionObserver) {\n globalIntersectionObserver.unobserve(node);\n }\n}\nconst PrevHostNode = new WeakMap();\n// spec: onLayout fires one synchronous initial event on mount and on host swap\n// (RN parity, and before-paint so consumers can position without flicker).\n// bypasses the avoidUpdates queue on purpose; seeds the rect cache so the\n// measurement loop doesn't re-emit an identical event a frame later.\nfunction emitLayoutSync(node) {\n const onLayout = LayoutHandlers.get(node);\n if (typeof onLayout !== 'function')\n return;\n const parentNode = node.parentElement;\n if (!parentNode)\n return;\n const nodeRect = node.getBoundingClientRect();\n const parentRect = parentNode.getBoundingClientRect();\n NodeRectCache.set(node, nodeRect);\n NodeRectCache.set(parentNode, parentRect);\n onLayout(getElementLayoutEvent(nodeRect, parentRect, node));\n}\nexport function useElementLayout(ref, onLayout) {\n const disableKey = useContext(DisableLayoutContextKey);\n // keep handlers up to date so polling always calls the latest callback\n const node = ensureWebElement(ref.current?.host);\n if (node && onLayout) {\n LayoutHandlers.set(node, onLayout);\n LayoutDisableKey.set(node, disableKey);\n }\n // detect mounts + host swaps after commit and fire the immediate sync layout event\n useIsomorphicLayoutEffect(() => {\n if (!onLayout)\n return;\n const nextNode = ensureWebElement(ref.current?.host);\n const prevNode = PrevHostNode.get(ref);\n if (nextNode === prevNode)\n return;\n if (prevNode)\n cleanupNode(prevNode);\n PrevHostNode.set(ref, nextNode);\n if (!nextNode)\n return;\n LayoutHandlers.set(nextNode, onLayout);\n observeLayoutNode(nextNode, disableKey);\n emitLayoutSync(nextNode);\n });\n useIsomorphicLayoutEffect(() => {\n if (!onLayout)\n return;\n const node = ref.current?.host;\n if (!node)\n return;\n LayoutHandlers.set(node, onLayout);\n observeLayoutNode(node, disableKey);\n if (process.env.NODE_ENV === 'development' && isDebugLayout()) {\n console.log('[useElementLayout] register', {\n tag: node.tagName,\n id: node.id || undefined,\n className: (node.className || '').slice(0, 60) || undefined,\n totalNodes: Nodes.size,\n });\n }\n return () => {\n cleanupNode(node);\n // also clean up any node from a mid-lifecycle host swap\n const swappedNode = PrevHostNode.get(ref);\n if (swappedNode && swappedNode !== node) {\n cleanupNode(swappedNode);\n }\n PrevHostNode.delete(ref);\n };\n }, [ref, !!onLayout]);\n}\nfunction ensureWebElement(x) {\n if (typeof HTMLElement === 'undefined') {\n return undefined;\n }\n return x instanceof HTMLElement ? x : undefined;\n}\nexport const getBoundingClientRectAsync = (node) => {\n return new Promise((res) => {\n if (!node || node.nodeType !== 1)\n return res(false);\n const io = new IntersectionObserver((entries) => {\n io.disconnect();\n return res(entries[0].boundingClientRect);\n }, {\n threshold: 0,\n });\n io.observe(node);\n });\n};\nexport const measureNode = async (node, relativeTo) => {\n const relativeNode = relativeTo || node?.parentElement;\n if (relativeNode instanceof HTMLElement) {\n const [nodeDim, relativeNodeDim] = await Promise.all([\n getBoundingClientRectAsync(node),\n getBoundingClientRectAsync(relativeNode),\n ]);\n if (relativeNodeDim && nodeDim) {\n return getRelativeDimensions(nodeDim, relativeNodeDim, node);\n }\n }\n return null;\n};\nexport const measure = async (node, callback) => {\n const out = await measureNode(node, node.parentNode instanceof HTMLElement ? node.parentNode : null);\n if (out) {\n callback?.(out.x, out.y, out.width, out.height, out.pageX, out.pageY);\n }\n return out;\n};\nexport function createMeasure(node) {\n return (callback) => measure(node, callback);\n}\nexport const measureInWindow = async (node, callback) => {\n const out = await measureNode(node, null);\n if (out) {\n callback?.(out.pageX, out.pageY, out.width, out.height);\n }\n return out;\n};\nexport const createMeasureInWindow = (node) => {\n return (callback) => measureInWindow(node, callback);\n};\nexport const measureLayout = async (node, relativeNode, callback) => {\n const out = await measureNode(node, relativeNode);\n if (out) {\n callback?.(out.x, out.y, out.width, out.height, out.pageX, out.pageY);\n }\n return out;\n};\nexport function createMeasureLayout(node) {\n return (relativeTo, callback) => measureLayout(node, relativeTo, callback);\n}\n//# sourceMappingURL=index.js.map","export function getBaseViews() {\n // empty\n return null;\n}\n//# sourceMappingURL=getBaseViews.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\n// re-exports all of @hanzogui/web just adds hooks\nexport * from '@hanzogui/web';\nimport { createMedia } from '@hanzogui/react-native-media-driver';\nimport { isWeb } from '@hanzogui/constants';\nimport { createMeasure, createMeasureInWindow, createMeasureLayout, enable, useElementLayout, } from '@hanzogui/use-element-layout';\nimport { GuiProvider as WebGuiProvider, Text as WebText, View as WebView, createGui as createGuiWeb, setupHooks, useIsomorphicLayoutEffect, } from '@hanzogui/web';\nimport { createOptimizedView } from './createOptimizedView.js';\nimport { getBaseViews } from './getBaseViews.js';\nconst GESTURE_STATE_KEY = '__hanzogui_gesture__';\nconst GESTURE_ENABLED_FREEZE_KEY = '__hanzogui_gesture_enabled_freeze__';\nfunction freezeGestureHandlerEnabledMode() {\n const g = globalThis;\n const freezeState = (g[GESTURE_ENABLED_FREEZE_KEY] ?? (g[GESTURE_ENABLED_FREEZE_KEY] = {\n frozen: false,\n enabled: false,\n warned: false,\n }));\n if (freezeState.frozen) {\n return;\n }\n freezeState.frozen = true;\n freezeState.enabled = Boolean(g[GESTURE_STATE_KEY]?.enabled);\n freezeState.warned = false;\n}\n// helpful for usage outside of hanzogui\nexport { LayoutMeasurementController, registerLayoutNode, setOnLayoutStrategy, } from '@hanzogui/use-element-layout';\n// fixes issues with TS saying internal type usage is breaking\n// see https://discord.com/channels/909986013848412191/1146150253490348112/1146150253490348112\nexport * from './reactNativeTypes.js';\n// adds useElementLayout enable\nexport const GuiProvider = (props) => {\n if (\"web\" === 'native') {\n freezeGestureHandlerEnabledMode();\n }\n useIsomorphicLayoutEffect(() => {\n enable();\n }, []);\n return _jsx(WebGuiProvider, { ...props });\n};\n// automate using the react native media driver\nexport const createGui = (conf) => {\n if (!isWeb) {\n if (conf.media) {\n conf.media = createMedia(conf.media);\n }\n }\n return createGuiWeb(conf);\n};\nconst baseViews = getBaseViews();\n// setup internal hooks:\nsetupHooks({\n getBaseViews,\n setElementProps: (node) => {\n if (\"web\" === 'web') {\n // web only\n if (node && !node['measure']) {\n node.measure || (node.measure = createMeasure(node));\n node.measureInWindow || (node.measureInWindow = createMeasureInWindow(node));\n node.measureLayout || (node.measureLayout = createMeasureLayout(node));\n }\n }\n },\n usePropsTransform(elementType, propsIn, stateRef, willHydrate) {\n if (\"web\" === 'web') {\n const isDOM = typeof elementType === 'string';\n // replicate react-native-web functionality\n const { \n // remove event props handles by useResponderEvents\n onMoveShouldSetResponder, onMoveShouldSetResponderCapture, onResponderEnd, onResponderGrant, onResponderMove, onResponderReject, onResponderRelease, onResponderStart, onResponderTerminate, onResponderTerminationRequest, onScrollShouldSetResponder, onScrollShouldSetResponderCapture, onSelectionChangeShouldSetResponder, onSelectionChangeShouldSetResponderCapture, onStartShouldSetResponder, onStartShouldSetResponderCapture, \n // android\n collapsable, focusable, \n // deprecated,\n accessible, accessibilityDisabled, onLayout, hrefAttrs, ...plainDOMProps } = propsIn;\n if (willHydrate || isDOM) {\n useElementLayout(stateRef, !isDOM ? undefined : onLayout);\n // responder events removed for web - use native pointer/touch events instead\n // the onResponder* props are stripped above and not passed to DOM\n }\n if (isDOM) {\n // TODO move into getSplitStyles\n if (plainDOMProps.href && hrefAttrs) {\n const { download, rel, target } = hrefAttrs;\n if (download != null) {\n plainDOMProps.download = download;\n }\n if (rel) {\n plainDOMProps.rel = rel;\n }\n if (typeof target === 'string') {\n plainDOMProps.target = target.charAt(0) !== '_' ? `_${target}` : target;\n }\n }\n return plainDOMProps;\n }\n }\n },\n // attempt at properly fixing RN input, but <Pressable><TextInput /> just doesnt work on RN\n ...(\"web\" === 'native' && {\n useChildren(elementType, children, viewProps) {\n if (process.env.NODE_ENV === 'test') {\n // test mode - just use regular views since optimizations cause weirdness\n return;\n }\n if (elementType === baseViews.View && baseViews.TextAncestor) {\n // optimize view\n return createOptimizedView(children, viewProps, baseViews);\n }\n },\n }),\n});\n// overwrite web versions:\n// putting at the end ensures it overwrites in dist/cjs/index.js\nexport const View = WebView;\nexport const Text = WebText;\n//# sourceMappingURL=index.js.map","import { getVariableValue, isAndroid, isVariable } from '@hanzogui/core';\nexport const getElevation = (size, extras) => {\n if (!size)\n return;\n const { tokens } = extras;\n const token = tokens.size[size];\n const sizeNum = (isVariable(token) ? +token.val : size);\n return getSizedElevation(sizeNum, extras);\n};\nexport const getSizedElevation = (val, { theme, tokens }) => {\n let num = 0;\n if (val === true) {\n const val = getVariableValue(tokens.size['true']);\n if (typeof val === 'number') {\n num = val;\n }\n else {\n num = 10;\n }\n }\n else {\n num = +val;\n }\n if (num === 0) {\n return;\n }\n const [height, shadowRadius] = [Math.round(num / 4 + 1), Math.round(num / 2 + 2)];\n const shadow = {\n shadowColor: theme.shadowColor,\n shadowRadius,\n shadowOffset: { height, width: 0 },\n ...(isAndroid\n ? {\n elevationAndroid: 2 * height,\n }\n : {}),\n };\n return shadow;\n};\n//# sourceMappingURL=getElevation.js.map","import { View, styled } from '@hanzogui/core';\nimport { getElevation } from './getElevation.js';\nexport const fullscreenStyle = {\n position: 'absolute',\n inset: 0,\n};\nconst variants = {\n fullscreen: {\n true: fullscreenStyle,\n },\n elevation: {\n '...size': getElevation,\n ':number': getElevation,\n },\n};\n/**\n * @summary A view that arranges its children in a vertical line.\n * @see — Docs https://hanzogui.dev/ui/stacks#xstack-ystack-zstack\n */\nexport const YStack = styled(View, {\n flexDirection: 'column',\n variants,\n});\nYStack['displayName'] = 'YStack';\n/**\n * @summary A view that arranges its children in a horizontal line.\n * @see — Docs https://hanzogui.dev/ui/stacks#xstack-ystack-zstack\n */\nexport const XStack = styled(View, {\n flexDirection: 'row',\n variants,\n});\nXStack['displayName'] = 'XStack';\n/**\n * @summary A view that stacks its children on top of each other.\n * @see — Docs https://hanzogui.dev/ui/stacks#xstack-ystack-zstack\n */\nexport const ZStack = styled(YStack, {\n position: 'relative',\n}, {\n neverFlatten: true,\n isZStack: true,\n});\nZStack['displayName'] = 'ZStack';\n//# sourceMappingURL=Stacks.js.map","import { getElevation } from './getElevation.js';\nexport const elevate = {\n true: (_, extras) => {\n return getElevation(extras.props['size'], extras);\n },\n};\nexport const bordered = (val, { props }) => {\n return {\n // TODO size it with size in '...size'\n borderWidth: typeof val === 'number' ? val : 1,\n borderColor: '$borderColor',\n };\n};\nconst circularStyle = {\n borderRadius: 100000,\n padding: 0,\n};\nexport const circular = {\n true: (_, { props, tokens }) => {\n if (!('size' in props)) {\n return circularStyle;\n }\n const size = typeof props.size === 'number' ? props.size : tokens.size[props.size];\n return {\n ...circularStyle,\n width: size,\n height: size,\n maxWidth: size,\n maxHeight: size,\n minWidth: size,\n minHeight: size,\n };\n },\n};\n//# sourceMappingURL=variants.js.map","import { styled } from '@hanzogui/core';\nimport { YStack } from './Stacks.js';\nimport { bordered, circular, elevate } from './variants.js';\nconst chromelessStyle = {\n backgroundColor: 'transparent',\n borderColor: 'transparent',\n shadowColor: 'transparent',\n hoverStyle: {\n borderColor: 'transparent',\n },\n};\nexport const themeableVariants = {\n circular,\n elevate,\n bordered: {\n true: bordered,\n },\n transparent: {\n true: {\n backgroundColor: 'transparent',\n },\n },\n chromeless: {\n true: chromelessStyle,\n all: {\n ...chromelessStyle,\n hoverStyle: chromelessStyle,\n pressStyle: chromelessStyle,\n focusStyle: chromelessStyle,\n },\n },\n};\nexport const ThemeableStack = styled(YStack, {\n variants: themeableVariants,\n});\n//# sourceMappingURL=ThemeableStack.js.map","import { getTokens, isVariable } from '@hanzogui/web';\nconst defaultOptions = {\n shift: 0,\n bounds: [0],\n};\nexport const getSize = (size, options) => {\n return getTokenRelative('size', size, options);\n};\nexport const getSpace = (space, options) => {\n return getTokenRelative('space', space, options);\n};\nexport const getRadius = (radius, options) => {\n return getTokenRelative('radius', radius, options);\n};\nconst cacheVariables = {};\nconst cacheWholeVariables = {};\nconst cacheKeys = {};\nconst cacheWholeKeys = {};\n/** @deprecated use getSize, getSpace, or getTokenRelative instead */\nexport const stepTokenUpOrDown = (type, current, options = defaultOptions) => {\n const tokens = getTokens({ prefixed: true })[type];\n if (!(type in cacheVariables)) {\n cacheKeys[type] = [];\n cacheVariables[type] = [];\n cacheWholeKeys[type] = [];\n cacheWholeVariables[type] = [];\n const sorted = Object.keys(tokens)\n .map((k) => tokens[k])\n .sort((a, b) => a.val - b.val);\n for (const token of sorted) {\n cacheKeys[type].push(token.key);\n cacheVariables[type].push(token);\n }\n const sortedExcludingHalfSteps = sorted.filter((x) => !x.key.endsWith('.5'));\n for (const token of sortedExcludingHalfSteps) {\n cacheWholeKeys[type].push(token.key);\n cacheWholeVariables[type].push(token);\n }\n }\n const isString = typeof current === 'string';\n const cache = options.excludeHalfSteps\n ? isString\n ? cacheWholeKeys\n : cacheWholeVariables\n : isString\n ? cacheKeys\n : cacheVariables;\n const tokensOrdered = cache[type];\n const min = options.bounds?.[0] ?? 0;\n const max = options.bounds?.[1] ?? tokensOrdered.length - 1;\n const currentIndex = tokensOrdered.indexOf(current);\n let shift = options.shift || 0;\n if (shift) {\n if (current === '$true' || (isVariable(current) && current.name === 'true')) {\n shift += shift > 0 ? 1 : -1;\n }\n }\n const index = Math.min(max, Math.max(min, currentIndex + shift));\n const found = tokensOrdered[index];\n const result = (typeof found === 'string' ? tokens[found] : found) || tokens['$true'];\n // console.log('found', { current, shift, index, found, result })\n // @ts-ignore\n return result;\n};\nexport const getTokenRelative = stepTokenUpOrDown;\n//# sourceMappingURL=index.js.map","import { getSpace } from '@hanzogui/get-token';\nexport const getButtonSized = (val, { tokens, props }) => {\n if (!val || props.circular) {\n return;\n }\n if (typeof val === 'number') {\n return {\n paddingHorizontal: val * 0.25,\n height: val,\n borderRadius: props.circular ? 100000 : val * 0.2,\n };\n }\n const xSize = getSpace(val);\n const radiusToken = tokens.radius[val] ?? tokens.radius['$true'];\n return {\n paddingHorizontal: xSize,\n height: val,\n borderRadius: props.circular ? 100000 : radiusToken,\n };\n};\n//# sourceMappingURL=index.js.map","import React from 'react';\nexport const ButtonNestingContext = React.createContext(false);\n//# sourceMappingURL=NestingContext.js.map","import { isClient } from '@hanzogui/constants';\nimport { getTokens, styled, Text } from '@hanzogui/web';\nexport const getFontSized = (sizeTokenIn = '$true', { font, fontFamily, props }) => {\n if (!font) {\n return {\n fontSize: sizeTokenIn,\n };\n }\n const sizeToken = sizeTokenIn === '$true' ? getDefaultSizeToken(font) : sizeTokenIn;\n const style = {};\n // A raw numeric size (e.g. `fontSize={32}`) is not a token key, so the\n // `font.size` / `font.lineHeight` maps have no entry for it and every lookup\n // below returns undefined. Treat the number as a literal fontSize and leave\n // lineHeight unset, otherwise a stale default token lineHeight survives and\n // clips glyph tops on iOS (see #4028). We don't scale the lineHeight here,\n // leaving it to the platform default for the given font size.\n if (typeof sizeToken === 'number') {\n style.fontSize = sizeToken;\n if (fontFamily)\n style.fontFamily = fontFamily;\n if (props.fontStyle)\n style.fontStyle = props.fontStyle;\n if (props.color)\n style.color = props.color;\n return style;\n }\n // size related, treat them as overrides\n const fontSize = font.size[sizeToken];\n const lineHeight = font.lineHeight?.[sizeToken];\n const fontWeight = font.weight?.[sizeToken];\n const letterSpacing = font.letterSpacing?.[sizeToken];\n const textTransform = font.transform?.[sizeToken];\n const fontStyle = props.fontStyle ?? font.style?.[sizeToken];\n const color = props.color ?? font.color?.[sizeToken];\n if (fontStyle)\n style.fontStyle = fontStyle;\n if (textTransform)\n style.textTransform = textTransform;\n if (fontFamily)\n style.fontFamily = fontFamily;\n if (fontWeight)\n style.fontWeight = fontWeight;\n if (letterSpacing)\n style.letterSpacing = letterSpacing;\n if (fontSize)\n style.fontSize = fontSize;\n if (lineHeight)\n style.lineHeight = lineHeight;\n if (color)\n style.color = color;\n if (process.env.NODE_ENV === 'development') {\n if (props['debug'] && props['debug'] === 'verbose') {\n console.groupCollapsed(' 🔹 getFontSized', sizeTokenIn, sizeToken);\n if (isClient) {\n console.info({ style, props, font });\n }\n console.groupEnd();\n }\n }\n return style;\n};\nexport const SizableText = styled(Text, {\n name: 'SizableText',\n fontFamily: '$body',\n variants: {\n size: {\n '...fontSize': getFontSized,\n },\n },\n defaultVariants: {\n size: '$true',\n },\n});\nconst cache = new WeakMap();\nfunction getDefaultSizeToken(font) {\n if (typeof font === 'object' && cache.has(font)) {\n return cache.get(font);\n }\n // use either font.size if it has true set, or fallback to tokens.size mapping to the same\n const tokens = getTokens();\n const sizeTokens = '$true' in font.size ? font.size : tokens?.size;\n if (!sizeTokens) {\n return Object.keys(font.size)[3];\n }\n const sizeDefault = sizeTokens['$true'];\n const sizeDefaultSpecific = sizeDefault\n ? Object.keys(sizeTokens).find((x) => x !== '$true' && sizeTokens[x]['val'] === sizeDefault['val'])\n : null;\n if (!sizeDefault || !sizeDefaultSpecific) {\n if (process.env.NODE_ENV === 'development') {\n console.warn(`No default size is set in your tokens for the \"true\" key, fonts will be inconsistent.\n\n Fix this by having consistent tokens across fonts and sizes and setting a true key for your size tokens, or\n set true keys for all your font tokens: \"size\", \"lineHeight\", \"fontStyle\", etc.`);\n }\n return Object.keys(font.size)[3];\n }\n cache.set(font, sizeDefaultSpecific);\n return sizeDefaultSpecific;\n}\n//# sourceMappingURL=index.js.map","import { getFontSized } from '@hanzogui/get-font-sized';\nimport { Text, styled } from '@hanzogui/web';\nexport const SizableText = styled(Text, {\n name: 'SizableText',\n fontFamily: '$body',\n variants: {\n unstyled: {\n false: {\n size: '$true',\n color: '$color',\n },\n },\n size: getFontSized,\n },\n defaultVariants: {\n unstyled: process.env.GUI_HEADLESS === '1',\n },\n});\nSizableText.staticConfig.inlineProps = new Set([\n ...(SizableText.staticConfig.inlineProps || []),\n 'maxFontSizeMultiplier',\n]);\n// we are doing weird stuff to avoid bad types\n// TODO make this just work\nSizableText.staticConfig.variants.fontFamily = {\n '...': (val, extras) => {\n // pass through inherit directly without font variant expansion\n if (val === 'inherit') {\n return { fontFamily: 'inherit' };\n }\n const sizeProp = extras.props['size'];\n const fontSizeProp = extras.props['fontSize'];\n const size = sizeProp === '$true' && fontSizeProp\n ? fontSizeProp\n : extras.props['size'] || '$true';\n return getFontSized(size, extras);\n },\n};\n//# sourceMappingURL=SizableText.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport React from 'react';\nexport function wrapChildrenInText(TextComponent, propsIn, extraProps) {\n const { children, textProps, size, noTextWrap, color, fontFamily, fontSize, fontWeight, letterSpacing, textAlign, fontStyle, ellipsis, maxFontSizeMultiplier, } = propsIn;\n if (noTextWrap || !children) {\n return [children];\n }\n const props = {\n ...extraProps,\n };\n // to avoid setting undefined\n if (color)\n props.color = color;\n if (fontFamily)\n props.fontFamily = fontFamily;\n if (fontSize)\n props.fontSize = fontSize;\n if (fontWeight)\n props.fontWeight = fontWeight;\n if (letterSpacing)\n props.letterSpacing = letterSpacing;\n if (textAlign)\n props.textAlign = textAlign;\n if (size)\n props.size = size;\n if (fontStyle)\n props.fontStyle = fontStyle;\n if (ellipsis !== undefined)\n props.ellipsis = ellipsis;\n if (maxFontSizeMultiplier != null)\n props.maxFontSizeMultiplier = maxFontSizeMultiplier;\n return React.Children.toArray(children).map((child, index) => {\n return typeof child === 'string' ? (_jsx(TextComponent, { ...props, ...textProps, children: child }, index)) : (child);\n });\n}\n//# sourceMappingURL=wrapChildrenInText.js.map","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar isDisabled = props => props.disabled || Array.isArray(props.accessibilityStates) && props.accessibilityStates.indexOf('disabled') > -1;\nexport default isDisabled;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar accessibilityRoleToWebRole = {\n adjustable: 'slider',\n button: 'button',\n header: 'heading',\n image: 'img',\n imagebutton: null,\n keyboardkey: null,\n label: null,\n link: 'link',\n none: 'presentation',\n search: 'search',\n summary: 'region',\n text: null\n};\nvar propsToAriaRole = _ref => {\n var accessibilityRole = _ref.accessibilityRole,\n role = _ref.role;\n var _role = role || accessibilityRole;\n if (_role) {\n var inferredRole = accessibilityRoleToWebRole[_role];\n if (inferredRole !== null) {\n // ignore roles that don't map to web\n return inferredRole || _role;\n }\n }\n};\nexport default propsToAriaRole;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport propsToAriaRole from './propsToAriaRole';\nvar roleComponents = {\n article: 'article',\n banner: 'header',\n blockquote: 'blockquote',\n button: 'button',\n code: 'code',\n complementary: 'aside',\n contentinfo: 'footer',\n deletion: 'del',\n emphasis: 'em',\n figure: 'figure',\n insertion: 'ins',\n form: 'form',\n list: 'ul',\n listitem: 'li',\n main: 'main',\n navigation: 'nav',\n paragraph: 'p',\n region: 'section',\n strong: 'strong'\n};\nvar emptyObject = {};\nvar propsToAccessibilityComponent = function propsToAccessibilityComponent(props) {\n if (props === void 0) {\n props = emptyObject;\n }\n var roleProp = props.role || props.accessibilityRole;\n // special-case for \"label\" role which doesn't map to an ARIA role\n if (roleProp === 'label') {\n return 'label';\n }\n var role = propsToAriaRole(props);\n if (role) {\n if (role === 'heading') {\n var level = props.accessibilityLevel || props['aria-level'];\n if (level != null) {\n return \"h\" + level;\n }\n return 'h1';\n }\n return roleComponents[role];\n }\n};\nexport default propsToAccessibilityComponent;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport isDisabled from './isDisabled';\nimport propsToAccessibilityComponent from './propsToAccessibilityComponent';\nimport propsToAriaRole from './propsToAriaRole';\nvar AccessibilityUtil = {\n isDisabled,\n propsToAccessibilityComponent,\n propsToAriaRole\n};\nexport default AccessibilityUtil;","function _typeof(o) {\n \"@babel/helpers - typeof\";\n\n return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) {\n return typeof o;\n } : function (o) {\n return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o;\n }, _typeof(o);\n}\nexport { _typeof as default };","import _typeof from \"./typeof.js\";\nfunction toPrimitive(t, r) {\n if (\"object\" != _typeof(t) || !t) return t;\n var e = t[Symbol.toPrimitive];\n if (void 0 !== e) {\n var i = e.call(t, r || \"default\");\n if (\"object\" != _typeof(i)) return i;\n throw new TypeError(\"@@toPrimitive must return a primitive value.\");\n }\n return (\"string\" === r ? String : Number)(t);\n}\nexport { toPrimitive as default };","import _typeof from \"./typeof.js\";\nimport toPrimitive from \"./toPrimitive.js\";\nfunction toPropertyKey(t) {\n var i = toPrimitive(t, \"string\");\n return \"symbol\" == _typeof(i) ? i : i + \"\";\n}\nexport { toPropertyKey as default };","import toPropertyKey from \"./toPropertyKey.js\";\nfunction _defineProperty(e, r, t) {\n return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {\n value: t,\n enumerable: !0,\n configurable: !0,\n writable: !0\n }) : e[r] = t, e;\n}\nexport { _defineProperty as default };","import defineProperty from \"./defineProperty.js\";\nfunction ownKeys(e, r) {\n var t = Object.keys(e);\n if (Object.getOwnPropertySymbols) {\n var o = Object.getOwnPropertySymbols(e);\n r && (o = o.filter(function (r) {\n return Object.getOwnPropertyDescriptor(e, r).enumerable;\n })), t.push.apply(t, o);\n }\n return t;\n}\nfunction _objectSpread2(e) {\n for (var r = 1; r < arguments.length; r++) {\n var t = null != arguments[r] ? arguments[r] : {};\n r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {\n defineProperty(e, r, t[r]);\n }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {\n Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));\n });\n }\n return e;\n}\nexport { _objectSpread2 as default };","function _objectWithoutPropertiesLoose(r, e) {\n if (null == r) return {};\n var t = {};\n for (var n in r) if ({}.hasOwnProperty.call(r, n)) {\n if (-1 !== e.indexOf(n)) continue;\n t[n] = r[n];\n }\n return t;\n}\nexport { _objectWithoutPropertiesLoose as default };","/**\n * Copyright (c) Nicolas Gallagher.\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar unitlessNumbers = {\n animationIterationCount: true,\n aspectRatio: true,\n borderImageOutset: true,\n borderImageSlice: true,\n borderImageWidth: true,\n boxFlex: true,\n boxFlexGroup: true,\n boxOrdinalGroup: true,\n columnCount: true,\n flex: true,\n flexGrow: true,\n flexOrder: true,\n flexPositive: true,\n flexShrink: true,\n flexNegative: true,\n fontWeight: true,\n gridRow: true,\n gridRowEnd: true,\n gridRowGap: true,\n gridRowStart: true,\n gridColumn: true,\n gridColumnEnd: true,\n gridColumnGap: true,\n gridColumnStart: true,\n lineClamp: true,\n opacity: true,\n order: true,\n orphans: true,\n tabSize: true,\n widows: true,\n zIndex: true,\n zoom: true,\n // SVG-related\n fillOpacity: true,\n floodOpacity: true,\n stopOpacity: true,\n strokeDasharray: true,\n strokeDashoffset: true,\n strokeMiterlimit: true,\n strokeOpacity: true,\n strokeWidth: true,\n // transform types\n scale: true,\n scaleX: true,\n scaleY: true,\n scaleZ: true,\n // RN properties\n shadowOpacity: true\n};\n\n/**\n * Support style names that may come passed in prefixed by adding permutations\n * of vendor prefixes.\n */\nvar prefixes = ['ms', 'Moz', 'O', 'Webkit'];\nvar prefixKey = (prefix, key) => {\n return prefix + key.charAt(0).toUpperCase() + key.substring(1);\n};\nObject.keys(unitlessNumbers).forEach(prop => {\n prefixes.forEach(prefix => {\n unitlessNumbers[prefixKey(prefix, prop)] = unitlessNumbers[prop];\n });\n});\nexport default unitlessNumbers;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar isWebColor = color => color === 'currentcolor' || color === 'currentColor' || color === 'inherit' || color.indexOf('var(') === 0;\nexport default isWebColor;","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * @format\n * @noflow\n */\n\n/* eslint no-bitwise: 0 */\n\n'use strict';\n\nfunction normalizeColor(color) {\n if (typeof color === 'number') {\n if (color >>> 0 === color && color >= 0 && color <= 0xffffffff) {\n return color;\n }\n return null;\n }\n\n if (typeof color !== 'string') {\n return null;\n }\n\n const matchers = getMatchers();\n let match;\n\n // Ordered based on occurrences on Facebook codebase\n if ((match = matchers.hex6.exec(color))) {\n return parseInt(match[1] + 'ff', 16) >>> 0;\n }\n\n const colorFromKeyword = normalizeKeyword(color);\n if (colorFromKeyword != null) {\n return colorFromKeyword;\n }\n\n if ((match = matchers.rgb.exec(color))) {\n return (\n ((parse255(match[1]) << 24) | // r\n (parse255(match[2]) << 16) | // g\n (parse255(match[3]) << 8) | // b\n 0x000000ff) >>> // a\n 0\n );\n }\n\n if ((match = matchers.rgba.exec(color))) {\n // rgba(R G B / A) notation\n if (match[6] !== undefined) {\n return (\n ((parse255(match[6]) << 24) | // r\n (parse255(match[7]) << 16) | // g\n (parse255(match[8]) << 8) | // b\n parse1(match[9])) >>> // a\n 0\n );\n }\n\n // rgba(R, G, B, A) notation\n return (\n ((parse255(match[2]) << 24) | // r\n (parse255(match[3]) << 16) | // g\n (parse255(match[4]) << 8) | // b\n parse1(match[5])) >>> // a\n 0\n );\n }\n\n if ((match = matchers.hex3.exec(color))) {\n return (\n parseInt(\n match[1] +\n match[1] + // r\n match[2] +\n match[2] + // g\n match[3] +\n match[3] + // b\n 'ff', // a\n 16,\n ) >>> 0\n );\n }\n\n // https://drafts.csswg.org/css-color-4/#hex-notation\n if ((match = matchers.hex8.exec(color))) {\n return parseInt(match[1], 16) >>> 0;\n }\n\n if ((match = matchers.hex4.exec(color))) {\n return (\n parseInt(\n match[1] +\n match[1] + // r\n match[2] +\n match[2] + // g\n match[3] +\n match[3] + // b\n match[4] +\n match[4], // a\n 16,\n ) >>> 0\n );\n }\n\n if ((match = matchers.hsl.exec(color))) {\n return (\n (hslToRgb(\n parse360(match[1]), // h\n parsePercentage(match[2]), // s\n parsePercentage(match[3]), // l\n ) |\n 0x000000ff) >>> // a\n 0\n );\n }\n\n if ((match = matchers.hsla.exec(color))) {\n // hsla(H S L / A) notation\n if (match[6] !== undefined) {\n return (\n (hslToRgb(\n parse360(match[6]), // h\n parsePercentage(match[7]), // s\n parsePercentage(match[8]), // l\n ) |\n parse1(match[9])) >>> // a\n 0\n );\n }\n\n // hsla(H, S, L, A) notation\n return (\n (hslToRgb(\n parse360(match[2]), // h\n parsePercentage(match[3]), // s\n parsePercentage(match[4]), // l\n ) |\n parse1(match[5])) >>> // a\n 0\n );\n }\n\n if ((match = matchers.hwb.exec(color))) {\n return (\n (hwbToRgb(\n parse360(match[1]), // h\n parsePercentage(match[2]), // w\n parsePercentage(match[3]), // b\n ) |\n 0x000000ff) >>> // a\n 0\n );\n }\n\n return null;\n}\n\nfunction hue2rgb(p, q, t) {\n if (t < 0) {\n t += 1;\n }\n if (t > 1) {\n t -= 1;\n }\n if (t < 1 / 6) {\n return p + (q - p) * 6 * t;\n }\n if (t < 1 / 2) {\n return q;\n }\n if (t < 2 / 3) {\n return p + (q - p) * (2 / 3 - t) * 6;\n }\n return p;\n}\n\nfunction hslToRgb(h, s, l) {\n const q = l < 0.5 ? l * (1 + s) : l + s - l * s;\n const p = 2 * l - q;\n const r = hue2rgb(p, q, h + 1 / 3);\n const g = hue2rgb(p, q, h);\n const b = hue2rgb(p, q, h - 1 / 3);\n\n return (\n (Math.round(r * 255) << 24) |\n (Math.round(g * 255) << 16) |\n (Math.round(b * 255) << 8)\n );\n}\n\nfunction hwbToRgb(h, w, b) {\n if (w + b >= 1) {\n const gray = Math.round((w * 255) / (w + b));\n\n return (gray << 24) | (gray << 16) | (gray << 8);\n }\n\n const red = hue2rgb(0, 1, h + 1 / 3) * (1 - w - b) + w;\n const green = hue2rgb(0, 1, h) * (1 - w - b) + w;\n const blue = hue2rgb(0, 1, h - 1 / 3) * (1 - w - b) + w;\n\n return (\n (Math.round(red * 255) << 24) |\n (Math.round(green * 255) << 16) |\n (Math.round(blue * 255) << 8)\n );\n}\n\nconst NUMBER = '[-+]?\\\\d*\\\\.?\\\\d+';\nconst PERCENTAGE = NUMBER + '%';\n\nfunction call(...args) {\n return '\\\\(\\\\s*(' + args.join(')\\\\s*,?\\\\s*(') + ')\\\\s*\\\\)';\n}\n\nfunction callWithSlashSeparator(...args) {\n return (\n '\\\\(\\\\s*(' +\n args.slice(0, args.length - 1).join(')\\\\s*,?\\\\s*(') +\n ')\\\\s*/\\\\s*(' +\n args[args.length - 1] +\n ')\\\\s*\\\\)'\n );\n}\n\nfunction commaSeparatedCall(...args) {\n return '\\\\(\\\\s*(' + args.join(')\\\\s*,\\\\s*(') + ')\\\\s*\\\\)';\n}\n\nlet cachedMatchers;\n\nfunction getMatchers() {\n if (cachedMatchers === undefined) {\n cachedMatchers = {\n rgb: new RegExp('rgb' + call(NUMBER, NUMBER, NUMBER)),\n rgba: new RegExp(\n 'rgba(' +\n commaSeparatedCall(NUMBER, NUMBER, NUMBER, NUMBER) +\n '|' +\n callWithSlashSeparator(NUMBER, NUMBER, NUMBER, NUMBER) +\n ')',\n ),\n hsl: new RegExp('hsl' + call(NUMBER, PERCENTAGE, PERCENTAGE)),\n hsla: new RegExp(\n 'hsla(' +\n commaSeparatedCall(NUMBER, PERCENTAGE, PERCENTAGE, NUMBER) +\n '|' +\n callWithSlashSeparator(NUMBER, PERCENTAGE, PERCENTAGE, NUMBER) +\n ')',\n ),\n hwb: new RegExp('hwb' + call(NUMBER, PERCENTAGE, PERCENTAGE)),\n hex3: /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,\n hex4: /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,\n hex6: /^#([0-9a-fA-F]{6})$/,\n hex8: /^#([0-9a-fA-F]{8})$/,\n };\n }\n return cachedMatchers;\n}\n\nfunction parse255(str) {\n const int = parseInt(str, 10);\n if (int < 0) {\n return 0;\n }\n if (int > 255) {\n return 255;\n }\n return int;\n}\n\nfunction parse360(str) {\n const int = parseFloat(str);\n return (((int % 360) + 360) % 360) / 360;\n}\n\nfunction parse1(str) {\n const num = parseFloat(str);\n if (num < 0) {\n return 0;\n }\n if (num > 1) {\n return 255;\n }\n return Math.round(num * 255);\n}\n\nfunction parsePercentage(str) {\n // parseFloat conveniently ignores the final %\n const int = parseFloat(str);\n if (int < 0) {\n return 0;\n }\n if (int > 100) {\n return 1;\n }\n return int / 100;\n}\n\nfunction normalizeKeyword(name) {\n // prettier-ignore\n switch (name) {\n case 'transparent': return 0x00000000;\n // http://www.w3.org/TR/css3-color/#svg-color\n case 'aliceblue': return 0xf0f8ffff;\n case 'antiquewhite': return 0xfaebd7ff;\n case 'aqua': return 0x00ffffff;\n case 'aquamarine': return 0x7fffd4ff;\n case 'azure': return 0xf0ffffff;\n case 'beige': return 0xf5f5dcff;\n case 'bisque': return 0xffe4c4ff;\n case 'black': return 0x000000ff;\n case 'blanchedalmond': return 0xffebcdff;\n case 'blue': return 0x0000ffff;\n case 'blueviolet': return 0x8a2be2ff;\n case 'brown': return 0xa52a2aff;\n case 'burlywood': return 0xdeb887ff;\n case 'burntsienna': return 0xea7e5dff;\n case 'cadetblue': return 0x5f9ea0ff;\n case 'chartreuse': return 0x7fff00ff;\n case 'chocolate': return 0xd2691eff;\n case 'coral': return 0xff7f50ff;\n case 'cornflowerblue': return 0x6495edff;\n case 'cornsilk': return 0xfff8dcff;\n case 'crimson': return 0xdc143cff;\n case 'cyan': return 0x00ffffff;\n case 'darkblue': return 0x00008bff;\n case 'darkcyan': return 0x008b8bff;\n case 'darkgoldenrod': return 0xb8860bff;\n case 'darkgray': return 0xa9a9a9ff;\n case 'darkgreen': return 0x006400ff;\n case 'darkgrey': return 0xa9a9a9ff;\n case 'darkkhaki': return 0xbdb76bff;\n case 'darkmagenta': return 0x8b008bff;\n case 'darkolivegreen': return 0x556b2fff;\n case 'darkorange': return 0xff8c00ff;\n case 'darkorchid': return 0x9932ccff;\n case 'darkred': return 0x8b0000ff;\n case 'darksalmon': return 0xe9967aff;\n case 'darkseagreen': return 0x8fbc8fff;\n case 'darkslateblue': return 0x483d8bff;\n case 'darkslategray': return 0x2f4f4fff;\n case 'darkslategrey': return 0x2f4f4fff;\n case 'darkturquoise': return 0x00ced1ff;\n case 'darkviolet': return 0x9400d3ff;\n case 'deeppink': return 0xff1493ff;\n case 'deepskyblue': return 0x00bfffff;\n case 'dimgray': return 0x696969ff;\n case 'dimgrey': return 0x696969ff;\n case 'dodgerblue': return 0x1e90ffff;\n case 'firebrick': return 0xb22222ff;\n case 'floralwhite': return 0xfffaf0ff;\n case 'forestgreen': return 0x228b22ff;\n case 'fuchsia': return 0xff00ffff;\n case 'gainsboro': return 0xdcdcdcff;\n case 'ghostwhite': return 0xf8f8ffff;\n case 'gold': return 0xffd700ff;\n case 'goldenrod': return 0xdaa520ff;\n case 'gray': return 0x808080ff;\n case 'green': return 0x008000ff;\n case 'greenyellow': return 0xadff2fff;\n case 'grey': return 0x808080ff;\n case 'honeydew': return 0xf0fff0ff;\n case 'hotpink': return 0xff69b4ff;\n case 'indianred': return 0xcd5c5cff;\n case 'indigo': return 0x4b0082ff;\n case 'ivory': return 0xfffff0ff;\n case 'khaki': return 0xf0e68cff;\n case 'lavender': return 0xe6e6faff;\n case 'lavenderblush': return 0xfff0f5ff;\n case 'lawngreen': return 0x7cfc00ff;\n case 'lemonchiffon': return 0xfffacdff;\n case 'lightblue': return 0xadd8e6ff;\n case 'lightcoral': return 0xf08080ff;\n case 'lightcyan': return 0xe0ffffff;\n case 'lightgoldenrodyellow': return 0xfafad2ff;\n case 'lightgray': return 0xd3d3d3ff;\n case 'lightgreen': return 0x90ee90ff;\n case 'lightgrey': return 0xd3d3d3ff;\n case 'lightpink': return 0xffb6c1ff;\n case 'lightsalmon': return 0xffa07aff;\n case 'lightseagreen': return 0x20b2aaff;\n case 'lightskyblue': return 0x87cefaff;\n case 'lightslategray': return 0x778899ff;\n case 'lightslategrey': return 0x778899ff;\n case 'lightsteelblue': return 0xb0c4deff;\n case 'lightyellow': return 0xffffe0ff;\n case 'lime': return 0x00ff00ff;\n case 'limegreen': return 0x32cd32ff;\n case 'linen': return 0xfaf0e6ff;\n case 'magenta': return 0xff00ffff;\n case 'maroon': return 0x800000ff;\n case 'mediumaquamarine': return 0x66cdaaff;\n case 'mediumblue': return 0x0000cdff;\n case 'mediumorchid': return 0xba55d3ff;\n case 'mediumpurple': return 0x9370dbff;\n case 'mediumseagreen': return 0x3cb371ff;\n case 'mediumslateblue': return 0x7b68eeff;\n case 'mediumspringgreen': return 0x00fa9aff;\n case 'mediumturquoise': return 0x48d1ccff;\n case 'mediumvioletred': return 0xc71585ff;\n case 'midnightblue': return 0x191970ff;\n case 'mintcream': return 0xf5fffaff;\n case 'mistyrose': return 0xffe4e1ff;\n case 'moccasin': return 0xffe4b5ff;\n case 'navajowhite': return 0xffdeadff;\n case 'navy': return 0x000080ff;\n case 'oldlace': return 0xfdf5e6ff;\n case 'olive': return 0x808000ff;\n case 'olivedrab': return 0x6b8e23ff;\n case 'orange': return 0xffa500ff;\n case 'orangered': return 0xff4500ff;\n case 'orchid': return 0xda70d6ff;\n case 'palegoldenrod': return 0xeee8aaff;\n case 'palegreen': return 0x98fb98ff;\n case 'paleturquoise': return 0xafeeeeff;\n case 'palevioletred': return 0xdb7093ff;\n case 'papayawhip': return 0xffefd5ff;\n case 'peachpuff': return 0xffdab9ff;\n case 'peru': return 0xcd853fff;\n case 'pink': return 0xffc0cbff;\n case 'plum': return 0xdda0ddff;\n case 'powderblue': return 0xb0e0e6ff;\n case 'purple': return 0x800080ff;\n case 'rebeccapurple': return 0x663399ff;\n case 'red': return 0xff0000ff;\n case 'rosybrown': return 0xbc8f8fff;\n case 'royalblue': return 0x4169e1ff;\n case 'saddlebrown': return 0x8b4513ff;\n case 'salmon': return 0xfa8072ff;\n case 'sandybrown': return 0xf4a460ff;\n case 'seagreen': return 0x2e8b57ff;\n case 'seashell': return 0xfff5eeff;\n case 'sienna': return 0xa0522dff;\n case 'silver': return 0xc0c0c0ff;\n case 'skyblue': return 0x87ceebff;\n case 'slateblue': return 0x6a5acdff;\n case 'slategray': return 0x708090ff;\n case 'slategrey': return 0x708090ff;\n case 'snow': return 0xfffafaff;\n case 'springgreen': return 0x00ff7fff;\n case 'steelblue': return 0x4682b4ff;\n case 'tan': return 0xd2b48cff;\n case 'teal': return 0x008080ff;\n case 'thistle': return 0xd8bfd8ff;\n case 'tomato': return 0xff6347ff;\n case 'turquoise': return 0x40e0d0ff;\n case 'violet': return 0xee82eeff;\n case 'wheat': return 0xf5deb3ff;\n case 'white': return 0xffffffff;\n case 'whitesmoke': return 0xf5f5f5ff;\n case 'yellow': return 0xffff00ff;\n case 'yellowgreen': return 0x9acd32ff;\n }\n return null;\n}\n\nmodule.exports = normalizeColor;\n","/**\n * Copyright (c) Nicolas Gallagher.\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport normalizeColor from '@react-native/normalize-colors';\nvar processColor = color => {\n if (color === undefined || color === null) {\n return color;\n }\n\n // convert number and hex\n var int32Color = normalizeColor(color);\n if (int32Color === undefined || int32Color === null) {\n return undefined;\n }\n int32Color = (int32Color << 24 | int32Color >>> 8) >>> 0;\n return int32Color;\n};\nexport default processColor;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport isWebColor from '../../../modules/isWebColor';\nimport processColor from '../../../exports/processColor';\nvar normalizeColor = function normalizeColor(color, opacity) {\n if (opacity === void 0) {\n opacity = 1;\n }\n if (color == null) return;\n if (typeof color === 'string' && isWebColor(color)) {\n return color;\n }\n var colorInt = processColor(color);\n if (colorInt != null) {\n var r = colorInt >> 16 & 255;\n var g = colorInt >> 8 & 255;\n var b = colorInt & 255;\n var a = (colorInt >> 24 & 255) / 255;\n var alpha = (a * opacity).toFixed(2);\n return \"rgba(\" + r + \",\" + g + \",\" + b + \",\" + alpha + \")\";\n }\n};\nexport default normalizeColor;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport unitlessNumbers from './unitlessNumbers';\nimport normalizeColor from './normalizeColor';\nvar colorProps = {\n backgroundColor: true,\n borderColor: true,\n borderTopColor: true,\n borderRightColor: true,\n borderBottomColor: true,\n borderLeftColor: true,\n color: true,\n shadowColor: true,\n textDecorationColor: true,\n textShadowColor: true\n};\nexport default function normalizeValueWithProperty(value, property) {\n var returnValue = value;\n if ((property == null || !unitlessNumbers[property]) && typeof value === 'number') {\n returnValue = value + \"px\";\n } else if (property != null && colorProps[property]) {\n returnValue = normalizeColor(value);\n }\n return returnValue;\n}","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);\nexport default canUseDOM;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport normalizeValueWithProperty from './normalizeValueWithProperty';\nimport canUseDOM from '../../../modules/canUseDom';\n/**\n * The browser implements the CSS cascade, where the order of properties is a\n * factor in determining which styles to paint. React Native is different. It\n * gives giving precedence to the more specific style property. For example,\n * the value of `paddingTop` takes precedence over that of `padding`.\n *\n * This module creates mutally exclusive style declarations by expanding all of\n * React Native's supported shortform properties (e.g. `padding`) to their\n * longfrom equivalents.\n */\n\nvar emptyObject = {};\nvar supportsCSS3TextDecoration = !canUseDOM || window.CSS != null && window.CSS.supports != null && (window.CSS.supports('text-decoration-line', 'none') || window.CSS.supports('-webkit-text-decoration-line', 'none'));\nvar MONOSPACE_FONT_STACK = 'monospace,monospace';\nvar SYSTEM_FONT_STACK = '-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif';\nvar STYLE_SHORT_FORM_EXPANSIONS = {\n borderColor: ['borderTopColor', 'borderRightColor', 'borderBottomColor', 'borderLeftColor'],\n borderBlockColor: ['borderTopColor', 'borderBottomColor'],\n borderInlineColor: ['borderRightColor', 'borderLeftColor'],\n borderRadius: ['borderTopLeftRadius', 'borderTopRightRadius', 'borderBottomRightRadius', 'borderBottomLeftRadius'],\n borderStyle: ['borderTopStyle', 'borderRightStyle', 'borderBottomStyle', 'borderLeftStyle'],\n borderBlockStyle: ['borderTopStyle', 'borderBottomStyle'],\n borderInlineStyle: ['borderRightStyle', 'borderLeftStyle'],\n borderWidth: ['borderTopWidth', 'borderRightWidth', 'borderBottomWidth', 'borderLeftWidth'],\n borderBlockWidth: ['borderTopWidth', 'borderBottomWidth'],\n borderInlineWidth: ['borderRightWidth', 'borderLeftWidth'],\n insetBlock: ['top', 'bottom'],\n insetInline: ['left', 'right'],\n marginBlock: ['marginTop', 'marginBottom'],\n marginInline: ['marginRight', 'marginLeft'],\n paddingBlock: ['paddingTop', 'paddingBottom'],\n paddingInline: ['paddingRight', 'paddingLeft'],\n overflow: ['overflowX', 'overflowY'],\n overscrollBehavior: ['overscrollBehaviorX', 'overscrollBehaviorY'],\n borderBlockStartColor: ['borderTopColor'],\n borderBlockStartStyle: ['borderTopStyle'],\n borderBlockStartWidth: ['borderTopWidth'],\n borderBlockEndColor: ['borderBottomColor'],\n borderBlockEndStyle: ['borderBottomStyle'],\n borderBlockEndWidth: ['borderBottomWidth'],\n //borderInlineStartColor: ['borderLeftColor'],\n //borderInlineStartStyle: ['borderLeftStyle'],\n //borderInlineStartWidth: ['borderLeftWidth'],\n //borderInlineEndColor: ['borderRightColor'],\n //borderInlineEndStyle: ['borderRightStyle'],\n //borderInlineEndWidth: ['borderRightWidth'],\n borderEndStartRadius: ['borderBottomLeftRadius'],\n borderEndEndRadius: ['borderBottomRightRadius'],\n borderStartStartRadius: ['borderTopLeftRadius'],\n borderStartEndRadius: ['borderTopRightRadius'],\n insetBlockEnd: ['bottom'],\n insetBlockStart: ['top'],\n //insetInlineEnd: ['right'],\n //insetInlineStart: ['left'],\n marginBlockStart: ['marginTop'],\n marginBlockEnd: ['marginBottom'],\n //marginInlineStart: ['marginLeft'],\n //marginInlineEnd: ['marginRight'],\n paddingBlockStart: ['paddingTop'],\n paddingBlockEnd: ['paddingBottom']\n //paddingInlineStart: ['marginLeft'],\n //paddingInlineEnd: ['marginRight'],\n};\n\n/**\n * Reducer\n */\n\nvar createReactDOMStyle = (style, isInline) => {\n if (!style) {\n return emptyObject;\n }\n var resolvedStyle = {};\n var _loop = function _loop() {\n var value = style[prop];\n if (\n // Ignore everything with a null value\n value == null) {\n return \"continue\";\n }\n if (prop === 'backgroundClip') {\n // TODO: remove once this issue is fixed\n // https://github.com/rofrischmann/inline-style-prefixer/issues/159\n if (value === 'text') {\n resolvedStyle.backgroundClip = value;\n resolvedStyle.WebkitBackgroundClip = value;\n }\n } else if (prop === 'flex') {\n if (value === -1) {\n resolvedStyle.flexGrow = 0;\n resolvedStyle.flexShrink = 1;\n resolvedStyle.flexBasis = 'auto';\n } else {\n resolvedStyle.flex = value;\n }\n } else if (prop === 'font') {\n resolvedStyle[prop] = value.replace('System', SYSTEM_FONT_STACK);\n } else if (prop === 'fontFamily') {\n if (value.indexOf('System') > -1) {\n var stack = value.split(/,\\s*/);\n stack[stack.indexOf('System')] = SYSTEM_FONT_STACK;\n resolvedStyle[prop] = stack.join(',');\n } else if (value === 'monospace') {\n resolvedStyle[prop] = MONOSPACE_FONT_STACK;\n } else {\n resolvedStyle[prop] = value;\n }\n } else if (prop === 'textDecorationLine') {\n // use 'text-decoration' for browsers that only support CSS2\n // text-decoration (e.g., IE, Edge)\n if (!supportsCSS3TextDecoration) {\n resolvedStyle.textDecoration = value;\n } else {\n resolvedStyle.textDecorationLine = value;\n }\n } else if (prop === 'writingDirection') {\n resolvedStyle.direction = value;\n } else {\n var _value = normalizeValueWithProperty(style[prop], prop);\n var longFormProperties = STYLE_SHORT_FORM_EXPANSIONS[prop];\n if (isInline && prop === 'inset') {\n if (style.insetInline == null) {\n resolvedStyle.left = _value;\n resolvedStyle.right = _value;\n }\n if (style.insetBlock == null) {\n resolvedStyle.top = _value;\n resolvedStyle.bottom = _value;\n }\n } else if (isInline && prop === 'margin') {\n if (style.marginInline == null) {\n resolvedStyle.marginLeft = _value;\n resolvedStyle.marginRight = _value;\n }\n if (style.marginBlock == null) {\n resolvedStyle.marginTop = _value;\n resolvedStyle.marginBottom = _value;\n }\n } else if (isInline && prop === 'padding') {\n if (style.paddingInline == null) {\n resolvedStyle.paddingLeft = _value;\n resolvedStyle.paddingRight = _value;\n }\n if (style.paddingBlock == null) {\n resolvedStyle.paddingTop = _value;\n resolvedStyle.paddingBottom = _value;\n }\n } else if (longFormProperties) {\n longFormProperties.forEach((longForm, i) => {\n // The value of any longform property in the original styles takes\n // precedence over the shortform's value.\n if (style[longForm] == null) {\n resolvedStyle[longForm] = _value;\n }\n });\n } else {\n resolvedStyle[prop] = _value;\n }\n }\n };\n for (var prop in style) {\n var _ret = _loop();\n if (_ret === \"continue\") continue;\n }\n return resolvedStyle;\n};\nexport default createReactDOMStyle;","/* eslint-disable */\n\n/**\n * JS Implementation of MurmurHash2\n *\n * @author <a href=\"mailto:gary.court@gmail.com\">Gary Court</a>\n * @see http://github.com/garycourt/murmurhash-js\n * @author <a href=\"mailto:aappleby@gmail.com\">Austin Appleby</a>\n * @see http://sites.google.com/site/murmurhash/\n *\n * @param {string} str ASCII only\n * @param {number} seed Positive integer only\n * @return {number} 32-bit positive integer hash\n *\n * \n */\n\nfunction murmurhash2_32_gc(str, seed) {\n var l = str.length,\n h = seed ^ l,\n i = 0,\n k;\n while (l >= 4) {\n k = str.charCodeAt(i) & 0xff | (str.charCodeAt(++i) & 0xff) << 8 | (str.charCodeAt(++i) & 0xff) << 16 | (str.charCodeAt(++i) & 0xff) << 24;\n k = (k & 0xffff) * 0x5bd1e995 + (((k >>> 16) * 0x5bd1e995 & 0xffff) << 16);\n k ^= k >>> 24;\n k = (k & 0xffff) * 0x5bd1e995 + (((k >>> 16) * 0x5bd1e995 & 0xffff) << 16);\n h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16) ^ k;\n l -= 4;\n ++i;\n }\n switch (l) {\n case 3:\n h ^= (str.charCodeAt(i + 2) & 0xff) << 16;\n case 2:\n h ^= (str.charCodeAt(i + 1) & 0xff) << 8;\n case 1:\n h ^= str.charCodeAt(i) & 0xff;\n h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16);\n }\n h ^= h >>> 13;\n h = (h & 0xffff) * 0x5bd1e995 + (((h >>> 16) * 0x5bd1e995 & 0xffff) << 16);\n h ^= h >>> 15;\n return h >>> 0;\n}\nvar hash = str => murmurhash2_32_gc(str, 1).toString(36);\nexport default hash;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar uppercasePattern = /[A-Z]/g;\nvar msPattern = /^ms-/;\nvar cache = {};\nfunction toHyphenLower(match) {\n return '-' + match.toLowerCase();\n}\nfunction hyphenateStyleName(name) {\n if (name in cache) {\n return cache[name];\n }\n var hName = name.replace(uppercasePattern, toHyphenLower);\n return cache[name] = msPattern.test(hName) ? '-' + hName : hName;\n}\nexport default hyphenateStyleName;","\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = capitalizeString;\nfunction capitalizeString(str) {\n return str.charAt(0).toUpperCase() + str.slice(1);\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = prefixProperty;\n\nvar _capitalizeString = require('./capitalizeString');\n\nvar _capitalizeString2 = _interopRequireDefault(_capitalizeString);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction prefixProperty(prefixProperties, property, style) {\n var requiredPrefixes = prefixProperties[property];\n\n if (requiredPrefixes && style.hasOwnProperty(property)) {\n var capitalizedProperty = (0, _capitalizeString2.default)(property);\n\n for (var i = 0; i < requiredPrefixes.length; ++i) {\n var prefixedProperty = requiredPrefixes[i] + capitalizedProperty;\n\n if (!style[prefixedProperty]) {\n style[prefixedProperty] = style[property];\n }\n }\n }\n\n return style;\n}","\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = prefixValue;\nfunction prefixValue(plugins, property, value, style, metaData) {\n for (var i = 0, len = plugins.length; i < len; ++i) {\n var processedValue = plugins[i](property, value, style, metaData);\n\n // we can stop processing if a value is returned\n // as all plugin criteria are unique\n if (processedValue) {\n return processedValue;\n }\n }\n}","\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = addNewValuesOnly;\nfunction addIfNew(list, value) {\n if (list.indexOf(value) === -1) {\n list.push(value);\n }\n}\n\nfunction addNewValuesOnly(list, values) {\n if (Array.isArray(values)) {\n for (var i = 0, len = values.length; i < len; ++i) {\n addIfNew(list, values[i]);\n }\n } else {\n addIfNew(list, values);\n }\n}","\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = isObject;\nfunction isObject(value) {\n return value instanceof Object && !Array.isArray(value);\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = createPrefixer;\n\nvar _prefixProperty = require('./utils/prefixProperty');\n\nvar _prefixProperty2 = _interopRequireDefault(_prefixProperty);\n\nvar _prefixValue = require('./utils/prefixValue');\n\nvar _prefixValue2 = _interopRequireDefault(_prefixValue);\n\nvar _addNewValuesOnly = require('./utils/addNewValuesOnly');\n\nvar _addNewValuesOnly2 = _interopRequireDefault(_addNewValuesOnly);\n\nvar _isObject = require('./utils/isObject');\n\nvar _isObject2 = _interopRequireDefault(_isObject);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nfunction createPrefixer(_ref) {\n var prefixMap = _ref.prefixMap,\n plugins = _ref.plugins;\n\n return function prefix(style) {\n for (var property in style) {\n var value = style[property];\n\n // handle nested objects\n if ((0, _isObject2.default)(value)) {\n style[property] = prefix(value);\n // handle array values\n } else if (Array.isArray(value)) {\n var combinedValue = [];\n\n for (var i = 0, len = value.length; i < len; ++i) {\n var processedValue = (0, _prefixValue2.default)(plugins, property, value[i], style, prefixMap);\n\n (0, _addNewValuesOnly2.default)(combinedValue, processedValue || value[i]);\n }\n\n // only modify the value if it was touched\n // by any plugin to prevent unnecessary mutations\n if (combinedValue.length > 0) {\n style[property] = combinedValue;\n }\n } else {\n var _processedValue = (0, _prefixValue2.default)(plugins, property, value, style, prefixMap);\n\n // only modify the value if it was touched\n // by any plugin to prevent unnecessary mutations\n if (_processedValue) {\n style[property] = _processedValue;\n }\n\n style = (0, _prefixProperty2.default)(prefixMap, property, style);\n }\n }\n\n return style;\n };\n}","function _typeof(obj) { \"@babel/helpers - typeof\"; if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; }; } return _typeof(obj); }\n\nfunction _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }\n\nfunction _nonIterableSpread() { throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\n\nfunction _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === \"string\") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === \"Object\" && o.constructor) n = o.constructor.name; if (n === \"Map\" || n === \"Set\") return Array.from(n); if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }\n\nfunction _iterableToArray(iter) { if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter); }\n\nfunction _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }\n\nfunction _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }\n\nfunction filterUniqueArray(arr) {\n return arr.filter(function (val, index) {\n return arr.lastIndexOf(val) === index;\n });\n}\n\nexport default function assignStyle(base) {\n for (var i = 0, len = arguments.length <= 1 ? 0 : arguments.length - 1; i < len; ++i) {\n var style = i + 1 < 1 || arguments.length <= i + 1 ? undefined : arguments[i + 1];\n\n for (var property in style) {\n var value = style[property];\n var baseValue = base[property];\n\n if (baseValue && value) {\n if (Array.isArray(baseValue)) {\n base[property] = filterUniqueArray(baseValue.concat(value));\n continue;\n }\n\n if (Array.isArray(value)) {\n base[property] = filterUniqueArray([baseValue].concat(_toConsumableArray(value)));\n continue;\n }\n\n if (_typeof(value) === 'object') {\n base[property] = assignStyle({}, baseValue, value);\n continue;\n }\n }\n\n base[property] = value;\n }\n }\n\n return base;\n}","var DASH = /-([a-z])/g;\nvar MS = /^Ms/g;\nvar cache = {};\n\nfunction toUpper(match) {\n return match[1].toUpperCase();\n}\n\nexport default function camelCaseProperty(property) {\n if (cache.hasOwnProperty(property)) {\n return cache[property];\n }\n\n var camelProp = property.replace(DASH, toUpper).replace(MS, 'ms');\n cache[property] = camelProp;\n return camelProp;\n}","/* eslint-disable no-var, prefer-template */\nvar uppercasePattern = /[A-Z]/g\nvar msPattern = /^ms-/\nvar cache = {}\n\nfunction toHyphenLower(match) {\n return '-' + match.toLowerCase()\n}\n\nfunction hyphenateStyleName(name) {\n if (cache.hasOwnProperty(name)) {\n return cache[name]\n }\n\n var hName = name.replace(uppercasePattern, toHyphenLower)\n return (cache[name] = msPattern.test(hName) ? '-' + hName : hName)\n}\n\nexport default hyphenateStyleName\n","import hyphenateStyleName from 'hyphenate-style-name';\nexport default function hyphenateProperty(property) {\n return hyphenateStyleName(property);\n}","import hyphenateProperty from './hyphenateProperty';\nexport default function cssifyDeclaration(property, value) {\n return hyphenateProperty(property) + ':' + value;\n}","import cssifyDeclaration from './cssifyDeclaration';\nexport default function cssifyObject(style) {\n var css = '';\n\n for (var property in style) {\n var value = style[property];\n\n if (typeof value !== 'string' && typeof value !== 'number') {\n continue;\n } // prevents the semicolon after\n // the last rule declaration\n\n\n if (css) {\n css += ';';\n }\n\n css += cssifyDeclaration(property, value);\n }\n\n return css;\n}","var RE = /^(Webkit|Moz|O|ms)/;\nexport default function isPrefixedProperty(property) {\n return RE.test(property);\n}","var RE = /-webkit-|-moz-|-ms-/;\nexport default function isPrefixedValue(value) {\n return typeof value === 'string' && RE.test(value);\n}","import hyphenateProperty from './hyphenateProperty';\nvar unitlessProperties = {\n borderImageOutset: true,\n borderImageSlice: true,\n borderImageWidth: true,\n fontWeight: true,\n lineHeight: true,\n opacity: true,\n orphans: true,\n tabSize: true,\n widows: true,\n zIndex: true,\n zoom: true,\n // SVG-related properties\n fillOpacity: true,\n floodOpacity: true,\n stopOpacity: true,\n strokeDasharray: true,\n strokeDashoffset: true,\n strokeMiterlimit: true,\n strokeOpacity: true,\n strokeWidth: true\n};\nvar prefixedUnitlessProperties = ['animationIterationCount', 'boxFlex', 'boxFlexGroup', 'boxOrdinalGroup', 'columnCount', 'flex', 'flexGrow', 'flexPositive', 'flexShrink', 'flexNegative', 'flexOrder', 'gridColumn', 'gridColumnEnd', 'gridColumnStart', 'gridRow', 'gridRowEnd', 'gridRowStart', 'lineClamp', 'order'];\nvar prefixes = ['Webkit', 'ms', 'Moz', 'O'];\n\nfunction getPrefixedProperty(prefix, property) {\n return prefix + property.charAt(0).toUpperCase() + property.slice(1);\n} // add all prefixed properties to the unitless properties\n\n\nfor (var i = 0, len = prefixedUnitlessProperties.length; i < len; ++i) {\n var property = prefixedUnitlessProperties[i];\n unitlessProperties[property] = true;\n\n for (var j = 0, jLen = prefixes.length; j < jLen; ++j) {\n unitlessProperties[getPrefixedProperty(prefixes[j], property)] = true;\n }\n} // add all hypenated properties as well\n\n\nfor (var _property in unitlessProperties) {\n unitlessProperties[hyphenateProperty(_property)] = true;\n}\n\nexport default function isUnitlessProperty(property) {\n return unitlessProperties.hasOwnProperty(property);\n}","var RE = /^(ms|Webkit|Moz|O)/;\nexport default function unprefixProperty(property) {\n var propertyWithoutPrefix = property.replace(RE, '');\n return propertyWithoutPrefix.charAt(0).toLowerCase() + propertyWithoutPrefix.slice(1);\n}","import camelCaseProperty from './camelCaseProperty';\nimport unprefixProperty from './unprefixProperty';\nexport default function normalizeProperty(property) {\n return unprefixProperty(camelCaseProperty(property));\n}","import hyphenateProperty from './hyphenateProperty';\nexport default function resolveArrayValue(property, value) {\n return value.join(';' + hyphenateProperty(property) + ':');\n}","var RE = /(-ms-|-webkit-|-moz-|-o-)/g;\nexport default function unprefixValue(value) {\n if (typeof value === 'string') {\n return value.replace(RE, '');\n }\n\n return value;\n}","import assignStyle from './assignStyle';\nimport camelCaseProperty from './camelCaseProperty';\nimport cssifyDeclaration from './cssifyDeclaration';\nimport cssifyObject from './cssifyObject';\nimport hyphenateProperty from './hyphenateProperty';\nimport isPrefixedProperty from './isPrefixedProperty';\nimport isPrefixedValue from './isPrefixedValue';\nimport isUnitlessProperty from './isUnitlessProperty';\nimport normalizeProperty from './normalizeProperty';\nimport resolveArrayValue from './resolveArrayValue';\nimport unprefixProperty from './unprefixProperty';\nimport unprefixValue from './unprefixValue';\nexport { assignStyle, camelCaseProperty, cssifyDeclaration, cssifyObject, hyphenateProperty, isPrefixedProperty, isPrefixedValue, isUnitlessProperty, normalizeProperty, resolveArrayValue, unprefixProperty, unprefixValue };","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = crossFade;\n\nvar _cssInJsUtils = require('css-in-js-utils');\n\nvar CROSS_FADE_REGEX = /cross-fade\\(/g;\n// http://caniuse.com/#search=cross-fade\nvar prefixes = ['-webkit-', ''];\n\nfunction crossFade(property, value) {\n if (typeof value === 'string' && !(0, _cssInJsUtils.isPrefixedValue)(value) && value.indexOf('cross-fade(') !== -1) {\n return prefixes.map(function (prefix) {\n return value.replace(CROSS_FADE_REGEX, prefix + 'cross-fade(');\n });\n }\n}","\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports[\"default\"] = isPrefixedValue;\nvar RE = /-webkit-|-moz-|-ms-/;\n\nfunction isPrefixedValue(value) {\n return typeof value === 'string' && RE.test(value);\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = imageSet;\n\nvar _isPrefixedValue = require('css-in-js-utils/lib/isPrefixedValue');\n\nvar _isPrefixedValue2 = _interopRequireDefault(_isPrefixedValue);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\n// http://caniuse.com/#feat=css-image-set\nvar prefixes = ['-webkit-', ''];\n\nfunction imageSet(property, value) {\n if (typeof value === 'string' && !(0, _isPrefixedValue2.default)(value) && value.indexOf('image-set(') > -1) {\n return prefixes.map(function (prefix) {\n return value.replace(/image-set\\(/g, prefix + 'image-set(');\n });\n }\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = logical;\nvar alternativeProps = {\n marginBlockStart: ['WebkitMarginBefore'],\n marginBlockEnd: ['WebkitMarginAfter'],\n marginInlineStart: ['WebkitMarginStart', 'MozMarginStart'],\n marginInlineEnd: ['WebkitMarginEnd', 'MozMarginEnd'],\n paddingBlockStart: ['WebkitPaddingBefore'],\n paddingBlockEnd: ['WebkitPaddingAfter'],\n paddingInlineStart: ['WebkitPaddingStart', 'MozPaddingStart'],\n paddingInlineEnd: ['WebkitPaddingEnd', 'MozPaddingEnd'],\n borderBlockStart: ['WebkitBorderBefore'],\n borderBlockStartColor: ['WebkitBorderBeforeColor'],\n borderBlockStartStyle: ['WebkitBorderBeforeStyle'],\n borderBlockStartWidth: ['WebkitBorderBeforeWidth'],\n borderBlockEnd: ['WebkitBorderAfter'],\n borderBlockEndColor: ['WebkitBorderAfterColor'],\n borderBlockEndStyle: ['WebkitBorderAfterStyle'],\n borderBlockEndWidth: ['WebkitBorderAfterWidth'],\n borderInlineStart: ['WebkitBorderStart', 'MozBorderStart'],\n borderInlineStartColor: ['WebkitBorderStartColor', 'MozBorderStartColor'],\n borderInlineStartStyle: ['WebkitBorderStartStyle', 'MozBorderStartStyle'],\n borderInlineStartWidth: ['WebkitBorderStartWidth', 'MozBorderStartWidth'],\n borderInlineEnd: ['WebkitBorderEnd', 'MozBorderEnd'],\n borderInlineEndColor: ['WebkitBorderEndColor', 'MozBorderEndColor'],\n borderInlineEndStyle: ['WebkitBorderEndStyle', 'MozBorderEndStyle'],\n borderInlineEndWidth: ['WebkitBorderEndWidth', 'MozBorderEndWidth']\n};\n\nfunction logical(property, value, style) {\n if (Object.prototype.hasOwnProperty.call(alternativeProps, property)) {\n var alternativePropList = alternativeProps[property];\n for (var i = 0, len = alternativePropList.length; i < len; ++i) {\n style[alternativePropList[i]] = value;\n }\n }\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = position;\nfunction position(property, value) {\n if (property === 'position' && value === 'sticky') {\n return ['-webkit-sticky', 'sticky'];\n }\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = sizing;\nvar prefixes = ['-webkit-', '-moz-', ''];\n\nvar properties = {\n maxHeight: true,\n maxWidth: true,\n width: true,\n height: true,\n columnWidth: true,\n minWidth: true,\n minHeight: true\n};\nvar values = {\n 'min-content': true,\n 'max-content': true,\n 'fill-available': true,\n 'fit-content': true,\n 'contain-floats': true\n};\n\nfunction sizing(property, value) {\n if (properties.hasOwnProperty(property) && values.hasOwnProperty(value)) {\n return prefixes.map(function (prefix) {\n return prefix + value;\n });\n }\n}","\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports[\"default\"] = hyphenateProperty;\n\nvar _hyphenateStyleName = require(\"hyphenate-style-name\");\n\nvar _hyphenateStyleName2 = _interopRequireDefault(_hyphenateStyleName);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { \"default\": obj }; }\n\nfunction hyphenateProperty(property) {\n return (0, _hyphenateStyleName2[\"default\"])(property);\n}","'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.default = transition;\n\nvar _hyphenateProperty = require('css-in-js-utils/lib/hyphenateProperty');\n\nvar _hyphenateProperty2 = _interopRequireDefault(_hyphenateProperty);\n\nvar _isPrefixedValue = require('css-in-js-utils/lib/isPrefixedValue');\n\nvar _isPrefixedValue2 = _interopRequireDefault(_isPrefixedValue);\n\nvar _capitalizeString = require('../utils/capitalizeString');\n\nvar _capitalizeString2 = _interopRequireDefault(_capitalizeString);\n\nfunction _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }\n\nvar properties = {\n transition: true,\n transitionProperty: true,\n WebkitTransition: true,\n WebkitTransitionProperty: true,\n MozTransition: true,\n MozTransitionProperty: true\n};\n\nvar prefixMapping = {\n Webkit: '-webkit-',\n Moz: '-moz-',\n ms: '-ms-'\n};\n\nfunction prefixValue(value, propertyPrefixMap) {\n if ((0, _isPrefixedValue2.default)(value)) {\n return value;\n }\n\n // only split multi values, not cubic beziers\n var multipleValues = value.split(/,(?![^()]*(?:\\([^()]*\\))?\\))/g);\n\n for (var i = 0, len = multipleValues.length; i < len; ++i) {\n var singleValue = multipleValues[i];\n var values = [singleValue];\n for (var property in propertyPrefixMap) {\n var dashCaseProperty = (0, _hyphenateProperty2.default)(property);\n\n if (singleValue.indexOf(dashCaseProperty) > -1 && dashCaseProperty !== 'order') {\n var prefixes = propertyPrefixMap[property];\n for (var j = 0, pLen = prefixes.length; j < pLen; ++j) {\n // join all prefixes and create a new value\n values.unshift(singleValue.replace(dashCaseProperty, prefixMapping[prefixes[j]] + dashCaseProperty));\n }\n }\n }\n\n multipleValues[i] = values.join(',');\n }\n\n return multipleValues.join(',');\n}\n\nfunction transition(property, value, style, propertyPrefixMap) {\n // also check for already prefixed transitions\n if (typeof value === 'string' && properties.hasOwnProperty(property)) {\n var outputValue = prefixValue(value, propertyPrefixMap);\n // if the property is already prefixed\n var webkitOutput = outputValue.split(/,(?![^()]*(?:\\([^()]*\\))?\\))/g).filter(function (val) {\n return !/-moz-|-ms-/.test(val);\n }).join(',');\n\n if (property.indexOf('Webkit') > -1) {\n return webkitOutput;\n }\n\n var mozOutput = outputValue.split(/,(?![^()]*(?:\\([^()]*\\))?\\))/g).filter(function (val) {\n return !/-webkit-|-ms-/.test(val);\n }).join(',');\n\n if (property.indexOf('Moz') > -1) {\n return mozOutput;\n }\n\n style['Webkit' + (0, _capitalizeString2.default)(property)] = webkitOutput;\n style['Moz' + (0, _capitalizeString2.default)(property)] = mozOutput;\n return outputValue;\n }\n}","import crossFade from 'inline-style-prefixer/lib/plugins/crossFade';\nimport imageSet from 'inline-style-prefixer/lib/plugins/imageSet';\nimport logical from 'inline-style-prefixer/lib/plugins/logical';\nimport position from 'inline-style-prefixer/lib/plugins/position';\nimport sizing from 'inline-style-prefixer/lib/plugins/sizing';\nimport transition from 'inline-style-prefixer/lib/plugins/transition';\nvar w = ['Webkit'];\nvar m = ['Moz'];\nvar wm = ['Webkit', 'Moz'];\nvar wms = ['Webkit', 'ms'];\nvar wmms = ['Webkit', 'Moz', 'ms'];\nexport default {\n plugins: [crossFade, imageSet, logical, position, sizing, transition],\n prefixMap: {\n appearance: wmms,\n userSelect: wm,\n textEmphasisPosition: wms,\n textEmphasis: wms,\n textEmphasisStyle: wms,\n textEmphasisColor: wms,\n boxDecorationBreak: wms,\n clipPath: w,\n maskImage: wms,\n maskMode: wms,\n maskRepeat: wms,\n maskPosition: wms,\n maskClip: wms,\n maskOrigin: wms,\n maskSize: wms,\n maskComposite: wms,\n mask: wms,\n maskBorderSource: wms,\n maskBorderMode: wms,\n maskBorderSlice: wms,\n maskBorderWidth: wms,\n maskBorderOutset: wms,\n maskBorderRepeat: wms,\n maskBorder: wms,\n maskType: wms,\n textDecorationStyle: w,\n textDecorationSkip: w,\n textDecorationLine: w,\n textDecorationColor: w,\n filter: w,\n breakAfter: w,\n breakBefore: w,\n breakInside: w,\n columnCount: w,\n columnFill: w,\n columnGap: w,\n columnRule: w,\n columnRuleColor: w,\n columnRuleStyle: w,\n columnRuleWidth: w,\n columns: w,\n columnSpan: w,\n columnWidth: w,\n backdropFilter: w,\n hyphens: w,\n flowInto: w,\n flowFrom: w,\n regionFragment: w,\n textOrientation: w,\n tabSize: m,\n fontKerning: w,\n textSizeAdjust: w\n }\n};","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport createPrefixer from 'inline-style-prefixer/lib/createPrefixer';\nimport staticData from './static';\nvar prefixAll = createPrefixer(staticData);\nexport default prefixAll;","import _objectSpread from \"@babel/runtime/helpers/objectSpread2\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nvar _excluded = [\"animationKeyframes\"];\n/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport createReactDOMStyle from './createReactDOMStyle';\nimport hash from './hash';\nimport hyphenateStyleName from './hyphenateStyleName';\nimport normalizeValueWithProperty from './normalizeValueWithProperty';\nimport prefixStyles from '../../../modules/prefixStyles';\nvar cache = new Map();\nvar emptyObject = {};\nvar classicGroup = 1;\nvar atomicGroup = 3;\nvar customGroup = {\n borderColor: 2,\n borderRadius: 2,\n borderStyle: 2,\n borderWidth: 2,\n display: 2,\n flex: 2,\n inset: 2,\n margin: 2,\n overflow: 2,\n overscrollBehavior: 2,\n padding: 2,\n insetBlock: 2.1,\n insetInline: 2.1,\n marginInline: 2.1,\n marginBlock: 2.1,\n paddingInline: 2.1,\n paddingBlock: 2.1,\n borderBlockStartColor: 2.2,\n borderBlockStartStyle: 2.2,\n borderBlockStartWidth: 2.2,\n borderBlockEndColor: 2.2,\n borderBlockEndStyle: 2.2,\n borderBlockEndWidth: 2.2,\n borderInlineStartColor: 2.2,\n borderInlineStartStyle: 2.2,\n borderInlineStartWidth: 2.2,\n borderInlineEndColor: 2.2,\n borderInlineEndStyle: 2.2,\n borderInlineEndWidth: 2.2,\n borderEndStartRadius: 2.2,\n borderEndEndRadius: 2.2,\n borderStartStartRadius: 2.2,\n borderStartEndRadius: 2.2,\n insetBlockEnd: 2.2,\n insetBlockStart: 2.2,\n insetInlineEnd: 2.2,\n insetInlineStart: 2.2,\n marginBlockStart: 2.2,\n marginBlockEnd: 2.2,\n marginInlineStart: 2.2,\n marginInlineEnd: 2.2,\n paddingBlockStart: 2.2,\n paddingBlockEnd: 2.2,\n paddingInlineStart: 2.2,\n paddingInlineEnd: 2.2\n};\nvar borderTopLeftRadius = 'borderTopLeftRadius';\nvar borderTopRightRadius = 'borderTopRightRadius';\nvar borderBottomLeftRadius = 'borderBottomLeftRadius';\nvar borderBottomRightRadius = 'borderBottomRightRadius';\nvar borderLeftColor = 'borderLeftColor';\nvar borderLeftStyle = 'borderLeftStyle';\nvar borderLeftWidth = 'borderLeftWidth';\nvar borderRightColor = 'borderRightColor';\nvar borderRightStyle = 'borderRightStyle';\nvar borderRightWidth = 'borderRightWidth';\nvar right = 'right';\nvar marginLeft = 'marginLeft';\nvar marginRight = 'marginRight';\nvar paddingLeft = 'paddingLeft';\nvar paddingRight = 'paddingRight';\nvar left = 'left';\n\n// Map of LTR property names to their BiDi equivalent.\nvar PROPERTIES_FLIP = {\n [borderTopLeftRadius]: borderTopRightRadius,\n [borderTopRightRadius]: borderTopLeftRadius,\n [borderBottomLeftRadius]: borderBottomRightRadius,\n [borderBottomRightRadius]: borderBottomLeftRadius,\n [borderLeftColor]: borderRightColor,\n [borderLeftStyle]: borderRightStyle,\n [borderLeftWidth]: borderRightWidth,\n [borderRightColor]: borderLeftColor,\n [borderRightStyle]: borderLeftStyle,\n [borderRightWidth]: borderLeftWidth,\n [left]: right,\n [marginLeft]: marginRight,\n [marginRight]: marginLeft,\n [paddingLeft]: paddingRight,\n [paddingRight]: paddingLeft,\n [right]: left\n};\n\n// Map of I18N property names to their LTR equivalent.\nvar PROPERTIES_I18N = {\n borderStartStartRadius: borderTopLeftRadius,\n borderStartEndRadius: borderTopRightRadius,\n borderEndStartRadius: borderBottomLeftRadius,\n borderEndEndRadius: borderBottomRightRadius,\n borderInlineStartColor: borderLeftColor,\n borderInlineStartStyle: borderLeftStyle,\n borderInlineStartWidth: borderLeftWidth,\n borderInlineEndColor: borderRightColor,\n borderInlineEndStyle: borderRightStyle,\n borderInlineEndWidth: borderRightWidth,\n insetInlineEnd: right,\n insetInlineStart: left,\n marginInlineStart: marginLeft,\n marginInlineEnd: marginRight,\n paddingInlineStart: paddingLeft,\n paddingInlineEnd: paddingRight\n};\nvar PROPERTIES_VALUE = ['clear', 'float', 'textAlign'];\nexport function atomic(style) {\n var compiledStyle = {\n $$css: true\n };\n var compiledRules = [];\n function atomicCompile(srcProp, prop, value) {\n var valueString = stringifyValueWithProperty(value, prop);\n var cacheKey = prop + valueString;\n var cachedResult = cache.get(cacheKey);\n var identifier;\n if (cachedResult != null) {\n identifier = cachedResult[0];\n compiledRules.push(cachedResult[1]);\n } else {\n var v = srcProp !== prop ? cacheKey : valueString;\n identifier = createIdentifier('r', srcProp, v);\n var order = customGroup[srcProp] || atomicGroup;\n var rules = createAtomicRules(identifier, prop, value);\n var orderedRules = [rules, order];\n compiledRules.push(orderedRules);\n cache.set(cacheKey, [identifier, orderedRules]);\n }\n return identifier;\n }\n Object.keys(style).sort().forEach(srcProp => {\n var value = style[srcProp];\n if (value != null) {\n var localizeableValue;\n // BiDi flip values\n if (PROPERTIES_VALUE.indexOf(srcProp) > -1) {\n var _left = atomicCompile(srcProp, srcProp, 'left');\n var _right = atomicCompile(srcProp, srcProp, 'right');\n if (value === 'start') {\n localizeableValue = [_left, _right];\n } else if (value === 'end') {\n localizeableValue = [_right, _left];\n }\n }\n // BiDi flip properties\n var propPolyfill = PROPERTIES_I18N[srcProp];\n if (propPolyfill != null) {\n var ltr = atomicCompile(srcProp, propPolyfill, value);\n var rtl = atomicCompile(srcProp, PROPERTIES_FLIP[propPolyfill], value);\n localizeableValue = [ltr, rtl];\n }\n // BiDi flip transitionProperty value\n if (srcProp === 'transitionProperty') {\n var values = Array.isArray(value) ? value : [value];\n var polyfillIndices = [];\n for (var i = 0; i < values.length; i++) {\n var val = values[i];\n if (typeof val === 'string' && PROPERTIES_I18N[val] != null) {\n polyfillIndices.push(i);\n }\n }\n if (polyfillIndices.length > 0) {\n var ltrPolyfillValues = [...values];\n var rtlPolyfillValues = [...values];\n polyfillIndices.forEach(i => {\n var ltrVal = ltrPolyfillValues[i];\n if (typeof ltrVal === 'string') {\n var ltrPolyfill = PROPERTIES_I18N[ltrVal];\n var rtlPolyfill = PROPERTIES_FLIP[ltrPolyfill];\n ltrPolyfillValues[i] = ltrPolyfill;\n rtlPolyfillValues[i] = rtlPolyfill;\n var _ltr = atomicCompile(srcProp, srcProp, ltrPolyfillValues);\n var _rtl = atomicCompile(srcProp, srcProp, rtlPolyfillValues);\n localizeableValue = [_ltr, _rtl];\n }\n });\n }\n }\n if (localizeableValue == null) {\n localizeableValue = atomicCompile(srcProp, srcProp, value);\n } else {\n compiledStyle['$$css$localize'] = true;\n }\n compiledStyle[srcProp] = localizeableValue;\n }\n });\n return [compiledStyle, compiledRules];\n}\n\n/**\n * Compile simple style object to classic CSS rules.\n * No support for 'placeholderTextColor', 'scrollbarWidth', or 'pointerEvents'.\n */\nexport function classic(style, name) {\n var compiledStyle = {\n $$css: true\n };\n var compiledRules = [];\n var animationKeyframes = style.animationKeyframes,\n rest = _objectWithoutPropertiesLoose(style, _excluded);\n var identifier = createIdentifier('css', name, JSON.stringify(style));\n var selector = \".\" + identifier;\n var animationName;\n if (animationKeyframes != null) {\n var _processKeyframesValu = processKeyframesValue(animationKeyframes),\n animationNames = _processKeyframesValu[0],\n keyframesRules = _processKeyframesValu[1];\n animationName = animationNames.join(',');\n compiledRules.push(...keyframesRules);\n }\n var block = createDeclarationBlock(_objectSpread(_objectSpread({}, rest), {}, {\n animationName\n }));\n compiledRules.push(\"\" + selector + block);\n compiledStyle[identifier] = identifier;\n return [compiledStyle, [[compiledRules, classicGroup]]];\n}\n\n/**\n * Compile simple style object to inline DOM styles.\n * No support for 'animationKeyframes', 'placeholderTextColor', 'scrollbarWidth', or 'pointerEvents'.\n */\nexport function inline(originalStyle, isRTL) {\n var style = originalStyle || emptyObject;\n var frozenProps = {};\n var nextStyle = {};\n var _loop = function _loop() {\n var originalValue = style[originalProp];\n var prop = originalProp;\n var value = originalValue;\n if (!Object.prototype.hasOwnProperty.call(style, originalProp) || originalValue == null) {\n return \"continue\";\n }\n\n // BiDi flip values\n if (PROPERTIES_VALUE.indexOf(originalProp) > -1) {\n if (originalValue === 'start') {\n value = isRTL ? 'right' : 'left';\n } else if (originalValue === 'end') {\n value = isRTL ? 'left' : 'right';\n }\n }\n // BiDi flip properties\n var propPolyfill = PROPERTIES_I18N[originalProp];\n if (propPolyfill != null) {\n prop = isRTL ? PROPERTIES_FLIP[propPolyfill] : propPolyfill;\n }\n // BiDi flip transitionProperty value\n if (originalProp === 'transitionProperty') {\n // $FlowFixMe\n var originalValues = Array.isArray(originalValue) ? originalValue : [originalValue];\n originalValues.forEach((val, i) => {\n if (typeof val === 'string') {\n var valuePolyfill = PROPERTIES_I18N[val];\n if (valuePolyfill != null) {\n originalValues[i] = isRTL ? PROPERTIES_FLIP[valuePolyfill] : valuePolyfill;\n value = originalValues.join(' ');\n }\n }\n });\n }\n\n // Create finalized style\n if (!frozenProps[prop]) {\n nextStyle[prop] = value;\n }\n if (prop === originalProp) {\n frozenProps[prop] = true;\n }\n\n // if (PROPERTIES_I18N.hasOwnProperty(originalProp)) {\n // frozenProps[prop] = true;\n //}\n };\n for (var originalProp in style) {\n var _ret = _loop();\n if (_ret === \"continue\") continue;\n }\n return createReactDOMStyle(nextStyle, true);\n}\n\n/**\n * Create a value string that normalizes different input values with a common\n * output.\n */\nexport function stringifyValueWithProperty(value, property) {\n // e.g., 0 => '0px', 'black' => 'rgba(0,0,0,1)'\n var normalizedValue = normalizeValueWithProperty(value, property);\n return typeof normalizedValue !== 'string' ? JSON.stringify(normalizedValue || '') : normalizedValue;\n}\n\n/**\n * Create the Atomic CSS rules needed for a given StyleSheet rule.\n * Translates StyleSheet declarations to CSS.\n */\nfunction createAtomicRules(identifier, property, value) {\n var rules = [];\n var selector = \".\" + identifier;\n\n // Handle non-standard properties and object values that require multiple\n // CSS rules to be created.\n switch (property) {\n case 'animationKeyframes':\n {\n var _processKeyframesValu2 = processKeyframesValue(value),\n animationNames = _processKeyframesValu2[0],\n keyframesRules = _processKeyframesValu2[1];\n var block = createDeclarationBlock({\n animationName: animationNames.join(',')\n });\n rules.push(\"\" + selector + block, ...keyframesRules);\n break;\n }\n\n // Equivalent to using '::placeholder'\n case 'placeholderTextColor':\n {\n var _block = createDeclarationBlock({\n color: value,\n opacity: 1\n });\n rules.push(selector + \"::-webkit-input-placeholder\" + _block, selector + \"::-moz-placeholder\" + _block, selector + \":-ms-input-placeholder\" + _block, selector + \"::placeholder\" + _block);\n break;\n }\n\n // Polyfill for additional 'pointer-events' values\n // See d13f78622b233a0afc0c7a200c0a0792c8ca9e58\n // See https://reactnative.dev/docs/view#pointerevents\n case 'pointerEvents':\n {\n var finalValue = value;\n if (value === 'auto') {\n finalValue = 'auto!important';\n } else if (value === 'none') {\n finalValue = 'none!important';\n var _block2 = createDeclarationBlock({\n pointerEvents: 'none'\n });\n rules.push(selector + \">* \" + _block2);\n } else if (value === 'box-none') {\n finalValue = 'none!important';\n var _block3 = createDeclarationBlock({\n pointerEvents: 'auto'\n });\n rules.push(selector + \">* \" + _block3);\n } else if (value === 'box-only') {\n finalValue = 'auto!important';\n var _block4 = createDeclarationBlock({\n pointerEvents: 'none'\n });\n rules.push(selector + \">* \" + _block4);\n }\n var _block5 = createDeclarationBlock({\n pointerEvents: finalValue\n });\n rules.push(\"\" + selector + _block5);\n break;\n }\n\n // Polyfill for draft spec\n // https://drafts.csswg.org/css-scrollbars-1/\n case 'scrollbarWidth':\n {\n if (value === 'none') {\n rules.push(selector + \"::-webkit-scrollbar{display:none}\");\n }\n var _block6 = createDeclarationBlock({\n scrollbarWidth: value\n });\n rules.push(\"\" + selector + _block6);\n break;\n }\n default:\n {\n var _block7 = createDeclarationBlock({\n [property]: value\n });\n rules.push(\"\" + selector + _block7);\n break;\n }\n }\n return rules;\n}\n\n/**\n * Creates a CSS declaration block from a StyleSheet object.\n */\nfunction createDeclarationBlock(style) {\n var domStyle = prefixStyles(createReactDOMStyle(style));\n var declarationsString = Object.keys(domStyle).map(property => {\n var value = domStyle[property];\n var prop = hyphenateStyleName(property);\n // The prefixer may return an array of values:\n // { display: [ '-webkit-flex', 'flex' ] }\n // to represent \"fallback\" declarations\n // { display: -webkit-flex; display: flex; }\n if (Array.isArray(value)) {\n return value.map(v => prop + \":\" + v).join(';');\n } else {\n return prop + \":\" + value;\n }\n })\n // Once properties are hyphenated, this will put the vendor\n // prefixed and short-form properties first in the list.\n .sort().join(';');\n return \"{\" + declarationsString + \";}\";\n}\n\n/**\n * An identifier is associated with a unique set of styles.\n */\nfunction createIdentifier(prefix, name, key) {\n var hashedString = hash(name + key);\n return process.env.NODE_ENV !== 'production' ? prefix + \"-\" + name + \"-\" + hashedString : prefix + \"-\" + hashedString;\n}\n\n/**\n * Create individual CSS keyframes rules.\n */\nfunction createKeyframes(keyframes) {\n var prefixes = ['-webkit-', ''];\n var identifier = createIdentifier('r', 'animation', JSON.stringify(keyframes));\n var steps = '{' + Object.keys(keyframes).map(stepName => {\n var rule = keyframes[stepName];\n var block = createDeclarationBlock(rule);\n return \"\" + stepName + block;\n }).join('') + '}';\n var rules = prefixes.map(prefix => {\n return \"@\" + prefix + \"keyframes \" + identifier + steps;\n });\n return [identifier, rules];\n}\n\n/**\n * Create CSS keyframes rules and names from a StyleSheet keyframes object.\n */\nfunction processKeyframesValue(keyframesValue) {\n if (typeof keyframesValue === 'number') {\n throw new Error(\"Invalid CSS keyframes type: \" + typeof keyframesValue);\n }\n var animationNames = [];\n var rules = [];\n var value = Array.isArray(keyframesValue) ? keyframesValue : [keyframesValue];\n value.forEach(keyframes => {\n if (typeof keyframes === 'string') {\n // Support external animation libraries (identifiers only)\n animationNames.push(keyframes);\n } else {\n // Create rules for each of the keyframes\n var _createKeyframes = createKeyframes(keyframes),\n identifier = _createKeyframes[0],\n keyframesRules = _createKeyframes[1];\n animationNames.push(identifier);\n rules.push(...keyframesRules);\n }\n });\n return [animationNames, rules];\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\nimport canUseDOM from '../../../modules/canUseDom';\n\n// $FlowFixMe: HTMLStyleElement is incorrectly typed - https://github.com/facebook/flow/issues/2696\nexport default function createCSSStyleSheet(id, rootNode, textContent) {\n if (canUseDOM) {\n var root = rootNode != null ? rootNode : document;\n var element = root.getElementById(id);\n if (element == null) {\n element = document.createElement('style');\n element.setAttribute('id', id);\n if (typeof textContent === 'string') {\n element.appendChild(document.createTextNode(textContent));\n }\n if (root instanceof ShadowRoot) {\n root.insertBefore(element, root.firstChild);\n } else {\n var head = root.head;\n if (head) {\n head.insertBefore(element, head.firstChild);\n }\n }\n }\n // $FlowFixMe: HTMLElement is incorrectly typed\n return element.sheet;\n } else {\n return null;\n }\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar slice = Array.prototype.slice;\n\n/**\n * Order-based insertion of CSS.\n *\n * Each rule is associated with a numerically defined group.\n * Groups are ordered within the style sheet according to their number, with the\n * lowest first.\n *\n * Groups are implemented using marker rules. The selector of the first rule of\n * each group is used only to encode the group number for hydration. An\n * alternative implementation could rely on CSSMediaRule, allowing groups to be\n * treated as a sub-sheet, but the Edge implementation of CSSMediaRule is\n * broken.\n * https://developer.mozilla.org/en-US/docs/Web/API/CSSMediaRule\n * https://gist.github.com/necolas/aa0c37846ad6bd3b05b727b959e82674\n */\nexport default function createOrderedCSSStyleSheet(sheet) {\n var groups = {};\n var selectors = {};\n\n /**\n * Hydrate approximate record from any existing rules in the sheet.\n */\n if (sheet != null) {\n var group;\n slice.call(sheet.cssRules).forEach((cssRule, i) => {\n var cssText = cssRule.cssText;\n // Create record of existing selectors and rules\n if (cssText.indexOf('stylesheet-group') > -1) {\n group = decodeGroupRule(cssRule);\n groups[group] = {\n start: i,\n rules: [cssText]\n };\n } else {\n var selectorText = getSelectorText(cssText);\n if (selectorText != null) {\n selectors[selectorText] = true;\n groups[group].rules.push(cssText);\n }\n }\n });\n }\n function sheetInsert(sheet, group, text) {\n var orderedGroups = getOrderedGroups(groups);\n var groupIndex = orderedGroups.indexOf(group);\n var nextGroupIndex = groupIndex + 1;\n var nextGroup = orderedGroups[nextGroupIndex];\n // Insert rule before the next group, or at the end of the stylesheet\n var position = nextGroup != null && groups[nextGroup].start != null ? groups[nextGroup].start : sheet.cssRules.length;\n var isInserted = insertRuleAt(sheet, text, position);\n if (isInserted) {\n // Set the starting index of the new group\n if (groups[group].start == null) {\n groups[group].start = position;\n }\n // Increment the starting index of all subsequent groups\n for (var i = nextGroupIndex; i < orderedGroups.length; i += 1) {\n var groupNumber = orderedGroups[i];\n var previousStart = groups[groupNumber].start || 0;\n groups[groupNumber].start = previousStart + 1;\n }\n }\n return isInserted;\n }\n var OrderedCSSStyleSheet = {\n /**\n * The textContent of the style sheet.\n */\n getTextContent() {\n return getOrderedGroups(groups).map(group => {\n var rules = groups[group].rules;\n // Sorting provides deterministic order of styles in group for\n // build-time extraction of the style sheet.\n var marker = rules.shift();\n rules.sort();\n rules.unshift(marker);\n return rules.join('\\n');\n }).join('\\n');\n },\n /**\n * Insert a rule into the style sheet\n */\n insert(cssText, groupValue) {\n var group = Number(groupValue);\n\n // Create a new group.\n if (groups[group] == null) {\n var markerRule = encodeGroupRule(group);\n // Create the internal record.\n groups[group] = {\n start: null,\n rules: [markerRule]\n };\n // Update CSSOM.\n if (sheet != null) {\n sheetInsert(sheet, group, markerRule);\n }\n }\n\n // selectorText is more reliable than cssText for insertion checks. The\n // browser excludes vendor-prefixed properties and rewrites certain values\n // making cssText more likely to be different from what was inserted.\n var selectorText = getSelectorText(cssText);\n if (selectorText != null && selectors[selectorText] == null) {\n // Update the internal records.\n selectors[selectorText] = true;\n groups[group].rules.push(cssText);\n // Update CSSOM.\n if (sheet != null) {\n var isInserted = sheetInsert(sheet, group, cssText);\n if (!isInserted) {\n // Revert internal record change if a rule was rejected (e.g.,\n // unrecognized pseudo-selector)\n groups[group].rules.pop();\n }\n }\n }\n }\n };\n return OrderedCSSStyleSheet;\n}\n\n/**\n * Helper functions\n */\n\nfunction encodeGroupRule(group) {\n return \"[stylesheet-group=\\\"\" + group + \"\\\"]{}\";\n}\nvar groupPattern = /[\"']/g;\nfunction decodeGroupRule(cssRule) {\n return Number(cssRule.selectorText.split(groupPattern)[1]);\n}\nfunction getOrderedGroups(obj) {\n return Object.keys(obj).map(Number).sort((a, b) => a > b ? 1 : -1);\n}\nvar selectorPattern = /\\s*([,])\\s*/g;\nfunction getSelectorText(cssText) {\n var selector = cssText.split('{')[0].trim();\n return selector !== '' ? selector.replace(selectorPattern, '$1') : null;\n}\nfunction insertRuleAt(root, cssText, position) {\n try {\n // $FlowFixMe: Flow is missing CSSOM types needed to type 'root'.\n root.insertRule(cssText, position);\n return true;\n } catch (e) {\n // JSDOM doesn't support `CSSSMediaRule#insertRule`.\n // Also ignore errors that occur from attempting to insert vendor-prefixed selectors.\n return false;\n }\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport canUseDOM from '../../../modules/canUseDom';\nimport createCSSStyleSheet from './createCSSStyleSheet';\nimport createOrderedCSSStyleSheet from './createOrderedCSSStyleSheet';\nvar defaultId = 'react-native-stylesheet';\nvar roots = new WeakMap();\nvar sheets = [];\nvar initialRules = [\n// minimal top-level reset\n'html{-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:rgba(0,0,0,0);}', 'body{margin:0;}',\n// minimal form pseudo-element reset\n'button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0;}', 'input::-webkit-search-cancel-button,input::-webkit-search-decoration,input::-webkit-search-results-button,input::-webkit-search-results-decoration{display:none;}'];\nexport function createSheet(root, id) {\n if (id === void 0) {\n id = defaultId;\n }\n var sheet;\n if (canUseDOM) {\n var rootNode = root != null ? root.getRootNode() : document;\n // Create the initial style sheet\n if (sheets.length === 0) {\n sheet = createOrderedCSSStyleSheet(createCSSStyleSheet(id));\n initialRules.forEach(rule => {\n sheet.insert(rule, 0);\n });\n roots.set(rootNode, sheets.length);\n sheets.push(sheet);\n } else {\n var index = roots.get(rootNode);\n if (index == null) {\n var initialSheet = sheets[0];\n // If we're creating a new sheet, populate it with existing styles\n var textContent = initialSheet != null ? initialSheet.getTextContent() : '';\n // Cast rootNode to 'any' because Flow types for getRootNode are wrong\n sheet = createOrderedCSSStyleSheet(createCSSStyleSheet(id, rootNode, textContent));\n roots.set(rootNode, sheets.length);\n sheets.push(sheet);\n } else {\n sheet = sheets[index];\n }\n }\n } else {\n // Create the initial style sheet\n if (sheets.length === 0) {\n sheet = createOrderedCSSStyleSheet(createCSSStyleSheet(id));\n initialRules.forEach(rule => {\n sheet.insert(rule, 0);\n });\n sheets.push(sheet);\n } else {\n sheet = sheets[0];\n }\n }\n return {\n getTextContent() {\n return sheet.getTextContent();\n },\n id,\n insert(cssText, groupValue) {\n sheets.forEach(s => {\n s.insert(cssText, groupValue);\n });\n }\n };\n}","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.localizeStyle = localizeStyle;\nvar cache = new WeakMap();\nvar markerProp = '$$css$localize';\n/**\n * The compiler polyfills logical properties and values, generating a class\n * name for both writing directions. The style objects are annotated by\n * the compiler as needing this runtime transform. The results are memoized.\n *\n * { '$$css$localize': true, float: [ 'float-left', 'float-right' ] }\n * => { float: 'float-left' }\n */\n\nfunction compileStyle(style, isRTL) {\n // Create a new compiled style for styleq\n var compiledStyle = {};\n\n for (var prop in style) {\n if (prop !== markerProp) {\n var value = style[prop];\n\n if (Array.isArray(value)) {\n compiledStyle[prop] = isRTL ? value[1] : value[0];\n } else {\n compiledStyle[prop] = value;\n }\n }\n }\n\n return compiledStyle;\n}\n\nfunction localizeStyle(style, isRTL) {\n if (style[markerProp] != null) {\n var compiledStyleIndex = isRTL ? 1 : 0; // Check the cache in case we've already seen this object\n\n if (cache.has(style)) {\n var _cachedStyles = cache.get(style);\n\n var _compiledStyle = _cachedStyles[compiledStyleIndex];\n\n if (_compiledStyle == null) {\n // Update the missing cache entry\n _compiledStyle = compileStyle(style, isRTL);\n _cachedStyles[compiledStyleIndex] = _compiledStyle;\n cache.set(style, _cachedStyles);\n }\n\n return _compiledStyle;\n } // Create a new compiled style for styleq\n\n\n var compiledStyle = compileStyle(style, isRTL);\n var cachedStyles = new Array(2);\n cachedStyles[compiledStyleIndex] = compiledStyle;\n cache.set(style, cachedStyles);\n return compiledStyle;\n }\n\n return style;\n}","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nmodule.exports = require('./dist/transform-localize-style');\n","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar warnedKeys = {};\n\n/**\n * A simple function that prints a warning message once per session.\n *\n * @param {string} key - The key used to ensure the message is printed once.\n * This should be unique to the callsite.\n * @param {string} message - The message to print\n */\nexport function warnOnce(key, message) {\n if (process.env.NODE_ENV !== 'production') {\n if (warnedKeys[key]) {\n return;\n }\n console.warn(message);\n warnedKeys[key] = true;\n }\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport normalizeColor from './compiler/normalizeColor';\nimport normalizeValueWithProperty from './compiler/normalizeValueWithProperty';\nimport { warnOnce } from '../../modules/warnOnce';\nvar emptyObject = {};\n\n/**\n * Shadows\n */\n\nvar defaultOffset = {\n height: 0,\n width: 0\n};\nexport var createBoxShadowValue = style => {\n var shadowColor = style.shadowColor,\n shadowOffset = style.shadowOffset,\n shadowOpacity = style.shadowOpacity,\n shadowRadius = style.shadowRadius;\n var _ref = shadowOffset || defaultOffset,\n height = _ref.height,\n width = _ref.width;\n var offsetX = normalizeValueWithProperty(width);\n var offsetY = normalizeValueWithProperty(height);\n var blurRadius = normalizeValueWithProperty(shadowRadius || 0);\n var color = normalizeColor(shadowColor || 'black', shadowOpacity);\n if (color != null && offsetX != null && offsetY != null && blurRadius != null) {\n return offsetX + \" \" + offsetY + \" \" + blurRadius + \" \" + color;\n }\n};\nexport var createTextShadowValue = style => {\n var textShadowColor = style.textShadowColor,\n textShadowOffset = style.textShadowOffset,\n textShadowRadius = style.textShadowRadius;\n var _ref2 = textShadowOffset || defaultOffset,\n height = _ref2.height,\n width = _ref2.width;\n var radius = textShadowRadius || 0;\n var offsetX = normalizeValueWithProperty(width);\n var offsetY = normalizeValueWithProperty(height);\n var blurRadius = normalizeValueWithProperty(radius);\n var color = normalizeValueWithProperty(textShadowColor, 'textShadowColor');\n if (color && (height !== 0 || width !== 0 || radius !== 0) && offsetX != null && offsetY != null && blurRadius != null) {\n return offsetX + \" \" + offsetY + \" \" + blurRadius + \" \" + color;\n }\n};\n\n// { offsetX: 1, offsetY: 2, blurRadius: 3, spreadDistance: 4, color: 'rgba(255, 0, 0)', inset: true }\n// => 'rgba(255, 0, 0) 1px 2px 3px 4px inset'\nvar mapBoxShadow = boxShadow => {\n if (typeof boxShadow === 'string') {\n return boxShadow;\n }\n var offsetX = normalizeValueWithProperty(boxShadow.offsetX) || 0;\n var offsetY = normalizeValueWithProperty(boxShadow.offsetY) || 0;\n var blurRadius = normalizeValueWithProperty(boxShadow.blurRadius) || 0;\n var spreadDistance = normalizeValueWithProperty(boxShadow.spreadDistance) || 0;\n var color = normalizeColor(boxShadow.color) || 'black';\n var position = boxShadow.inset ? 'inset ' : '';\n return \"\" + position + offsetX + \" \" + offsetY + \" \" + blurRadius + \" \" + spreadDistance + \" \" + color;\n};\nexport var createBoxShadowArrayValue = value => {\n return value.map(mapBoxShadow).join(', ');\n};\n\n// { scale: 2 } => 'scale(2)'\n// { translateX: 20 } => 'translateX(20px)'\n// { matrix: [1,2,3,4,5,6] } => 'matrix(1,2,3,4,5,6)'\nvar mapTransform = transform => {\n var type = Object.keys(transform)[0];\n var value = transform[type];\n if (type === 'matrix' || type === 'matrix3d') {\n return type + \"(\" + value.join(',') + \")\";\n } else {\n var normalizedValue = normalizeValueWithProperty(value, type);\n return type + \"(\" + normalizedValue + \")\";\n }\n};\nexport var createTransformValue = value => {\n return value.map(mapTransform).join(' ');\n};\n\n// [2, '30%', 10] => '2px 30% 10px'\nexport var createTransformOriginValue = value => {\n return value.map(v => normalizeValueWithProperty(v)).join(' ');\n};\nvar PROPERTIES_STANDARD = {\n borderBottomEndRadius: 'borderEndEndRadius',\n borderBottomStartRadius: 'borderEndStartRadius',\n borderTopEndRadius: 'borderStartEndRadius',\n borderTopStartRadius: 'borderStartStartRadius',\n borderEndColor: 'borderInlineEndColor',\n borderEndStyle: 'borderInlineEndStyle',\n borderEndWidth: 'borderInlineEndWidth',\n borderStartColor: 'borderInlineStartColor',\n borderStartStyle: 'borderInlineStartStyle',\n borderStartWidth: 'borderInlineStartWidth',\n end: 'insetInlineEnd',\n marginEnd: 'marginInlineEnd',\n marginHorizontal: 'marginInline',\n marginStart: 'marginInlineStart',\n marginVertical: 'marginBlock',\n paddingEnd: 'paddingInlineEnd',\n paddingHorizontal: 'paddingInline',\n paddingStart: 'paddingInlineStart',\n paddingVertical: 'paddingBlock',\n start: 'insetInlineStart'\n};\nvar ignoredProps = {\n elevation: true,\n overlayColor: true,\n resizeMode: true,\n tintColor: true\n};\n\n/**\n * Preprocess styles\n */\nexport var preprocess = function preprocess(originalStyle, options) {\n if (options === void 0) {\n options = {};\n }\n var style = originalStyle || emptyObject;\n var nextStyle = {};\n\n // Convert shadow styles\n if (options.shadow === true, style.shadowColor != null || style.shadowOffset != null || style.shadowOpacity != null || style.shadowRadius != null) {\n warnOnce('shadowStyles', \"\\\"shadow*\\\" style props are deprecated. Use \\\"boxShadow\\\".\");\n var boxShadowValue = createBoxShadowValue(style);\n if (boxShadowValue != null) {\n nextStyle.boxShadow = boxShadowValue;\n }\n }\n\n // Convert text shadow styles\n if (options.textShadow === true, style.textShadowColor != null || style.textShadowOffset != null || style.textShadowRadius != null) {\n warnOnce('textShadowStyles', \"\\\"textShadow*\\\" style props are deprecated. Use \\\"textShadow\\\".\");\n var textShadowValue = createTextShadowValue(style);\n if (textShadowValue != null && nextStyle.textShadow == null) {\n var textShadow = style.textShadow;\n var value = textShadow ? textShadow + \", \" + textShadowValue : textShadowValue;\n nextStyle.textShadow = value;\n }\n }\n for (var originalProp in style) {\n if (\n // Ignore some React Native styles\n ignoredProps[originalProp] != null || originalProp === 'shadowColor' || originalProp === 'shadowOffset' || originalProp === 'shadowOpacity' || originalProp === 'shadowRadius' || originalProp === 'textShadowColor' || originalProp === 'textShadowOffset' || originalProp === 'textShadowRadius') {\n continue;\n }\n var originalValue = style[originalProp];\n var prop = PROPERTIES_STANDARD[originalProp] || originalProp;\n var _value = originalValue;\n if (!Object.prototype.hasOwnProperty.call(style, originalProp) || prop !== originalProp && style[prop] != null) {\n continue;\n }\n if (prop === 'aspectRatio' && typeof _value === 'number') {\n nextStyle[prop] = _value.toString();\n } else if (prop === 'boxShadow') {\n if (Array.isArray(_value)) {\n _value = createBoxShadowArrayValue(_value);\n }\n var boxShadow = nextStyle.boxShadow;\n nextStyle.boxShadow = boxShadow ? _value + \", \" + boxShadow : _value;\n } else if (prop === 'fontVariant') {\n if (Array.isArray(_value) && _value.length > 0) {\n /*\n warnOnce(\n 'fontVariant',\n '\"fontVariant\" style array value is deprecated. Use space-separated values.'\n );\n */\n _value = _value.join(' ');\n }\n nextStyle[prop] = _value;\n } else if (prop === 'textAlignVertical') {\n /*\n warnOnce(\n 'textAlignVertical',\n '\"textAlignVertical\" style is deprecated. Use \"verticalAlign\".'\n );\n */\n if (style.verticalAlign == null) {\n nextStyle.verticalAlign = _value === 'center' ? 'middle' : _value;\n }\n } else if (prop === 'transform') {\n if (Array.isArray(_value)) {\n _value = createTransformValue(_value);\n }\n nextStyle.transform = _value;\n } else if (prop === 'transformOrigin') {\n if (Array.isArray(_value)) {\n _value = createTransformOriginValue(_value);\n }\n nextStyle.transformOrigin = _value;\n } else {\n nextStyle[prop] = _value;\n }\n }\n\n // $FlowIgnore\n return nextStyle;\n};\nexport default preprocess;","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.styleq = void 0;\nvar cache = new WeakMap();\nvar compiledKey = '$$css';\n\nfunction createStyleq(options) {\n var disableCache;\n var disableMix;\n var transform;\n\n if (options != null) {\n disableCache = options.disableCache === true;\n disableMix = options.disableMix === true;\n transform = options.transform;\n }\n\n return function styleq() {\n // Keep track of property commits to the className\n var definedProperties = []; // The className and inline style to build up\n\n var className = '';\n var inlineStyle = null; // The current position in the cache graph\n\n var nextCache = disableCache ? null : cache; // This way of creating an array from arguments is fastest\n\n var styles = new Array(arguments.length);\n\n for (var i = 0; i < arguments.length; i++) {\n styles[i] = arguments[i];\n } // Iterate over styles from last to first\n\n\n while (styles.length > 0) {\n var possibleStyle = styles.pop(); // Skip empty items\n\n if (possibleStyle == null || possibleStyle === false) {\n continue;\n } // Push nested styles back onto the stack to be processed\n\n\n if (Array.isArray(possibleStyle)) {\n for (var _i = 0; _i < possibleStyle.length; _i++) {\n styles.push(possibleStyle[_i]);\n }\n\n continue;\n } // Process an individual style object\n\n\n var style = transform != null ? transform(possibleStyle) : possibleStyle;\n\n if (style.$$css) {\n // Build up the class names defined by this object\n var classNameChunk = ''; // Check the cache to see if we've already done this work\n\n if (nextCache != null && nextCache.has(style)) {\n // Cache: read\n var cacheEntry = nextCache.get(style);\n\n if (cacheEntry != null) {\n classNameChunk = cacheEntry[0]; // $FlowIgnore\n\n definedProperties.push.apply(definedProperties, cacheEntry[1]);\n nextCache = cacheEntry[2];\n }\n } // Update the chunks with data from this object\n else {\n // The properties defined by this object\n var definedPropertiesChunk = [];\n\n for (var prop in style) {\n var value = style[prop];\n if (prop === compiledKey) continue; // Each property value is used as an HTML class name\n // { 'debug.string': 'debug.string', opacity: 's-jskmnoqp' }\n\n if (typeof value === 'string' || value === null) {\n // Only add to chunks if this property hasn't already been seen\n if (!definedProperties.includes(prop)) {\n definedProperties.push(prop);\n\n if (nextCache != null) {\n definedPropertiesChunk.push(prop);\n }\n\n if (typeof value === 'string') {\n classNameChunk += classNameChunk ? ' ' + value : value;\n }\n }\n } // If we encounter a value that isn't a string or `null`\n else {\n console.error(\"styleq: \".concat(prop, \" typeof \").concat(String(value), \" is not \\\"string\\\" or \\\"null\\\".\"));\n }\n } // Cache: write\n\n\n if (nextCache != null) {\n // Create the next WeakMap for this sequence of styles\n var weakMap = new WeakMap();\n nextCache.set(style, [classNameChunk, definedPropertiesChunk, weakMap]);\n nextCache = weakMap;\n }\n } // Order of classes in chunks matches property-iteration order of style\n // object. Order of chunks matches passed order of styles from first to\n // last (which we iterate over in reverse).\n\n\n if (classNameChunk) {\n className = className ? classNameChunk + ' ' + className : classNameChunk;\n }\n } // ----- DYNAMIC: Process inline style object -----\n else {\n if (disableMix) {\n if (inlineStyle == null) {\n inlineStyle = {};\n }\n\n inlineStyle = Object.assign({}, style, inlineStyle);\n } else {\n var subStyle = null;\n\n for (var _prop in style) {\n var _value = style[_prop];\n\n if (_value !== undefined) {\n if (!definedProperties.includes(_prop)) {\n if (_value != null) {\n if (inlineStyle == null) {\n inlineStyle = {};\n }\n\n if (subStyle == null) {\n subStyle = {};\n }\n\n subStyle[_prop] = _value;\n }\n\n definedProperties.push(_prop); // Cache is unnecessary overhead if results can't be reused.\n\n nextCache = null;\n }\n }\n }\n\n if (subStyle != null) {\n inlineStyle = Object.assign(subStyle, inlineStyle);\n }\n }\n }\n }\n\n var styleProps = [className, inlineStyle];\n return styleProps;\n };\n}\n\nvar styleq = createStyleq();\nexports.styleq = styleq;\nstyleq.factory = createStyleq;","import _objectSpread from \"@babel/runtime/helpers/objectSpread2\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nvar _excluded = [\"writingDirection\"];\n/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport { atomic, classic, inline } from './compiler';\nimport { createSheet } from './dom';\nimport { localizeStyle } from 'styleq/transform-localize-style';\nimport { preprocess } from './preprocess';\nimport { styleq } from 'styleq';\nimport { validate } from './validate';\nimport canUseDOM from '../../modules/canUseDom';\nvar staticStyleMap = new WeakMap();\nvar sheet = createSheet();\nvar defaultPreprocessOptions = {\n shadow: true,\n textShadow: true\n};\nfunction customStyleq(styles, options) {\n if (options === void 0) {\n options = {};\n }\n var _options = options,\n writingDirection = _options.writingDirection,\n preprocessOptions = _objectWithoutPropertiesLoose(_options, _excluded);\n var isRTL = writingDirection === 'rtl';\n return styleq.factory({\n transform(style) {\n var compiledStyle = staticStyleMap.get(style);\n if (compiledStyle != null) {\n return localizeStyle(compiledStyle, isRTL);\n }\n return preprocess(style, _objectSpread(_objectSpread({}, defaultPreprocessOptions), preprocessOptions));\n }\n })(styles);\n}\nfunction insertRules(compiledOrderedRules) {\n compiledOrderedRules.forEach(_ref => {\n var rules = _ref[0],\n order = _ref[1];\n if (sheet != null) {\n rules.forEach(rule => {\n sheet.insert(rule, order);\n });\n }\n });\n}\nfunction compileAndInsertAtomic(style) {\n var _atomic = atomic(preprocess(style, defaultPreprocessOptions)),\n compiledStyle = _atomic[0],\n compiledOrderedRules = _atomic[1];\n insertRules(compiledOrderedRules);\n return compiledStyle;\n}\nfunction compileAndInsertReset(style, key) {\n var _classic = classic(style, key),\n compiledStyle = _classic[0],\n compiledOrderedRules = _classic[1];\n insertRules(compiledOrderedRules);\n return compiledStyle;\n}\n\n/* ----- API ----- */\n\nvar absoluteFillObject = {\n position: 'absolute',\n left: 0,\n right: 0,\n top: 0,\n bottom: 0\n};\nvar absoluteFill = create({\n x: _objectSpread({}, absoluteFillObject)\n}).x;\n\n/**\n * create\n */\nfunction create(styles) {\n Object.keys(styles).forEach(key => {\n var styleObj = styles[key];\n // Only compile at runtime if the style is not already compiled\n if (styleObj != null && styleObj.$$css !== true) {\n var compiledStyles;\n if (key.indexOf('$raw') > -1) {\n compiledStyles = compileAndInsertReset(styleObj, key.split('$raw')[0]);\n } else {\n if (process.env.NODE_ENV !== 'production') {\n validate(styleObj);\n styles[key] = Object.freeze(styleObj);\n }\n compiledStyles = compileAndInsertAtomic(styleObj);\n }\n staticStyleMap.set(styleObj, compiledStyles);\n }\n });\n return styles;\n}\n\n/**\n * compose\n */\nfunction compose(style1, style2) {\n if (process.env.NODE_ENV !== 'production') {\n /* eslint-disable prefer-rest-params */\n var len = arguments.length;\n if (len > 2) {\n var readableStyles = [...arguments].map(a => flatten(a));\n throw new Error(\"StyleSheet.compose() only accepts 2 arguments, received \" + len + \": \" + JSON.stringify(readableStyles));\n }\n /* eslint-enable prefer-rest-params */\n /*\n console.warn(\n 'StyleSheet.compose(a, b) is deprecated; use array syntax, i.e., [a,b].'\n );\n */\n }\n return [style1, style2];\n}\n\n/**\n * flatten\n */\nfunction flatten() {\n for (var _len = arguments.length, styles = new Array(_len), _key = 0; _key < _len; _key++) {\n styles[_key] = arguments[_key];\n }\n var flatArray = styles.flat(Infinity);\n var result = {};\n for (var i = 0; i < flatArray.length; i++) {\n var style = flatArray[i];\n if (style != null && typeof style === 'object') {\n // $FlowFixMe\n Object.assign(result, style);\n }\n }\n return result;\n}\n\n/**\n * getSheet\n */\nfunction getSheet() {\n return {\n id: sheet.id,\n textContent: sheet.getTextContent()\n };\n}\n\n/**\n * resolve\n */\n\nfunction StyleSheet(styles, options) {\n if (options === void 0) {\n options = {};\n }\n var isRTL = options.writingDirection === 'rtl';\n var styleProps = customStyleq(styles, options);\n if (Array.isArray(styleProps) && styleProps[1] != null) {\n styleProps[1] = inline(styleProps[1], isRTL);\n }\n return styleProps;\n}\nStyleSheet.absoluteFill = absoluteFill;\nStyleSheet.absoluteFillObject = absoluteFillObject;\nStyleSheet.create = create;\nStyleSheet.compose = compose;\nStyleSheet.flatten = flatten;\nStyleSheet.getSheet = getSheet;\n// `hairlineWidth` is not implemented using screen density as browsers may\n// round sub-pixel values down to `0`, causing the line not to be rendered.\nStyleSheet.hairlineWidth = 1;\nif (canUseDOM && window.__REACT_DEVTOOLS_GLOBAL_HOOK__) {\n window.__REACT_DEVTOOLS_GLOBAL_HOOK__.resolveRNStyle = StyleSheet.flatten;\n}\nvar stylesheet = StyleSheet;\nexport default stylesheet;","import _objectSpread from \"@babel/runtime/helpers/objectSpread2\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nvar _excluded = [\"aria-activedescendant\", \"accessibilityActiveDescendant\", \"aria-atomic\", \"accessibilityAtomic\", \"aria-autocomplete\", \"accessibilityAutoComplete\", \"aria-busy\", \"accessibilityBusy\", \"aria-checked\", \"accessibilityChecked\", \"aria-colcount\", \"accessibilityColumnCount\", \"aria-colindex\", \"accessibilityColumnIndex\", \"aria-colspan\", \"accessibilityColumnSpan\", \"aria-controls\", \"accessibilityControls\", \"aria-current\", \"accessibilityCurrent\", \"aria-describedby\", \"accessibilityDescribedBy\", \"aria-details\", \"accessibilityDetails\", \"aria-disabled\", \"accessibilityDisabled\", \"aria-errormessage\", \"accessibilityErrorMessage\", \"aria-expanded\", \"accessibilityExpanded\", \"aria-flowto\", \"accessibilityFlowTo\", \"aria-haspopup\", \"accessibilityHasPopup\", \"aria-hidden\", \"accessibilityHidden\", \"aria-invalid\", \"accessibilityInvalid\", \"aria-keyshortcuts\", \"accessibilityKeyShortcuts\", \"aria-label\", \"accessibilityLabel\", \"aria-labelledby\", \"accessibilityLabelledBy\", \"aria-level\", \"accessibilityLevel\", \"aria-live\", \"accessibilityLiveRegion\", \"aria-modal\", \"accessibilityModal\", \"aria-multiline\", \"accessibilityMultiline\", \"aria-multiselectable\", \"accessibilityMultiSelectable\", \"aria-orientation\", \"accessibilityOrientation\", \"aria-owns\", \"accessibilityOwns\", \"aria-placeholder\", \"accessibilityPlaceholder\", \"aria-posinset\", \"accessibilityPosInSet\", \"aria-pressed\", \"accessibilityPressed\", \"aria-readonly\", \"accessibilityReadOnly\", \"aria-required\", \"accessibilityRequired\", \"role\", \"accessibilityRole\", \"aria-roledescription\", \"accessibilityRoleDescription\", \"aria-rowcount\", \"accessibilityRowCount\", \"aria-rowindex\", \"accessibilityRowIndex\", \"aria-rowspan\", \"accessibilityRowSpan\", \"aria-selected\", \"accessibilitySelected\", \"aria-setsize\", \"accessibilitySetSize\", \"aria-sort\", \"accessibilitySort\", \"aria-valuemax\", \"accessibilityValueMax\", \"aria-valuemin\", \"accessibilityValueMin\", \"aria-valuenow\", \"accessibilityValueNow\", \"aria-valuetext\", \"accessibilityValueText\", \"dataSet\", \"focusable\", \"id\", \"nativeID\", \"pointerEvents\", \"style\", \"tabIndex\", \"testID\"];\n/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport AccessibilityUtil from '../AccessibilityUtil';\nimport StyleSheet from '../../exports/StyleSheet';\nimport { warnOnce } from '../warnOnce';\nvar emptyObject = {};\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar isArray = Array.isArray;\nvar uppercasePattern = /[A-Z]/g;\nfunction toHyphenLower(match) {\n return '-' + match.toLowerCase();\n}\nfunction hyphenateString(str) {\n return str.replace(uppercasePattern, toHyphenLower);\n}\nfunction processIDRefList(idRefList) {\n return isArray(idRefList) ? idRefList.join(' ') : idRefList;\n}\nvar pointerEventsStyles = StyleSheet.create({\n auto: {\n pointerEvents: 'auto'\n },\n 'box-none': {\n pointerEvents: 'box-none'\n },\n 'box-only': {\n pointerEvents: 'box-only'\n },\n none: {\n pointerEvents: 'none'\n }\n});\nvar createDOMProps = (elementType, props, options) => {\n if (!props) {\n props = emptyObject;\n }\n var _props = props,\n ariaActiveDescendant = _props['aria-activedescendant'],\n accessibilityActiveDescendant = _props.accessibilityActiveDescendant,\n ariaAtomic = _props['aria-atomic'],\n accessibilityAtomic = _props.accessibilityAtomic,\n ariaAutoComplete = _props['aria-autocomplete'],\n accessibilityAutoComplete = _props.accessibilityAutoComplete,\n ariaBusy = _props['aria-busy'],\n accessibilityBusy = _props.accessibilityBusy,\n ariaChecked = _props['aria-checked'],\n accessibilityChecked = _props.accessibilityChecked,\n ariaColumnCount = _props['aria-colcount'],\n accessibilityColumnCount = _props.accessibilityColumnCount,\n ariaColumnIndex = _props['aria-colindex'],\n accessibilityColumnIndex = _props.accessibilityColumnIndex,\n ariaColumnSpan = _props['aria-colspan'],\n accessibilityColumnSpan = _props.accessibilityColumnSpan,\n ariaControls = _props['aria-controls'],\n accessibilityControls = _props.accessibilityControls,\n ariaCurrent = _props['aria-current'],\n accessibilityCurrent = _props.accessibilityCurrent,\n ariaDescribedBy = _props['aria-describedby'],\n accessibilityDescribedBy = _props.accessibilityDescribedBy,\n ariaDetails = _props['aria-details'],\n accessibilityDetails = _props.accessibilityDetails,\n ariaDisabled = _props['aria-disabled'],\n accessibilityDisabled = _props.accessibilityDisabled,\n ariaErrorMessage = _props['aria-errormessage'],\n accessibilityErrorMessage = _props.accessibilityErrorMessage,\n ariaExpanded = _props['aria-expanded'],\n accessibilityExpanded = _props.accessibilityExpanded,\n ariaFlowTo = _props['aria-flowto'],\n accessibilityFlowTo = _props.accessibilityFlowTo,\n ariaHasPopup = _props['aria-haspopup'],\n accessibilityHasPopup = _props.accessibilityHasPopup,\n ariaHidden = _props['aria-hidden'],\n accessibilityHidden = _props.accessibilityHidden,\n ariaInvalid = _props['aria-invalid'],\n accessibilityInvalid = _props.accessibilityInvalid,\n ariaKeyShortcuts = _props['aria-keyshortcuts'],\n accessibilityKeyShortcuts = _props.accessibilityKeyShortcuts,\n ariaLabel = _props['aria-label'],\n accessibilityLabel = _props.accessibilityLabel,\n ariaLabelledBy = _props['aria-labelledby'],\n accessibilityLabelledBy = _props.accessibilityLabelledBy,\n ariaLevel = _props['aria-level'],\n accessibilityLevel = _props.accessibilityLevel,\n ariaLive = _props['aria-live'],\n accessibilityLiveRegion = _props.accessibilityLiveRegion,\n ariaModal = _props['aria-modal'],\n accessibilityModal = _props.accessibilityModal,\n ariaMultiline = _props['aria-multiline'],\n accessibilityMultiline = _props.accessibilityMultiline,\n ariaMultiSelectable = _props['aria-multiselectable'],\n accessibilityMultiSelectable = _props.accessibilityMultiSelectable,\n ariaOrientation = _props['aria-orientation'],\n accessibilityOrientation = _props.accessibilityOrientation,\n ariaOwns = _props['aria-owns'],\n accessibilityOwns = _props.accessibilityOwns,\n ariaPlaceholder = _props['aria-placeholder'],\n accessibilityPlaceholder = _props.accessibilityPlaceholder,\n ariaPosInSet = _props['aria-posinset'],\n accessibilityPosInSet = _props.accessibilityPosInSet,\n ariaPressed = _props['aria-pressed'],\n accessibilityPressed = _props.accessibilityPressed,\n ariaReadOnly = _props['aria-readonly'],\n accessibilityReadOnly = _props.accessibilityReadOnly,\n ariaRequired = _props['aria-required'],\n accessibilityRequired = _props.accessibilityRequired,\n ariaRole = _props.role,\n accessibilityRole = _props.accessibilityRole,\n ariaRoleDescription = _props['aria-roledescription'],\n accessibilityRoleDescription = _props.accessibilityRoleDescription,\n ariaRowCount = _props['aria-rowcount'],\n accessibilityRowCount = _props.accessibilityRowCount,\n ariaRowIndex = _props['aria-rowindex'],\n accessibilityRowIndex = _props.accessibilityRowIndex,\n ariaRowSpan = _props['aria-rowspan'],\n accessibilityRowSpan = _props.accessibilityRowSpan,\n ariaSelected = _props['aria-selected'],\n accessibilitySelected = _props.accessibilitySelected,\n ariaSetSize = _props['aria-setsize'],\n accessibilitySetSize = _props.accessibilitySetSize,\n ariaSort = _props['aria-sort'],\n accessibilitySort = _props.accessibilitySort,\n ariaValueMax = _props['aria-valuemax'],\n accessibilityValueMax = _props.accessibilityValueMax,\n ariaValueMin = _props['aria-valuemin'],\n accessibilityValueMin = _props.accessibilityValueMin,\n ariaValueNow = _props['aria-valuenow'],\n accessibilityValueNow = _props.accessibilityValueNow,\n ariaValueText = _props['aria-valuetext'],\n accessibilityValueText = _props.accessibilityValueText,\n dataSet = _props.dataSet,\n focusable = _props.focusable,\n id = _props.id,\n nativeID = _props.nativeID,\n pointerEvents = _props.pointerEvents,\n style = _props.style,\n tabIndex = _props.tabIndex,\n testID = _props.testID,\n domProps = _objectWithoutPropertiesLoose(_props, _excluded);\n\n /*\n if (accessibilityDisabled != null) {\n warnOnce('accessibilityDisabled', `accessibilityDisabled is deprecated.`);\n }\n */\n var disabled = ariaDisabled || accessibilityDisabled;\n var role = AccessibilityUtil.propsToAriaRole(props);\n\n // ACCESSIBILITY\n /*\n if (accessibilityActiveDescendant != null) {\n warnOnce(\n 'accessibilityActiveDescendant',\n `accessibilityActiveDescendant is deprecated. Use aria-activedescendant.`\n );\n }\n */\n var _ariaActiveDescendant = ariaActiveDescendant != null ? ariaActiveDescendant : accessibilityActiveDescendant;\n if (_ariaActiveDescendant != null) {\n domProps['aria-activedescendant'] = _ariaActiveDescendant;\n }\n\n /*\n if (accessibilityAtomic != null) {\n warnOnce(\n 'accessibilityAtomic',\n `accessibilityAtomic is deprecated. Use aria-atomic.`\n );\n }\n */\n var _ariaAtomic = ariaAtomic != null ? ariaActiveDescendant : accessibilityAtomic;\n if (_ariaAtomic != null) {\n domProps['aria-atomic'] = _ariaAtomic;\n }\n\n /*\n if (accessibilityAutoComplete != null) {\n warnOnce(\n 'accessibilityAutoComplete',\n `accessibilityAutoComplete is deprecated. Use aria-autocomplete.`\n );\n }\n */\n var _ariaAutoComplete = ariaAutoComplete != null ? ariaAutoComplete : accessibilityAutoComplete;\n if (_ariaAutoComplete != null) {\n domProps['aria-autocomplete'] = _ariaAutoComplete;\n }\n\n /*\n if (accessibilityBusy != null) {\n warnOnce(\n 'accessibilityBusy',\n `accessibilityBusy is deprecated. Use aria-busy.`\n );\n }\n */\n var _ariaBusy = ariaBusy != null ? ariaBusy : accessibilityBusy;\n if (_ariaBusy != null) {\n domProps['aria-busy'] = _ariaBusy;\n }\n\n /*\n if (accessibilityChecked != null) {\n warnOnce(\n 'accessibilityChecked',\n `accessibilityChecked is deprecated. Use aria-checked.`\n );\n }\n */\n var _ariaChecked = ariaChecked != null ? ariaChecked : accessibilityChecked;\n if (_ariaChecked != null) {\n domProps['aria-checked'] = _ariaChecked;\n }\n\n /*\n if (accessibilityColumnCount != null) {\n warnOnce(\n 'accessibilityColumnCount',\n `accessibilityColumnCount is deprecated. Use aria-colcount.`\n );\n }\n */\n var _ariaColumnCount = ariaColumnCount != null ? ariaColumnCount : accessibilityColumnCount;\n if (_ariaColumnCount != null) {\n domProps['aria-colcount'] = _ariaColumnCount;\n }\n\n /*\n if (accessibilityColumnIndex != null) {\n warnOnce(\n 'accessibilityColumnIndex',\n `accessibilityColumnIndex is deprecated. Use aria-colindex.`\n );\n }\n */\n var _ariaColumnIndex = ariaColumnIndex != null ? ariaColumnIndex : accessibilityColumnIndex;\n if (_ariaColumnIndex != null) {\n domProps['aria-colindex'] = _ariaColumnIndex;\n }\n\n /*\n if (accessibilityColumnSpan != null) {\n warnOnce(\n 'accessibilityColumnSpan',\n `accessibilityColumnSpan is deprecated. Use aria-colspan.`\n );\n }\n */\n var _ariaColumnSpan = ariaColumnSpan != null ? ariaColumnSpan : accessibilityColumnSpan;\n if (_ariaColumnSpan != null) {\n domProps['aria-colspan'] = _ariaColumnSpan;\n }\n\n /*\n if (accessibilityControls != null) {\n warnOnce(\n 'accessibilityControls',\n `accessibilityControls is deprecated. Use aria-controls.`\n );\n }\n */\n var _ariaControls = ariaControls != null ? ariaControls : accessibilityControls;\n if (_ariaControls != null) {\n domProps['aria-controls'] = processIDRefList(_ariaControls);\n }\n\n /*\n if (accessibilityCurrent != null) {\n warnOnce(\n 'accessibilityCurrent',\n `accessibilityCurrent is deprecated. Use aria-current.`\n );\n }\n */\n var _ariaCurrent = ariaCurrent != null ? ariaCurrent : accessibilityCurrent;\n if (_ariaCurrent != null) {\n domProps['aria-current'] = _ariaCurrent;\n }\n\n /*\n if (accessibilityDescribedBy != null) {\n warnOnce(\n 'accessibilityDescribedBy',\n `accessibilityDescribedBy is deprecated. Use aria-describedby.`\n );\n }\n */\n var _ariaDescribedBy = ariaDescribedBy != null ? ariaDescribedBy : accessibilityDescribedBy;\n if (_ariaDescribedBy != null) {\n domProps['aria-describedby'] = processIDRefList(_ariaDescribedBy);\n }\n\n /*\n if (accessibilityDetails != null) {\n warnOnce(\n 'accessibilityDetails',\n `accessibilityDetails is deprecated. Use aria-details.`\n );\n }\n */\n var _ariaDetails = ariaDetails != null ? ariaDetails : accessibilityDetails;\n if (_ariaDetails != null) {\n domProps['aria-details'] = _ariaDetails;\n }\n if (disabled === true) {\n domProps['aria-disabled'] = true;\n // Enhance with native semantics\n if (elementType === 'button' || elementType === 'form' || elementType === 'input' || elementType === 'select' || elementType === 'textarea') {\n domProps.disabled = true;\n }\n }\n\n /*\n if (accessibilityErrorMessage != null) {\n warnOnce(\n 'accessibilityErrorMessage',\n `accessibilityErrorMessage is deprecated. Use aria-errormessage.`\n );\n }\n */\n var _ariaErrorMessage = ariaErrorMessage != null ? ariaErrorMessage : accessibilityErrorMessage;\n if (_ariaErrorMessage != null) {\n domProps['aria-errormessage'] = _ariaErrorMessage;\n }\n\n /*\n if (accessibilityExpanded != null) {\n warnOnce(\n 'accessibilityExpanded',\n `accessibilityExpanded is deprecated. Use aria-expanded.`\n );\n }\n */\n var _ariaExpanded = ariaExpanded != null ? ariaExpanded : accessibilityExpanded;\n if (_ariaExpanded != null) {\n domProps['aria-expanded'] = _ariaExpanded;\n }\n\n /*\n if (accessibilityFlowTo != null) {\n warnOnce(\n 'accessibilityFlowTo',\n `accessibilityFlowTo is deprecated. Use aria-flowto.`\n );\n }\n */\n var _ariaFlowTo = ariaFlowTo != null ? ariaFlowTo : accessibilityFlowTo;\n if (_ariaFlowTo != null) {\n domProps['aria-flowto'] = processIDRefList(_ariaFlowTo);\n }\n\n /*\n if (accessibilityHasPopup != null) {\n warnOnce(\n 'accessibilityHasPopup',\n `accessibilityHasPopup is deprecated. Use aria-haspopup.`\n );\n }\n */\n var _ariaHasPopup = ariaHasPopup != null ? ariaHasPopup : accessibilityHasPopup;\n if (_ariaHasPopup != null) {\n domProps['aria-haspopup'] = _ariaHasPopup;\n }\n\n /*\n if (accessibilityHidden != null) {\n warnOnce(\n 'accessibilityHidden',\n `accessibilityHidden is deprecated. Use aria-hidden.`\n );\n }\n */\n var _ariaHidden = ariaHidden != null ? ariaHidden : accessibilityHidden;\n if (_ariaHidden === true) {\n domProps['aria-hidden'] = _ariaHidden;\n }\n\n /*\n if (accessibilityInvalid != null) {\n warnOnce(\n 'accessibilityInvalid',\n `accessibilityInvalid is deprecated. Use aria-invalid.`\n );\n }\n */\n var _ariaInvalid = ariaInvalid != null ? ariaInvalid : accessibilityInvalid;\n if (_ariaInvalid != null) {\n domProps['aria-invalid'] = _ariaInvalid;\n }\n\n /*\n if (accessibilityKeyShortcuts != null) {\n warnOnce(\n 'accessibilityKeyShortcuts',\n `accessibilityKeyShortcuts is deprecated. Use aria-keyshortcuts.`\n );\n }\n */\n var _ariaKeyShortcuts = ariaKeyShortcuts != null ? ariaKeyShortcuts : accessibilityKeyShortcuts;\n if (_ariaKeyShortcuts != null) {\n domProps['aria-keyshortcuts'] = processIDRefList(_ariaKeyShortcuts);\n }\n\n /*\n if (accessibilityLabel != null) {\n warnOnce(\n 'accessibilityLabel',\n `accessibilityLabel is deprecated. Use aria-label.`\n );\n }\n */\n var _ariaLabel = ariaLabel != null ? ariaLabel : accessibilityLabel;\n if (_ariaLabel != null) {\n domProps['aria-label'] = _ariaLabel;\n }\n\n /*\n if (accessibilityLabelledBy != null) {\n warnOnce(\n 'accessibilityLabelledBy',\n `accessibilityLabelledBy is deprecated. Use aria-labelledby.`\n );\n }\n */\n var _ariaLabelledBy = ariaLabelledBy != null ? ariaLabelledBy : accessibilityLabelledBy;\n if (_ariaLabelledBy != null) {\n domProps['aria-labelledby'] = processIDRefList(_ariaLabelledBy);\n }\n\n /*\n if (accessibilityLevel != null) {\n warnOnce(\n 'accessibilityLevel',\n `accessibilityLevel is deprecated. Use aria-level.`\n );\n }\n */\n var _ariaLevel = ariaLevel != null ? ariaLevel : accessibilityLevel;\n if (_ariaLevel != null) {\n domProps['aria-level'] = _ariaLevel;\n }\n\n /*\n if (accessibilityLiveRegion != null) {\n warnOnce(\n 'accessibilityLiveRegion',\n `accessibilityLiveRegion is deprecated. Use aria-live.`\n );\n }\n */\n var _ariaLive = ariaLive != null ? ariaLive : accessibilityLiveRegion;\n if (_ariaLive != null) {\n domProps['aria-live'] = _ariaLive === 'none' ? 'off' : _ariaLive;\n }\n\n /*\n if (accessibilityModal != null) {\n warnOnce(\n 'accessibilityModal',\n `accessibilityModal is deprecated. Use aria-modal.`\n );\n }\n */\n var _ariaModal = ariaModal != null ? ariaModal : accessibilityModal;\n if (_ariaModal != null) {\n domProps['aria-modal'] = _ariaModal;\n }\n\n /*\n if (accessibilityMultiline != null) {\n warnOnce(\n 'accessibilityMultiline',\n `accessibilityMultiline is deprecated. Use aria-multiline.`\n );\n }\n */\n var _ariaMultiline = ariaMultiline != null ? ariaMultiline : accessibilityMultiline;\n if (_ariaMultiline != null) {\n domProps['aria-multiline'] = _ariaMultiline;\n }\n\n /*\n if (accessibilityMultiSelectable != null) {\n warnOnce(\n 'accessibilityMultiSelectable',\n `accessibilityMultiSelectable is deprecated. Use aria-multiselectable.`\n );\n }\n */\n var _ariaMultiSelectable = ariaMultiSelectable != null ? ariaMultiSelectable : accessibilityMultiSelectable;\n if (_ariaMultiSelectable != null) {\n domProps['aria-multiselectable'] = _ariaMultiSelectable;\n }\n\n /*\n if (accessibilityOrientation != null) {\n warnOnce(\n 'accessibilityOrientation',\n `accessibilityOrientation is deprecated. Use aria-orientation.`\n );\n }\n */\n var _ariaOrientation = ariaOrientation != null ? ariaOrientation : accessibilityOrientation;\n if (_ariaOrientation != null) {\n domProps['aria-orientation'] = _ariaOrientation;\n }\n\n /*\n if (accessibilityOwns != null) {\n warnOnce(\n 'accessibilityOwns',\n `accessibilityOwns is deprecated. Use aria-owns.`\n );\n }\n */\n var _ariaOwns = ariaOwns != null ? ariaOwns : accessibilityOwns;\n if (_ariaOwns != null) {\n domProps['aria-owns'] = processIDRefList(_ariaOwns);\n }\n\n /*\n if (accessibilityPlaceholder != null) {\n warnOnce(\n 'accessibilityPlaceholder',\n `accessibilityPlaceholder is deprecated. Use aria-placeholder.`\n );\n }\n */\n var _ariaPlaceholder = ariaPlaceholder != null ? ariaPlaceholder : accessibilityPlaceholder;\n if (_ariaPlaceholder != null) {\n domProps['aria-placeholder'] = _ariaPlaceholder;\n }\n\n /*\n if (accessibilityPosInSet != null) {\n warnOnce(\n 'accessibilityPosInSet',\n `accessibilityPosInSet is deprecated. Use aria-posinset.`\n );\n }\n */\n var _ariaPosInSet = ariaPosInSet != null ? ariaPosInSet : accessibilityPosInSet;\n if (_ariaPosInSet != null) {\n domProps['aria-posinset'] = _ariaPosInSet;\n }\n\n /*\n if (accessibilityPressed != null) {\n warnOnce(\n 'accessibilityPressed',\n `accessibilityPressed is deprecated. Use aria-pressed.`\n );\n }\n */\n var _ariaPressed = ariaPressed != null ? ariaPressed : accessibilityPressed;\n if (_ariaPressed != null) {\n domProps['aria-pressed'] = _ariaPressed;\n }\n\n /*\n if (accessibilityReadOnly != null) {\n warnOnce(\n 'accessibilityReadOnly',\n `accessibilityReadOnly is deprecated. Use aria-readonly.`\n );\n }\n */\n var _ariaReadOnly = ariaReadOnly != null ? ariaReadOnly : accessibilityReadOnly;\n if (_ariaReadOnly != null) {\n domProps['aria-readonly'] = _ariaReadOnly;\n // Enhance with native semantics\n if (elementType === 'input' || elementType === 'select' || elementType === 'textarea') {\n domProps.readOnly = true;\n }\n }\n\n /*\n if (accessibilityRequired != null) {\n warnOnce(\n 'accessibilityRequired',\n `accessibilityRequired is deprecated. Use aria-required.`\n );\n }\n */\n var _ariaRequired = ariaRequired != null ? ariaRequired : accessibilityRequired;\n if (_ariaRequired != null) {\n domProps['aria-required'] = _ariaRequired;\n // Enhance with native semantics\n if (elementType === 'input' || elementType === 'select' || elementType === 'textarea') {\n domProps.required = accessibilityRequired;\n }\n }\n\n /*\n if (accessibilityRole != null) {\n warnOnce('accessibilityRole', `accessibilityRole is deprecated. Use role.`);\n }\n */\n if (role != null) {\n // 'presentation' synonym has wider browser support\n domProps['role'] = role === 'none' ? 'presentation' : role;\n }\n\n /*\n if (accessibilityRoleDescription != null) {\n warnOnce(\n 'accessibilityRoleDescription',\n `accessibilityRoleDescription is deprecated. Use aria-roledescription.`\n );\n }\n */\n var _ariaRoleDescription = ariaRoleDescription != null ? ariaRoleDescription : accessibilityRoleDescription;\n if (_ariaRoleDescription != null) {\n domProps['aria-roledescription'] = _ariaRoleDescription;\n }\n\n /*\n if (accessibilityRowCount != null) {\n warnOnce(\n 'accessibilityRowCount',\n `accessibilityRowCount is deprecated. Use aria-rowcount.`\n );\n }\n */\n var _ariaRowCount = ariaRowCount != null ? ariaRowCount : accessibilityRowCount;\n if (_ariaRowCount != null) {\n domProps['aria-rowcount'] = _ariaRowCount;\n }\n\n /*\n if (accessibilityRowIndex != null) {\n warnOnce(\n 'accessibilityRowIndex',\n `accessibilityRowIndex is deprecated. Use aria-rowindex.`\n );\n }\n */\n var _ariaRowIndex = ariaRowIndex != null ? ariaRowIndex : accessibilityRowIndex;\n if (_ariaRowIndex != null) {\n domProps['aria-rowindex'] = _ariaRowIndex;\n }\n\n /*\n if (accessibilityRowSpan != null) {\n warnOnce(\n 'accessibilityRowSpan',\n `accessibilityRowSpan is deprecated. Use aria-rowspan.`\n );\n }\n */\n var _ariaRowSpan = ariaRowSpan != null ? ariaRowSpan : accessibilityRowSpan;\n if (_ariaRowSpan != null) {\n domProps['aria-rowspan'] = _ariaRowSpan;\n }\n\n /*\n if (accessibilitySelected != null) {\n warnOnce(\n 'accessibilitySelected',\n `accessibilitySelected is deprecated. Use aria-selected.`\n );\n }\n */\n var _ariaSelected = ariaSelected != null ? ariaSelected : accessibilitySelected;\n if (_ariaSelected != null) {\n domProps['aria-selected'] = _ariaSelected;\n }\n\n /*\n if (accessibilitySetSize != null) {\n warnOnce(\n 'accessibilitySetSize',\n `accessibilitySetSize is deprecated. Use aria-setsize.`\n );\n }\n */\n var _ariaSetSize = ariaSetSize != null ? ariaSetSize : accessibilitySetSize;\n if (_ariaSetSize != null) {\n domProps['aria-setsize'] = _ariaSetSize;\n }\n\n /*\n if (accessibilitySort != null) {\n warnOnce(\n 'accessibilitySort',\n `accessibilitySort is deprecated. Use aria-sort.`\n );\n }\n */\n var _ariaSort = ariaSort != null ? ariaSort : accessibilitySort;\n if (_ariaSort != null) {\n domProps['aria-sort'] = _ariaSort;\n }\n\n /*\n if (accessibilityValueMax != null) {\n warnOnce(\n 'accessibilityValueMax',\n `accessibilityValueMax is deprecated. Use aria-valuemax.`\n );\n }\n */\n var _ariaValueMax = ariaValueMax != null ? ariaValueMax : accessibilityValueMax;\n if (_ariaValueMax != null) {\n domProps['aria-valuemax'] = _ariaValueMax;\n }\n\n /*\n if (accessibilityValueMin != null) {\n warnOnce(\n 'accessibilityValueMin',\n `accessibilityValueMin is deprecated. Use aria-valuemin.`\n );\n }\n */\n var _ariaValueMin = ariaValueMin != null ? ariaValueMin : accessibilityValueMin;\n if (_ariaValueMin != null) {\n domProps['aria-valuemin'] = _ariaValueMin;\n }\n\n /*\n if (accessibilityValueNow != null) {\n warnOnce(\n 'accessibilityValueNow',\n `accessibilityValueNow is deprecated. Use aria-valuenow.`\n );\n }\n */\n var _ariaValueNow = ariaValueNow != null ? ariaValueNow : accessibilityValueNow;\n if (_ariaValueNow != null) {\n domProps['aria-valuenow'] = _ariaValueNow;\n }\n\n /*\n if (accessibilityValueText != null) {\n warnOnce(\n 'accessibilityValueText',\n `accessibilityValueText is deprecated. Use aria-valuetext.`\n );\n }\n */\n var _ariaValueText = ariaValueText != null ? ariaValueText : accessibilityValueText;\n if (_ariaValueText != null) {\n domProps['aria-valuetext'] = _ariaValueText;\n }\n\n // \"dataSet\" replaced with \"data-*\"\n if (dataSet != null) {\n for (var dataProp in dataSet) {\n if (hasOwnProperty.call(dataSet, dataProp)) {\n var dataName = hyphenateString(dataProp);\n var dataValue = dataSet[dataProp];\n if (dataValue != null) {\n domProps[\"data-\" + dataName] = dataValue;\n }\n }\n }\n }\n\n // FOCUS\n if (tabIndex === 0 || tabIndex === '0' || tabIndex === -1 || tabIndex === '-1') {\n domProps.tabIndex = tabIndex;\n } else {\n /*\n if (focusable != null) {\n warnOnce('focusable', `focusable is deprecated.`);\n }\n */\n\n // \"focusable\" indicates that an element may be a keyboard tab-stop.\n if (focusable === false) {\n domProps.tabIndex = '-1';\n }\n if (\n // These native elements are keyboard focusable by default\n elementType === 'a' || elementType === 'button' || elementType === 'input' || elementType === 'select' || elementType === 'textarea') {\n if (focusable === false || accessibilityDisabled === true) {\n domProps.tabIndex = '-1';\n }\n } else if (\n // These roles are made keyboard focusable by default\n role === 'button' || role === 'checkbox' || role === 'link' || role === 'radio' || role === 'textbox' || role === 'switch') {\n if (focusable !== false) {\n domProps.tabIndex = '0';\n }\n } else {\n // Everything else must explicitly set the prop\n if (focusable === true) {\n domProps.tabIndex = '0';\n }\n }\n }\n\n // Resolve styles\n if (pointerEvents != null) {\n warnOnce('pointerEvents', \"props.pointerEvents is deprecated. Use style.pointerEvents\");\n }\n var _StyleSheet = StyleSheet([style, pointerEvents && pointerEventsStyles[pointerEvents]], _objectSpread({\n writingDirection: 'ltr'\n }, options)),\n className = _StyleSheet[0],\n inlineStyle = _StyleSheet[1];\n if (className) {\n domProps.className = className;\n }\n if (inlineStyle) {\n domProps.style = inlineStyle;\n }\n\n // OTHER\n // Native element ID\n /*\n if (nativeID != null) {\n warnOnce('nativeID', `nativeID is deprecated. Use id.`);\n }\n */\n var _id = id != null ? id : nativeID;\n if (_id != null) {\n domProps.id = _id;\n }\n // Automated test IDs\n if (testID != null) {\n domProps['data-testid'] = testID;\n }\n if (domProps.type == null && elementType === 'button') {\n domProps.type = 'button';\n }\n return domProps;\n};\nexport default createDOMProps;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar rtlScripts = new Set(['Arab', 'Syrc', 'Samr', 'Mand', 'Thaa', 'Mend', 'Nkoo', 'Adlm', 'Rohg', 'Hebr']);\nvar rtlLangs = new Set(['ae',\n// Avestan\n'ar',\n// Arabic\n'arc',\n// Aramaic\n'bcc',\n// Southern Balochi\n'bqi',\n// Bakthiari\n'ckb',\n// Sorani\n'dv',\n// Dhivehi\n'fa', 'far',\n// Persian\n'glk',\n// Gilaki\n'he', 'iw',\n// Hebrew\n'khw',\n// Khowar\n'ks',\n// Kashmiri\n'ku',\n// Kurdish\n'mzn',\n// Mazanderani\n'nqo',\n// N'Ko\n'pnb',\n// Western Punjabi\n'ps',\n// Pashto\n'sd',\n// Sindhi\n'ug',\n// Uyghur\n'ur',\n// Urdu\n'yi' // Yiddish\n]);\nvar cache = new Map();\n\n/**\n * Determine the writing direction of a locale\n */\nexport function isLocaleRTL(locale) {\n var cachedRTL = cache.get(locale);\n if (cachedRTL) {\n return cachedRTL;\n }\n var isRTL = false;\n // $FlowFixMe\n if (Intl.Locale) {\n try {\n // $FlowFixMe\n var script = new Intl.Locale(locale).maximize().script;\n isRTL = rtlScripts.has(script);\n } catch (_unused) {\n // RangeError: Incorrect locale information provided\n // Fallback to inferring from language\n var lang = locale.split('-')[0];\n isRTL = rtlLangs.has(lang);\n }\n } else {\n // Fallback to inferring from language\n var _lang = locale.split('-')[0];\n isRTL = rtlLangs.has(_lang);\n }\n cache.set(locale, isRTL);\n return isRTL;\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport React, { createContext, useContext } from 'react';\nimport { isLocaleRTL } from './isLocaleRTL';\nvar defaultLocale = {\n direction: 'ltr',\n locale: 'en-US'\n};\nvar LocaleContext = /*#__PURE__*/createContext(defaultLocale);\nexport function getLocaleDirection(locale) {\n return isLocaleRTL(locale) ? 'rtl' : 'ltr';\n}\nexport function LocaleProvider(props) {\n var direction = props.direction,\n locale = props.locale,\n children = props.children;\n var needsContext = direction || locale;\n return needsContext ? /*#__PURE__*/React.createElement(LocaleContext.Provider, {\n children: children,\n value: {\n direction: locale ? getLocaleDirection(locale) : direction,\n locale\n }\n }) : children;\n}\nexport function useLocaleContext() {\n return useContext(LocaleContext);\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\n'use client';\n\nimport AccessibilityUtil from '../../modules/AccessibilityUtil';\nimport createDOMProps from '../../modules/createDOMProps';\nimport React from 'react';\nimport { LocaleProvider } from '../../modules/useLocale';\nvar createElement = (component, props, options) => {\n // Use equivalent platform elements where possible.\n var accessibilityComponent;\n if (component && component.constructor === String) {\n accessibilityComponent = AccessibilityUtil.propsToAccessibilityComponent(props);\n }\n var Component = accessibilityComponent || component;\n var domProps = createDOMProps(Component, props, options);\n var element = /*#__PURE__*/React.createElement(Component, domProps);\n\n // Update locale context if element's writing direction prop changes\n var elementWithLocaleProvider = domProps.dir ? /*#__PURE__*/React.createElement(LocaleProvider, {\n children: element,\n direction: domProps.dir,\n locale: domProps.lang\n }) : element;\n return elementWithLocaleProvider;\n};\nexport default createElement;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar getBoundingClientRect = node => {\n if (node != null) {\n var isElement = node.nodeType === 1; /* Node.ELEMENT_NODE */\n if (isElement && typeof node.getBoundingClientRect === 'function') {\n return node.getBoundingClientRect();\n }\n }\n};\nexport default getBoundingClientRect;","/**\n * Copyright (c) Nicolas Gallagher.\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar unitlessNumbers = {\n animationIterationCount: true,\n aspectRatio: true,\n borderImageOutset: true,\n borderImageSlice: true,\n borderImageWidth: true,\n boxFlex: true,\n boxFlexGroup: true,\n boxOrdinalGroup: true,\n columnCount: true,\n flex: true,\n flexGrow: true,\n flexOrder: true,\n flexPositive: true,\n flexShrink: true,\n flexNegative: true,\n fontWeight: true,\n gridRow: true,\n gridRowEnd: true,\n gridRowGap: true,\n gridRowStart: true,\n gridColumn: true,\n gridColumnEnd: true,\n gridColumnGap: true,\n gridColumnStart: true,\n lineClamp: true,\n opacity: true,\n order: true,\n orphans: true,\n tabSize: true,\n widows: true,\n zIndex: true,\n zoom: true,\n // SVG-related\n fillOpacity: true,\n floodOpacity: true,\n stopOpacity: true,\n strokeDasharray: true,\n strokeDashoffset: true,\n strokeMiterlimit: true,\n strokeOpacity: true,\n strokeWidth: true,\n // transform types\n scale: true,\n scaleX: true,\n scaleY: true,\n scaleZ: true,\n // RN properties\n shadowOpacity: true\n};\n\n/**\n * Support style names that may come passed in prefixed by adding permutations\n * of vendor prefixes.\n */\nvar prefixes = ['ms', 'Moz', 'O', 'Webkit'];\nvar prefixKey = (prefix, key) => {\n return prefix + key.charAt(0).toUpperCase() + key.substring(1);\n};\nObject.keys(unitlessNumbers).forEach(prop => {\n prefixes.forEach(prefix => {\n unitlessNumbers[prefixKey(prefix, prop)] = unitlessNumbers[prop];\n });\n});\nexport default unitlessNumbers;","/* eslint-disable */\n\n/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * From React 16.0.0\n * \n */\n\nimport isUnitlessNumber from '../unitlessNumbers';\n\n/**\n * Convert a value into the proper css writable value. The style name `name`\n * should be logical (no hyphens), as specified\n * in `CSSProperty.isUnitlessNumber`.\n *\n * @param {string} name CSS property name such as `topMargin`.\n * @param {*} value CSS property value such as `10px`.\n * @return {string} Normalized style value with dimensions applied.\n */\nfunction dangerousStyleValue(name, value, isCustomProperty) {\n // Note that we've removed escapeTextForBrowser() calls here since the\n // whole string will be escaped when the attribute is injected into\n // the markup. If you provide unsafe user data here they can inject\n // arbitrary CSS which may be problematic (I couldn't repro this):\n // https://www.owasp.org/index.php/XSS_Filter_Evasion_Cheat_Sheet\n // http://www.thespanner.co.uk/2007/11/26/ultimate-xss-css-injection/\n // This is not an XSS hole but instead a potential CSS injection issue\n // which has lead to a greater discussion about how we're going to\n // trust URLs moving forward. See #2115901\n\n var isEmpty = value == null || typeof value === 'boolean' || value === '';\n if (isEmpty) {\n return '';\n }\n if (!isCustomProperty && typeof value === 'number' && value !== 0 && !(isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name])) {\n return value + 'px'; // Presumes implicit 'px' suffix for unitless numbers\n }\n return ('' + value).trim();\n}\nexport default dangerousStyleValue;","/* eslint-disable */\n\n/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * From React 16.3.0\n * \n */\n\nimport dangerousStyleValue from './dangerousStyleValue';\n\n/**\n * Sets the value for multiple styles on a node. If a value is specified as\n * '' (empty string), the corresponding style property will be unset.\n *\n * @param {DOMElement} node\n * @param {object} styles\n */\nfunction setValueForStyles(node, styles) {\n var style = node.style;\n for (var styleName in styles) {\n if (!styles.hasOwnProperty(styleName)) {\n continue;\n }\n var isCustomProperty = styleName.indexOf('--') === 0;\n var styleValue = dangerousStyleValue(styleName, styles[styleName], isCustomProperty);\n if (styleName === 'float') {\n styleName = 'cssFloat';\n }\n if (isCustomProperty) {\n style.setProperty(styleName, styleValue);\n } else {\n style[styleName] = styleValue;\n }\n }\n}\nexport default setValueForStyles;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport getBoundingClientRect from '../../modules/getBoundingClientRect';\nimport setValueForStyles from '../../modules/setValueForStyles';\nvar getRect = node => {\n var height = node.offsetHeight;\n var width = node.offsetWidth;\n var left = node.offsetLeft;\n var top = node.offsetTop;\n node = node.offsetParent;\n while (node && node.nodeType === 1 /* Node.ELEMENT_NODE */) {\n left += node.offsetLeft + node.clientLeft - node.scrollLeft;\n top += node.offsetTop + node.clientTop - node.scrollTop;\n node = node.offsetParent;\n }\n top -= window.scrollY;\n left -= window.scrollX;\n return {\n width,\n height,\n top,\n left\n };\n};\nvar measureLayout = (node, relativeToNativeNode, callback) => {\n var relativeNode = relativeToNativeNode || node && node.parentNode;\n if (node && relativeNode) {\n setTimeout(() => {\n if (node.isConnected && relativeNode.isConnected) {\n var relativeRect = getRect(relativeNode);\n var _getRect = getRect(node),\n height = _getRect.height,\n left = _getRect.left,\n top = _getRect.top,\n width = _getRect.width;\n var x = left - relativeRect.left;\n var y = top - relativeRect.top;\n callback(x, y, width, height, left, top);\n }\n }, 0);\n }\n};\nvar elementsToIgnore = {\n A: true,\n BODY: true,\n INPUT: true,\n SELECT: true,\n TEXTAREA: true\n};\nvar UIManager = {\n blur(node) {\n try {\n node.blur();\n } catch (err) {}\n },\n focus(node) {\n try {\n var name = node.nodeName;\n // A tabIndex of -1 allows element to be programmatically focused but\n // prevents keyboard focus. We don't want to set the tabindex value on\n // elements that should not prevent keyboard focus.\n if (node.getAttribute('tabIndex') == null && node.isContentEditable !== true && elementsToIgnore[name] == null) {\n node.setAttribute('tabIndex', '-1');\n }\n node.focus();\n } catch (err) {}\n },\n measure(node, callback) {\n measureLayout(node, null, callback);\n },\n measureInWindow(node, callback) {\n if (node) {\n setTimeout(() => {\n var _getBoundingClientRec = getBoundingClientRect(node),\n height = _getBoundingClientRec.height,\n left = _getBoundingClientRec.left,\n top = _getBoundingClientRec.top,\n width = _getBoundingClientRec.width;\n callback(left, top, width, height);\n }, 0);\n }\n },\n measureLayout(node, relativeToNativeNode, onFail, onSuccess) {\n measureLayout(node, relativeToNativeNode, onSuccess);\n },\n updateView(node, props) {\n for (var prop in props) {\n if (!Object.prototype.hasOwnProperty.call(props, prop)) {\n continue;\n }\n var value = props[prop];\n switch (prop) {\n case 'style':\n {\n setValueForStyles(node, value);\n break;\n }\n case 'class':\n case 'className':\n {\n node.setAttribute('class', value);\n break;\n }\n case 'text':\n case 'value':\n // native platforms use `text` prop to replace text input value\n node.value = value;\n break;\n default:\n node.setAttribute(prop, value);\n }\n }\n },\n configureNextLayoutAnimation(config, onAnimationDidEnd) {\n onAnimationDidEnd();\n },\n // mocks\n setLayoutAnimationEnabledExperimental() {}\n};\nexport default UIManager;","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nexport var defaultProps = {\n children: true,\n dataSet: true,\n dir: true,\n id: true,\n ref: true,\n suppressHydrationWarning: true,\n tabIndex: true,\n testID: true,\n // @deprecated\n focusable: true,\n nativeID: true\n};\nexport var accessibilityProps = {\n 'aria-activedescendant': true,\n 'aria-atomic': true,\n 'aria-autocomplete': true,\n 'aria-busy': true,\n 'aria-checked': true,\n 'aria-colcount': true,\n 'aria-colindex': true,\n 'aria-colspan': true,\n 'aria-controls': true,\n 'aria-current': true,\n 'aria-describedby': true,\n 'aria-details': true,\n 'aria-disabled': true,\n 'aria-errormessage': true,\n 'aria-expanded': true,\n 'aria-flowto': true,\n 'aria-haspopup': true,\n 'aria-hidden': true,\n 'aria-invalid': true,\n 'aria-keyshortcuts': true,\n 'aria-label': true,\n 'aria-labelledby': true,\n 'aria-level': true,\n 'aria-live': true,\n 'aria-modal': true,\n 'aria-multiline': true,\n 'aria-multiselectable': true,\n 'aria-orientation': true,\n 'aria-owns': true,\n 'aria-placeholder': true,\n 'aria-posinset': true,\n 'aria-pressed': true,\n 'aria-readonly': true,\n 'aria-required': true,\n inert: true,\n role: true,\n 'aria-roledescription': true,\n 'aria-rowcount': true,\n 'aria-rowindex': true,\n 'aria-rowspan': true,\n 'aria-selected': true,\n 'aria-setsize': true,\n 'aria-sort': true,\n 'aria-valuemax': true,\n 'aria-valuemin': true,\n 'aria-valuenow': true,\n 'aria-valuetext': true,\n // @deprecated\n accessibilityActiveDescendant: true,\n accessibilityAtomic: true,\n accessibilityAutoComplete: true,\n accessibilityBusy: true,\n accessibilityChecked: true,\n accessibilityColumnCount: true,\n accessibilityColumnIndex: true,\n accessibilityColumnSpan: true,\n accessibilityControls: true,\n accessibilityCurrent: true,\n accessibilityDescribedBy: true,\n accessibilityDetails: true,\n accessibilityDisabled: true,\n accessibilityErrorMessage: true,\n accessibilityExpanded: true,\n accessibilityFlowTo: true,\n accessibilityHasPopup: true,\n accessibilityHidden: true,\n accessibilityInvalid: true,\n accessibilityKeyShortcuts: true,\n accessibilityLabel: true,\n accessibilityLabelledBy: true,\n accessibilityLevel: true,\n accessibilityLiveRegion: true,\n accessibilityModal: true,\n accessibilityMultiline: true,\n accessibilityMultiSelectable: true,\n accessibilityOrientation: true,\n accessibilityOwns: true,\n accessibilityPlaceholder: true,\n accessibilityPosInSet: true,\n accessibilityPressed: true,\n accessibilityReadOnly: true,\n accessibilityRequired: true,\n accessibilityRole: true,\n accessibilityRoleDescription: true,\n accessibilityRowCount: true,\n accessibilityRowIndex: true,\n accessibilityRowSpan: true,\n accessibilitySelected: true,\n accessibilitySetSize: true,\n accessibilitySort: true,\n accessibilityValueMax: true,\n accessibilityValueMin: true,\n accessibilityValueNow: true,\n accessibilityValueText: true\n};\nexport var clickProps = {\n onClick: true,\n onAuxClick: true,\n onContextMenu: true,\n onGotPointerCapture: true,\n onLostPointerCapture: true,\n onPointerCancel: true,\n onPointerDown: true,\n onPointerEnter: true,\n onPointerMove: true,\n onPointerLeave: true,\n onPointerOut: true,\n onPointerOver: true,\n onPointerUp: true\n};\nexport var focusProps = {\n onBlur: true,\n onFocus: true\n};\nexport var keyboardProps = {\n onKeyDown: true,\n onKeyDownCapture: true,\n onKeyUp: true,\n onKeyUpCapture: true\n};\nexport var mouseProps = {\n onMouseDown: true,\n onMouseEnter: true,\n onMouseLeave: true,\n onMouseMove: true,\n onMouseOver: true,\n onMouseOut: true,\n onMouseUp: true\n};\nexport var touchProps = {\n onTouchCancel: true,\n onTouchCancelCapture: true,\n onTouchEnd: true,\n onTouchEndCapture: true,\n onTouchMove: true,\n onTouchMoveCapture: true,\n onTouchStart: true,\n onTouchStartCapture: true\n};\nexport var styleProps = {\n style: true\n};","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nexport default function pick(obj, list) {\n var nextObj = {};\n for (var key in obj) {\n if (obj.hasOwnProperty(key)) {\n if (list[key] === true) {\n nextObj[key] = obj[key];\n }\n }\n }\n return nextObj;\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * useLayoutEffect throws an error on the server. On the few occasions where is\n * problematic, use this hook.\n *\n * \n */\n\nimport { useEffect, useLayoutEffect } from 'react';\nimport canUseDOM from '../canUseDom';\nvar useLayoutEffectImpl = canUseDOM ? useLayoutEffect : useEffect;\nexport default useLayoutEffectImpl;","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport useLayoutEffect from '../useLayoutEffect';\nimport UIManager from '../../exports/UIManager';\nimport canUseDOM from '../canUseDom';\nvar DOM_LAYOUT_HANDLER_NAME = '__reactLayoutHandler';\nvar didWarn = !canUseDOM;\nvar resizeObserver = null;\nfunction getResizeObserver() {\n if (canUseDOM && typeof window.ResizeObserver !== 'undefined') {\n if (resizeObserver == null) {\n resizeObserver = new window.ResizeObserver(function (entries) {\n entries.forEach(entry => {\n var node = entry.target;\n var onLayout = node[DOM_LAYOUT_HANDLER_NAME];\n if (typeof onLayout === 'function') {\n // We still need to measure the view because browsers don't yet provide\n // border-box dimensions in the entry\n UIManager.measure(node, (x, y, width, height, left, top) => {\n var event = {\n // $FlowFixMe\n nativeEvent: {\n layout: {\n x,\n y,\n width,\n height,\n left,\n top\n }\n },\n timeStamp: Date.now()\n };\n Object.defineProperty(event.nativeEvent, 'target', {\n enumerable: true,\n get: () => entry.target\n });\n onLayout(event);\n });\n }\n });\n });\n }\n } else if (!didWarn) {\n if (process.env.NODE_ENV !== 'production' && process.env.NODE_ENV !== 'test') {\n console.warn('onLayout relies on ResizeObserver which is not supported by your browser. ' + 'Please include a polyfill, e.g., https://github.com/que-etc/resize-observer-polyfill.');\n didWarn = true;\n }\n }\n return resizeObserver;\n}\nexport default function useElementLayout(ref, onLayout) {\n var observer = getResizeObserver();\n useLayoutEffect(() => {\n var node = ref.current;\n if (node != null) {\n node[DOM_LAYOUT_HANDLER_NAME] = onLayout;\n }\n }, [ref, onLayout]);\n\n // Observing is done in a separate effect to avoid this effect running\n // when 'onLayout' changes.\n useLayoutEffect(() => {\n var node = ref.current;\n if (node != null && observer != null) {\n if (typeof node[DOM_LAYOUT_HANDLER_NAME] === 'function') {\n observer.observe(node);\n } else {\n observer.unobserve(node);\n }\n }\n return () => {\n if (node != null && observer != null) {\n observer.unobserve(node);\n }\n };\n }, [ref, observer]);\n}","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport * as React from 'react';\nexport default function mergeRefs() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n return function forwardRef(node) {\n args.forEach(ref => {\n if (ref == null) {\n return;\n }\n if (typeof ref === 'function') {\n ref(node);\n return;\n }\n if (typeof ref === 'object') {\n ref.current = node;\n return;\n }\n console.error(\"mergeRefs cannot handle Refs of type boolean, number or string, received ref \" + String(ref));\n });\n };\n}","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport * as React from 'react';\nimport mergeRefs from '../mergeRefs';\nexport default function useMergeRefs() {\n for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n args[_key] = arguments[_key];\n }\n return React.useMemo(() => mergeRefs(...args),\n // eslint-disable-next-line\n [...args]);\n}","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport * as React from 'react';\nvar UNINITIALIZED = typeof Symbol === 'function' && typeof Symbol() === 'symbol' ? Symbol() : Object.freeze({});\nexport default function useStable(getInitialValue) {\n var ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = getInitialValue();\n }\n // $FlowFixMe (#64650789) Trouble refining types where `Symbol` is concerned.\n return ref.current;\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport UIManager from '../../exports/UIManager';\nimport useStable from '../useStable';\n\n/**\n * Adds non-standard methods to the hode element. This is temporarily until an\n * API like `ReactNative.measure(hostRef, callback)` is added to React Native.\n */\nexport default function usePlatformMethods(_ref) {\n var pointerEvents = _ref.pointerEvents,\n style = _ref.style;\n // Avoid creating a new ref on every render.\n var ref = useStable(() => hostNode => {\n if (hostNode != null) {\n hostNode.measure = callback => UIManager.measure(hostNode, callback);\n hostNode.measureLayout = (relativeToNode, success, failure) => UIManager.measureLayout(hostNode, relativeToNode, failure, success);\n hostNode.measureInWindow = callback => UIManager.measureInWindow(hostNode, callback);\n }\n });\n return ref;\n}","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport getBoundingClientRect from '../../modules/getBoundingClientRect';\nvar emptyFunction = () => {};\nvar emptyObject = {};\nvar emptyArray = [];\n\n/**\n * Safari produces very large identifiers that would cause the `touchBank` array\n * length to be so large as to crash the browser, if not normalized like this.\n * In the future the `touchBank` should use an object/map instead.\n */\nfunction normalizeIdentifier(identifier) {\n return identifier > 20 ? identifier % 20 : identifier;\n}\n\n/**\n * Converts a native DOM event to a ResponderEvent.\n * Mouse events are transformed into fake touch events.\n */\nexport default function createResponderEvent(domEvent, responderTouchHistoryStore) {\n var rect;\n var propagationWasStopped = false;\n var changedTouches;\n var touches;\n var domEventChangedTouches = domEvent.changedTouches;\n var domEventType = domEvent.type;\n var metaKey = domEvent.metaKey === true;\n var shiftKey = domEvent.shiftKey === true;\n var force = domEventChangedTouches && domEventChangedTouches[0].force || 0;\n var identifier = normalizeIdentifier(domEventChangedTouches && domEventChangedTouches[0].identifier || 0);\n var clientX = domEventChangedTouches && domEventChangedTouches[0].clientX || domEvent.clientX;\n var clientY = domEventChangedTouches && domEventChangedTouches[0].clientY || domEvent.clientY;\n var pageX = domEventChangedTouches && domEventChangedTouches[0].pageX || domEvent.pageX;\n var pageY = domEventChangedTouches && domEventChangedTouches[0].pageY || domEvent.pageY;\n var preventDefault = typeof domEvent.preventDefault === 'function' ? domEvent.preventDefault.bind(domEvent) : emptyFunction;\n var timestamp = domEvent.timeStamp;\n function normalizeTouches(touches) {\n return Array.prototype.slice.call(touches).map(touch => {\n return {\n force: touch.force,\n identifier: normalizeIdentifier(touch.identifier),\n get locationX() {\n return locationX(touch.clientX);\n },\n get locationY() {\n return locationY(touch.clientY);\n },\n pageX: touch.pageX,\n pageY: touch.pageY,\n target: touch.target,\n timestamp\n };\n });\n }\n if (domEventChangedTouches != null) {\n changedTouches = normalizeTouches(domEventChangedTouches);\n touches = normalizeTouches(domEvent.touches);\n } else {\n var emulatedTouches = [{\n force,\n identifier,\n get locationX() {\n return locationX(clientX);\n },\n get locationY() {\n return locationY(clientY);\n },\n pageX,\n pageY,\n target: domEvent.target,\n timestamp\n }];\n changedTouches = emulatedTouches;\n touches = domEventType === 'mouseup' || domEventType === 'dragstart' ? emptyArray : emulatedTouches;\n }\n var responderEvent = {\n bubbles: true,\n cancelable: true,\n // `currentTarget` is set before dispatch\n currentTarget: null,\n defaultPrevented: domEvent.defaultPrevented,\n dispatchConfig: emptyObject,\n eventPhase: domEvent.eventPhase,\n isDefaultPrevented() {\n return domEvent.defaultPrevented;\n },\n isPropagationStopped() {\n return propagationWasStopped;\n },\n isTrusted: domEvent.isTrusted,\n nativeEvent: {\n altKey: false,\n ctrlKey: false,\n metaKey,\n shiftKey,\n changedTouches,\n force,\n identifier,\n get locationX() {\n return locationX(clientX);\n },\n get locationY() {\n return locationY(clientY);\n },\n pageX,\n pageY,\n target: domEvent.target,\n timestamp,\n touches,\n type: domEventType\n },\n persist: emptyFunction,\n preventDefault,\n stopPropagation() {\n propagationWasStopped = true;\n },\n target: domEvent.target,\n timeStamp: timestamp,\n touchHistory: responderTouchHistoryStore.touchHistory\n };\n\n // Using getters and functions serves two purposes:\n // 1) The value of `currentTarget` is not initially available.\n // 2) Measuring the clientRect may cause layout jank and should only be done on-demand.\n function locationX(x) {\n rect = rect || getBoundingClientRect(responderEvent.currentTarget);\n if (rect) {\n return x - rect.left;\n }\n }\n function locationY(y) {\n rect = rect || getBoundingClientRect(responderEvent.currentTarget);\n if (rect) {\n return y - rect.top;\n }\n }\n return responderEvent;\n}","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nexport var BLUR = 'blur';\nexport var CONTEXT_MENU = 'contextmenu';\nexport var FOCUS_OUT = 'focusout';\nexport var MOUSE_DOWN = 'mousedown';\nexport var MOUSE_MOVE = 'mousemove';\nexport var MOUSE_UP = 'mouseup';\nexport var MOUSE_CANCEL = 'dragstart';\nexport var TOUCH_START = 'touchstart';\nexport var TOUCH_MOVE = 'touchmove';\nexport var TOUCH_END = 'touchend';\nexport var TOUCH_CANCEL = 'touchcancel';\nexport var SCROLL = 'scroll';\nexport var SELECT = 'select';\nexport var SELECTION_CHANGE = 'selectionchange';\nexport function isStartish(eventType) {\n return eventType === TOUCH_START || eventType === MOUSE_DOWN;\n}\nexport function isMoveish(eventType) {\n return eventType === TOUCH_MOVE || eventType === MOUSE_MOVE;\n}\nexport function isEndish(eventType) {\n return eventType === TOUCH_END || eventType === MOUSE_UP || isCancelish(eventType);\n}\nexport function isCancelish(eventType) {\n return eventType === TOUCH_CANCEL || eventType === MOUSE_CANCEL;\n}\nexport function isScroll(eventType) {\n return eventType === SCROLL;\n}\nexport function isSelectionChange(eventType) {\n return eventType === SELECT || eventType === SELECTION_CHANGE;\n}","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nexport default function isSelectionValid() {\n var selection = window.getSelection();\n var string = selection.toString();\n var anchorNode = selection.anchorNode;\n var focusNode = selection.focusNode;\n var isTextNode = anchorNode && anchorNode.nodeType === window.Node.TEXT_NODE || focusNode && focusNode.nodeType === window.Node.TEXT_NODE;\n return string.length >= 1 && string !== '\\n' && isTextNode;\n}","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport isSelectionValid from '../../modules/isSelectionValid';\nvar keyName = '__reactResponderId';\nfunction getEventPath(domEvent) {\n // The 'selectionchange' event always has the 'document' as the target.\n // Use the anchor node as the initial target to reconstruct a path.\n // (We actually only need the first \"responder\" node in practice.)\n if (domEvent.type === 'selectionchange') {\n var target = window.getSelection().anchorNode;\n return composedPathFallback(target);\n } else {\n var path = domEvent.composedPath != null ? domEvent.composedPath() : composedPathFallback(domEvent.target);\n return path;\n }\n}\nfunction composedPathFallback(target) {\n var path = [];\n while (target != null && target !== document.body) {\n path.push(target);\n target = target.parentNode;\n }\n return path;\n}\n\n/**\n * Retrieve the responderId from a host node\n */\nfunction getResponderId(node) {\n if (node != null) {\n return node[keyName];\n }\n return null;\n}\n\n/**\n * Store the responderId on a host node\n */\nexport function setResponderId(node, id) {\n if (node != null) {\n node[keyName] = id;\n }\n}\n\n/**\n * Filter the event path to contain only the nodes attached to the responder system\n */\nexport function getResponderPaths(domEvent) {\n var idPath = [];\n var nodePath = [];\n var eventPath = getEventPath(domEvent);\n for (var i = 0; i < eventPath.length; i++) {\n var node = eventPath[i];\n var id = getResponderId(node);\n if (id != null) {\n idPath.push(id);\n nodePath.push(node);\n }\n }\n return {\n idPath,\n nodePath\n };\n}\n\n/**\n * Walk the paths and find the first common ancestor\n */\nexport function getLowestCommonAncestor(pathA, pathB) {\n var pathALength = pathA.length;\n var pathBLength = pathB.length;\n if (\n // If either path is empty\n pathALength === 0 || pathBLength === 0 ||\n // If the last elements aren't the same there can't be a common ancestor\n // that is connected to the responder system\n pathA[pathALength - 1] !== pathB[pathBLength - 1]) {\n return null;\n }\n var itemA = pathA[0];\n var indexA = 0;\n var itemB = pathB[0];\n var indexB = 0;\n\n // If A is deeper, skip indices that can't match.\n if (pathALength - pathBLength > 0) {\n indexA = pathALength - pathBLength;\n itemA = pathA[indexA];\n pathALength = pathBLength;\n }\n\n // If B is deeper, skip indices that can't match\n if (pathBLength - pathALength > 0) {\n indexB = pathBLength - pathALength;\n itemB = pathB[indexB];\n pathBLength = pathALength;\n }\n\n // Walk in lockstep until a match is found\n var depth = pathALength;\n while (depth--) {\n if (itemA === itemB) {\n return itemA;\n }\n itemA = pathA[indexA++];\n itemB = pathB[indexB++];\n }\n return null;\n}\n\n/**\n * Determine whether any of the active touches are within the current responder.\n * This cannot rely on W3C `targetTouches`, as neither IE11 nor Safari implement it.\n */\nexport function hasTargetTouches(target, touches) {\n if (!touches || touches.length === 0) {\n return false;\n }\n for (var i = 0; i < touches.length; i++) {\n var node = touches[i].target;\n if (node != null) {\n if (target.contains(node)) {\n return true;\n }\n }\n }\n return false;\n}\n\n/**\n * Ignore 'selectionchange' events that don't correspond with a person's intent to\n * select text.\n */\nexport function hasValidSelection(domEvent) {\n if (domEvent.type === 'selectionchange') {\n return isSelectionValid();\n }\n return domEvent.type === 'select';\n}\n\n/**\n * Events are only valid if the primary button was used without specific modifier keys.\n */\nexport function isPrimaryPointerDown(domEvent) {\n var altKey = domEvent.altKey,\n button = domEvent.button,\n buttons = domEvent.buttons,\n ctrlKey = domEvent.ctrlKey,\n type = domEvent.type;\n var isTouch = type === 'touchstart' || type === 'touchmove';\n var isPrimaryMouseDown = type === 'mousedown' && (button === 0 || buttons === 1);\n var isPrimaryMouseMove = type === 'mousemove' && buttons === 1;\n var noModifiers = altKey === false && ctrlKey === false;\n if (isTouch || isPrimaryMouseDown && noModifiers || isPrimaryMouseMove && noModifiers) {\n return true;\n }\n return false;\n}","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport { isStartish, isMoveish, isEndish } from './ResponderEventTypes';\n/**\n * Tracks the position and time of each active touch by `touch.identifier`. We\n * should typically only see IDs in the range of 1-20 because IDs get recycled\n * when touches end and start again.\n */\n\nvar __DEV__ = process.env.NODE_ENV !== 'production';\nvar MAX_TOUCH_BANK = 20;\nfunction timestampForTouch(touch) {\n // The legacy internal implementation provides \"timeStamp\", which has been\n // renamed to \"timestamp\".\n return touch.timeStamp || touch.timestamp;\n}\n\n/**\n * TODO: Instead of making gestures recompute filtered velocity, we could\n * include a built in velocity computation that can be reused globally.\n */\nfunction createTouchRecord(touch) {\n return {\n touchActive: true,\n startPageX: touch.pageX,\n startPageY: touch.pageY,\n startTimeStamp: timestampForTouch(touch),\n currentPageX: touch.pageX,\n currentPageY: touch.pageY,\n currentTimeStamp: timestampForTouch(touch),\n previousPageX: touch.pageX,\n previousPageY: touch.pageY,\n previousTimeStamp: timestampForTouch(touch)\n };\n}\nfunction resetTouchRecord(touchRecord, touch) {\n touchRecord.touchActive = true;\n touchRecord.startPageX = touch.pageX;\n touchRecord.startPageY = touch.pageY;\n touchRecord.startTimeStamp = timestampForTouch(touch);\n touchRecord.currentPageX = touch.pageX;\n touchRecord.currentPageY = touch.pageY;\n touchRecord.currentTimeStamp = timestampForTouch(touch);\n touchRecord.previousPageX = touch.pageX;\n touchRecord.previousPageY = touch.pageY;\n touchRecord.previousTimeStamp = timestampForTouch(touch);\n}\nfunction getTouchIdentifier(_ref) {\n var identifier = _ref.identifier;\n if (identifier == null) {\n console.error('Touch object is missing identifier.');\n }\n if (__DEV__) {\n if (identifier > MAX_TOUCH_BANK) {\n console.error('Touch identifier %s is greater than maximum supported %s which causes ' + 'performance issues backfilling array locations for all of the indices.', identifier, MAX_TOUCH_BANK);\n }\n }\n return identifier;\n}\nfunction recordTouchStart(touch, touchHistory) {\n var identifier = getTouchIdentifier(touch);\n var touchRecord = touchHistory.touchBank[identifier];\n if (touchRecord) {\n resetTouchRecord(touchRecord, touch);\n } else {\n touchHistory.touchBank[identifier] = createTouchRecord(touch);\n }\n touchHistory.mostRecentTimeStamp = timestampForTouch(touch);\n}\nfunction recordTouchMove(touch, touchHistory) {\n var touchRecord = touchHistory.touchBank[getTouchIdentifier(touch)];\n if (touchRecord) {\n touchRecord.touchActive = true;\n touchRecord.previousPageX = touchRecord.currentPageX;\n touchRecord.previousPageY = touchRecord.currentPageY;\n touchRecord.previousTimeStamp = touchRecord.currentTimeStamp;\n touchRecord.currentPageX = touch.pageX;\n touchRecord.currentPageY = touch.pageY;\n touchRecord.currentTimeStamp = timestampForTouch(touch);\n touchHistory.mostRecentTimeStamp = timestampForTouch(touch);\n } else {\n console.warn('Cannot record touch move without a touch start.\\n', \"Touch Move: \" + printTouch(touch) + \"\\n\", \"Touch Bank: \" + printTouchBank(touchHistory));\n }\n}\nfunction recordTouchEnd(touch, touchHistory) {\n var touchRecord = touchHistory.touchBank[getTouchIdentifier(touch)];\n if (touchRecord) {\n touchRecord.touchActive = false;\n touchRecord.previousPageX = touchRecord.currentPageX;\n touchRecord.previousPageY = touchRecord.currentPageY;\n touchRecord.previousTimeStamp = touchRecord.currentTimeStamp;\n touchRecord.currentPageX = touch.pageX;\n touchRecord.currentPageY = touch.pageY;\n touchRecord.currentTimeStamp = timestampForTouch(touch);\n touchHistory.mostRecentTimeStamp = timestampForTouch(touch);\n } else {\n console.warn('Cannot record touch end without a touch start.\\n', \"Touch End: \" + printTouch(touch) + \"\\n\", \"Touch Bank: \" + printTouchBank(touchHistory));\n }\n}\nfunction printTouch(touch) {\n return JSON.stringify({\n identifier: touch.identifier,\n pageX: touch.pageX,\n pageY: touch.pageY,\n timestamp: timestampForTouch(touch)\n });\n}\nfunction printTouchBank(touchHistory) {\n var touchBank = touchHistory.touchBank;\n var printed = JSON.stringify(touchBank.slice(0, MAX_TOUCH_BANK));\n if (touchBank.length > MAX_TOUCH_BANK) {\n printed += ' (original size: ' + touchBank.length + ')';\n }\n return printed;\n}\nexport class ResponderTouchHistoryStore {\n constructor() {\n this._touchHistory = {\n touchBank: [],\n //Array<TouchRecord>\n numberActiveTouches: 0,\n // If there is only one active touch, we remember its location. This prevents\n // us having to loop through all of the touches all the time in the most\n // common case.\n indexOfSingleActiveTouch: -1,\n mostRecentTimeStamp: 0\n };\n }\n recordTouchTrack(topLevelType, nativeEvent) {\n var touchHistory = this._touchHistory;\n if (isMoveish(topLevelType)) {\n nativeEvent.changedTouches.forEach(touch => recordTouchMove(touch, touchHistory));\n } else if (isStartish(topLevelType)) {\n nativeEvent.changedTouches.forEach(touch => recordTouchStart(touch, touchHistory));\n touchHistory.numberActiveTouches = nativeEvent.touches.length;\n if (touchHistory.numberActiveTouches === 1) {\n touchHistory.indexOfSingleActiveTouch = nativeEvent.touches[0].identifier;\n }\n } else if (isEndish(topLevelType)) {\n nativeEvent.changedTouches.forEach(touch => recordTouchEnd(touch, touchHistory));\n touchHistory.numberActiveTouches = nativeEvent.touches.length;\n if (touchHistory.numberActiveTouches === 1) {\n var touchBank = touchHistory.touchBank;\n for (var i = 0; i < touchBank.length; i++) {\n var touchTrackToCheck = touchBank[i];\n if (touchTrackToCheck != null && touchTrackToCheck.touchActive) {\n touchHistory.indexOfSingleActiveTouch = i;\n break;\n }\n }\n if (__DEV__) {\n var activeRecord = touchBank[touchHistory.indexOfSingleActiveTouch];\n if (!(activeRecord != null && activeRecord.touchActive)) {\n console.error('Cannot find single active touch.');\n }\n }\n }\n }\n }\n get touchHistory() {\n return this._touchHistory;\n }\n}","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\n/**\n * RESPONDER EVENT SYSTEM\n *\n * A single, global \"interaction lock\" on views. For a view to be the \"responder\" means\n * that pointer interactions are exclusive to that view and none other. The \"interaction\n * lock\" can be transferred (only) to ancestors of the current \"responder\" as long as\n * pointers continue to be active.\n *\n * Responder being granted:\n *\n * A view can become the \"responder\" after the following events:\n * * \"pointerdown\" (implemented using \"touchstart\", \"mousedown\")\n * * \"pointermove\" (implemented using \"touchmove\", \"mousemove\")\n * * \"scroll\" (while a pointer is down)\n * * \"selectionchange\" (while a pointer is down)\n *\n * If nothing is already the \"responder\", the event propagates to (capture) and from\n * (bubble) the event target until a view returns `true` for\n * `on*ShouldSetResponder(Capture)`.\n *\n * If something is already the responder, the event propagates to (capture) and from\n * (bubble) the lowest common ancestor of the event target and the current \"responder\".\n * Then negotiation happens between the current \"responder\" and a view that wants to\n * become the \"responder\": see the timing diagram below.\n *\n * (NOTE: Scrolled views either automatically become the \"responder\" or release the\n * \"interaction lock\". A native scroll view that isn't built on top of the responder\n * system must result in the current \"responder\" being notified that it no longer has\n * the \"interaction lock\" - the native system has taken over.\n *\n * Responder being released:\n *\n * As soon as there are no more active pointers that *started* inside descendants\n * of the *current* \"responder\", an `onResponderRelease` event is dispatched to the\n * current \"responder\", and the responder lock is released.\n *\n * Typical sequence of events:\n * * startShouldSetResponder\n * * responderGrant/Reject\n * * responderStart\n * * responderMove\n * * responderEnd\n * * responderRelease\n */\n\n/* Negotiation Performed\n +-----------------------+\n / \\\nProcess low level events to + Current Responder + wantsResponderID\ndetermine who to perform negot-| (if any exists at all) |\niation/transition | Otherwise just pass through|\n-------------------------------+----------------------------+------------------+\nBubble to find first ID | |\nto return true:wantsResponderID| |\n | |\n +--------------+ | |\n | onTouchStart | | |\n +------+-------+ none | |\n | return| |\n+-----------v-------------+true| +------------------------+ |\n|onStartShouldSetResponder|----->| onResponderStart (cur) |<-----------+\n+-----------+-------------+ | +------------------------+ | |\n | | | +--------+-------+\n | returned true for| false:REJECT +-------->|onResponderReject\n | wantsResponderID | | | +----------------+\n | (now attempt | +------------------+-----+ |\n | handoff) | | onResponder | |\n +------------------->| TerminationRequest | |\n | +------------------+-----+ |\n | | | +----------------+\n | true:GRANT +-------->|onResponderGrant|\n | | +--------+-------+\n | +------------------------+ | |\n | | onResponderTerminate |<-----------+\n | +------------------+-----+ |\n | | | +----------------+\n | +-------->|onResponderStart|\n | | +----------------+\nBubble to find first ID | |\nto return true:wantsResponderID| |\n | |\n +-------------+ | |\n | onTouchMove | | |\n +------+------+ none | |\n | return| |\n+-----------v-------------+true| +------------------------+ |\n|onMoveShouldSetResponder |----->| onResponderMove (cur) |<-----------+\n+-----------+-------------+ | +------------------------+ | |\n | | | +--------+-------+\n | returned true for| false:REJECT +-------->|onResponderReject\n | wantsResponderID | | | +----------------+\n | (now attempt | +------------------+-----+ |\n | handoff) | | onResponder | |\n +------------------->| TerminationRequest| |\n | +------------------+-----+ |\n | | | +----------------+\n | true:GRANT +-------->|onResponderGrant|\n | | +--------+-------+\n | +------------------------+ | |\n | | onResponderTerminate |<-----------+\n | +------------------+-----+ |\n | | | +----------------+\n | +-------->|onResponderMove |\n | | +----------------+\n | |\n | |\n Some active touch started| |\n inside current responder | +------------------------+ |\n +------------------------->| onResponderEnd | |\n | | +------------------------+ |\n +---+---------+ | |\n | onTouchEnd | | |\n +---+---------+ | |\n | | +------------------------+ |\n +------------------------->| onResponderEnd | |\n No active touches started| +-----------+------------+ |\n inside current responder | | |\n | v |\n | +------------------------+ |\n | | onResponderRelease | |\n | +------------------------+ |\n | |\n + + */\n\nimport createResponderEvent from './createResponderEvent';\nimport { isCancelish, isEndish, isMoveish, isScroll, isSelectionChange, isStartish } from './ResponderEventTypes';\nimport { getLowestCommonAncestor, getResponderPaths, hasTargetTouches, hasValidSelection, isPrimaryPointerDown, setResponderId } from './utils';\nimport { ResponderTouchHistoryStore } from './ResponderTouchHistoryStore';\nimport canUseDOM from '../canUseDom';\n\n/* ------------ TYPES ------------ */\n\nvar emptyObject = {};\n\n/* ------------ IMPLEMENTATION ------------ */\n\nvar startRegistration = ['onStartShouldSetResponderCapture', 'onStartShouldSetResponder', {\n bubbles: true\n}];\nvar moveRegistration = ['onMoveShouldSetResponderCapture', 'onMoveShouldSetResponder', {\n bubbles: true\n}];\nvar scrollRegistration = ['onScrollShouldSetResponderCapture', 'onScrollShouldSetResponder', {\n bubbles: false\n}];\nvar shouldSetResponderEvents = {\n touchstart: startRegistration,\n mousedown: startRegistration,\n touchmove: moveRegistration,\n mousemove: moveRegistration,\n scroll: scrollRegistration\n};\nvar emptyResponder = {\n id: null,\n idPath: null,\n node: null\n};\nvar responderListenersMap = new Map();\nvar isEmulatingMouseEvents = false;\nvar trackedTouchCount = 0;\nvar currentResponder = {\n id: null,\n node: null,\n idPath: null\n};\nvar responderTouchHistoryStore = new ResponderTouchHistoryStore();\nfunction changeCurrentResponder(responder) {\n currentResponder = responder;\n}\nfunction getResponderConfig(id) {\n var config = responderListenersMap.get(id);\n return config != null ? config : emptyObject;\n}\n\n/**\n * Process native events\n *\n * A single event listener is used to manage the responder system.\n * All pointers are tracked in the ResponderTouchHistoryStore. Native events\n * are interpreted in terms of the Responder System and checked to see if\n * the responder should be transferred. Each host node that is attached to\n * the Responder System has an ID, which is used to look up its associated\n * callbacks.\n */\nfunction eventListener(domEvent) {\n var eventType = domEvent.type;\n var eventTarget = domEvent.target;\n\n /**\n * Manage emulated events and early bailout.\n * Since PointerEvent is not used yet (lack of support in older Safari), it's\n * necessary to manually manage the mess of browser touch/mouse events.\n * And bailout early for termination events when there is no active responder.\n */\n\n // Flag when browser may produce emulated events\n if (eventType === 'touchstart') {\n isEmulatingMouseEvents = true;\n }\n // Remove flag when browser will not produce emulated events\n if (eventType === 'touchmove' || trackedTouchCount > 1) {\n isEmulatingMouseEvents = false;\n }\n // Ignore various events in particular circumstances\n if (\n // Ignore browser emulated mouse events\n eventType === 'mousedown' && isEmulatingMouseEvents || eventType === 'mousemove' && isEmulatingMouseEvents ||\n // Ignore mousemove if a mousedown didn't occur first\n eventType === 'mousemove' && trackedTouchCount < 1) {\n return;\n }\n // Remove flag after emulated events are finished\n if (isEmulatingMouseEvents && eventType === 'mouseup') {\n if (trackedTouchCount === 0) {\n isEmulatingMouseEvents = false;\n }\n return;\n }\n var isStartEvent = isStartish(eventType) && isPrimaryPointerDown(domEvent);\n var isMoveEvent = isMoveish(eventType);\n var isEndEvent = isEndish(eventType);\n var isScrollEvent = isScroll(eventType);\n var isSelectionChangeEvent = isSelectionChange(eventType);\n var responderEvent = createResponderEvent(domEvent, responderTouchHistoryStore);\n\n /**\n * Record the state of active pointers\n */\n\n if (isStartEvent || isMoveEvent || isEndEvent) {\n if (domEvent.touches) {\n trackedTouchCount = domEvent.touches.length;\n } else {\n if (isStartEvent) {\n trackedTouchCount = 1;\n } else if (isEndEvent) {\n trackedTouchCount = 0;\n }\n }\n responderTouchHistoryStore.recordTouchTrack(eventType, responderEvent.nativeEvent);\n }\n\n /**\n * Responder System logic\n */\n\n var eventPaths = getResponderPaths(domEvent);\n var wasNegotiated = false;\n var wantsResponder;\n\n // If an event occured that might change the current responder...\n if (isStartEvent || isMoveEvent || isScrollEvent && trackedTouchCount > 0) {\n // If there is already a responder, prune the event paths to the lowest common ancestor\n // of the existing responder and deepest target of the event.\n var currentResponderIdPath = currentResponder.idPath;\n var eventIdPath = eventPaths.idPath;\n if (currentResponderIdPath != null && eventIdPath != null) {\n var lowestCommonAncestor = getLowestCommonAncestor(currentResponderIdPath, eventIdPath);\n if (lowestCommonAncestor != null) {\n var indexOfLowestCommonAncestor = eventIdPath.indexOf(lowestCommonAncestor);\n // Skip the current responder so it doesn't receive unexpected \"shouldSet\" events.\n var index = indexOfLowestCommonAncestor + (lowestCommonAncestor === currentResponder.id ? 1 : 0);\n eventPaths = {\n idPath: eventIdPath.slice(index),\n nodePath: eventPaths.nodePath.slice(index)\n };\n } else {\n eventPaths = null;\n }\n }\n if (eventPaths != null) {\n // If a node wants to become the responder, attempt to transfer.\n wantsResponder = findWantsResponder(eventPaths, domEvent, responderEvent);\n if (wantsResponder != null) {\n // Sets responder if none exists, or negotates with existing responder.\n attemptTransfer(responderEvent, wantsResponder);\n wasNegotiated = true;\n }\n }\n }\n\n // If there is now a responder, invoke its callbacks for the lifecycle of the gesture.\n if (currentResponder.id != null && currentResponder.node != null) {\n var _currentResponder = currentResponder,\n id = _currentResponder.id,\n node = _currentResponder.node;\n var _getResponderConfig = getResponderConfig(id),\n onResponderStart = _getResponderConfig.onResponderStart,\n onResponderMove = _getResponderConfig.onResponderMove,\n onResponderEnd = _getResponderConfig.onResponderEnd,\n onResponderRelease = _getResponderConfig.onResponderRelease,\n onResponderTerminate = _getResponderConfig.onResponderTerminate,\n onResponderTerminationRequest = _getResponderConfig.onResponderTerminationRequest;\n responderEvent.bubbles = false;\n responderEvent.cancelable = false;\n responderEvent.currentTarget = node;\n\n // Start\n if (isStartEvent) {\n if (onResponderStart != null) {\n responderEvent.dispatchConfig.registrationName = 'onResponderStart';\n onResponderStart(responderEvent);\n }\n }\n // Move\n else if (isMoveEvent) {\n if (onResponderMove != null) {\n responderEvent.dispatchConfig.registrationName = 'onResponderMove';\n onResponderMove(responderEvent);\n }\n } else {\n var isTerminateEvent = isCancelish(eventType) ||\n // native context menu\n eventType === 'contextmenu' ||\n // window blur\n eventType === 'blur' && eventTarget === window ||\n // responder (or ancestors) blur\n eventType === 'blur' && eventTarget.contains(node) && domEvent.relatedTarget !== node ||\n // native scroll without using a pointer\n isScrollEvent && trackedTouchCount === 0 ||\n // native scroll on node that is parent of the responder (allow siblings to scroll)\n isScrollEvent && eventTarget.contains(node) && eventTarget !== node ||\n // native select/selectionchange on node\n isSelectionChangeEvent && hasValidSelection(domEvent);\n var isReleaseEvent = isEndEvent && !isTerminateEvent && !hasTargetTouches(node, domEvent.touches);\n\n // End\n if (isEndEvent) {\n if (onResponderEnd != null) {\n responderEvent.dispatchConfig.registrationName = 'onResponderEnd';\n onResponderEnd(responderEvent);\n }\n }\n // Release\n if (isReleaseEvent) {\n if (onResponderRelease != null) {\n responderEvent.dispatchConfig.registrationName = 'onResponderRelease';\n onResponderRelease(responderEvent);\n }\n changeCurrentResponder(emptyResponder);\n }\n // Terminate\n if (isTerminateEvent) {\n var shouldTerminate = true;\n\n // Responders can still avoid termination but only for these events.\n if (eventType === 'contextmenu' || eventType === 'scroll' || eventType === 'selectionchange') {\n // Only call this function is it wasn't already called during negotiation.\n if (wasNegotiated) {\n shouldTerminate = false;\n } else if (onResponderTerminationRequest != null) {\n responderEvent.dispatchConfig.registrationName = 'onResponderTerminationRequest';\n if (onResponderTerminationRequest(responderEvent) === false) {\n shouldTerminate = false;\n }\n }\n }\n if (shouldTerminate) {\n if (onResponderTerminate != null) {\n responderEvent.dispatchConfig.registrationName = 'onResponderTerminate';\n onResponderTerminate(responderEvent);\n }\n changeCurrentResponder(emptyResponder);\n isEmulatingMouseEvents = false;\n trackedTouchCount = 0;\n }\n }\n }\n }\n}\n\n/**\n * Walk the event path to/from the target node. At each node, stop and call the\n * relevant \"shouldSet\" functions for the given event type. If any of those functions\n * call \"stopPropagation\" on the event, stop searching for a responder.\n */\nfunction findWantsResponder(eventPaths, domEvent, responderEvent) {\n var shouldSetCallbacks = shouldSetResponderEvents[domEvent.type]; // for Flow\n\n if (shouldSetCallbacks != null) {\n var idPath = eventPaths.idPath,\n nodePath = eventPaths.nodePath;\n var shouldSetCallbackCaptureName = shouldSetCallbacks[0];\n var shouldSetCallbackBubbleName = shouldSetCallbacks[1];\n var bubbles = shouldSetCallbacks[2].bubbles;\n var check = function check(id, node, callbackName) {\n var config = getResponderConfig(id);\n var shouldSetCallback = config[callbackName];\n if (shouldSetCallback != null) {\n responderEvent.currentTarget = node;\n if (shouldSetCallback(responderEvent) === true) {\n // Start the path from the potential responder\n var prunedIdPath = idPath.slice(idPath.indexOf(id));\n return {\n id,\n node,\n idPath: prunedIdPath\n };\n }\n }\n };\n\n // capture\n for (var i = idPath.length - 1; i >= 0; i--) {\n var id = idPath[i];\n var node = nodePath[i];\n var result = check(id, node, shouldSetCallbackCaptureName);\n if (result != null) {\n return result;\n }\n if (responderEvent.isPropagationStopped() === true) {\n return;\n }\n }\n\n // bubble\n if (bubbles) {\n for (var _i = 0; _i < idPath.length; _i++) {\n var _id = idPath[_i];\n var _node = nodePath[_i];\n var _result = check(_id, _node, shouldSetCallbackBubbleName);\n if (_result != null) {\n return _result;\n }\n if (responderEvent.isPropagationStopped() === true) {\n return;\n }\n }\n } else {\n var _id2 = idPath[0];\n var _node2 = nodePath[0];\n var target = domEvent.target;\n if (target === _node2) {\n return check(_id2, _node2, shouldSetCallbackBubbleName);\n }\n }\n }\n}\n\n/**\n * Attempt to transfer the responder.\n */\nfunction attemptTransfer(responderEvent, wantsResponder) {\n var _currentResponder2 = currentResponder,\n currentId = _currentResponder2.id,\n currentNode = _currentResponder2.node;\n var id = wantsResponder.id,\n node = wantsResponder.node;\n var _getResponderConfig2 = getResponderConfig(id),\n onResponderGrant = _getResponderConfig2.onResponderGrant,\n onResponderReject = _getResponderConfig2.onResponderReject;\n responderEvent.bubbles = false;\n responderEvent.cancelable = false;\n responderEvent.currentTarget = node;\n\n // Set responder\n if (currentId == null) {\n if (onResponderGrant != null) {\n responderEvent.currentTarget = node;\n responderEvent.dispatchConfig.registrationName = 'onResponderGrant';\n onResponderGrant(responderEvent);\n }\n changeCurrentResponder(wantsResponder);\n }\n // Negotiate with current responder\n else {\n var _getResponderConfig3 = getResponderConfig(currentId),\n onResponderTerminate = _getResponderConfig3.onResponderTerminate,\n onResponderTerminationRequest = _getResponderConfig3.onResponderTerminationRequest;\n var allowTransfer = true;\n if (onResponderTerminationRequest != null) {\n responderEvent.currentTarget = currentNode;\n responderEvent.dispatchConfig.registrationName = 'onResponderTerminationRequest';\n if (onResponderTerminationRequest(responderEvent) === false) {\n allowTransfer = false;\n }\n }\n if (allowTransfer) {\n // Terminate existing responder\n if (onResponderTerminate != null) {\n responderEvent.currentTarget = currentNode;\n responderEvent.dispatchConfig.registrationName = 'onResponderTerminate';\n onResponderTerminate(responderEvent);\n }\n // Grant next responder\n if (onResponderGrant != null) {\n responderEvent.currentTarget = node;\n responderEvent.dispatchConfig.registrationName = 'onResponderGrant';\n onResponderGrant(responderEvent);\n }\n changeCurrentResponder(wantsResponder);\n } else {\n // Reject responder request\n if (onResponderReject != null) {\n responderEvent.currentTarget = node;\n responderEvent.dispatchConfig.registrationName = 'onResponderReject';\n onResponderReject(responderEvent);\n }\n }\n }\n}\n\n/* ------------ PUBLIC API ------------ */\n\n/**\n * Attach Listeners\n *\n * Use native events as ReactDOM doesn't have a non-plugin API to implement\n * this system.\n */\nvar documentEventsCapturePhase = ['blur', 'scroll'];\nvar documentEventsBubblePhase = [\n// mouse\n'mousedown', 'mousemove', 'mouseup', 'dragstart',\n// touch\n'touchstart', 'touchmove', 'touchend', 'touchcancel',\n// other\n'contextmenu', 'select', 'selectionchange'];\nexport function attachListeners() {\n if (canUseDOM && window.__reactResponderSystemActive == null) {\n window.addEventListener('blur', eventListener);\n documentEventsBubblePhase.forEach(eventType => {\n document.addEventListener(eventType, eventListener);\n });\n documentEventsCapturePhase.forEach(eventType => {\n document.addEventListener(eventType, eventListener, true);\n });\n window.__reactResponderSystemActive = true;\n }\n}\n\n/**\n * Register a node with the ResponderSystem.\n */\nexport function addNode(id, node, config) {\n setResponderId(node, id);\n responderListenersMap.set(id, config);\n}\n\n/**\n * Unregister a node with the ResponderSystem.\n */\nexport function removeNode(id) {\n if (currentResponder.id === id) {\n terminateResponder();\n }\n if (responderListenersMap.has(id)) {\n responderListenersMap.delete(id);\n }\n}\n\n/**\n * Allow the current responder to be terminated from within components to support\n * more complex requirements, such as use with other React libraries for working\n * with scroll views, input views, etc.\n */\nexport function terminateResponder() {\n var _currentResponder3 = currentResponder,\n id = _currentResponder3.id,\n node = _currentResponder3.node;\n if (id != null && node != null) {\n var _getResponderConfig4 = getResponderConfig(id),\n onResponderTerminate = _getResponderConfig4.onResponderTerminate;\n if (onResponderTerminate != null) {\n var event = createResponderEvent({}, responderTouchHistoryStore);\n event.currentTarget = node;\n onResponderTerminate(event);\n }\n changeCurrentResponder(emptyResponder);\n }\n isEmulatingMouseEvents = false;\n trackedTouchCount = 0;\n}\n\n/**\n * Allow unit tests to inspect the current responder in the system.\n * FOR TESTING ONLY.\n */\nexport function getResponderNode() {\n return currentResponder.node;\n}","/**\n * Copyright (c) Nicolas Gallagher\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\n/**\n * Hook for integrating the Responder System into React\n *\n * function SomeComponent({ onStartShouldSetResponder }) {\n * const ref = useRef(null);\n * useResponderEvents(ref, { onStartShouldSetResponder });\n * return <div ref={ref} />\n * }\n */\n\nimport * as React from 'react';\nimport * as ResponderSystem from './ResponderSystem';\nvar emptyObject = {};\nvar idCounter = 0;\nfunction useStable(getInitialValue) {\n var ref = React.useRef(null);\n if (ref.current == null) {\n ref.current = getInitialValue();\n }\n return ref.current;\n}\nexport default function useResponderEvents(hostRef, config) {\n if (config === void 0) {\n config = emptyObject;\n }\n var id = useStable(() => idCounter++);\n var isAttachedRef = React.useRef(false);\n\n // This is a separate effects so it doesn't run when the config changes.\n // On initial mount, attach global listeners if needed.\n // On unmount, remove node potentially attached to the Responder System.\n React.useEffect(() => {\n ResponderSystem.attachListeners();\n return () => {\n ResponderSystem.removeNode(id);\n };\n }, [id]);\n\n // Register and unregister with the Responder System as necessary\n React.useEffect(() => {\n var _config = config,\n onMoveShouldSetResponder = _config.onMoveShouldSetResponder,\n onMoveShouldSetResponderCapture = _config.onMoveShouldSetResponderCapture,\n onScrollShouldSetResponder = _config.onScrollShouldSetResponder,\n onScrollShouldSetResponderCapture = _config.onScrollShouldSetResponderCapture,\n onSelectionChangeShouldSetResponder = _config.onSelectionChangeShouldSetResponder,\n onSelectionChangeShouldSetResponderCapture = _config.onSelectionChangeShouldSetResponderCapture,\n onStartShouldSetResponder = _config.onStartShouldSetResponder,\n onStartShouldSetResponderCapture = _config.onStartShouldSetResponderCapture;\n var requiresResponderSystem = onMoveShouldSetResponder != null || onMoveShouldSetResponderCapture != null || onScrollShouldSetResponder != null || onScrollShouldSetResponderCapture != null || onSelectionChangeShouldSetResponder != null || onSelectionChangeShouldSetResponderCapture != null || onStartShouldSetResponder != null || onStartShouldSetResponderCapture != null;\n var node = hostRef.current;\n if (requiresResponderSystem) {\n ResponderSystem.addNode(id, node, config);\n isAttachedRef.current = true;\n } else if (isAttachedRef.current) {\n ResponderSystem.removeNode(id);\n isAttachedRef.current = false;\n }\n }, [config, hostRef, id]);\n React.useDebugValue({\n isResponder: hostRef.current === ResponderSystem.getResponderNode()\n });\n React.useDebugValue(config);\n}","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\n'use client';\n\nimport { createContext } from 'react';\nvar TextAncestorContext = /*#__PURE__*/createContext(false);\nexport default TextAncestorContext;","/**\n * Copyright (c) Nicolas Gallagher.\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\n'use client';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nvar _excluded = [\"hrefAttrs\", \"onLayout\", \"onMoveShouldSetResponder\", \"onMoveShouldSetResponderCapture\", \"onResponderEnd\", \"onResponderGrant\", \"onResponderMove\", \"onResponderReject\", \"onResponderRelease\", \"onResponderStart\", \"onResponderTerminate\", \"onResponderTerminationRequest\", \"onScrollShouldSetResponder\", \"onScrollShouldSetResponderCapture\", \"onSelectionChangeShouldSetResponder\", \"onSelectionChangeShouldSetResponderCapture\", \"onStartShouldSetResponder\", \"onStartShouldSetResponderCapture\"];\nimport * as React from 'react';\nimport createElement from '../createElement';\nimport * as forwardedProps from '../../modules/forwardedProps';\nimport pick from '../../modules/pick';\nimport useElementLayout from '../../modules/useElementLayout';\nimport useMergeRefs from '../../modules/useMergeRefs';\nimport usePlatformMethods from '../../modules/usePlatformMethods';\nimport useResponderEvents from '../../modules/useResponderEvents';\nimport StyleSheet from '../StyleSheet';\nimport TextAncestorContext from '../Text/TextAncestorContext';\nimport { useLocaleContext, getLocaleDirection } from '../../modules/useLocale';\nvar forwardPropsList = Object.assign({}, forwardedProps.defaultProps, forwardedProps.accessibilityProps, forwardedProps.clickProps, forwardedProps.focusProps, forwardedProps.keyboardProps, forwardedProps.mouseProps, forwardedProps.touchProps, forwardedProps.styleProps, {\n href: true,\n lang: true,\n onScroll: true,\n onWheel: true,\n pointerEvents: true\n});\nvar pickProps = props => pick(props, forwardPropsList);\nvar View = /*#__PURE__*/React.forwardRef((props, forwardedRef) => {\n var hrefAttrs = props.hrefAttrs,\n onLayout = props.onLayout,\n onMoveShouldSetResponder = props.onMoveShouldSetResponder,\n onMoveShouldSetResponderCapture = props.onMoveShouldSetResponderCapture,\n onResponderEnd = props.onResponderEnd,\n onResponderGrant = props.onResponderGrant,\n onResponderMove = props.onResponderMove,\n onResponderReject = props.onResponderReject,\n onResponderRelease = props.onResponderRelease,\n onResponderStart = props.onResponderStart,\n onResponderTerminate = props.onResponderTerminate,\n onResponderTerminationRequest = props.onResponderTerminationRequest,\n onScrollShouldSetResponder = props.onScrollShouldSetResponder,\n onScrollShouldSetResponderCapture = props.onScrollShouldSetResponderCapture,\n onSelectionChangeShouldSetResponder = props.onSelectionChangeShouldSetResponder,\n onSelectionChangeShouldSetResponderCapture = props.onSelectionChangeShouldSetResponderCapture,\n onStartShouldSetResponder = props.onStartShouldSetResponder,\n onStartShouldSetResponderCapture = props.onStartShouldSetResponderCapture,\n rest = _objectWithoutPropertiesLoose(props, _excluded);\n if (process.env.NODE_ENV !== 'production') {\n React.Children.toArray(props.children).forEach(item => {\n if (typeof item === 'string') {\n console.error(\"Unexpected text node: \" + item + \". A text node cannot be a child of a <View>.\");\n }\n });\n }\n var hasTextAncestor = React.useContext(TextAncestorContext);\n var hostRef = React.useRef(null);\n var _useLocaleContext = useLocaleContext(),\n contextDirection = _useLocaleContext.direction;\n useElementLayout(hostRef, onLayout);\n useResponderEvents(hostRef, {\n onMoveShouldSetResponder,\n onMoveShouldSetResponderCapture,\n onResponderEnd,\n onResponderGrant,\n onResponderMove,\n onResponderReject,\n onResponderRelease,\n onResponderStart,\n onResponderTerminate,\n onResponderTerminationRequest,\n onScrollShouldSetResponder,\n onScrollShouldSetResponderCapture,\n onSelectionChangeShouldSetResponder,\n onSelectionChangeShouldSetResponderCapture,\n onStartShouldSetResponder,\n onStartShouldSetResponderCapture\n });\n var component = 'div';\n var langDirection = props.lang != null ? getLocaleDirection(props.lang) : null;\n var componentDirection = props.dir || langDirection;\n var writingDirection = componentDirection || contextDirection;\n var supportedProps = pickProps(rest);\n supportedProps.dir = componentDirection;\n supportedProps.style = [styles.view$raw, hasTextAncestor && styles.inline, props.style];\n if (props.href != null) {\n component = 'a';\n if (hrefAttrs != null) {\n var download = hrefAttrs.download,\n rel = hrefAttrs.rel,\n target = hrefAttrs.target;\n if (download != null) {\n supportedProps.download = download;\n }\n if (rel != null) {\n supportedProps.rel = rel;\n }\n if (typeof target === 'string') {\n supportedProps.target = target.charAt(0) !== '_' ? '_' + target : target;\n }\n }\n }\n var platformMethodsRef = usePlatformMethods(supportedProps);\n var setRef = useMergeRefs(hostRef, platformMethodsRef, forwardedRef);\n supportedProps.ref = setRef;\n return createElement(component, supportedProps, {\n writingDirection\n });\n});\nView.displayName = 'View';\nvar styles = StyleSheet.create({\n view$raw: {\n alignContent: 'flex-start',\n alignItems: 'stretch',\n backgroundColor: 'transparent',\n border: '0 solid black',\n boxSizing: 'border-box',\n display: 'flex',\n flexBasis: 'auto',\n flexDirection: 'column',\n flexShrink: 0,\n listStyle: 'none',\n margin: 0,\n minHeight: 0,\n minWidth: 0,\n padding: 0,\n position: 'relative',\n textDecoration: 'none',\n zIndex: 0\n },\n inline: {\n display: 'inline-flex'\n }\n});\nexport default View;","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n'use strict';\n\nvar validateFormat = process.env.NODE_ENV !== \"production\" ? function (format) {\n if (format === undefined) {\n throw new Error('invariant(...): Second argument must be a string.');\n }\n} : function (format) {};\n/**\n * Use invariant() to assert state which your program assumes to be true.\n *\n * Provide sprintf-style format (only %s is supported) and arguments to provide\n * information about what broke and what you were expecting.\n *\n * The invariant message will be stripped in production, but the invariant will\n * remain to ensure logic does not differ in production.\n */\n\nfunction invariant(condition, format) {\n for (var _len = arguments.length, args = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {\n args[_key - 2] = arguments[_key];\n }\n\n validateFormat(format);\n\n if (!condition) {\n var error;\n\n if (format === undefined) {\n error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.');\n } else {\n var argIndex = 0;\n error = new Error(format.replace(/%s/g, function () {\n return String(args[argIndex++]);\n }));\n error.name = 'Invariant Violation';\n }\n\n error.framesToPop = 1; // Skip invariant's own stack frame.\n\n throw error;\n }\n}\n\nmodule.exports = invariant;","/**\n * Copyright (c) Nicolas Gallagher.\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\n'use client';\n\nimport invariant from 'fbjs/lib/invariant';\nimport canUseDOM from '../../modules/canUseDom';\nvar dimensions = {\n window: {\n fontScale: 1,\n height: 0,\n scale: 1,\n width: 0\n },\n screen: {\n fontScale: 1,\n height: 0,\n scale: 1,\n width: 0\n }\n};\nvar listeners = {};\nvar shouldInit = canUseDOM;\nfunction update() {\n if (!canUseDOM) {\n return;\n }\n var win = window;\n var height;\n var width;\n\n /**\n * iOS does not update viewport dimensions on keyboard open/close.\n * window.visualViewport(https://developer.mozilla.org/en-US/docs/Web/API/VisualViewport)\n * is used instead of document.documentElement.clientHeight (which remains as a fallback)\n */\n if (win.visualViewport) {\n var visualViewport = win.visualViewport;\n /**\n * We are multiplying by scale because height and width from visual viewport\n * also react to pinch zoom, and become smaller when zoomed. But it is not desired\n * behaviour, since originally documentElement client height and width were used,\n * and they do not react to pinch zoom.\n */\n height = Math.round(visualViewport.height * visualViewport.scale);\n width = Math.round(visualViewport.width * visualViewport.scale);\n } else {\n var docEl = win.document.documentElement;\n height = docEl.clientHeight;\n width = docEl.clientWidth;\n }\n dimensions.window = {\n fontScale: 1,\n height,\n scale: win.devicePixelRatio || 1,\n width\n };\n dimensions.screen = {\n fontScale: 1,\n height: win.screen.height,\n scale: win.devicePixelRatio || 1,\n width: win.screen.width\n };\n}\nfunction handleResize() {\n update();\n if (Array.isArray(listeners['change'])) {\n listeners['change'].forEach(handler => handler(dimensions));\n }\n}\nexport default class Dimensions {\n static get(dimension) {\n if (shouldInit) {\n shouldInit = false;\n update();\n }\n invariant(dimensions[dimension], \"No dimension set for key \" + dimension);\n return dimensions[dimension];\n }\n static set(initialDimensions) {\n if (initialDimensions) {\n if (canUseDOM) {\n invariant(false, 'Dimensions cannot be set in the browser');\n } else {\n if (initialDimensions.screen != null) {\n dimensions.screen = initialDimensions.screen;\n }\n if (initialDimensions.window != null) {\n dimensions.window = initialDimensions.window;\n }\n }\n }\n }\n static addEventListener(type, handler) {\n listeners[type] = listeners[type] || [];\n listeners[type].push(handler);\n return {\n remove: () => {\n this.removeEventListener(type, handler);\n }\n };\n }\n static removeEventListener(type, handler) {\n if (Array.isArray(listeners[type])) {\n listeners[type] = listeners[type].filter(_handler => _handler !== handler);\n }\n }\n}\nif (canUseDOM) {\n if (window.visualViewport) {\n window.visualViewport.addEventListener('resize', handleResize, false);\n } else {\n window.addEventListener('resize', handleResize, false);\n }\n}","/**\n * Copyright (c) Nicolas Gallagher.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nvar assets = [];\nexport function registerAsset(asset) {\n // `push` returns new array length, so the first asset will\n // get id 1 (not 0) to make the value truthy\n return assets.push(asset);\n}\nexport function getAssetByID(assetId) {\n return assets[assetId - 1];\n}","/**\n * Copyright (c) Nicolas Gallagher.\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport Dimensions from '../Dimensions';\n\n/**\n * PixelRatio gives access to the device pixel density.\n */\nexport default class PixelRatio {\n /**\n * Returns the device pixel density.\n */\n static get() {\n return Dimensions.get('window').scale;\n }\n\n /**\n * No equivalent for Web\n */\n static getFontScale() {\n return Dimensions.get('window').fontScale || PixelRatio.get();\n }\n\n /**\n * Converts a layout size (dp) to pixel size (px).\n * Guaranteed to return an integer number.\n */\n static getPixelSizeForLayoutSize(layoutSize) {\n return Math.round(layoutSize * PixelRatio.get());\n }\n\n /**\n * Rounds a layout size (dp) to the nearest layout size that corresponds to\n * an integer number of pixels. For example, on a device with a PixelRatio\n * of 3, `PixelRatio.roundToNearestPixel(8.4) = 8.33`, which corresponds to\n * exactly (8.33 * 3) = 25 pixels.\n */\n static roundToNearestPixel(layoutSize) {\n var ratio = PixelRatio.get();\n return Math.round(layoutSize * ratio) / ratio;\n }\n}","/* eslint-disable */\n\n/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * From React 16.0.0\n */\n\nimport invariant from 'fbjs/lib/invariant';\nvar twoArgumentPooler = function twoArgumentPooler(a1, a2) {\n var Klass = this;\n if (Klass.instancePool.length) {\n var instance = Klass.instancePool.pop();\n Klass.call(instance, a1, a2);\n return instance;\n } else {\n return new Klass(a1, a2);\n }\n};\nvar standardReleaser = function standardReleaser(instance) {\n var Klass = this;\n instance.destructor();\n if (Klass.instancePool.length < Klass.poolSize) {\n Klass.instancePool.push(instance);\n }\n};\nvar DEFAULT_POOL_SIZE = 10;\nvar DEFAULT_POOLER = twoArgumentPooler;\n\n/**\n * Augments `CopyConstructor` to be a poolable class, augmenting only the class\n * itself (statically) not adding any prototypical fields. Any CopyConstructor\n * you give this may have a `poolSize` property, and will look for a\n * prototypical `destructor` on instances.\n *\n * @param {Function} CopyConstructor Constructor that can be used to reset.\n * @param {Function} pooler Customizable pooler.\n */\nvar addPoolingTo = function addPoolingTo(CopyConstructor, pooler) {\n // Casting as any so that flow ignores the actual implementation and trusts\n // it to match the type we declared\n var NewKlass = CopyConstructor;\n NewKlass.instancePool = [];\n NewKlass.getPooled = pooler || DEFAULT_POOLER;\n if (!NewKlass.poolSize) {\n NewKlass.poolSize = DEFAULT_POOL_SIZE;\n }\n NewKlass.release = standardReleaser;\n return NewKlass;\n};\nvar PooledClass = {\n addPoolingTo: addPoolingTo,\n twoArgumentPooler: twoArgumentPooler\n};\nexport default PooledClass;","/**\n * Copyright (c) Nicolas Gallagher.\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport PooledClass from '../../vendor/react-native/PooledClass';\nvar twoArgumentPooler = PooledClass.twoArgumentPooler;\n\n/**\n * PooledClass representing the bounding rectangle of a region.\n */\nfunction BoundingDimensions(width, height) {\n this.width = width;\n this.height = height;\n}\nBoundingDimensions.prototype.destructor = function () {\n this.width = null;\n this.height = null;\n};\nBoundingDimensions.getPooledFromElement = function (element) {\n return BoundingDimensions.getPooled(element.offsetWidth, element.offsetHeight);\n};\nPooledClass.addPoolingTo(BoundingDimensions, twoArgumentPooler);\nexport default BoundingDimensions;","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\n\nimport PooledClass from '../../vendor/react-native/PooledClass';\nvar twoArgumentPooler = PooledClass.twoArgumentPooler;\nfunction Position(left, top) {\n this.left = left;\n this.top = top;\n}\nPosition.prototype.destructor = function () {\n this.left = null;\n this.top = null;\n};\nPooledClass.addPoolingTo(Position, twoArgumentPooler);\nexport default Position;","/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n * @format\n */\n\n'use strict';\n\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nimport _objectSpread from \"@babel/runtime/helpers/objectSpread2\";\nimport AccessibilityUtil from '../../modules/AccessibilityUtil';\nimport BoundingDimensions from './BoundingDimensions';\nimport normalizeColor from '@react-native/normalize-colors';\nimport Position from './Position';\nimport React from 'react';\nimport UIManager from '../UIManager';\nimport View from '../View';\nimport { warnOnce } from '../../modules/warnOnce';\nvar extractSingleTouch = nativeEvent => {\n var touches = nativeEvent.touches;\n var changedTouches = nativeEvent.changedTouches;\n var hasTouches = touches && touches.length > 0;\n var hasChangedTouches = changedTouches && changedTouches.length > 0;\n return !hasTouches && hasChangedTouches ? changedTouches[0] : hasTouches ? touches[0] : nativeEvent;\n};\n\n/**\n * `Touchable`: Taps done right.\n *\n * You hook your `ResponderEventPlugin` events into `Touchable`. `Touchable`\n * will measure time/geometry and tells you when to give feedback to the user.\n *\n * ====================== Touchable Tutorial ===============================\n * The `Touchable` mixin helps you handle the \"press\" interaction. It analyzes\n * the geometry of elements, and observes when another responder (scroll view\n * etc) has stolen the touch lock. It notifies your component when it should\n * give feedback to the user. (bouncing/highlighting/unhighlighting).\n *\n * - When a touch was activated (typically you highlight)\n * - When a touch was deactivated (typically you unhighlight)\n * - When a touch was \"pressed\" - a touch ended while still within the geometry\n * of the element, and no other element (like scroller) has \"stolen\" touch\n * lock (\"responder\") (Typically you bounce the element).\n *\n * A good tap interaction isn't as simple as you might think. There should be a\n * slight delay before showing a highlight when starting a touch. If a\n * subsequent touch move exceeds the boundary of the element, it should\n * unhighlight, but if that same touch is brought back within the boundary, it\n * should rehighlight again. A touch can move in and out of that boundary\n * several times, each time toggling highlighting, but a \"press\" is only\n * triggered if that touch ends while within the element's boundary and no\n * scroller (or anything else) has stolen the lock on touches.\n *\n * To create a new type of component that handles interaction using the\n * `Touchable` mixin, do the following:\n *\n * - Initialize the `Touchable` state.\n *\n * getInitialState: function() {\n * return merge(this.touchableGetInitialState(), yourComponentState);\n * }\n *\n * - Add a method to get your touchable component's node.\n * getTouchableNode: function() {\n * return this.touchableRef.current\n * }\n *\n * - Choose the rendered component who's touches should start the interactive\n * sequence. On that rendered node, forward all `Touchable` responder\n * handlers. You can choose any rendered node you like. Choose a node whose\n * hit target you'd like to instigate the interaction sequence:\n *\n * // In render function:\n * return (\n * <View\n * ref={this.touchableRef}\n * onStartShouldSetResponder={this.touchableHandleStartShouldSetResponder}\n * onResponderTerminationRequest={this.touchableHandleResponderTerminationRequest}\n * onResponderGrant={this.touchableHandleResponderGrant}\n * onResponderMove={this.touchableHandleResponderMove}\n * onResponderRelease={this.touchableHandleResponderRelease}\n * onResponderTerminate={this.touchableHandleResponderTerminate}>\n * <View>\n * Even though the hit detection/interactions are triggered by the\n * wrapping (typically larger) node, we usually end up implementing\n * custom logic that highlights this inner one.\n * </View>\n * </View>\n * );\n *\n * - You may set up your own handlers for each of these events, so long as you\n * also invoke the `touchable*` handlers inside of your custom handler.\n *\n * - Implement the handlers on your component class in order to provide\n * feedback to the user. See documentation for each of these class methods\n * that you should implement.\n *\n * touchableHandlePress: function() {\n * this.performBounceAnimation(); // or whatever you want to do.\n * },\n * touchableHandleActivePressIn: function() {\n * this.beginHighlighting(...); // Whatever you like to convey activation\n * },\n * touchableHandleActivePressOut: function() {\n * this.endHighlighting(...); // Whatever you like to convey deactivation\n * },\n *\n * - There are more advanced methods you can implement (see documentation below):\n * touchableGetHighlightDelayMS: function() {\n * return 20;\n * }\n * // In practice, *always* use a predeclared constant (conserve memory).\n * touchableGetPressRectOffset: function() {\n * return {top: 20, left: 20, right: 20, bottom: 100};\n * }\n */\n\n/**\n * Touchable states.\n */\n\nvar States = {\n NOT_RESPONDER: 'NOT_RESPONDER',\n // Not the responder\n RESPONDER_INACTIVE_PRESS_IN: 'RESPONDER_INACTIVE_PRESS_IN',\n // Responder, inactive, in the `PressRect`\n RESPONDER_INACTIVE_PRESS_OUT: 'RESPONDER_INACTIVE_PRESS_OUT',\n // Responder, inactive, out of `PressRect`\n RESPONDER_ACTIVE_PRESS_IN: 'RESPONDER_ACTIVE_PRESS_IN',\n // Responder, active, in the `PressRect`\n RESPONDER_ACTIVE_PRESS_OUT: 'RESPONDER_ACTIVE_PRESS_OUT',\n // Responder, active, out of `PressRect`\n RESPONDER_ACTIVE_LONG_PRESS_IN: 'RESPONDER_ACTIVE_LONG_PRESS_IN',\n // Responder, active, in the `PressRect`, after long press threshold\n RESPONDER_ACTIVE_LONG_PRESS_OUT: 'RESPONDER_ACTIVE_LONG_PRESS_OUT',\n // Responder, active, out of `PressRect`, after long press threshold\n ERROR: 'ERROR'\n};\n/*\n * Quick lookup map for states that are considered to be \"active\"\n */\n\nvar baseStatesConditions = {\n NOT_RESPONDER: false,\n RESPONDER_INACTIVE_PRESS_IN: false,\n RESPONDER_INACTIVE_PRESS_OUT: false,\n RESPONDER_ACTIVE_PRESS_IN: false,\n RESPONDER_ACTIVE_PRESS_OUT: false,\n RESPONDER_ACTIVE_LONG_PRESS_IN: false,\n RESPONDER_ACTIVE_LONG_PRESS_OUT: false,\n ERROR: false\n};\nvar IsActive = _objectSpread(_objectSpread({}, baseStatesConditions), {}, {\n RESPONDER_ACTIVE_PRESS_OUT: true,\n RESPONDER_ACTIVE_PRESS_IN: true\n});\n\n/**\n * Quick lookup for states that are considered to be \"pressing\" and are\n * therefore eligible to result in a \"selection\" if the press stops.\n */\nvar IsPressingIn = _objectSpread(_objectSpread({}, baseStatesConditions), {}, {\n RESPONDER_INACTIVE_PRESS_IN: true,\n RESPONDER_ACTIVE_PRESS_IN: true,\n RESPONDER_ACTIVE_LONG_PRESS_IN: true\n});\nvar IsLongPressingIn = _objectSpread(_objectSpread({}, baseStatesConditions), {}, {\n RESPONDER_ACTIVE_LONG_PRESS_IN: true\n});\n\n/**\n * Inputs to the state machine.\n */\nvar Signals = {\n DELAY: 'DELAY',\n RESPONDER_GRANT: 'RESPONDER_GRANT',\n RESPONDER_RELEASE: 'RESPONDER_RELEASE',\n RESPONDER_TERMINATED: 'RESPONDER_TERMINATED',\n ENTER_PRESS_RECT: 'ENTER_PRESS_RECT',\n LEAVE_PRESS_RECT: 'LEAVE_PRESS_RECT',\n LONG_PRESS_DETECTED: 'LONG_PRESS_DETECTED'\n};\n/**\n * Mapping from States x Signals => States\n */\nvar Transitions = {\n NOT_RESPONDER: {\n DELAY: States.ERROR,\n RESPONDER_GRANT: States.RESPONDER_INACTIVE_PRESS_IN,\n RESPONDER_RELEASE: States.ERROR,\n RESPONDER_TERMINATED: States.ERROR,\n ENTER_PRESS_RECT: States.ERROR,\n LEAVE_PRESS_RECT: States.ERROR,\n LONG_PRESS_DETECTED: States.ERROR\n },\n RESPONDER_INACTIVE_PRESS_IN: {\n DELAY: States.RESPONDER_ACTIVE_PRESS_IN,\n RESPONDER_GRANT: States.ERROR,\n RESPONDER_RELEASE: States.NOT_RESPONDER,\n RESPONDER_TERMINATED: States.NOT_RESPONDER,\n ENTER_PRESS_RECT: States.RESPONDER_INACTIVE_PRESS_IN,\n LEAVE_PRESS_RECT: States.RESPONDER_INACTIVE_PRESS_OUT,\n LONG_PRESS_DETECTED: States.ERROR\n },\n RESPONDER_INACTIVE_PRESS_OUT: {\n DELAY: States.RESPONDER_ACTIVE_PRESS_OUT,\n RESPONDER_GRANT: States.ERROR,\n RESPONDER_RELEASE: States.NOT_RESPONDER,\n RESPONDER_TERMINATED: States.NOT_RESPONDER,\n ENTER_PRESS_RECT: States.RESPONDER_INACTIVE_PRESS_IN,\n LEAVE_PRESS_RECT: States.RESPONDER_INACTIVE_PRESS_OUT,\n LONG_PRESS_DETECTED: States.ERROR\n },\n RESPONDER_ACTIVE_PRESS_IN: {\n DELAY: States.ERROR,\n RESPONDER_GRANT: States.ERROR,\n RESPONDER_RELEASE: States.NOT_RESPONDER,\n RESPONDER_TERMINATED: States.NOT_RESPONDER,\n ENTER_PRESS_RECT: States.RESPONDER_ACTIVE_PRESS_IN,\n LEAVE_PRESS_RECT: States.RESPONDER_ACTIVE_PRESS_OUT,\n LONG_PRESS_DETECTED: States.RESPONDER_ACTIVE_LONG_PRESS_IN\n },\n RESPONDER_ACTIVE_PRESS_OUT: {\n DELAY: States.ERROR,\n RESPONDER_GRANT: States.ERROR,\n RESPONDER_RELEASE: States.NOT_RESPONDER,\n RESPONDER_TERMINATED: States.NOT_RESPONDER,\n ENTER_PRESS_RECT: States.RESPONDER_ACTIVE_PRESS_IN,\n LEAVE_PRESS_RECT: States.RESPONDER_ACTIVE_PRESS_OUT,\n LONG_PRESS_DETECTED: States.ERROR\n },\n RESPONDER_ACTIVE_LONG_PRESS_IN: {\n DELAY: States.ERROR,\n RESPONDER_GRANT: States.ERROR,\n RESPONDER_RELEASE: States.NOT_RESPONDER,\n RESPONDER_TERMINATED: States.NOT_RESPONDER,\n ENTER_PRESS_RECT: States.RESPONDER_ACTIVE_LONG_PRESS_IN,\n LEAVE_PRESS_RECT: States.RESPONDER_ACTIVE_LONG_PRESS_OUT,\n LONG_PRESS_DETECTED: States.RESPONDER_ACTIVE_LONG_PRESS_IN\n },\n RESPONDER_ACTIVE_LONG_PRESS_OUT: {\n DELAY: States.ERROR,\n RESPONDER_GRANT: States.ERROR,\n RESPONDER_RELEASE: States.NOT_RESPONDER,\n RESPONDER_TERMINATED: States.NOT_RESPONDER,\n ENTER_PRESS_RECT: States.RESPONDER_ACTIVE_LONG_PRESS_IN,\n LEAVE_PRESS_RECT: States.RESPONDER_ACTIVE_LONG_PRESS_OUT,\n LONG_PRESS_DETECTED: States.ERROR\n },\n error: {\n DELAY: States.NOT_RESPONDER,\n RESPONDER_GRANT: States.RESPONDER_INACTIVE_PRESS_IN,\n RESPONDER_RELEASE: States.NOT_RESPONDER,\n RESPONDER_TERMINATED: States.NOT_RESPONDER,\n ENTER_PRESS_RECT: States.NOT_RESPONDER,\n LEAVE_PRESS_RECT: States.NOT_RESPONDER,\n LONG_PRESS_DETECTED: States.NOT_RESPONDER\n }\n};\n\n// ==== Typical Constants for integrating into UI components ====\n// var HIT_EXPAND_PX = 20;\n// var HIT_VERT_OFFSET_PX = 10;\nvar HIGHLIGHT_DELAY_MS = 130;\nvar PRESS_EXPAND_PX = 20;\nvar LONG_PRESS_THRESHOLD = 500;\nvar LONG_PRESS_DELAY_MS = LONG_PRESS_THRESHOLD - HIGHLIGHT_DELAY_MS;\nvar LONG_PRESS_ALLOWED_MOVEMENT = 10;\n\n// Default amount \"active\" region protrudes beyond box\n\n/**\n * By convention, methods prefixed with underscores are meant to be @private,\n * and not @protected. Mixers shouldn't access them - not even to provide them\n * as callback handlers.\n *\n *\n * ========== Geometry =========\n * `Touchable` only assumes that there exists a `HitRect` node. The `PressRect`\n * is an abstract box that is extended beyond the `HitRect`.\n *\n * +--------------------------+\n * | | - \"Start\" events in `HitRect` cause `HitRect`\n * | +--------------------+ | to become the responder.\n * | | +--------------+ | | - `HitRect` is typically expanded around\n * | | | | | | the `VisualRect`, but shifted downward.\n * | | | VisualRect | | | - After pressing down, after some delay,\n * | | | | | | and before letting up, the Visual React\n * | | +--------------+ | | will become \"active\". This makes it eligible\n * | | HitRect | | for being highlighted (so long as the\n * | +--------------------+ | press remains in the `PressRect`).\n * | PressRect o |\n * +----------------------|---+\n * Out Region |\n * +-----+ This gap between the `HitRect` and\n * `PressRect` allows a touch to move far away\n * from the original hit rect, and remain\n * highlighted, and eligible for a \"Press\".\n * Customize this via\n * `touchableGetPressRectOffset()`.\n *\n *\n *\n * ======= State Machine =======\n *\n * +-------------+ <---+ RESPONDER_RELEASE\n * |NOT_RESPONDER|\n * +-------------+ <---+ RESPONDER_TERMINATED\n * +\n * | RESPONDER_GRANT (HitRect)\n * v\n * +---------------------------+ DELAY +-------------------------+ T + DELAY +------------------------------+\n * |RESPONDER_INACTIVE_PRESS_IN|+-------->|RESPONDER_ACTIVE_PRESS_IN| +------------> |RESPONDER_ACTIVE_LONG_PRESS_IN|\n * +---------------------------+ +-------------------------+ +------------------------------+\n * + ^ + ^ + ^\n * |LEAVE_ |ENTER_ |LEAVE_ |ENTER_ |LEAVE_ |ENTER_\n * |PRESS_RECT |PRESS_RECT |PRESS_RECT |PRESS_RECT |PRESS_RECT |PRESS_RECT\n * | | | | | |\n * v + v + v +\n * +----------------------------+ DELAY +--------------------------+ +-------------------------------+\n * |RESPONDER_INACTIVE_PRESS_OUT|+------->|RESPONDER_ACTIVE_PRESS_OUT| |RESPONDER_ACTIVE_LONG_PRESS_OUT|\n * +----------------------------+ +--------------------------+ +-------------------------------+\n *\n * T + DELAY => LONG_PRESS_DELAY_MS + DELAY\n *\n * Not drawn are the side effects of each transition. The most important side\n * effect is the `touchableHandlePress` abstract method invocation that occurs\n * when a responder is released while in either of the \"Press\" states.\n *\n * The other important side effects are the highlight abstract method\n * invocations (internal callbacks) to be implemented by the mixer.\n *\n *\n * @lends Touchable.prototype\n */\nvar TouchableMixin = {\n // HACK (part 1): basic support for touchable interactions using a keyboard\n componentDidMount: function componentDidMount() {\n warnOnce('TouchableMixin', 'TouchableMixin is deprecated. Please use Pressable.');\n var touchableNode = this.getTouchableNode && this.getTouchableNode();\n if (touchableNode && touchableNode.addEventListener) {\n this._touchableBlurListener = e => {\n if (this._isTouchableKeyboardActive) {\n if (this.state.touchable.touchState && this.state.touchable.touchState !== States.NOT_RESPONDER) {\n this.touchableHandleResponderTerminate({\n nativeEvent: e\n });\n }\n this._isTouchableKeyboardActive = false;\n }\n };\n touchableNode.addEventListener('blur', this._touchableBlurListener);\n }\n },\n /**\n * Clear all timeouts on unmount\n */\n componentWillUnmount: function componentWillUnmount() {\n var touchableNode = this.getTouchableNode && this.getTouchableNode();\n if (touchableNode && touchableNode.addEventListener) {\n touchableNode.removeEventListener('blur', this._touchableBlurListener);\n }\n this.touchableDelayTimeout && clearTimeout(this.touchableDelayTimeout);\n this.longPressDelayTimeout && clearTimeout(this.longPressDelayTimeout);\n this.pressOutDelayTimeout && clearTimeout(this.pressOutDelayTimeout);\n // Clear DOM nodes\n this.pressInLocation = null;\n this.state.touchable.responderID = null;\n },\n /**\n * It's prefer that mixins determine state in this way, having the class\n * explicitly mix the state in the one and only `getInitialState` method.\n *\n * @return {object} State object to be placed inside of\n * `this.state.touchable`.\n */\n touchableGetInitialState: function touchableGetInitialState() {\n return {\n touchable: {\n touchState: undefined,\n responderID: null\n }\n };\n },\n // ==== Hooks to Gesture Responder system ====\n /**\n * Must return true if embedded in a native platform scroll view.\n */\n touchableHandleResponderTerminationRequest: function touchableHandleResponderTerminationRequest() {\n return !this.props.rejectResponderTermination;\n },\n /**\n * Must return true to start the process of `Touchable`.\n */\n touchableHandleStartShouldSetResponder: function touchableHandleStartShouldSetResponder() {\n return !this.props.disabled;\n },\n /**\n * Return true to cancel press on long press.\n */\n touchableLongPressCancelsPress: function touchableLongPressCancelsPress() {\n return true;\n },\n /**\n * Place as callback for a DOM element's `onResponderGrant` event.\n * @param {SyntheticEvent} e Synthetic event from event system.\n *\n */\n touchableHandleResponderGrant: function touchableHandleResponderGrant(e) {\n var dispatchID = e.currentTarget;\n // Since e is used in a callback invoked on another event loop\n // (as in setTimeout etc), we need to call e.persist() on the\n // event to make sure it doesn't get reused in the event object pool.\n e.persist();\n this.pressOutDelayTimeout && clearTimeout(this.pressOutDelayTimeout);\n this.pressOutDelayTimeout = null;\n this.state.touchable.touchState = States.NOT_RESPONDER;\n this.state.touchable.responderID = dispatchID;\n this._receiveSignal(Signals.RESPONDER_GRANT, e);\n var delayMS = this.touchableGetHighlightDelayMS !== undefined ? Math.max(this.touchableGetHighlightDelayMS(), 0) : HIGHLIGHT_DELAY_MS;\n delayMS = isNaN(delayMS) ? HIGHLIGHT_DELAY_MS : delayMS;\n if (delayMS !== 0) {\n this.touchableDelayTimeout = setTimeout(this._handleDelay.bind(this, e), delayMS);\n } else {\n this._handleDelay(e);\n }\n var longDelayMS = this.touchableGetLongPressDelayMS !== undefined ? Math.max(this.touchableGetLongPressDelayMS(), 10) : LONG_PRESS_DELAY_MS;\n longDelayMS = isNaN(longDelayMS) ? LONG_PRESS_DELAY_MS : longDelayMS;\n this.longPressDelayTimeout = setTimeout(this._handleLongDelay.bind(this, e), longDelayMS + delayMS);\n },\n /**\n * Place as callback for a DOM element's `onResponderRelease` event.\n */\n touchableHandleResponderRelease: function touchableHandleResponderRelease(e) {\n this.pressInLocation = null;\n this._receiveSignal(Signals.RESPONDER_RELEASE, e);\n },\n /**\n * Place as callback for a DOM element's `onResponderTerminate` event.\n */\n touchableHandleResponderTerminate: function touchableHandleResponderTerminate(e) {\n this.pressInLocation = null;\n this._receiveSignal(Signals.RESPONDER_TERMINATED, e);\n },\n /**\n * Place as callback for a DOM element's `onResponderMove` event.\n */\n touchableHandleResponderMove: function touchableHandleResponderMove(e) {\n // Measurement may not have returned yet.\n if (!this.state.touchable.positionOnActivate) {\n return;\n }\n var positionOnActivate = this.state.touchable.positionOnActivate;\n var dimensionsOnActivate = this.state.touchable.dimensionsOnActivate;\n var pressRectOffset = this.touchableGetPressRectOffset ? this.touchableGetPressRectOffset() : {\n left: PRESS_EXPAND_PX,\n right: PRESS_EXPAND_PX,\n top: PRESS_EXPAND_PX,\n bottom: PRESS_EXPAND_PX\n };\n var pressExpandLeft = pressRectOffset.left;\n var pressExpandTop = pressRectOffset.top;\n var pressExpandRight = pressRectOffset.right;\n var pressExpandBottom = pressRectOffset.bottom;\n var hitSlop = this.touchableGetHitSlop ? this.touchableGetHitSlop() : null;\n if (hitSlop) {\n pressExpandLeft += hitSlop.left || 0;\n pressExpandTop += hitSlop.top || 0;\n pressExpandRight += hitSlop.right || 0;\n pressExpandBottom += hitSlop.bottom || 0;\n }\n var touch = extractSingleTouch(e.nativeEvent);\n var pageX = touch && touch.pageX;\n var pageY = touch && touch.pageY;\n if (this.pressInLocation) {\n var movedDistance = this._getDistanceBetweenPoints(pageX, pageY, this.pressInLocation.pageX, this.pressInLocation.pageY);\n if (movedDistance > LONG_PRESS_ALLOWED_MOVEMENT) {\n this._cancelLongPressDelayTimeout();\n }\n }\n var isTouchWithinActive = pageX > positionOnActivate.left - pressExpandLeft && pageY > positionOnActivate.top - pressExpandTop && pageX < positionOnActivate.left + dimensionsOnActivate.width + pressExpandRight && pageY < positionOnActivate.top + dimensionsOnActivate.height + pressExpandBottom;\n if (isTouchWithinActive) {\n var prevState = this.state.touchable.touchState;\n this._receiveSignal(Signals.ENTER_PRESS_RECT, e);\n var curState = this.state.touchable.touchState;\n if (curState === States.RESPONDER_INACTIVE_PRESS_IN && prevState !== States.RESPONDER_INACTIVE_PRESS_IN) {\n // fix for t7967420\n this._cancelLongPressDelayTimeout();\n }\n } else {\n this._cancelLongPressDelayTimeout();\n this._receiveSignal(Signals.LEAVE_PRESS_RECT, e);\n }\n },\n /**\n * Invoked when the item receives focus. Mixers might override this to\n * visually distinguish the `VisualRect` so that the user knows that it\n * currently has the focus. Most platforms only support a single element being\n * focused at a time, in which case there may have been a previously focused\n * element that was blurred just prior to this. This can be overridden when\n * using `Touchable.Mixin.withoutDefaultFocusAndBlur`.\n */\n touchableHandleFocus: function touchableHandleFocus(e) {\n this.props.onFocus && this.props.onFocus(e);\n },\n /**\n * Invoked when the item loses focus. Mixers might override this to\n * visually distinguish the `VisualRect` so that the user knows that it\n * no longer has focus. Most platforms only support a single element being\n * focused at a time, in which case the focus may have moved to another.\n * This can be overridden when using\n * `Touchable.Mixin.withoutDefaultFocusAndBlur`.\n */\n touchableHandleBlur: function touchableHandleBlur(e) {\n this.props.onBlur && this.props.onBlur(e);\n },\n // ==== Abstract Application Callbacks ====\n\n /**\n * Invoked when the item should be highlighted. Mixers should implement this\n * to visually distinguish the `VisualRect` so that the user knows that\n * releasing a touch will result in a \"selection\" (analog to click).\n *\n * @abstract\n * touchableHandleActivePressIn: function,\n */\n\n /**\n * Invoked when the item is \"active\" (in that it is still eligible to become\n * a \"select\") but the touch has left the `PressRect`. Usually the mixer will\n * want to unhighlight the `VisualRect`. If the user (while pressing) moves\n * back into the `PressRect` `touchableHandleActivePressIn` will be invoked\n * again and the mixer should probably highlight the `VisualRect` again. This\n * event will not fire on an `touchEnd/mouseUp` event, only move events while\n * the user is depressing the mouse/touch.\n *\n * @abstract\n * touchableHandleActivePressOut: function\n */\n\n /**\n * Invoked when the item is \"selected\" - meaning the interaction ended by\n * letting up while the item was either in the state\n * `RESPONDER_ACTIVE_PRESS_IN` or `RESPONDER_INACTIVE_PRESS_IN`.\n *\n * @abstract\n * touchableHandlePress: function\n */\n\n /**\n * Invoked when the item is long pressed - meaning the interaction ended by\n * letting up while the item was in `RESPONDER_ACTIVE_LONG_PRESS_IN`. If\n * `touchableHandleLongPress` is *not* provided, `touchableHandlePress` will\n * be called as it normally is. If `touchableHandleLongPress` is provided, by\n * default any `touchableHandlePress` callback will not be invoked. To\n * override this default behavior, override `touchableLongPressCancelsPress`\n * to return false. As a result, `touchableHandlePress` will be called when\n * lifting up, even if `touchableHandleLongPress` has also been called.\n *\n * @abstract\n * touchableHandleLongPress: function\n */\n\n /**\n * Returns the number of millis to wait before triggering a highlight.\n *\n * @abstract\n * touchableGetHighlightDelayMS: function\n */\n\n /**\n * Returns the amount to extend the `HitRect` into the `PressRect`. Positive\n * numbers mean the size expands outwards.\n *\n * @abstract\n * touchableGetPressRectOffset: function\n */\n\n // ==== Internal Logic ====\n\n /**\n * Measures the `HitRect` node on activation. The Bounding rectangle is with\n * respect to viewport - not page, so adding the `pageXOffset/pageYOffset`\n * should result in points that are in the same coordinate system as an\n * event's `globalX/globalY` data values.\n *\n * - Consider caching this for the lifetime of the component, or possibly\n * being able to share this cache between any `ScrollMap` view.\n *\n * @sideeffects\n * @private\n */\n _remeasureMetricsOnActivation: function _remeasureMetricsOnActivation() {\n var tag = this.state.touchable.responderID;\n if (tag == null) {\n return;\n }\n UIManager.measure(tag, this._handleQueryLayout);\n },\n _handleQueryLayout: function _handleQueryLayout(l, t, w, h, globalX, globalY) {\n //don't do anything UIManager failed to measure node\n if (!l && !t && !w && !h && !globalX && !globalY) {\n return;\n }\n this.state.touchable.positionOnActivate && Position.release(this.state.touchable.positionOnActivate);\n this.state.touchable.dimensionsOnActivate &&\n // $FlowFixMe\n BoundingDimensions.release(this.state.touchable.dimensionsOnActivate);\n this.state.touchable.positionOnActivate = Position.getPooled(globalX, globalY);\n // $FlowFixMe\n this.state.touchable.dimensionsOnActivate = BoundingDimensions.getPooled(w, h);\n },\n _handleDelay: function _handleDelay(e) {\n this.touchableDelayTimeout = null;\n this._receiveSignal(Signals.DELAY, e);\n },\n _handleLongDelay: function _handleLongDelay(e) {\n this.longPressDelayTimeout = null;\n var curState = this.state.touchable.touchState;\n if (curState !== States.RESPONDER_ACTIVE_PRESS_IN && curState !== States.RESPONDER_ACTIVE_LONG_PRESS_IN) {\n console.error('Attempted to transition from state `' + curState + '` to `' + States.RESPONDER_ACTIVE_LONG_PRESS_IN + '`, which is not supported. This is ' + 'most likely due to `Touchable.longPressDelayTimeout` not being cancelled.');\n } else {\n this._receiveSignal(Signals.LONG_PRESS_DETECTED, e);\n }\n },\n /**\n * Receives a state machine signal, performs side effects of the transition\n * and stores the new state. Validates the transition as well.\n *\n * @param {Signals} signal State machine signal.\n * @throws Error if invalid state transition or unrecognized signal.\n * @sideeffects\n */\n _receiveSignal: function _receiveSignal(signal, e) {\n var responderID = this.state.touchable.responderID;\n var curState = this.state.touchable.touchState;\n var nextState = Transitions[curState] && Transitions[curState][signal];\n if (!responderID && signal === Signals.RESPONDER_RELEASE) {\n return;\n }\n if (!nextState) {\n throw new Error('Unrecognized signal `' + signal + '` or state `' + curState + '` for Touchable responder `' + responderID + '`');\n }\n if (nextState === States.ERROR) {\n throw new Error('Touchable cannot transition from `' + curState + '` to `' + signal + '` for responder `' + responderID + '`');\n }\n if (curState !== nextState) {\n this._performSideEffectsForTransition(curState, nextState, signal, e);\n this.state.touchable.touchState = nextState;\n }\n },\n _cancelLongPressDelayTimeout: function _cancelLongPressDelayTimeout() {\n this.longPressDelayTimeout && clearTimeout(this.longPressDelayTimeout);\n this.longPressDelayTimeout = null;\n },\n _isHighlight: function _isHighlight(state) {\n return state === States.RESPONDER_ACTIVE_PRESS_IN || state === States.RESPONDER_ACTIVE_LONG_PRESS_IN;\n },\n _savePressInLocation: function _savePressInLocation(e) {\n var touch = extractSingleTouch(e.nativeEvent);\n var pageX = touch && touch.pageX;\n var pageY = touch && touch.pageY;\n var locationX = touch && touch.locationX;\n var locationY = touch && touch.locationY;\n this.pressInLocation = {\n pageX,\n pageY,\n locationX,\n locationY\n };\n },\n _getDistanceBetweenPoints: function _getDistanceBetweenPoints(aX, aY, bX, bY) {\n var deltaX = aX - bX;\n var deltaY = aY - bY;\n return Math.sqrt(deltaX * deltaX + deltaY * deltaY);\n },\n /**\n * Will perform a transition between touchable states, and identify any\n * highlighting or unhighlighting that must be performed for this particular\n * transition.\n *\n * @param {States} curState Current Touchable state.\n * @param {States} nextState Next Touchable state.\n * @param {Signal} signal Signal that triggered the transition.\n * @param {Event} e Native event.\n * @sideeffects\n */\n _performSideEffectsForTransition: function _performSideEffectsForTransition(curState, nextState, signal, e) {\n var curIsHighlight = this._isHighlight(curState);\n var newIsHighlight = this._isHighlight(nextState);\n var isFinalSignal = signal === Signals.RESPONDER_TERMINATED || signal === Signals.RESPONDER_RELEASE;\n if (isFinalSignal) {\n this._cancelLongPressDelayTimeout();\n }\n var isInitialTransition = curState === States.NOT_RESPONDER && nextState === States.RESPONDER_INACTIVE_PRESS_IN;\n var isActiveTransition = !IsActive[curState] && IsActive[nextState];\n if (isInitialTransition || isActiveTransition) {\n this._remeasureMetricsOnActivation();\n }\n if (IsPressingIn[curState] && signal === Signals.LONG_PRESS_DETECTED) {\n this.touchableHandleLongPress && this.touchableHandleLongPress(e);\n }\n if (newIsHighlight && !curIsHighlight) {\n this._startHighlight(e);\n } else if (!newIsHighlight && curIsHighlight) {\n this._endHighlight(e);\n }\n if (IsPressingIn[curState] && signal === Signals.RESPONDER_RELEASE) {\n var hasLongPressHandler = !!this.props.onLongPress;\n var pressIsLongButStillCallOnPress = IsLongPressingIn[curState] && (\n // We *are* long pressing.. // But either has no long handler\n !hasLongPressHandler || !this.touchableLongPressCancelsPress()); // or we're told to ignore it.\n\n var shouldInvokePress = !IsLongPressingIn[curState] || pressIsLongButStillCallOnPress;\n if (shouldInvokePress && this.touchableHandlePress) {\n if (!newIsHighlight && !curIsHighlight) {\n // we never highlighted because of delay, but we should highlight now\n this._startHighlight(e);\n this._endHighlight(e);\n }\n this.touchableHandlePress(e);\n }\n }\n this.touchableDelayTimeout && clearTimeout(this.touchableDelayTimeout);\n this.touchableDelayTimeout = null;\n },\n _playTouchSound: function _playTouchSound() {\n UIManager.playTouchSound();\n },\n _startHighlight: function _startHighlight(e) {\n this._savePressInLocation(e);\n this.touchableHandleActivePressIn && this.touchableHandleActivePressIn(e);\n },\n _endHighlight: function _endHighlight(e) {\n if (this.touchableHandleActivePressOut) {\n if (this.touchableGetPressOutDelayMS && this.touchableGetPressOutDelayMS()) {\n this.pressOutDelayTimeout = setTimeout(() => {\n this.touchableHandleActivePressOut(e);\n }, this.touchableGetPressOutDelayMS());\n } else {\n this.touchableHandleActivePressOut(e);\n }\n }\n },\n // HACK (part 2): basic support for touchable interactions using a keyboard (including\n // delays and longPress)\n touchableHandleKeyEvent: function touchableHandleKeyEvent(e) {\n var type = e.type,\n key = e.key;\n if (key === 'Enter' || key === ' ') {\n if (type === 'keydown') {\n if (!this._isTouchableKeyboardActive) {\n if (!this.state.touchable.touchState || this.state.touchable.touchState === States.NOT_RESPONDER) {\n this.touchableHandleResponderGrant(e);\n this._isTouchableKeyboardActive = true;\n }\n }\n } else if (type === 'keyup') {\n if (this._isTouchableKeyboardActive) {\n if (this.state.touchable.touchState && this.state.touchable.touchState !== States.NOT_RESPONDER) {\n this.touchableHandleResponderRelease(e);\n this._isTouchableKeyboardActive = false;\n }\n }\n }\n e.stopPropagation();\n // prevent the default behaviour unless the Touchable functions as a link\n // and Enter is pressed\n if (!(key === 'Enter' && AccessibilityUtil.propsToAriaRole(this.props) === 'link')) {\n e.preventDefault();\n }\n }\n },\n withoutDefaultFocusAndBlur: {}\n};\n\n/**\n * Provide an optional version of the mixin where `touchableHandleFocus` and\n * `touchableHandleBlur` can be overridden. This allows appropriate defaults to\n * be set on TV platforms, without breaking existing implementations of\n * `Touchable`.\n */\nvar touchableHandleFocus = TouchableMixin.touchableHandleFocus,\n touchableHandleBlur = TouchableMixin.touchableHandleBlur,\n TouchableMixinWithoutDefaultFocusAndBlur = _objectWithoutPropertiesLoose(TouchableMixin, [\"touchableHandleFocus\", \"touchableHandleBlur\"]);\nTouchableMixin.withoutDefaultFocusAndBlur = TouchableMixinWithoutDefaultFocusAndBlur;\nvar Touchable = {\n Mixin: TouchableMixin,\n TOUCH_TARGET_DEBUG: false,\n // Highlights all touchable targets. Toggle with Inspector.\n /**\n * Renders a debugging overlay to visualize touch target with hitSlop (might not work on Android).\n */\n renderDebugView: _ref => {\n var color = _ref.color,\n hitSlop = _ref.hitSlop;\n if (!Touchable.TOUCH_TARGET_DEBUG) {\n return null;\n }\n if (process.env.NODE_ENV !== 'production') {\n throw Error('Touchable.TOUCH_TARGET_DEBUG should not be enabled in prod!');\n }\n var debugHitSlopStyle = {};\n hitSlop = hitSlop || {\n top: 0,\n bottom: 0,\n left: 0,\n right: 0\n };\n for (var key in hitSlop) {\n debugHitSlopStyle[key] = -hitSlop[key];\n }\n var normalizedColor = normalizeColor(color);\n if (typeof normalizedColor !== 'number') {\n return null;\n }\n var hexColor = '#' + ('00000000' + normalizedColor.toString(16)).substr(-8);\n return /*#__PURE__*/React.createElement(View, {\n pointerEvents: \"none\",\n style: _objectSpread({\n position: 'absolute',\n borderColor: hexColor.slice(0, -2) + '55',\n // More opaque\n borderWidth: 1,\n borderStyle: 'dashed',\n backgroundColor: hexColor.slice(0, -2) + '0F'\n }, debugHitSlopStyle)\n });\n }\n};\nexport default Touchable;","import { getConfig, isVariable } from '@hanzogui/core';\nexport const getFontSize = (inSize, opts) => {\n const res = getFontSizeVariable(inSize, opts);\n return px(isVariable(res) ? res.val : res) ?? 16;\n};\n// A size on a design ramp reads `var(--text-base, 14px)`; the number a caller\n// needs is the fallback it carries.\nconst px = (val) => {\n const n = typeof val === 'number'\n ? val\n : Number.parseFloat(String(val).match(/(\\d*\\.?\\d+)px/)?.[1] ?? String(val));\n return Number.isFinite(n) ? n : undefined;\n};\nexport const getFontSizeVariable = (inSize, opts) => {\n const token = getFontSizeToken(inSize, opts);\n if (!token) {\n return inSize;\n }\n const conf = getConfig();\n const font = conf.fontsParsed[opts?.font || conf.defaultFontToken];\n return font?.size[token];\n};\nexport const getFontSizeToken = (inSize, opts) => {\n if (typeof inSize === 'number') {\n return null;\n }\n // backwards compat\n const relativeSize = opts?.relativeSize || 0;\n const conf = getConfig();\n const font = conf.fontsParsed[opts?.font || conf.defaultFontToken];\n const fontSize = font?.size ||\n // fallback to size tokens\n conf.tokensParsed.size;\n const size = (inSize === '$true' && !('$true' in fontSize) ? '$4' : inSize) ??\n ('$true' in fontSize ? '$true' : '$4');\n const sizeTokens = Object.keys(fontSize);\n let foundIndex = sizeTokens.indexOf(size);\n if (foundIndex === -1) {\n if (size.endsWith('.5')) {\n foundIndex = sizeTokens.indexOf(size.replace('.5', ''));\n }\n }\n if (process.env.NODE_ENV === 'development') {\n if (foundIndex === -1) {\n console.warn('No font size found', size, opts, 'in size tokens', sizeTokens);\n }\n }\n const tokenIndex = Math.min(Math.max(0, foundIndex + relativeSize), sizeTokens.length - 1);\n return (sizeTokens[tokenIndex] ?? size);\n};\n//# sourceMappingURL=getFontSize.js.map","import { getVariable, useTheme } from '@hanzogui/web';\nexport const useCurrentColor = (colorProp) => {\n const theme = useTheme();\n const out = colorProp\n ? getVariable(colorProp)\n : theme[colorProp]?.get() || theme.color?.get();\n return out;\n};\n//# sourceMappingURL=useCurrentColor.js.map","import React from 'react';\nexport const getIcon = (el, props) => {\n if (!el)\n return el;\n if (React.isValidElement(el)) {\n return React.cloneElement(el, {\n ...props,\n // @ts-expect-error\n ...el.props,\n });\n }\n return React.createElement(el, props);\n};\n//# sourceMappingURL=getIcon.js.map","import { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { getFontSize } from '@hanzogui/font-size';\nimport { getButtonSized } from '@hanzogui/get-button-sized';\nimport { getIcon, useCurrentColor } from '@hanzogui/component-helpers';\nimport { ButtonNestingContext, getElevation, themeableVariants } from '@hanzogui/stacks';\nimport { SizableText, wrapChildrenInText } from '@hanzogui/text';\nimport { createStyledContext, getTokenValue, styled, useProps, View, withStaticProperties, } from '@hanzogui/web';\nimport { useContext } from 'react';\nconst context = createStyledContext({\n size: undefined,\n variant: undefined,\n color: undefined,\n elevation: undefined,\n ellipsis: undefined,\n fontFamily: undefined,\n fontSize: undefined,\n fontStyle: undefined,\n fontWeight: undefined,\n letterSpacing: undefined,\n maxFontSizeMultiplier: undefined,\n textAlign: undefined,\n});\nconst Frame = styled(View, {\n context,\n name: 'Button',\n role: 'button',\n render: _jsx(\"button\", { type: \"button\" }),\n tabIndex: 0,\n variants: {\n unstyled: {\n true: {\n // reset browser <button> defaults\n outlineWidth: 0,\n borderWidth: 0,\n backgroundColor: 'transparent',\n },\n false: {\n size: '$true',\n justifyContent: 'center',\n alignItems: 'center',\n flexWrap: 'nowrap',\n flexDirection: 'row',\n backgroundColor: '$background',\n borderWidth: 1,\n borderColor: 'transparent',\n '$platform-web': {\n cursor: 'pointer',\n },\n hoverStyle: {\n backgroundColor: '$backgroundHover',\n borderColor: '$borderColorHover',\n },\n pressStyle: {\n backgroundColor: '$backgroundPress',\n borderColor: '$borderColorHover',\n },\n focusVisibleStyle: {\n outlineColor: '$outlineColor',\n outlineStyle: 'solid',\n outlineWidth: 2,\n },\n },\n },\n variant: {\n outlined: process.env.GUI_HEADLESS === '1'\n ? {}\n : {\n backgroundColor: 'transparent',\n borderWidth: 1,\n borderColor: '$borderColor',\n hoverStyle: {\n backgroundColor: 'transparent',\n borderColor: '$borderColorHover',\n },\n pressStyle: {\n backgroundColor: 'transparent',\n borderColor: '$borderColorPress',\n },\n },\n },\n circular: themeableVariants.circular,\n chromeless: themeableVariants.chromeless,\n size: {\n '...size': (val, extras) => {\n const buttonStyle = getButtonSized(val, extras);\n const gap = getTokenValue(val);\n return {\n ...buttonStyle,\n gap,\n };\n },\n ':number': (val, extras) => {\n const buttonStyle = getButtonSized(val, extras);\n const gap = val * 0.4;\n return {\n ...buttonStyle,\n gap,\n };\n },\n },\n elevation: {\n '...size': getElevation,\n ':number': getElevation,\n },\n disabled: {\n true: {\n pointerEvents: 'none',\n // @ts-ignore\n 'aria-disabled': true,\n },\n },\n },\n defaultVariants: {\n unstyled: process.env.GUI_HEADLESS === '1',\n },\n});\nconst Text = styled(SizableText, {\n context,\n variants: {\n unstyled: {\n false: {\n userSelect: 'none',\n // flexGrow 1 leads to inconsistent native style where text pushes to start of view\n flexGrow: 0,\n flexShrink: 1,\n ellipsis: true,\n color: '$color',\n '$platform-web': {\n cursor: 'pointer',\n },\n },\n },\n },\n defaultVariants: {\n unstyled: process.env.GUI_HEADLESS === '1',\n },\n});\nconst Icon = (props) => {\n const { children, scaleIcon = 1, size } = props;\n const styledContext = context.useStyledContext();\n if (!styledContext) {\n throw new Error('Button.Icon must be used within a Button');\n }\n const sizeToken = size ?? styledContext.size;\n const iconColorProp = styledContext.color === 'unset' || typeof styledContext.color === 'number'\n ? undefined\n : styledContext.color;\n const iconColor = useCurrentColor(iconColorProp);\n const iconSize = (typeof sizeToken === 'number' ? sizeToken * 0.5 : getFontSize(sizeToken)) *\n scaleIcon;\n return getIcon(children, {\n size: iconSize,\n color: iconColor,\n });\n};\nexport const ButtonContext = createStyledContext({\n size: undefined,\n variant: undefined,\n color: undefined,\n});\nconst ButtonComponent = Frame.styleable((propsIn, ref) => {\n const isNested = useContext(ButtonNestingContext);\n // Process props through useProps to expand shorthands (like br -> borderRadius)\n const processedProps = useProps(propsIn, {\n noNormalize: true,\n noExpand: true,\n });\n const { children, iconSize, icon, iconAfter, scaleIcon = 1, noTextWrap, textProps, color, ellipsis, fontFamily, fontSize, fontStyle, fontWeight, letterSpacing, maxFontSizeMultiplier, textAlign, ...props } = processedProps;\n const size = propsIn.size || (propsIn.unstyled ? undefined : '$true');\n const styledContext = context.useStyledContext();\n const contextColor = color ?? propsIn.color ?? styledContext?.color;\n const iconColorProp = contextColor === 'unset' || typeof contextColor === 'number'\n ? undefined\n : contextColor;\n const iconColor = useCurrentColor(iconColorProp);\n const finalSize = iconSize ?? size ?? styledContext?.size;\n const iconSizeNumber = (typeof finalSize === 'number' ? finalSize * 0.5 : getFontSize(finalSize)) *\n scaleIcon;\n const [themedIcon, themedIconAfter] = [icon, iconAfter].map((icon) => {\n if (!icon)\n return null;\n return getIcon(icon, {\n size: iconSizeNumber,\n color: iconColor,\n // No marginLeft or marginRight needed - spacing is handled by the gap property in Frame's size variants\n });\n });\n const wrappedChildren = wrapChildrenInText(Text, {\n children,\n color: contextColor,\n ellipsis: ellipsis ?? propsIn.ellipsis ?? styledContext?.ellipsis,\n fontFamily: fontFamily ?? propsIn.fontFamily ?? styledContext?.fontFamily,\n fontSize: fontSize ?? propsIn.fontSize ?? styledContext?.fontSize,\n fontStyle: fontStyle ?? propsIn.fontStyle ?? styledContext?.fontStyle,\n fontWeight: fontWeight ?? propsIn.fontWeight ?? styledContext?.fontWeight,\n letterSpacing: letterSpacing ?? propsIn.letterSpacing ?? styledContext?.letterSpacing,\n maxFontSizeMultiplier: maxFontSizeMultiplier ??\n propsIn.maxFontSizeMultiplier ??\n styledContext?.maxFontSizeMultiplier,\n noTextWrap: noTextWrap ?? propsIn.noTextWrap,\n textAlign: textAlign ?? propsIn.textAlign ?? styledContext?.textAlign,\n textProps: textProps ?? propsIn.textProps,\n }, {\n unstyled: process.env.GUI_HEADLESS === '1',\n size: finalSize ?? styledContext?.size,\n });\n const textContext = {\n color: contextColor,\n ellipsis: ellipsis ?? propsIn.ellipsis ?? styledContext?.ellipsis,\n fontFamily: fontFamily ?? propsIn.fontFamily ?? styledContext?.fontFamily,\n fontSize: fontSize ?? propsIn.fontSize ?? styledContext?.fontSize,\n fontStyle: fontStyle ?? propsIn.fontStyle ?? styledContext?.fontStyle,\n fontWeight: fontWeight ?? propsIn.fontWeight ?? styledContext?.fontWeight,\n letterSpacing: letterSpacing ?? propsIn.letterSpacing ?? styledContext?.letterSpacing,\n maxFontSizeMultiplier: maxFontSizeMultiplier ??\n propsIn.maxFontSizeMultiplier ??\n styledContext?.maxFontSizeMultiplier,\n textAlign: textAlign ?? propsIn.textAlign ?? styledContext?.textAlign,\n };\n const buttonContext = {\n ...styledContext,\n ...textContext,\n size: props.size ?? propsIn.size ?? styledContext?.size,\n variant: props.variant ?? propsIn.variant ?? styledContext?.variant,\n elevation: props.elevation ?? propsIn.elevation ?? styledContext?.elevation,\n };\n return (_jsx(ButtonNestingContext.Provider, { value: true, children: _jsx(context.Provider, { ...buttonContext, children: _jsxs(Frame, { ref: ref, ...props, ...(isNested && { render: 'span' }), ...(props.circular && !propsIn.size && { size }), tabIndex: 0, children: [themedIcon, wrappedChildren, themedIconAfter] }) }) }));\n});\nexport const Button = withStaticProperties(ButtonComponent, {\n Apply: context.Provider,\n Frame,\n Text,\n Icon,\n});\n//# sourceMappingURL=Button.js.map","import { createStyledContext } from '@hanzogui/core';\nexport const SizableContext = createStyledContext({\n size: undefined,\n});\n//# sourceMappingURL=index.js.map","// Consent, in one place.\n//\n// Two independent signals, one answer:\n//\n// 1. The browser's standing preference — Do-Not-Track / Global Privacy\n// Control. Honored by default, with no code in the app.\n// 2. The person's explicit in-app choice, persisted. A choice they made\n// themselves outranks the browser default in BOTH directions — that is\n// what \"explicit\" means.\n//\n// An app that wants no persistence at all just passes `consent=\"granted\"` or\n// `consent=\"denied\"` and never calls `setConsent`.\nconst KEY = 'hz_consent';\nconst hasWindow = () => typeof window !== 'undefined';\nfunction store() {\n try {\n if (!hasWindow() || !window.localStorage)\n return undefined;\n return window.localStorage;\n }\n catch {\n return undefined; // Safari private mode / blocked storage\n }\n}\n/** True when the browser is asking not to be tracked — DNT in any of its three\n * historical spellings, or the Global Privacy Control signal. */\nexport function doNotTrack() {\n if (!hasWindow())\n return false;\n try {\n const n = navigator;\n const w = window;\n if (n.globalPrivacyControl === true)\n return true;\n return n.doNotTrack === '1' || w.doNotTrack === '1' || n.msDoNotTrack === '1';\n }\n catch {\n return false;\n }\n}\n/** The person's persisted choice, or undefined if they never made one. */\nexport function getConsent() {\n const s = store();\n if (!s)\n return undefined;\n try {\n const v = s.getItem(KEY);\n return v === 'granted' || v === 'denied' ? v : undefined;\n }\n catch {\n return undefined;\n }\n}\nconst listeners = new Set();\n/** Record the person's choice. `'unset'` forgets it, so the `auto` policy\n * (DNT/GPC) applies again. Live providers re-evaluate immediately. */\nexport function setConsent(consent) {\n const s = store();\n try {\n if (consent === 'unset')\n s?.removeItem(KEY);\n else\n s?.setItem(KEY, consent);\n }\n catch {\n /* storage blocked — the in-memory notification below still applies */\n }\n const next = consent === 'unset' ? undefined : consent;\n for (const fn of listeners) {\n try {\n fn(next);\n }\n catch {\n /* a listener must never break the caller */\n }\n }\n}\n/** Subscribe to consent changes; returns the unsubscribe. */\nexport function onConsentChange(fn) {\n listeners.add(fn);\n return () => {\n listeners.delete(fn);\n };\n}\n/** The single policy decision. `enabled` is a hard build-time override and wins\n * over everything; otherwise an explicit stored choice wins; otherwise the\n * declared posture; otherwise DNT/GPC. */\nexport function resolveEnabled(opts) {\n if (typeof opts.enabled === 'boolean')\n return opts.enabled;\n const stored = opts.stored !== undefined ? opts.stored : getConsent();\n if (stored === 'denied')\n return false;\n if (stored === 'granted')\n return true;\n const mode = opts.consent ?? 'auto';\n if (mode === 'denied')\n return false;\n if (mode === 'granted')\n return true;\n return !doNotTrack();\n}\n//# sourceMappingURL=consent.js.map","// The build-time environment a bundler inlines for a module, read as the\n// member expression bundlers substitute.\nexport const env = import.meta.env;\n//# sourceMappingURL=here.js.map","// Zero-config resolution: where telemetry goes and what it calls itself, with\n// nobody having configured anything.\n//\n// THE ONE ENDPOINT. Everything a Hanzo surface emits — pageviews, product\n// events, exceptions, interaction capture — is POSTed to\n//\n// POST https://api.hanzo.ai/v1/event { batch: [Event, …] }\n//\n// and Cloud lenses that single stream into the three views:\n//\n// sentry.hanzo.ai errors + stacks + session capture\n// analytics.hanzo.ai web analytics (pageviews, referrers, campaigns)\n// insights.hanzo.ai product insights + notebooks (incl. analytics_errors,\n// so a funnel drop joins to the exception that caused it)\n//\n// Those are dashboards — FRONTENDS. They are never ingest endpoints. There is\n// exactly one API host, so there is exactly one thing to configure, and by\n// default you configure nothing.\nimport { env } from './here.js';\nconst DEFAULT_HOST = 'https://api.hanzo.ai';\nconst first = (...vals) => {\n for (const v of vals) {\n if (typeof v === 'string' && v.trim() !== '')\n return v.trim();\n }\n return undefined;\n};\n/** `process.env.X` and `import.meta.env.X` must be written as LITERAL member\n * expressions or no bundler will inline them — hence the explicit table. This\n * is the only place in the package that reads the environment. */\nfunction processEnv() {\n try {\n if (typeof process === 'undefined' || !process.env)\n return {};\n const e = process.env;\n return {\n apiUrl: first(e.NEXT_PUBLIC_HANZO_API_URL, e.PUBLIC_HANZO_API_URL, e.HANZO_API_URL),\n // PUBLISHABLE_KEY is the name, and it is the one the fleet already\n // carries end to end: KMS holds `deploy/PUBLISHABLE_KEY`, each Dockerfile\n // takes it as a build-arg, and @hanzo/event reads the same spelling. The\n // HANZO_INGEST_KEY family below is the older spelling still set by three\n // surfaces; it is read second and is being retired, not extended.\n ingestKey: first(e.NEXT_PUBLIC_PUBLISHABLE_KEY, e.PUBLIC_PUBLISHABLE_KEY, e.PUBLISHABLE_KEY, e.NEXT_PUBLIC_HANZO_INGEST_KEY, e.PUBLIC_HANZO_INGEST_KEY, e.HANZO_INGEST_KEY),\n product: first(e.NEXT_PUBLIC_HANZO_PRODUCT, e.PUBLIC_HANZO_PRODUCT, e.HANZO_PRODUCT),\n telemetry: first(e.NEXT_PUBLIC_HANZO_TELEMETRY, e.PUBLIC_HANZO_TELEMETRY, e.HANZO_TELEMETRY),\n debug: first(e.NEXT_PUBLIC_HANZO_TELEMETRY_DEBUG, e.PUBLIC_HANZO_TELEMETRY_DEBUG),\n };\n }\n catch {\n return {};\n }\n}\nfunction metaEnv() {\n try {\n const e = env;\n if (!e)\n return {};\n return {\n apiUrl: first(e.VITE_HANZO_API_URL, e.EXPO_PUBLIC_HANZO_API_URL, e.PUBLIC_HANZO_API_URL),\n ingestKey: first(e.VITE_PUBLISHABLE_KEY, e.EXPO_PUBLIC_PUBLISHABLE_KEY, e.PUBLIC_PUBLISHABLE_KEY, e.VITE_HANZO_INGEST_KEY, e.EXPO_PUBLIC_HANZO_INGEST_KEY, e.PUBLIC_HANZO_INGEST_KEY),\n product: first(e.VITE_HANZO_PRODUCT, e.EXPO_PUBLIC_HANZO_PRODUCT, e.PUBLIC_HANZO_PRODUCT),\n telemetry: first(e.VITE_HANZO_TELEMETRY, e.EXPO_PUBLIC_HANZO_TELEMETRY, e.PUBLIC_HANZO_TELEMETRY),\n debug: first(e.VITE_HANZO_TELEMETRY_DEBUG, e.EXPO_PUBLIC_HANZO_TELEMETRY_DEBUG),\n };\n }\n catch {\n return {};\n }\n}\nfunction globalEnv() {\n try {\n const g = globalThis;\n return g.__HANZO_TELEMETRY__ ?? {};\n }\n catch {\n return {};\n }\n}\n/** Surfaces whose product name is not simply their first hostname label. */\nconst PRODUCT_BY_HOST = {\n 'hanzo.ai': 'site',\n 'hanzo.chat': 'chat',\n 'hanzo.app': 'app',\n 'hanzo.id': 'iam',\n 'hanzo.industries': 'industries',\n 'hanzo.network': 'network',\n};\n/** Product inferred from where the page is served — the reason you can ship\n * `<TelemetryProvider/>` with no props and still get correctly-labelled data. */\nexport function productFromHost(hostname) {\n if (!hostname)\n return undefined;\n const h = hostname.toLowerCase().replace(/^www\\./, '');\n if (h === 'localhost' || h === '::1' || h === '[::1]' || /^127\\./.test(h))\n return 'dev';\n const mapped = PRODUCT_BY_HOST[h];\n if (mapped)\n return mapped;\n // `console.hanzo.ai` → console, `cloud.hanzo.ai` → cloud, `zoo.ngo` → zoo.\n const label = h.split('.')[0];\n return label && label !== '' ? label : undefined;\n}\n/** React Native: a JS runtime with a global `window` but no DOM — no\n * `document`, no `location`, no History. `navigator.product === 'ReactNative'`\n * is the runtime's own tell, and the one thing that separates a mobile app from\n * a browser (both have `window`) and from SSR (which has neither). */\nexport function isReactNative() {\n try {\n return (typeof navigator !== 'undefined' &&\n navigator.product === 'ReactNative');\n }\n catch {\n return false;\n }\n}\n/** The product implied by the HOST RUNTIME rather than by the URL.\n *\n * A desktop shell serves one bundle from three different origins —\n * `tauri://localhost`, `http://tauri.localhost` on Windows, and the dev\n * server's `localhost:5175` — so a hostname rule reads the same app three\n * different ways and gets all three wrong. The Tauri bridge global IS the\n * runtime, so it answers identically in development and in the shipped app,\n * which is what lets a desktop app report as `desktop` with no app-side code.\n * React Native has no URL at all, so its runtime is the ONLY source — an\n * unconfigured mobile app reports as `mobile` the same way.\n *\n * Checked BEFORE the hostname and AFTER the environment, so a surface can\n * still name itself. */\nexport function runtimeProduct() {\n try {\n const g = globalThis;\n if (g.__TAURI_INTERNALS__ !== undefined || g.__TAURI__ !== undefined)\n return 'desktop';\n }\n catch {\n /* a locked-down global object — fall through to the hostname */\n }\n if (isReactNative())\n return 'mobile';\n return undefined;\n}\nconst isOff = (v) => v === '0' || v === 'false' || v === 'off' || v === 'no';\nconst isOn = (v) => v === '1' || v === 'true' || v === 'on' || v === 'yes';\n/** resolveEnv merges, in increasing precedence: built-in defaults, the build\n * environment (`process.env` / `import.meta.env`), and a runtime global. It\n * never throws and never touches the DOM. */\nexport function resolveEnv() {\n const p = processEnv();\n const m = metaEnv();\n const g = globalEnv();\n const telemetryFlag = first(m.telemetry, p.telemetry);\n const enabled = typeof g.enabled === 'boolean'\n ? g.enabled\n : isOff(telemetryFlag)\n ? false\n : isOn(telemetryFlag)\n ? true\n : undefined;\n return {\n host: first(g.host, g.apiUrl, m.apiUrl, p.apiUrl) ?? DEFAULT_HOST,\n product: first(g.product, m.product, p.product),\n ingestKey: first(g.ingestKey, m.ingestKey, p.ingestKey),\n enabled,\n debug: g.debug === true || isOn(first(m.debug, p.debug)),\n };\n}\nexport { DEFAULT_HOST };\n//# sourceMappingURL=env.js.map","// The framework-agnostic half: build a Telemetry, or reach for the ambient one.\n//\n// import { track } from '@hanzogui/telemetry'\n// track('checkout_started', { plan: 'pro' })\n//\n// No provider, no config, no init call. The first `track` lazily builds the\n// ambient client from the environment; `<TelemetryProvider/>` registers its own\n// client into the same slot, so React and non-React code emit through ONE\n// instance and one stream.\nimport { createAnalytics, keyForPage } from '@hanzo/event';\nimport { resolveEnabled } from './consent.js';\nimport { isReactNative, productFromHost, resolveEnv, runtimeProduct } from './env.js';\n/** A DOM — not merely a `window`. React Native defines a global `window` with\n * no `location`/`document`, and SSR defines neither. This is what gates the\n * DOM-only planes (History pageviews, session replay), NOT whether we emit. */\nexport const hasDom = () => typeof window !== 'undefined' && typeof document !== 'undefined';\n/** A live client host: a browser DOM, or React Native. Both send — RN POSTs the\n * event/identify/group/error stream through `fetch` exactly like the browser,\n * it just skips the DOM-only planes above. SSR/Node is neither and stays\n * silent, emitting half an event to nobody. This gates whether we collect. */\nexport const canEmit = () => hasDom() || isReactNative();\n/** Never let a telemetry call throw into the caller. This is the ONLY error\n * policy in the package: every public method funnels through it. */\nfunction soft(fn, debug) {\n try {\n fn();\n }\n catch (err) {\n if (debug)\n console.debug('[telemetry] swallowed', err);\n }\n}\nconst resolved = new WeakMap();\n/** describeTelemetry exposes what a client actually resolved to. */\nexport function describeTelemetry(t) {\n return resolved.get(t);\n}\n/** createTelemetry builds an isolated client. Most surfaces never call this —\n * they mount `<TelemetryProvider/>` or just `track()`. It is pure: no DOM\n * access beyond reading `location.hostname`, no listeners, no requests. */\nexport function createTelemetry(config = {}) {\n const env = resolveEnv();\n const debug = config.debug ?? env.debug;\n // Runtime before hostname: a desktop shell serves the SAME bundle from three\n // different origins (tauri://localhost, http://tauri.localhost, the Vite dev\n // server), so the URL is the one thing that cannot name that surface.\n const product = config.product ??\n env.product ??\n runtimeProduct() ??\n (hasDom() ? productFromHost(window.location?.hostname) : undefined) ??\n 'unknown';\n // A live client host is the precondition: a browser DOM or React Native, both\n // of which POST through `fetch`. Only SSR/Node stays silent — it would read\n // location/referrer and buffer to an unload beacon that never fire, emitting\n // half an event to nobody. `enabled` (a build-time kill switch) still wins.\n const permitted = canEmit() &&\n resolveEnabled({ enabled: config.enabled ?? env.enabled, consent: config.consent });\n const errors = config.errors ?? true;\n const replay = config.replay ?? true;\n const pageviews = config.pageviews ?? true;\n // A brand's own domain names its org, and an org has exactly one publishable\n // key, so a surface served from a domain we recognise needs no key configured\n // at all. Last, so anything stated explicitly still wins.\n //\n // Env-only is why so little of the fleet reports: PUBLISHABLE_KEY is a\n // BUILD-time variable, a static export is built once and served on every\n // brand, and nobody sets it — hanzo.ai's is commented out in .env.example and\n // both Zoo sites shipped with none. `keyForPage` returns undefined for a host\n // no brand claims, which stays the honest answer: report nowhere rather than\n // file one brand's visitors in another's project.\n //\n // Bound once. `describeTelemetry` used to restate this expression to answer\n // `hasIngestKey`, so the two could disagree about the same client — and they\n // did the moment this line gained a third source: the client got a key and\n // the description of it said there was none.\n const ingestKey = config.ingestKey ?? env.ingestKey ?? keyForPage();\n const client = createAnalytics({\n host: config.host !== undefined ? config.host : env.host,\n product,\n ingestKey,\n getToken: config.getToken,\n enabled: permitted,\n // The provider owns pageviews; @hanzo/event owns global error capture.\n captureErrors: permitted && errors,\n debug,\n });\n const telemetry = {\n enabled: permitted,\n product,\n client,\n track: (event, properties, commerce) => soft(() => client.capture(event, properties, commerce), debug),\n pageview: (path, properties) => soft(() => client.pageview(path, properties), debug),\n identify: (personId, traits) => soft(() => client.identify(personId, traits), debug),\n group: (groupId, traits) => soft(() => client.group(groupId, traits), debug),\n captureError: (err, context) => soft(() => client.captureError(err, context), debug),\n captureException: (err, context) => soft(() => client.captureError(err, context), debug),\n setCohort: (patch) => soft(() => client.setCohort(patch), debug),\n flush: () => soft(() => client.flush(), debug),\n };\n resolved.set(telemetry, {\n host: config.host !== undefined ? config.host : env.host,\n product,\n enabled: permitted,\n replay,\n errors,\n pageviews,\n hasIngestKey: Boolean(ingestKey),\n debug,\n });\n return telemetry;\n}\nlet ambient;\n/** True while an APP-owned client holds the ambient slot. A client installed by\n * `GuiProvider`'s fallback provider deliberately does NOT set this: it is the\n * owner of last resort and must yield the moment the app claims the stream. */\nlet appOwned = false;\nconst ownerListeners = new Set();\n/** getTelemetry returns the ambient client, building it from the environment on\n * first use. This is what makes `track()` work with zero setup. */\nexport function getTelemetry() {\n if (!ambient)\n ambient = createTelemetry();\n return ambient;\n}\n/** setTelemetry installs a client as the ambient one. `<TelemetryProvider/>`\n * calls this so module-scope `track()` and the React tree share one stream.\n *\n * `app: false` installs it as the FALLBACK owner — the posture `GuiProvider`\n * uses. A fallback owner is a real client in every other respect; it simply\n * does not claim the stream, so an app that mounts its own provider (before or\n * after, above or below) takes over and there is never a second one emitting. */\nexport function setTelemetry(t, opts) {\n ambient = t;\n appOwned = t !== undefined && (opts?.app ?? true);\n for (const fn of ownerListeners) {\n try {\n fn();\n }\n catch {\n /* a listener must never break the caller */\n }\n }\n}\n/** isTelemetryOwned reports whether the APP has claimed the stream. This is what\n * a fallback provider consults before collecting anything. */\nexport function isTelemetryOwned() {\n return appOwned;\n}\n/** onTelemetryOwnerChange subscribes to claims and releases; returns the\n * unsubscribe. A fallback owner uses it to yield when an app-owned provider\n * mounts late (a lazy route) and to resume if that provider unmounts. */\nexport function onTelemetryOwnerChange(fn) {\n ownerListeners.add(fn);\n return () => {\n ownerListeners.delete(fn);\n };\n}\n// ── The ambient API. Import and call; nothing to wire. ────────────────────────\n/** Record a named product event → insights.hanzo.ai. */\nexport const track = (event, properties, commerce) => getTelemetry().track(event, properties, commerce);\n/** Record a pageview → analytics.hanzo.ai. */\nexport const pageview = (path, properties) => getTelemetry().pageview(path, properties);\n/** Bind the visitor to a stable person id. */\nexport const identify = (personId, traits) => getTelemetry().identify(personId, traits);\n/** Associate the visitor with an org/team. */\nexport const group = (groupId, traits) => getTelemetry().group(groupId, traits);\n/** Report an exception → sentry.hanzo.ai (and `analytics_errors` in insights). */\nexport const captureError = (err, context) => getTelemetry().captureError(err, context);\n/** Alias of `captureError`. */\nexport const captureException = captureError;\n/** Drain the buffer now. */\nexport const flush = () => getTelemetry().flush();\n//# sourceMappingURL=telemetry.js.map","export const camelCaseToDashed = camelCase => {\n return camelCase.replace(/[A-Z]/g, m => '-' + m.toLowerCase());\n};\nexport const getBoundingClientRect = node => {\n if (node) {\n const isElement = node.nodeType === 1; /* Node.ELEMENT_NODE */\n if (isElement && typeof node.getBoundingClientRect === 'function') {\n return node.getBoundingClientRect();\n }\n }\n throw new Error('Can not get boundingClientRect of ' + node || 'undefined');\n};\nconst measureLayout = (node, callback) => {\n const relativeNode = node === null || node === void 0 ? void 0 : node.parentNode;\n if (relativeNode) {\n setTimeout(() => {\n // @ts-expect-error TODO: handle it better\n const relativeRect = getBoundingClientRect(relativeNode);\n const {\n height,\n left,\n top,\n width\n } = getBoundingClientRect(node);\n const x = left - relativeRect.left;\n const y = top - relativeRect.top;\n callback(x, y, width, height, left, top);\n }, 0);\n }\n};\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport function remeasure() {\n const tag = this.state.touchable.responderID;\n if (tag === null) {\n return;\n }\n measureLayout(tag, this._handleQueryLayout);\n}\n\n/* Taken from here: https://gist.github.com/jennyknuth/222825e315d45a738ed9d6e04c7a88d0 */\nexport function encodeSvg(svgString) {\n return svgString.replace('<svg', ~svgString.indexOf('xmlns') ? '<svg' : '<svg xmlns=\"http://www.w3.org/2000/svg\"').replace(/\"/g, \"'\").replace(/%/g, '%25').replace(/#/g, '%23').replace(/{/g, '%7B').replace(/}/g, '%7D').replace(/</g, '%3C').replace(/>/g, '%3E').replace(/\\s+/g, ' ');\n}\nconst KEEP_CAMEL_CASE = new Set(['stdDeviation', 'edgeMode', 'kernelMatrix', 'kernelUnitLength', 'preserveAlpha', 'baseFrequency', 'targetX', 'targetY', 'numOctaves', 'stitchTiles', 'filterUnits', 'primitiveUnits', 'pathLength', 'gradientUnits', 'gradientTransform', 'spreadMethod', 'markerHeight', 'markerUnits', 'markerWidth', 'viewBox', 'refX', 'refY', 'maskContentUnits', 'maskUnits', 'patternContentUnits', 'patternTransform', 'patternUnits', 'textLength', 'lengthAdjust', 'startOffset', 'clipPathUnits']);\nexport const getAttributeName = attr => {\n return KEEP_CAMEL_CASE.has(attr) ? attr : camelCaseToDashed(attr);\n};\n//# sourceMappingURL=index.js.map","export function hasTouchableProperty(props) {\n return !!(props.onPress || props.onPressIn || props.onPressOut || props.onLongPress);\n}\n//# sourceMappingURL=hasProperty.js.map","/**\n * based on\n * https://github.com/CreateJS/EaselJS/blob/631cdffb85eff9413dab43b4676f059b4232d291/src/easeljs/geom/Matrix2D.js\n */\nconst DEG_TO_RAD = Math.PI / 180;\nexport const identity = [1, 0, 0, 1, 0, 0];\nlet a = 1;\nlet b = 0;\nlet c = 0;\nlet d = 1;\nlet tx = 0;\nlet ty = 0;\nlet hasInitialState = true;\n\n/**\n * Represents an affine transformation matrix, and provides tools for concatenating transforms.\n *\n * This matrix can be visualized as:\n *\n * \t[ a c tx\n * \t b d ty\n * \t 0 0 1 ]\n *\n * Note the locations of b and c.\n **/\n\n/**\n * Reset current matrix to an identity matrix.\n * @method reset\n **/\nexport function reset() {\n if (hasInitialState) {\n return;\n }\n a = d = 1;\n b = c = tx = ty = 0;\n hasInitialState = true;\n}\n\n/**\n * Returns an array with current matrix values.\n * @method toArray\n * @return {Array} an array with current matrix values.\n **/\nexport function toArray() {\n if (hasInitialState) {\n return identity;\n }\n return [a, b, c, d, tx, ty];\n}\n\n/**\n * Appends the specified matrix properties to this matrix. All parameters are required.\n * This is the equivalent of multiplying `(this matrix) * (specified matrix)`.\n * @method append\n * @param {Number} a2\n * @param {Number} b2\n * @param {Number} c2\n * @param {Number} d2\n * @param {Number} tx2\n * @param {Number} ty2\n **/\nexport function append(a2, b2, c2, d2, tx2, ty2) {\n const change = a2 !== 1 || b2 !== 0 || c2 !== 0 || d2 !== 1;\n const translate = tx2 !== 0 || ty2 !== 0;\n if (!change && !translate) {\n return;\n }\n if (hasInitialState) {\n hasInitialState = false;\n a = a2;\n b = b2;\n c = c2;\n d = d2;\n tx = tx2;\n ty = ty2;\n return;\n }\n const a1 = a;\n const b1 = b;\n const c1 = c;\n const d1 = d;\n if (change) {\n a = a1 * a2 + c1 * b2;\n b = b1 * a2 + d1 * b2;\n c = a1 * c2 + c1 * d2;\n d = b1 * c2 + d1 * d2;\n }\n if (translate) {\n tx = a1 * tx2 + c1 * ty2 + tx;\n ty = b1 * tx2 + d1 * ty2 + ty;\n }\n}\n\n/**\n * Generates matrix properties from the specified display object transform properties, and appends them to this matrix.\n * For example, you can use this to generate a matrix representing the transformations of a display object:\n *\n * \treset();\n * \tappendTransform(o.x, o.y, o.scaleX, o.scaleY, o.rotation);\n * \tvar matrix = toArray()\n *\n * @method appendTransform\n * @param {Number} x\n * @param {Number} y\n * @param {Number} scaleX\n * @param {Number} scaleY\n * @param {Number} rotation\n * @param {Number} skewX\n * @param {Number} skewY\n * @param {Number} regX Optional.\n * @param {Number} regY Optional.\n **/\nexport function appendTransform(x, y, scaleX, scaleY, rotation, skewX, skewY, regX, regY) {\n if (x === 0 && y === 0 && scaleX === 1 && scaleY === 1 && rotation === 0 && skewX === 0 && skewY === 0 && regX === 0 && regY === 0) {\n return;\n }\n let cos, sin;\n if (rotation % 360) {\n const r = rotation * DEG_TO_RAD;\n cos = Math.cos(r);\n sin = Math.sin(r);\n } else {\n cos = 1;\n sin = 0;\n }\n const a2 = cos * scaleX;\n const b2 = sin * scaleX;\n const c2 = -sin * scaleY;\n const d2 = cos * scaleY;\n if (skewX || skewY) {\n const b1 = Math.tan(skewY * DEG_TO_RAD);\n const c1 = Math.tan(skewX * DEG_TO_RAD);\n append(a2 + c1 * b2, b1 * a2 + b2, c2 + c1 * d2, b1 * c2 + d2, x, y);\n } else {\n append(a2, b2, c2, d2, x, y);\n }\n if (regX || regY) {\n // append the registration offset:\n tx -= regX * a + regY * c;\n ty -= regX * b + regY * d;\n hasInitialState = false;\n }\n}\n//# sourceMappingURL=Matrix2D.js.map","/*\n * Generated by PEG.js 0.10.0.\n *\n * http://pegjs.org/\n */\n\n\"use strict\";\n\nfunction peg$subclass(child, parent) {\n function ctor() {\n this.constructor = child;\n }\n ctor.prototype = parent.prototype;\n child.prototype = new ctor();\n}\nfunction peg$SyntaxError(message, expected, found, location) {\n this.message = message;\n this.expected = expected;\n this.found = found;\n this.location = location;\n this.name = \"SyntaxError\";\n if (typeof Error.captureStackTrace === \"function\") {\n Error.captureStackTrace(this, peg$SyntaxError);\n }\n}\npeg$subclass(peg$SyntaxError, Error);\npeg$SyntaxError.buildMessage = function (expected, found) {\n var DESCRIBE_EXPECTATION_FNS = {\n literal: function (expectation) {\n return \"\\\"\" + literalEscape(expectation.text) + \"\\\"\";\n },\n \"class\": function (expectation) {\n var escapedParts = \"\",\n i;\n for (i = 0; i < expectation.parts.length; i++) {\n escapedParts += expectation.parts[i] instanceof Array ? classEscape(expectation.parts[i][0]) + \"-\" + classEscape(expectation.parts[i][1]) : classEscape(expectation.parts[i]);\n }\n return \"[\" + (expectation.inverted ? \"^\" : \"\") + escapedParts + \"]\";\n },\n any: function (expectation) {\n return \"any character\";\n },\n end: function (expectation) {\n return \"end of input\";\n },\n other: function (expectation) {\n return expectation.description;\n }\n };\n function hex(ch) {\n return ch.charCodeAt(0).toString(16).toUpperCase();\n }\n function literalEscape(s) {\n return s.replace(/\\\\/g, '\\\\\\\\').replace(/\"/g, '\\\\\"').replace(/\\0/g, '\\\\0').replace(/\\t/g, '\\\\t').replace(/\\n/g, '\\\\n').replace(/\\r/g, '\\\\r').replace(/[\\x00-\\x0F]/g, function (ch) {\n return '\\\\x0' + hex(ch);\n }).replace(/[\\x10-\\x1F\\x7F-\\x9F]/g, function (ch) {\n return '\\\\x' + hex(ch);\n });\n }\n function classEscape(s) {\n return s.replace(/\\\\/g, '\\\\\\\\').replace(/\\]/g, '\\\\]').replace(/\\^/g, '\\\\^').replace(/-/g, '\\\\-').replace(/\\0/g, '\\\\0').replace(/\\t/g, '\\\\t').replace(/\\n/g, '\\\\n').replace(/\\r/g, '\\\\r').replace(/[\\x00-\\x0F]/g, function (ch) {\n return '\\\\x0' + hex(ch);\n }).replace(/[\\x10-\\x1F\\x7F-\\x9F]/g, function (ch) {\n return '\\\\x' + hex(ch);\n });\n }\n function describeExpectation(expectation) {\n return DESCRIBE_EXPECTATION_FNS[expectation.type](expectation);\n }\n function describeExpected(expected) {\n var descriptions = new Array(expected.length),\n i,\n j;\n for (i = 0; i < expected.length; i++) {\n descriptions[i] = describeExpectation(expected[i]);\n }\n descriptions.sort();\n if (descriptions.length > 0) {\n for (i = 1, j = 1; i < descriptions.length; i++) {\n if (descriptions[i - 1] !== descriptions[i]) {\n descriptions[j] = descriptions[i];\n j++;\n }\n }\n descriptions.length = j;\n }\n switch (descriptions.length) {\n case 1:\n return descriptions[0];\n case 2:\n return descriptions[0] + \" or \" + descriptions[1];\n default:\n return descriptions.slice(0, -1).join(\", \") + \", or \" + descriptions[descriptions.length - 1];\n }\n }\n function describeFound(found) {\n return found ? \"\\\"\" + literalEscape(found) + \"\\\"\" : \"end of input\";\n }\n return \"Expected \" + describeExpected(expected) + \" but \" + describeFound(found) + \" found.\";\n};\nfunction peg$parse(input, options) {\n options = options !== void 0 ? options : {};\n var peg$FAILED = {},\n peg$startRuleFunctions = {\n transformList: peg$parsetransformList\n },\n peg$startRuleFunction = peg$parsetransformList,\n peg$c0 = function (ts) {\n return ts;\n },\n peg$c1 = function (t, ts) {\n return multiply_matrices(t, ts);\n },\n peg$c2 = \"matrix\",\n peg$c3 = peg$literalExpectation(\"matrix\", false),\n peg$c4 = \"(\",\n peg$c5 = peg$literalExpectation(\"(\", false),\n peg$c6 = \")\",\n peg$c7 = peg$literalExpectation(\")\", false),\n peg$c8 = function (a, b, c, d, e, f) {\n return [a, c, e, b, d, f];\n },\n peg$c9 = \"translate\",\n peg$c10 = peg$literalExpectation(\"translate\", false),\n peg$c11 = function (tx, ty) {\n return [1, 0, tx, 0, 1, ty || 0];\n },\n peg$c12 = \"scale\",\n peg$c13 = peg$literalExpectation(\"scale\", false),\n peg$c14 = function (sx, sy) {\n return [sx, 0, 0, 0, sy === null ? sx : sy, 0];\n },\n peg$c15 = \"rotate\",\n peg$c16 = peg$literalExpectation(\"rotate\", false),\n peg$c17 = function (angle, c) {\n var cos = Math.cos(deg2rad * angle);\n var sin = Math.sin(deg2rad * angle);\n if (c !== null) {\n var x = c[0];\n var y = c[1];\n return [cos, -sin, cos * -x + -sin * -y + x, sin, cos, sin * -x + cos * -y + y];\n }\n return [cos, -sin, 0, sin, cos, 0];\n },\n peg$c18 = \"skewX\",\n peg$c19 = peg$literalExpectation(\"skewX\", false),\n peg$c20 = function (angle) {\n return [1, Math.tan(deg2rad * angle), 0, 0, 1, 0];\n },\n peg$c21 = \"skewY\",\n peg$c22 = peg$literalExpectation(\"skewY\", false),\n peg$c23 = function (angle) {\n return [1, 0, 0, Math.tan(deg2rad * angle), 1, 0];\n },\n peg$c24 = function (f) {\n return parseFloat(f.join(\"\"));\n },\n peg$c25 = function (i) {\n return parseInt(i.join(\"\"));\n },\n peg$c26 = function (n) {\n return n;\n },\n peg$c27 = function (n1, n2) {\n return [n1, n2];\n },\n peg$c28 = \",\",\n peg$c29 = peg$literalExpectation(\",\", false),\n peg$c30 = function (ds) {\n return ds.join(\"\");\n },\n peg$c31 = function (f) {\n return f.join(\"\");\n },\n peg$c32 = function (d) {\n return d.join(\"\");\n },\n peg$c33 = peg$otherExpectation(\"fractionalConstant\"),\n peg$c34 = \".\",\n peg$c35 = peg$literalExpectation(\".\", false),\n peg$c36 = function (d1, d2) {\n return [d1 ? d1.join(\"\") : null, \".\", d2.join(\"\")].join(\"\");\n },\n peg$c37 = /^[eE]/,\n peg$c38 = peg$classExpectation([\"e\", \"E\"], false, false),\n peg$c39 = function (e) {\n return [e[0], e[1], e[2].join(\"\")].join(\"\");\n },\n peg$c40 = /^[+\\-]/,\n peg$c41 = peg$classExpectation([\"+\", \"-\"], false, false),\n peg$c42 = /^[0-9]/,\n peg$c43 = peg$classExpectation([[\"0\", \"9\"]], false, false),\n peg$c44 = /^[ \\t\\r\\n]/,\n peg$c45 = peg$classExpectation([\" \", \"\\t\", \"\\r\", \"\\n\"], false, false),\n peg$currPos = 0,\n peg$savedPos = 0,\n peg$posDetailsCache = [{\n line: 1,\n column: 1\n }],\n peg$maxFailPos = 0,\n peg$maxFailExpected = [],\n peg$silentFails = 0,\n peg$result;\n if (\"startRule\" in options) {\n if (!(options.startRule in peg$startRuleFunctions)) {\n throw new Error(\"Can't start parsing from rule \\\"\" + options.startRule + \"\\\".\");\n }\n peg$startRuleFunction = peg$startRuleFunctions[options.startRule];\n }\n function text() {\n return input.substring(peg$savedPos, peg$currPos);\n }\n function location() {\n return peg$computeLocation(peg$savedPos, peg$currPos);\n }\n function expected(description, location) {\n location = location !== void 0 ? location : peg$computeLocation(peg$savedPos, peg$currPos);\n throw peg$buildStructuredError([peg$otherExpectation(description)], input.substring(peg$savedPos, peg$currPos), location);\n }\n function error(message, location) {\n location = location !== void 0 ? location : peg$computeLocation(peg$savedPos, peg$currPos);\n throw peg$buildSimpleError(message, location);\n }\n function peg$literalExpectation(text, ignoreCase) {\n return {\n type: \"literal\",\n text: text,\n ignoreCase: ignoreCase\n };\n }\n function peg$classExpectation(parts, inverted, ignoreCase) {\n return {\n type: \"class\",\n parts: parts,\n inverted: inverted,\n ignoreCase: ignoreCase\n };\n }\n function peg$anyExpectation() {\n return {\n type: \"any\"\n };\n }\n function peg$endExpectation() {\n return {\n type: \"end\"\n };\n }\n function peg$otherExpectation(description) {\n return {\n type: \"other\",\n description: description\n };\n }\n function peg$computePosDetails(pos) {\n var details = peg$posDetailsCache[pos],\n p;\n if (details) {\n return details;\n } else {\n p = pos - 1;\n while (!peg$posDetailsCache[p]) {\n p--;\n }\n details = peg$posDetailsCache[p];\n details = {\n line: details.line,\n column: details.column\n };\n while (p < pos) {\n if (input.charCodeAt(p) === 10) {\n details.line++;\n details.column = 1;\n } else {\n details.column++;\n }\n p++;\n }\n peg$posDetailsCache[pos] = details;\n return details;\n }\n }\n function peg$computeLocation(startPos, endPos) {\n var startPosDetails = peg$computePosDetails(startPos),\n endPosDetails = peg$computePosDetails(endPos);\n return {\n start: {\n offset: startPos,\n line: startPosDetails.line,\n column: startPosDetails.column\n },\n end: {\n offset: endPos,\n line: endPosDetails.line,\n column: endPosDetails.column\n }\n };\n }\n function peg$fail(expected) {\n if (peg$currPos < peg$maxFailPos) {\n return;\n }\n if (peg$currPos > peg$maxFailPos) {\n peg$maxFailPos = peg$currPos;\n peg$maxFailExpected = [];\n }\n peg$maxFailExpected.push(expected);\n }\n function peg$buildSimpleError(message, location) {\n return new peg$SyntaxError(message, null, null, location);\n }\n function peg$buildStructuredError(expected, found, location) {\n return new peg$SyntaxError(peg$SyntaxError.buildMessage(expected, found), expected, found, location);\n }\n function peg$parsetransformList() {\n var s0, s1, s2, s3, s4;\n s0 = peg$currPos;\n s1 = [];\n s2 = peg$parsewsp();\n while (s2 !== peg$FAILED) {\n s1.push(s2);\n s2 = peg$parsewsp();\n }\n if (s1 !== peg$FAILED) {\n s2 = peg$parsetransforms();\n if (s2 === peg$FAILED) {\n s2 = null;\n }\n if (s2 !== peg$FAILED) {\n s3 = [];\n s4 = peg$parsewsp();\n while (s4 !== peg$FAILED) {\n s3.push(s4);\n s4 = peg$parsewsp();\n }\n if (s3 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c0(s2);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parsetransforms() {\n var s0, s1, s2, s3;\n s0 = peg$currPos;\n s1 = peg$parsetransform();\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$parsecommaWsp();\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$parsecommaWsp();\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parsetransforms();\n if (s3 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c1(s1, s3);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n if (s0 === peg$FAILED) {\n s0 = peg$parsetransform();\n }\n return s0;\n }\n function peg$parsetransform() {\n var s0;\n s0 = peg$parsematrix();\n if (s0 === peg$FAILED) {\n s0 = peg$parsetranslate();\n if (s0 === peg$FAILED) {\n s0 = peg$parsescale();\n if (s0 === peg$FAILED) {\n s0 = peg$parserotate();\n if (s0 === peg$FAILED) {\n s0 = peg$parseskewX();\n if (s0 === peg$FAILED) {\n s0 = peg$parseskewY();\n }\n }\n }\n }\n }\n return s0;\n }\n function peg$parsematrix() {\n var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9, s10, s11, s12, s13, s14, s15, s16, s17;\n s0 = peg$currPos;\n if (input.substr(peg$currPos, 6) === peg$c2) {\n s1 = peg$c2;\n peg$currPos += 6;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c3);\n }\n }\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$parsewsp();\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$parsewsp();\n }\n if (s2 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 40) {\n s3 = peg$c4;\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c5);\n }\n }\n if (s3 !== peg$FAILED) {\n s4 = [];\n s5 = peg$parsewsp();\n while (s5 !== peg$FAILED) {\n s4.push(s5);\n s5 = peg$parsewsp();\n }\n if (s4 !== peg$FAILED) {\n s5 = peg$parsenumber();\n if (s5 !== peg$FAILED) {\n s6 = peg$parsecommaWsp();\n if (s6 !== peg$FAILED) {\n s7 = peg$parsenumber();\n if (s7 !== peg$FAILED) {\n s8 = peg$parsecommaWsp();\n if (s8 !== peg$FAILED) {\n s9 = peg$parsenumber();\n if (s9 !== peg$FAILED) {\n s10 = peg$parsecommaWsp();\n if (s10 !== peg$FAILED) {\n s11 = peg$parsenumber();\n if (s11 !== peg$FAILED) {\n s12 = peg$parsecommaWsp();\n if (s12 !== peg$FAILED) {\n s13 = peg$parsenumber();\n if (s13 !== peg$FAILED) {\n s14 = peg$parsecommaWsp();\n if (s14 !== peg$FAILED) {\n s15 = peg$parsenumber();\n if (s15 !== peg$FAILED) {\n s16 = [];\n s17 = peg$parsewsp();\n while (s17 !== peg$FAILED) {\n s16.push(s17);\n s17 = peg$parsewsp();\n }\n if (s16 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 41) {\n s17 = peg$c6;\n peg$currPos++;\n } else {\n s17 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c7);\n }\n }\n if (s17 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c8(s5, s7, s9, s11, s13, s15);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parsetranslate() {\n var s0, s1, s2, s3, s4, s5, s6, s7, s8;\n s0 = peg$currPos;\n if (input.substr(peg$currPos, 9) === peg$c9) {\n s1 = peg$c9;\n peg$currPos += 9;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c10);\n }\n }\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$parsewsp();\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$parsewsp();\n }\n if (s2 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 40) {\n s3 = peg$c4;\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c5);\n }\n }\n if (s3 !== peg$FAILED) {\n s4 = [];\n s5 = peg$parsewsp();\n while (s5 !== peg$FAILED) {\n s4.push(s5);\n s5 = peg$parsewsp();\n }\n if (s4 !== peg$FAILED) {\n s5 = peg$parsenumber();\n if (s5 !== peg$FAILED) {\n s6 = peg$parsecommaWspNumber();\n if (s6 === peg$FAILED) {\n s6 = null;\n }\n if (s6 !== peg$FAILED) {\n s7 = [];\n s8 = peg$parsewsp();\n while (s8 !== peg$FAILED) {\n s7.push(s8);\n s8 = peg$parsewsp();\n }\n if (s7 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 41) {\n s8 = peg$c6;\n peg$currPos++;\n } else {\n s8 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c7);\n }\n }\n if (s8 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c11(s5, s6);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parsescale() {\n var s0, s1, s2, s3, s4, s5, s6, s7, s8;\n s0 = peg$currPos;\n if (input.substr(peg$currPos, 5) === peg$c12) {\n s1 = peg$c12;\n peg$currPos += 5;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c13);\n }\n }\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$parsewsp();\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$parsewsp();\n }\n if (s2 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 40) {\n s3 = peg$c4;\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c5);\n }\n }\n if (s3 !== peg$FAILED) {\n s4 = [];\n s5 = peg$parsewsp();\n while (s5 !== peg$FAILED) {\n s4.push(s5);\n s5 = peg$parsewsp();\n }\n if (s4 !== peg$FAILED) {\n s5 = peg$parsenumber();\n if (s5 !== peg$FAILED) {\n s6 = peg$parsecommaWspNumber();\n if (s6 === peg$FAILED) {\n s6 = null;\n }\n if (s6 !== peg$FAILED) {\n s7 = [];\n s8 = peg$parsewsp();\n while (s8 !== peg$FAILED) {\n s7.push(s8);\n s8 = peg$parsewsp();\n }\n if (s7 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 41) {\n s8 = peg$c6;\n peg$currPos++;\n } else {\n s8 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c7);\n }\n }\n if (s8 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c14(s5, s6);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parserotate() {\n var s0, s1, s2, s3, s4, s5, s6, s7, s8;\n s0 = peg$currPos;\n if (input.substr(peg$currPos, 6) === peg$c15) {\n s1 = peg$c15;\n peg$currPos += 6;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c16);\n }\n }\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$parsewsp();\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$parsewsp();\n }\n if (s2 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 40) {\n s3 = peg$c4;\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c5);\n }\n }\n if (s3 !== peg$FAILED) {\n s4 = [];\n s5 = peg$parsewsp();\n while (s5 !== peg$FAILED) {\n s4.push(s5);\n s5 = peg$parsewsp();\n }\n if (s4 !== peg$FAILED) {\n s5 = peg$parsenumber();\n if (s5 !== peg$FAILED) {\n s6 = peg$parsecommaWspTwoNumbers();\n if (s6 === peg$FAILED) {\n s6 = null;\n }\n if (s6 !== peg$FAILED) {\n s7 = [];\n s8 = peg$parsewsp();\n while (s8 !== peg$FAILED) {\n s7.push(s8);\n s8 = peg$parsewsp();\n }\n if (s7 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 41) {\n s8 = peg$c6;\n peg$currPos++;\n } else {\n s8 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c7);\n }\n }\n if (s8 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c17(s5, s6);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parseskewX() {\n var s0, s1, s2, s3, s4, s5, s6, s7;\n s0 = peg$currPos;\n if (input.substr(peg$currPos, 5) === peg$c18) {\n s1 = peg$c18;\n peg$currPos += 5;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c19);\n }\n }\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$parsewsp();\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$parsewsp();\n }\n if (s2 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 40) {\n s3 = peg$c4;\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c5);\n }\n }\n if (s3 !== peg$FAILED) {\n s4 = [];\n s5 = peg$parsewsp();\n while (s5 !== peg$FAILED) {\n s4.push(s5);\n s5 = peg$parsewsp();\n }\n if (s4 !== peg$FAILED) {\n s5 = peg$parsenumber();\n if (s5 !== peg$FAILED) {\n s6 = [];\n s7 = peg$parsewsp();\n while (s7 !== peg$FAILED) {\n s6.push(s7);\n s7 = peg$parsewsp();\n }\n if (s6 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 41) {\n s7 = peg$c6;\n peg$currPos++;\n } else {\n s7 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c7);\n }\n }\n if (s7 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c20(s5);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parseskewY() {\n var s0, s1, s2, s3, s4, s5, s6, s7;\n s0 = peg$currPos;\n if (input.substr(peg$currPos, 5) === peg$c21) {\n s1 = peg$c21;\n peg$currPos += 5;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c22);\n }\n }\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$parsewsp();\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$parsewsp();\n }\n if (s2 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 40) {\n s3 = peg$c4;\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c5);\n }\n }\n if (s3 !== peg$FAILED) {\n s4 = [];\n s5 = peg$parsewsp();\n while (s5 !== peg$FAILED) {\n s4.push(s5);\n s5 = peg$parsewsp();\n }\n if (s4 !== peg$FAILED) {\n s5 = peg$parsenumber();\n if (s5 !== peg$FAILED) {\n s6 = [];\n s7 = peg$parsewsp();\n while (s7 !== peg$FAILED) {\n s6.push(s7);\n s7 = peg$parsewsp();\n }\n if (s6 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 41) {\n s7 = peg$c6;\n peg$currPos++;\n } else {\n s7 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c7);\n }\n }\n if (s7 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c23(s5);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parsenumber() {\n var s0, s1, s2, s3;\n s0 = peg$currPos;\n s1 = peg$currPos;\n s2 = peg$parsesign();\n if (s2 === peg$FAILED) {\n s2 = null;\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parsefloatingPointConstant();\n if (s3 !== peg$FAILED) {\n s2 = [s2, s3];\n s1 = s2;\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c24(s1);\n }\n s0 = s1;\n if (s0 === peg$FAILED) {\n s0 = peg$currPos;\n s1 = peg$currPos;\n s2 = peg$parsesign();\n if (s2 === peg$FAILED) {\n s2 = null;\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parseintegerConstant();\n if (s3 !== peg$FAILED) {\n s2 = [s2, s3];\n s1 = s2;\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c25(s1);\n }\n s0 = s1;\n }\n return s0;\n }\n function peg$parsecommaWspNumber() {\n var s0, s1, s2;\n s0 = peg$currPos;\n s1 = peg$parsecommaWsp();\n if (s1 !== peg$FAILED) {\n s2 = peg$parsenumber();\n if (s2 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c26(s2);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parsecommaWspTwoNumbers() {\n var s0, s1, s2, s3, s4;\n s0 = peg$currPos;\n s1 = peg$parsecommaWsp();\n if (s1 !== peg$FAILED) {\n s2 = peg$parsenumber();\n if (s2 !== peg$FAILED) {\n s3 = peg$parsecommaWsp();\n if (s3 !== peg$FAILED) {\n s4 = peg$parsenumber();\n if (s4 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c27(s2, s4);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parsecommaWsp() {\n var s0, s1, s2, s3, s4;\n s0 = peg$currPos;\n s1 = [];\n s2 = peg$parsewsp();\n if (s2 !== peg$FAILED) {\n while (s2 !== peg$FAILED) {\n s1.push(s2);\n s2 = peg$parsewsp();\n }\n } else {\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n s2 = peg$parsecomma();\n if (s2 === peg$FAILED) {\n s2 = null;\n }\n if (s2 !== peg$FAILED) {\n s3 = [];\n s4 = peg$parsewsp();\n while (s4 !== peg$FAILED) {\n s3.push(s4);\n s4 = peg$parsewsp();\n }\n if (s3 !== peg$FAILED) {\n s1 = [s1, s2, s3];\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n if (s0 === peg$FAILED) {\n s0 = peg$currPos;\n s1 = peg$parsecomma();\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$parsewsp();\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$parsewsp();\n }\n if (s2 !== peg$FAILED) {\n s1 = [s1, s2];\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n }\n return s0;\n }\n function peg$parsecomma() {\n var s0;\n if (input.charCodeAt(peg$currPos) === 44) {\n s0 = peg$c28;\n peg$currPos++;\n } else {\n s0 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c29);\n }\n }\n return s0;\n }\n function peg$parseintegerConstant() {\n var s0, s1;\n s0 = peg$currPos;\n s1 = peg$parsedigitSequence();\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c30(s1);\n }\n s0 = s1;\n return s0;\n }\n function peg$parsefloatingPointConstant() {\n var s0, s1, s2, s3;\n s0 = peg$currPos;\n s1 = peg$currPos;\n s2 = peg$parsefractionalConstant();\n if (s2 !== peg$FAILED) {\n s3 = peg$parseexponent();\n if (s3 === peg$FAILED) {\n s3 = null;\n }\n if (s3 !== peg$FAILED) {\n s2 = [s2, s3];\n s1 = s2;\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c31(s1);\n }\n s0 = s1;\n if (s0 === peg$FAILED) {\n s0 = peg$currPos;\n s1 = peg$currPos;\n s2 = peg$parsedigitSequence();\n if (s2 !== peg$FAILED) {\n s3 = peg$parseexponent();\n if (s3 !== peg$FAILED) {\n s2 = [s2, s3];\n s1 = s2;\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c32(s1);\n }\n s0 = s1;\n }\n return s0;\n }\n function peg$parsefractionalConstant() {\n var s0, s1, s2, s3;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parsedigitSequence();\n if (s1 === peg$FAILED) {\n s1 = null;\n }\n if (s1 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 46) {\n s2 = peg$c34;\n peg$currPos++;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c35);\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parsedigitSequence();\n if (s3 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c36(s1, s3);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n if (s0 === peg$FAILED) {\n s0 = peg$currPos;\n s1 = peg$parsedigitSequence();\n if (s1 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 46) {\n s2 = peg$c34;\n peg$currPos++;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c35);\n }\n }\n if (s2 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c32(s1);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c33);\n }\n }\n return s0;\n }\n function peg$parseexponent() {\n var s0, s1, s2, s3, s4;\n s0 = peg$currPos;\n s1 = peg$currPos;\n if (peg$c37.test(input.charAt(peg$currPos))) {\n s2 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c38);\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parsesign();\n if (s3 === peg$FAILED) {\n s3 = null;\n }\n if (s3 !== peg$FAILED) {\n s4 = peg$parsedigitSequence();\n if (s4 !== peg$FAILED) {\n s2 = [s2, s3, s4];\n s1 = s2;\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n } else {\n peg$currPos = s1;\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c39(s1);\n }\n s0 = s1;\n return s0;\n }\n function peg$parsesign() {\n var s0;\n if (peg$c40.test(input.charAt(peg$currPos))) {\n s0 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s0 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c41);\n }\n }\n return s0;\n }\n function peg$parsedigitSequence() {\n var s0, s1;\n s0 = [];\n s1 = peg$parsedigit();\n if (s1 !== peg$FAILED) {\n while (s1 !== peg$FAILED) {\n s0.push(s1);\n s1 = peg$parsedigit();\n }\n } else {\n s0 = peg$FAILED;\n }\n return s0;\n }\n function peg$parsedigit() {\n var s0;\n if (peg$c42.test(input.charAt(peg$currPos))) {\n s0 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s0 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c43);\n }\n }\n return s0;\n }\n function peg$parsewsp() {\n var s0;\n if (peg$c44.test(input.charAt(peg$currPos))) {\n s0 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s0 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$c45);\n }\n }\n return s0;\n }\n var deg2rad = Math.PI / 180;\n\n /*\n ╔═ ═╗ ╔═ ═╗ ╔═ ═╗\n ║ al cl el ║ ║ ar cr er ║ ║ a c e ║\n ║ bl dl fl ║ * ║ br dr fr ║ = ║ b d f ║\n ║ 0 0 1 ║ ║ 0 0 1 ║ ║ 0 0 1 ║\n ╚═ ═╝ ╚═ ═╝ ╚═ ═╝\n */\n function multiply_matrices(l, r) {\n var al = l[0];\n var cl = l[1];\n var el = l[2];\n var bl = l[3];\n var dl = l[4];\n var fl = l[5];\n var ar = r[0];\n var cr = r[1];\n var er = r[2];\n var br = r[3];\n var dr = r[4];\n var fr = r[5];\n var a = al * ar + cl * br;\n var c = al * cr + cl * dr;\n var e = al * er + cl * fr + el;\n var b = bl * ar + dl * br;\n var d = bl * cr + dl * dr;\n var f = bl * er + dl * fr + fl;\n return [a, c, e, b, d, f];\n }\n peg$result = peg$startRuleFunction();\n if (peg$result !== peg$FAILED && peg$currPos === input.length) {\n return peg$result;\n } else {\n if (peg$result !== peg$FAILED && peg$currPos < input.length) {\n peg$fail(peg$endExpectation());\n }\n throw peg$buildStructuredError(peg$maxFailExpected, peg$maxFailPos < input.length ? input.charAt(peg$maxFailPos) : null, peg$maxFailPos < input.length ? peg$computeLocation(peg$maxFailPos, peg$maxFailPos + 1) : peg$computeLocation(peg$maxFailPos, peg$maxFailPos));\n }\n}\nmodule.exports = {\n SyntaxError: peg$SyntaxError,\n parse: peg$parse\n};\n//# sourceMappingURL=transform.js.map","// @generated by Peggy 4.0.3.\n//\n// https://peggyjs.org/\n\n'use strict';\n\nfunction peg$subclass(child, parent) {\n function C() {\n this.constructor = child;\n }\n C.prototype = parent.prototype;\n child.prototype = new C();\n}\nfunction peg$SyntaxError(message, expected, found, location) {\n var self = Error.call(this, message);\n // istanbul ignore next Check is a necessary evil to support older environments\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(self, peg$SyntaxError.prototype);\n }\n self.expected = expected;\n self.found = found;\n self.location = location;\n self.name = 'SyntaxError';\n return self;\n}\npeg$subclass(peg$SyntaxError, Error);\nfunction peg$padEnd(str, targetLength, padString) {\n padString = padString || ' ';\n if (str.length > targetLength) {\n return str;\n }\n targetLength -= str.length;\n padString += padString.repeat(targetLength);\n return str + padString.slice(0, targetLength);\n}\npeg$SyntaxError.prototype.format = function (sources) {\n var str = 'Error: ' + this.message;\n if (this.location) {\n var src = null;\n var k;\n for (k = 0; k < sources.length; k++) {\n if (sources[k].source === this.location.source) {\n src = sources[k].text.split(/\\r\\n|\\n|\\r/g);\n break;\n }\n }\n var s = this.location.start;\n var offset_s = this.location.source && typeof this.location.source.offset === 'function' ? this.location.source.offset(s) : s;\n var loc = this.location.source + ':' + offset_s.line + ':' + offset_s.column;\n if (src) {\n var e = this.location.end;\n var filler = peg$padEnd('', offset_s.line.toString().length, ' ');\n var line = src[s.line - 1];\n var last = s.line === e.line ? e.column : line.length + 1;\n var hatLen = last - s.column || 1;\n str += '\\n --> ' + loc + '\\n' + filler + ' |\\n' + offset_s.line + ' | ' + line + '\\n' + filler + ' | ' + peg$padEnd('', s.column - 1, ' ') + peg$padEnd('', hatLen, '^');\n } else {\n str += '\\n at ' + loc;\n }\n }\n return str;\n};\npeg$SyntaxError.buildMessage = function (expected, found) {\n var DESCRIBE_EXPECTATION_FNS = {\n literal: function (expectation) {\n return '\"' + literalEscape(expectation.text) + '\"';\n },\n class: function (expectation) {\n var escapedParts = expectation.parts.map(function (part) {\n return Array.isArray(part) ? classEscape(part[0]) + '-' + classEscape(part[1]) : classEscape(part);\n });\n return '[' + (expectation.inverted ? '^' : '') + escapedParts.join('') + ']';\n },\n any: function () {\n return 'any character';\n },\n end: function () {\n return 'end of input';\n },\n other: function (expectation) {\n return expectation.description;\n }\n };\n function hex(ch) {\n return ch.charCodeAt(0).toString(16).toUpperCase();\n }\n function literalEscape(s) {\n return s.replace(/\\\\/g, '\\\\\\\\').replace(/\"/g, '\\\\\"').replace(/\\0/g, '\\\\0').replace(/\\t/g, '\\\\t').replace(/\\n/g, '\\\\n').replace(/\\r/g, '\\\\r').replace(/[\\x00-\\x0F]/g, function (ch) {\n return '\\\\x0' + hex(ch);\n }).replace(/[\\x10-\\x1F\\x7F-\\x9F]/g, function (ch) {\n return '\\\\x' + hex(ch);\n });\n }\n function classEscape(s) {\n return s.replace(/\\\\/g, '\\\\\\\\').replace(/\\]/g, '\\\\]').replace(/\\^/g, '\\\\^').replace(/-/g, '\\\\-').replace(/\\0/g, '\\\\0').replace(/\\t/g, '\\\\t').replace(/\\n/g, '\\\\n').replace(/\\r/g, '\\\\r').replace(/[\\x00-\\x0F]/g, function (ch) {\n return '\\\\x0' + hex(ch);\n }).replace(/[\\x10-\\x1F\\x7F-\\x9F]/g, function (ch) {\n return '\\\\x' + hex(ch);\n });\n }\n function describeExpectation(expectation) {\n return DESCRIBE_EXPECTATION_FNS[expectation.type](expectation);\n }\n function describeExpected(expected) {\n var descriptions = expected.map(describeExpectation);\n var i, j;\n descriptions.sort();\n if (descriptions.length > 0) {\n for (i = 1, j = 1; i < descriptions.length; i++) {\n if (descriptions[i - 1] !== descriptions[i]) {\n descriptions[j] = descriptions[i];\n j++;\n }\n }\n descriptions.length = j;\n }\n switch (descriptions.length) {\n case 1:\n return descriptions[0];\n case 2:\n return descriptions[0] + ' or ' + descriptions[1];\n default:\n return descriptions.slice(0, -1).join(', ') + ', or ' + descriptions[descriptions.length - 1];\n }\n }\n function describeFound(found) {\n return found ? '\"' + literalEscape(found) + '\"' : 'end of input';\n }\n return 'Expected ' + describeExpected(expected) + ' but ' + describeFound(found) + ' found.';\n};\nfunction peg$parse(input, options) {\n options = options !== undefined ? options : {};\n var peg$FAILED = {};\n var peg$source = options.grammarSource;\n var peg$startRuleFunctions = {\n start: peg$parsestart\n };\n var peg$startRuleFunction = peg$parsestart;\n var peg$c0 = 'matrix(';\n var peg$c1 = ')';\n var peg$c2 = 'translate(';\n var peg$c3 = 'scale(';\n var peg$c4 = 'rotate(';\n var peg$c5 = 'skewX(';\n var peg$c6 = 'skewY(';\n var peg$c7 = '.';\n var peg$c8 = 'e';\n var peg$r0 = /^[ \\t\\n\\r,]/;\n var peg$r1 = /^[ \\t\\n\\r]/;\n var peg$r2 = /^[+\\-]/;\n var peg$r3 = /^[0-9]/;\n var peg$e0 = peg$otherExpectation('transform functions');\n var peg$e1 = peg$otherExpectation('transformFunctions');\n var peg$e2 = peg$otherExpectation('transform function');\n var peg$e3 = peg$otherExpectation('matrix');\n var peg$e4 = peg$literalExpectation('matrix(', false);\n var peg$e5 = peg$literalExpectation(')', false);\n var peg$e6 = peg$otherExpectation('translate');\n var peg$e7 = peg$literalExpectation('translate(', false);\n var peg$e8 = peg$otherExpectation('scale');\n var peg$e9 = peg$literalExpectation('scale(', false);\n var peg$e10 = peg$otherExpectation('rotate');\n var peg$e11 = peg$literalExpectation('rotate(', false);\n var peg$e12 = peg$otherExpectation('x, y');\n var peg$e13 = peg$otherExpectation('skewX');\n var peg$e14 = peg$literalExpectation('skewX(', false);\n var peg$e15 = peg$otherExpectation('skewY');\n var peg$e16 = peg$literalExpectation('skewY(', false);\n var peg$e17 = peg$otherExpectation('space or comma');\n var peg$e18 = peg$classExpectation([' ', '\\t', '\\n', '\\r', ','], false, false);\n var peg$e19 = peg$otherExpectation('whitespace');\n var peg$e20 = peg$classExpectation([' ', '\\t', '\\n', '\\r'], false, false);\n var peg$e21 = peg$classExpectation(['+', '-'], false, false);\n var peg$e22 = peg$classExpectation([['0', '9']], false, false);\n var peg$e23 = peg$literalExpectation('.', false);\n var peg$e24 = peg$literalExpectation('e', false);\n var peg$f0 = function (head, tail) {\n const results = Array.isArray(head) ? head : [head];\n tail.forEach(element => {\n if (Array.isArray(element[1])) {\n results.push(...element[1]);\n } else {\n results.push(element[1]);\n }\n });\n return results;\n };\n var peg$f1 = function (a, b, c, d, e, f, g, h, i) {\n return {\n matrix: [a, b, c, d, e, f, g, h, i]\n };\n };\n var peg$f2 = function (x, y) {\n if (y == undefined) {\n return {\n translate: x\n };\n }\n return {\n translate: [x, y]\n };\n };\n var peg$f3 = function (x, y) {\n if (y == undefined) {\n return {\n scale: x\n };\n }\n return [{\n scaleX: x\n }, {\n scaleY: y\n }];\n };\n var peg$f4 = function (x, yz) {\n if (yz !== null) {\n return {\n rotate: `${x}deg`\n };\n }\n return [{\n rotate: `${x}deg`\n }];\n };\n var peg$f5 = function (y, z) {\n return [y, z];\n };\n var peg$f6 = function (x) {\n return [{\n skewX: `${x}deg`\n }];\n };\n var peg$f7 = function (y) {\n return [{\n skewY: `${y}deg`\n }];\n };\n var peg$f8 = function () {\n return parseFloat(text());\n };\n var peg$currPos = options.peg$currPos | 0;\n var peg$savedPos = peg$currPos;\n var peg$posDetailsCache = [{\n line: 1,\n column: 1\n }];\n var peg$maxFailPos = peg$currPos;\n var peg$maxFailExpected = options.peg$maxFailExpected || [];\n var peg$silentFails = options.peg$silentFails | 0;\n var peg$result;\n if (options.startRule) {\n if (!(options.startRule in peg$startRuleFunctions)) {\n throw new Error('Can\\'t start parsing from rule \"' + options.startRule + '\".');\n }\n peg$startRuleFunction = peg$startRuleFunctions[options.startRule];\n }\n function text() {\n return input.substring(peg$savedPos, peg$currPos);\n }\n function offset() {\n return peg$savedPos;\n }\n function range() {\n return {\n source: peg$source,\n start: peg$savedPos,\n end: peg$currPos\n };\n }\n function location() {\n return peg$computeLocation(peg$savedPos, peg$currPos);\n }\n function expected(description, location) {\n location = location !== undefined ? location : peg$computeLocation(peg$savedPos, peg$currPos);\n throw peg$buildStructuredError([peg$otherExpectation(description)], input.substring(peg$savedPos, peg$currPos), location);\n }\n function error(message, location) {\n location = location !== undefined ? location : peg$computeLocation(peg$savedPos, peg$currPos);\n throw peg$buildSimpleError(message, location);\n }\n function peg$literalExpectation(text, ignoreCase) {\n return {\n type: 'literal',\n text: text,\n ignoreCase: ignoreCase\n };\n }\n function peg$classExpectation(parts, inverted, ignoreCase) {\n return {\n type: 'class',\n parts: parts,\n inverted: inverted,\n ignoreCase: ignoreCase\n };\n }\n function peg$anyExpectation() {\n return {\n type: 'any'\n };\n }\n function peg$endExpectation() {\n return {\n type: 'end'\n };\n }\n function peg$otherExpectation(description) {\n return {\n type: 'other',\n description: description\n };\n }\n function peg$computePosDetails(pos) {\n var details = peg$posDetailsCache[pos];\n var p;\n if (details) {\n return details;\n } else {\n if (pos >= peg$posDetailsCache.length) {\n p = peg$posDetailsCache.length - 1;\n } else {\n p = pos;\n while (!peg$posDetailsCache[--p]) {}\n }\n details = peg$posDetailsCache[p];\n details = {\n line: details.line,\n column: details.column\n };\n while (p < pos) {\n if (input.charCodeAt(p) === 10) {\n details.line++;\n details.column = 1;\n } else {\n details.column++;\n }\n p++;\n }\n peg$posDetailsCache[pos] = details;\n return details;\n }\n }\n function peg$computeLocation(startPos, endPos, offset) {\n var startPosDetails = peg$computePosDetails(startPos);\n var endPosDetails = peg$computePosDetails(endPos);\n var res = {\n source: peg$source,\n start: {\n offset: startPos,\n line: startPosDetails.line,\n column: startPosDetails.column\n },\n end: {\n offset: endPos,\n line: endPosDetails.line,\n column: endPosDetails.column\n }\n };\n if (offset && peg$source && typeof peg$source.offset === 'function') {\n res.start = peg$source.offset(res.start);\n res.end = peg$source.offset(res.end);\n }\n return res;\n }\n function peg$fail(expected) {\n if (peg$currPos < peg$maxFailPos) {\n return;\n }\n if (peg$currPos > peg$maxFailPos) {\n peg$maxFailPos = peg$currPos;\n peg$maxFailExpected = [];\n }\n peg$maxFailExpected.push(expected);\n }\n function peg$buildSimpleError(message, location) {\n return new peg$SyntaxError(message, null, null, location);\n }\n function peg$buildStructuredError(expected, found, location) {\n return new peg$SyntaxError(peg$SyntaxError.buildMessage(expected, found), expected, found, location);\n }\n function peg$parsestart() {\n var s0, s1;\n peg$silentFails++;\n s0 = peg$parsetransformFunctions();\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e0);\n }\n }\n return s0;\n }\n function peg$parsetransformFunctions() {\n var s0, s1, s2, s3, s4, s5;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parsefunction();\n if (s1 !== peg$FAILED) {\n s2 = [];\n s3 = peg$currPos;\n s4 = peg$parse_();\n s5 = peg$parsefunction();\n if (s5 !== peg$FAILED) {\n s4 = [s4, s5];\n s3 = s4;\n } else {\n peg$currPos = s3;\n s3 = peg$FAILED;\n }\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = peg$currPos;\n s4 = peg$parse_();\n s5 = peg$parsefunction();\n if (s5 !== peg$FAILED) {\n s4 = [s4, s5];\n s3 = s4;\n } else {\n peg$currPos = s3;\n s3 = peg$FAILED;\n }\n }\n peg$savedPos = s0;\n s0 = peg$f0(s1, s2);\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e1);\n }\n }\n return s0;\n }\n function peg$parsefunction() {\n var s0, s1;\n peg$silentFails++;\n s0 = peg$parsematrix();\n if (s0 === peg$FAILED) {\n s0 = peg$parsetranslate();\n if (s0 === peg$FAILED) {\n s0 = peg$parsescale();\n if (s0 === peg$FAILED) {\n s0 = peg$parserotate();\n if (s0 === peg$FAILED) {\n s0 = peg$parseskewX();\n if (s0 === peg$FAILED) {\n s0 = peg$parseskewY();\n }\n }\n }\n }\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e2);\n }\n }\n return s0;\n }\n function peg$parsematrix() {\n var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9, s10, s11, s12, s13, s14, s15, s16, s17, s18, s19, s20, s21, s22, s23;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parse_();\n if (input.substr(peg$currPos, 7) === peg$c0) {\n s2 = peg$c0;\n peg$currPos += 7;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e4);\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parse_();\n s4 = peg$parseNUM();\n if (s4 !== peg$FAILED) {\n s5 = peg$parsespaceOrComma();\n s6 = peg$parseNUM();\n if (s6 !== peg$FAILED) {\n s7 = peg$parsespaceOrComma();\n s8 = peg$parseNUM();\n if (s8 !== peg$FAILED) {\n s9 = peg$parsespaceOrComma();\n s10 = peg$parseNUM();\n if (s10 !== peg$FAILED) {\n s11 = peg$parsespaceOrComma();\n s12 = peg$parseNUM();\n if (s12 !== peg$FAILED) {\n s13 = peg$parsespaceOrComma();\n s14 = peg$parseNUM();\n if (s14 !== peg$FAILED) {\n s15 = peg$parsespaceOrComma();\n s16 = peg$parseNUM();\n if (s16 !== peg$FAILED) {\n s17 = peg$parsespaceOrComma();\n s18 = peg$parseNUM();\n if (s18 !== peg$FAILED) {\n s19 = peg$parsespaceOrComma();\n s20 = peg$parseNUM();\n if (s20 !== peg$FAILED) {\n s21 = peg$parse_();\n if (input.charCodeAt(peg$currPos) === 41) {\n s22 = peg$c1;\n peg$currPos++;\n } else {\n s22 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e5);\n }\n }\n if (s22 !== peg$FAILED) {\n s23 = peg$parse_();\n peg$savedPos = s0;\n s0 = peg$f1(s4, s6, s8, s10, s12, s14, s16, s18, s20);\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e3);\n }\n }\n return s0;\n }\n function peg$parsetranslate() {\n var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parse_();\n if (input.substr(peg$currPos, 10) === peg$c2) {\n s2 = peg$c2;\n peg$currPos += 10;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e7);\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parse_();\n s4 = peg$parseNUM();\n if (s4 !== peg$FAILED) {\n s5 = peg$parsespaceOrComma();\n s6 = peg$parseNUM();\n if (s6 === peg$FAILED) {\n s6 = null;\n }\n s7 = peg$parse_();\n if (input.charCodeAt(peg$currPos) === 41) {\n s8 = peg$c1;\n peg$currPos++;\n } else {\n s8 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e5);\n }\n }\n if (s8 !== peg$FAILED) {\n s9 = peg$parse_();\n peg$savedPos = s0;\n s0 = peg$f2(s4, s6);\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e6);\n }\n }\n return s0;\n }\n function peg$parsescale() {\n var s0, s1, s2, s3, s4, s5, s6, s7, s8, s9;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parse_();\n if (input.substr(peg$currPos, 6) === peg$c3) {\n s2 = peg$c3;\n peg$currPos += 6;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e9);\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parse_();\n s4 = peg$parseNUM();\n if (s4 !== peg$FAILED) {\n s5 = peg$parsespaceOrComma();\n s6 = peg$parseNUM();\n if (s6 === peg$FAILED) {\n s6 = null;\n }\n s7 = peg$parse_();\n if (input.charCodeAt(peg$currPos) === 41) {\n s8 = peg$c1;\n peg$currPos++;\n } else {\n s8 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e5);\n }\n }\n if (s8 !== peg$FAILED) {\n s9 = peg$parse_();\n peg$savedPos = s0;\n s0 = peg$f3(s4, s6);\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e8);\n }\n }\n return s0;\n }\n function peg$parserotate() {\n var s0, s1, s2, s3, s4, s5, s6, s7, s8;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parse_();\n if (input.substr(peg$currPos, 7) === peg$c4) {\n s2 = peg$c4;\n peg$currPos += 7;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e11);\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parse_();\n s4 = peg$parseNUM();\n if (s4 !== peg$FAILED) {\n s5 = peg$parsetwoNumbers();\n if (s5 === peg$FAILED) {\n s5 = null;\n }\n s6 = peg$parse_();\n if (input.charCodeAt(peg$currPos) === 41) {\n s7 = peg$c1;\n peg$currPos++;\n } else {\n s7 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e5);\n }\n }\n if (s7 !== peg$FAILED) {\n s8 = peg$parse_();\n peg$savedPos = s0;\n s0 = peg$f4(s4, s5);\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e10);\n }\n }\n return s0;\n }\n function peg$parsetwoNumbers() {\n var s0, s1, s2, s3, s4;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parsespaceOrComma();\n s2 = peg$parseNUM();\n if (s2 !== peg$FAILED) {\n s3 = peg$parsespaceOrComma();\n s4 = peg$parseNUM();\n if (s4 !== peg$FAILED) {\n peg$savedPos = s0;\n s0 = peg$f5(s2, s4);\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e12);\n }\n }\n return s0;\n }\n function peg$parseskewX() {\n var s0, s1, s2, s3, s4, s5, s6, s7;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parse_();\n if (input.substr(peg$currPos, 6) === peg$c5) {\n s2 = peg$c5;\n peg$currPos += 6;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e14);\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parse_();\n s4 = peg$parseNUM();\n if (s4 !== peg$FAILED) {\n s5 = peg$parse_();\n if (input.charCodeAt(peg$currPos) === 41) {\n s6 = peg$c1;\n peg$currPos++;\n } else {\n s6 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e5);\n }\n }\n if (s6 !== peg$FAILED) {\n s7 = peg$parse_();\n peg$savedPos = s0;\n s0 = peg$f6(s4);\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e13);\n }\n }\n return s0;\n }\n function peg$parseskewY() {\n var s0, s1, s2, s3, s4, s5, s6, s7;\n peg$silentFails++;\n s0 = peg$currPos;\n s1 = peg$parse_();\n if (input.substr(peg$currPos, 6) === peg$c6) {\n s2 = peg$c6;\n peg$currPos += 6;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e16);\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$parse_();\n s4 = peg$parseNUM();\n if (s4 !== peg$FAILED) {\n s5 = peg$parse_();\n if (input.charCodeAt(peg$currPos) === 41) {\n s6 = peg$c1;\n peg$currPos++;\n } else {\n s6 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e5);\n }\n }\n if (s6 !== peg$FAILED) {\n s7 = peg$parse_();\n peg$savedPos = s0;\n s0 = peg$f7(s4);\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n peg$silentFails--;\n if (s0 === peg$FAILED) {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e15);\n }\n }\n return s0;\n }\n function peg$parsespaceOrComma() {\n var s0, s1;\n peg$silentFails++;\n s0 = [];\n s1 = input.charAt(peg$currPos);\n if (peg$r0.test(s1)) {\n peg$currPos++;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e18);\n }\n }\n while (s1 !== peg$FAILED) {\n s0.push(s1);\n s1 = input.charAt(peg$currPos);\n if (peg$r0.test(s1)) {\n peg$currPos++;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e18);\n }\n }\n }\n peg$silentFails--;\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e17);\n }\n return s0;\n }\n function peg$parse_() {\n var s0, s1;\n peg$silentFails++;\n s0 = [];\n s1 = input.charAt(peg$currPos);\n if (peg$r1.test(s1)) {\n peg$currPos++;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e20);\n }\n }\n while (s1 !== peg$FAILED) {\n s0.push(s1);\n s1 = input.charAt(peg$currPos);\n if (peg$r1.test(s1)) {\n peg$currPos++;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e20);\n }\n }\n }\n peg$silentFails--;\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e19);\n }\n return s0;\n }\n function peg$parseNUM() {\n var s0, s1, s2, s3, s4, s5, s6, s7;\n s0 = peg$currPos;\n s1 = input.charAt(peg$currPos);\n if (peg$r2.test(s1)) {\n peg$currPos++;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e21);\n }\n }\n if (s1 === peg$FAILED) {\n s1 = null;\n }\n s2 = peg$currPos;\n s3 = [];\n s4 = input.charAt(peg$currPos);\n if (peg$r3.test(s4)) {\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e22);\n }\n }\n while (s4 !== peg$FAILED) {\n s3.push(s4);\n s4 = input.charAt(peg$currPos);\n if (peg$r3.test(s4)) {\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e22);\n }\n }\n }\n if (input.charCodeAt(peg$currPos) === 46) {\n s4 = peg$c7;\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e23);\n }\n }\n if (s4 !== peg$FAILED) {\n s5 = [];\n s6 = input.charAt(peg$currPos);\n if (peg$r3.test(s6)) {\n peg$currPos++;\n } else {\n s6 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e22);\n }\n }\n if (s6 !== peg$FAILED) {\n while (s6 !== peg$FAILED) {\n s5.push(s6);\n s6 = input.charAt(peg$currPos);\n if (peg$r3.test(s6)) {\n peg$currPos++;\n } else {\n s6 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e22);\n }\n }\n }\n } else {\n s5 = peg$FAILED;\n }\n if (s5 !== peg$FAILED) {\n s3 = [s3, s4, s5];\n s2 = s3;\n } else {\n peg$currPos = s2;\n s2 = peg$FAILED;\n }\n } else {\n peg$currPos = s2;\n s2 = peg$FAILED;\n }\n if (s2 === peg$FAILED) {\n s2 = [];\n s3 = input.charAt(peg$currPos);\n if (peg$r3.test(s3)) {\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e22);\n }\n }\n if (s3 !== peg$FAILED) {\n while (s3 !== peg$FAILED) {\n s2.push(s3);\n s3 = input.charAt(peg$currPos);\n if (peg$r3.test(s3)) {\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e22);\n }\n }\n }\n } else {\n s2 = peg$FAILED;\n }\n }\n if (s2 !== peg$FAILED) {\n s3 = peg$currPos;\n if (input.charCodeAt(peg$currPos) === 101) {\n s4 = peg$c8;\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e24);\n }\n }\n if (s4 !== peg$FAILED) {\n s5 = input.charAt(peg$currPos);\n if (peg$r2.test(s5)) {\n peg$currPos++;\n } else {\n s5 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e21);\n }\n }\n if (s5 === peg$FAILED) {\n s5 = null;\n }\n s6 = [];\n s7 = input.charAt(peg$currPos);\n if (peg$r3.test(s7)) {\n peg$currPos++;\n } else {\n s7 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e22);\n }\n }\n if (s7 !== peg$FAILED) {\n while (s7 !== peg$FAILED) {\n s6.push(s7);\n s7 = input.charAt(peg$currPos);\n if (peg$r3.test(s7)) {\n peg$currPos++;\n } else {\n s7 = peg$FAILED;\n if (peg$silentFails === 0) {\n peg$fail(peg$e22);\n }\n }\n }\n } else {\n s6 = peg$FAILED;\n }\n if (s6 !== peg$FAILED) {\n s4 = [s4, s5, s6];\n s3 = s4;\n } else {\n peg$currPos = s3;\n s3 = peg$FAILED;\n }\n } else {\n peg$currPos = s3;\n s3 = peg$FAILED;\n }\n if (s3 === peg$FAILED) {\n s3 = null;\n }\n peg$savedPos = s0;\n s0 = peg$f8();\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n return s0;\n }\n peg$result = peg$startRuleFunction();\n if (options.peg$library) {\n return /** @type {any} */{\n peg$result,\n peg$currPos,\n peg$FAILED,\n peg$maxFailExpected,\n peg$maxFailPos\n };\n }\n if (peg$result !== peg$FAILED && peg$currPos === input.length) {\n return peg$result;\n } else {\n if (peg$result !== peg$FAILED && peg$currPos < input.length) {\n peg$fail(peg$endExpectation());\n }\n throw peg$buildStructuredError(peg$maxFailExpected, peg$maxFailPos < input.length ? input.charAt(peg$maxFailPos) : null, peg$maxFailPos < input.length ? peg$computeLocation(peg$maxFailPos, peg$maxFailPos + 1) : peg$computeLocation(peg$maxFailPos, peg$maxFailPos));\n }\n}\nmodule.exports = {\n StartRules: ['start'],\n SyntaxError: peg$SyntaxError,\n parse: peg$parse\n};\n//# sourceMappingURL=transformToRn.js.map","import { append, appendTransform, identity, reset, toArray } from '../Matrix2D';\nimport { parse } from './transform';\nimport { parse as parseTransformSvgToRnStyle } from './transformToRn';\nfunction appendTransformProps(props) {\n const {\n x,\n y,\n originX,\n originY,\n scaleX,\n scaleY,\n rotation,\n skewX,\n skewY\n } = props;\n appendTransform(x + originX, y + originY, scaleX, scaleY, rotation, skewX, skewY, originX, originY);\n}\nfunction universal2axis(universal, axisX, axisY, defaultValue) {\n let x;\n let y;\n if (typeof universal === 'number') {\n x = y = universal;\n } else if (typeof universal === 'string') {\n const coords = universal.split(/\\s*,\\s*/);\n if (coords.length === 2) {\n x = +coords[0];\n y = +coords[1];\n } else if (coords.length === 1) {\n x = y = +coords[0];\n }\n } else if (Array.isArray(universal)) {\n if (universal.length === 2) {\n x = +universal[0];\n y = +universal[1];\n } else if (universal.length === 1) {\n x = y = +universal[0];\n }\n }\n axisX = +axisX;\n if (!isNaN(axisX)) {\n x = axisX;\n }\n axisY = +axisY;\n if (!isNaN(axisY)) {\n y = axisY;\n }\n return [x || defaultValue || 0, y || defaultValue || 0];\n}\nexport function props2transform(props) {\n if (!props) {\n return null;\n }\n const {\n rotation,\n translate,\n translateX,\n translateY,\n origin,\n originX,\n originY,\n scale,\n scaleX,\n scaleY,\n skew,\n skewX,\n skewY,\n x,\n y\n } = props;\n if (rotation == null && translate == null && translateX == null && translateY == null && origin == null && originX == null && originY == null && scale == null && scaleX == null && scaleY == null && skew == null && skewX == null && skewY == null && x == null && y == null) {\n return null;\n }\n if (Array.isArray(x) || Array.isArray(y)) {\n console.warn('Passing SvgLengthList to x or y attribute where SvgLength expected');\n }\n const tr = universal2axis(translate, translateX || (Array.isArray(x) ? x[0] : x), translateY || (Array.isArray(y) ? y[0] : y));\n const or = universal2axis(origin, originX, originY);\n const sc = universal2axis(scale, scaleX, scaleY, 1);\n const sk = universal2axis(skew, skewX, skewY);\n return {\n rotation: rotation == null ? 0 : +rotation || 0,\n originX: or[0],\n originY: or[1],\n scaleX: sc[0],\n scaleY: sc[1],\n skewX: sk[0],\n skewY: sk[1],\n x: tr[0],\n y: tr[1]\n };\n}\nexport function transformToMatrix(props, transform) {\n if (!props && !transform) {\n return null;\n }\n reset();\n props && appendTransformProps(props);\n if (transform) {\n if (Array.isArray(transform)) {\n if (typeof transform[0] === 'number') {\n const columnMatrix = transform;\n append(columnMatrix[0], columnMatrix[1], columnMatrix[2], columnMatrix[3], columnMatrix[4], columnMatrix[5]);\n } else {\n const stringifiedTransform = stringifyTransformArrayProps(\n // @ts-expect-error FIXME\n transform);\n const t = parse(stringifiedTransform);\n append(t[0], t[3], t[1], t[4], t[2], t[5]);\n }\n } else if (typeof transform === 'string') {\n try {\n const t = parse(transform);\n append(t[0], t[3], t[1], t[4], t[2], t[5]);\n } catch (e) {\n console.error(e);\n }\n } else {\n // @ts-expect-error FIXME\n const transformProps = props2transform(transform);\n transformProps && appendTransformProps(transformProps);\n }\n }\n return toArray();\n}\nexport default function extractTransform(props) {\n if (Array.isArray(props) && typeof props[0] === 'number') {\n return props;\n }\n if (typeof props === 'string') {\n try {\n const t = parse(props);\n return [t[0], t[3], t[1], t[4], t[2], t[5]];\n } catch (e) {\n console.error(e);\n return identity;\n }\n }\n // this type is not correct since props can be of type TransformsStyle['transform'] too\n // but it satisfies TS and should not produce any type errors\n const transformProps = props;\n return transformToMatrix(props2transform(transformProps), transformProps === null || transformProps === void 0 ? void 0 : transformProps.transform);\n}\nexport function extractTransformSvgView(props) {\n if (typeof props.transform === 'string') {\n return parseTransformSvgToRnStyle(props.transform);\n }\n return props.transform;\n}\nconst getAngleValueInDeg = angle => {\n if (angle.endsWith('rad')) {\n return parseFloat(angle) * (180 / Math.PI);\n }\n if (angle.endsWith('deg')) {\n return parseFloat(angle);\n }\n};\nexport function stringifyTransformArrayProps(transformArray) {\n if (!transformArray) {\n return '';\n }\n return transformArray.map(transform => {\n const [key, value] = Object.entries(transform)[0];\n switch (key) {\n case 'translateX':\n return `translate(${value}, 0)`;\n case 'translateY':\n return `translate(0, ${value})`;\n case 'rotate':\n return `rotate(${getAngleValueInDeg(value)})`;\n case 'scale':\n return `scale(${value})`;\n case 'scaleX':\n return `scale(${value}, 1)`;\n case 'scaleY':\n return `scale(1, ${value})`;\n case 'skewX':\n return `skewX(${getAngleValueInDeg(value)})`;\n case 'skewY':\n return `skewY(${getAngleValueInDeg(value)})`;\n case 'matrix':\n return `matrix(${value.join(', ')})`;\n default:\n return '';\n }\n }).join(' ');\n}\n//# sourceMappingURL=extractTransform.js.map","import { stringifyTransformArrayProps } from '../../lib/extract/extractTransform';\nexport function parseTransformProp(transform, props) {\n const transformArray = [];\n props && transformArray.push(...stringifyTransformProps(props));\n if (Array.isArray(transform)) {\n if (typeof transform[0] === 'number') {\n transformArray.push(`matrix(${transform.join(' ')})`);\n } else {\n const stringifiedProps = stringifyTransformArrayProps(\n // @ts-expect-error FIXME\n transform).split(' ');\n transformArray.push(...stringifiedProps);\n }\n } else if (typeof transform === 'string') {\n transformArray.push(transform);\n }\n return transformArray.length ? transformArray.join(' ') : undefined;\n}\nexport function stringifyTransformProps(transformProps) {\n const transformArray = [];\n if (transformProps.translate != null) {\n transformArray.push(`translate(${transformProps.translate})`);\n }\n if (transformProps.translateX != null || transformProps.translateY != null) {\n transformArray.push(`translate(${transformProps.translateX || 0}, ${transformProps.translateY || 0})`);\n }\n if (transformProps.scale != null) {\n transformArray.push(`scale(${transformProps.scale})`);\n }\n if (transformProps.scaleX != null || transformProps.scaleY != null) {\n transformArray.push(`scale(${transformProps.scaleX || 1}, ${transformProps.scaleY || 1})`);\n }\n // rotation maps to rotate, not to collide with the text rotate attribute (which acts per glyph rather than block)\n if (transformProps.rotation != null) {\n transformArray.push(`rotate(${transformProps.rotation})`);\n }\n if (transformProps.skewX != null) {\n transformArray.push(`skewX(${transformProps.skewX})`);\n }\n if (transformProps.skewY != null) {\n transformArray.push(`skewY(${transformProps.skewY})`);\n }\n return transformArray;\n}\n//# sourceMappingURL=parseTransform.js.map","import { StyleSheet } from 'react-native';\n\n// Kept in separate file, to avoid name collision with Symbol element\nexport function resolve(styleProp, cleanedProps) {\n if (styleProp) {\n return StyleSheet ? [styleProp, cleanedProps] :\n // Compatibility for arrays of styles in plain react web\n styleProp[Symbol.iterator] ? Object.assign({}, ...styleProp, cleanedProps) : Object.assign({}, styleProp, cleanedProps);\n } else {\n return cleanedProps;\n }\n}\n//# sourceMappingURL=resolve.js.map","import { PixelRatio } from 'react-native';\n// @ts-expect-error react-native/assets-registry doesn't export types.\nimport { getAssetByID } from '@react-native/assets-registry/registry';\nconst svgDataUriPattern = /^(data:image\\/svg\\+xml;utf8,)(.*)/;\n\n// Based on that function: https://github.com/necolas/react-native-web/blob/54c14d64dabd175e8055e1dc92e9196c821f9b7d/packages/react-native-web/src/exports/Image/index.js#L118-L156\nexport function resolveAssetUri(source) {\n let src = {};\n if (typeof source === 'number') {\n // get the URI from the packager\n const asset = getAssetByID(source);\n if (asset == null) {\n throw new Error(`Image: asset with ID \"${source}\" could not be found. Please check the image source or packager.`);\n }\n src = {\n width: asset.width,\n height: asset.height,\n scale: asset.scales[0]\n };\n if (asset.scales.length > 1) {\n const preferredScale = PixelRatio.get();\n // Get the scale which is closest to the preferred scale\n src.scale = asset.scales.reduce((prev, curr) => Math.abs(curr - preferredScale) < Math.abs(prev - preferredScale) ? curr : prev);\n }\n const scaleSuffix = src.scale !== 1 ? `@${src.scale}x` : '';\n src.uri = asset ? `${asset.httpServerLocation}/${asset.name}${scaleSuffix}.${asset.type}` : '';\n } else if (typeof source === 'string') {\n src.uri = source;\n } else if (source && !Array.isArray(source) && typeof source.uri === 'string') {\n src.uri = source.uri;\n }\n if (src.uri) {\n var _src;\n const match = (_src = src) === null || _src === void 0 || (_src = _src.uri) === null || _src === void 0 ? void 0 : _src.match(svgDataUriPattern);\n // inline SVG markup may contain characters (e.g., #, \") that need to be escaped\n if (match) {\n const [, prefix, svg] = match;\n const encodedSvg = encodeURIComponent(svg);\n src.uri = `${prefix}${encodedSvg}`;\n return src;\n }\n }\n return src;\n}\n//# sourceMappingURL=resolveAssetUri.js.map","import { hasTouchableProperty } from './hasProperty';\nimport { parseTransformProp } from './parseTransform';\nimport { resolve } from '../../lib/resolve';\nimport { resolveAssetUri } from '../../lib/resolveAssetUri';\n/**\n * `react-native-svg` supports additional props that aren't defined in the spec.\n * This function replaces them in a spec conforming manner.\n *\n * @param {WebShape} self Instance given to us.\n * @param {Object?} props Optional overridden props given to us.\n * @returns {Object} Cleaned props object.\n * @private\n */\nexport const prepare = (self, props = self.props) => {\n const {\n transform,\n origin,\n originX,\n originY,\n fontFamily,\n fontSize,\n fontWeight,\n fontStyle,\n style,\n forwardedRef,\n gradientTransform,\n patternTransform,\n onPress,\n ...rest\n } = props;\n const clean = {\n ...(hasTouchableProperty(props) ? {\n onStartShouldSetResponder: self.touchableHandleStartShouldSetResponder,\n onResponderTerminationRequest: self.touchableHandleResponderTerminationRequest,\n onResponderGrant: self.touchableHandleResponderGrant,\n onResponderMove: self.touchableHandleResponderMove,\n onResponderRelease: self.touchableHandleResponderRelease,\n onResponderTerminate: self.touchableHandleResponderTerminate\n } : null),\n ...rest\n };\n if (origin != null) {\n clean['transform-origin'] = origin.toString().replace(',', ' ');\n } else if (originX != null || originY != null) {\n clean['transform-origin'] = `${originX || 0} ${originY || 0}`;\n }\n\n // we do it like this because setting transform as undefined causes error in web\n const parsedTransform = parseTransformProp(transform, props);\n if (parsedTransform) {\n clean.transform = parsedTransform;\n }\n const parsedGradientTransform = parseTransformProp(gradientTransform);\n if (parsedGradientTransform) {\n clean.gradientTransform = parsedGradientTransform;\n }\n const parsedPatternTransform = parseTransformProp(patternTransform);\n if (parsedPatternTransform) {\n clean.patternTransform = parsedPatternTransform;\n }\n clean.ref = el => {\n self.elementRef.current = el;\n if (typeof forwardedRef === 'function') {\n forwardedRef(el);\n } else if (forwardedRef) {\n forwardedRef.current = el;\n }\n };\n const styles = {};\n if (fontFamily != null) {\n styles.fontFamily = fontFamily;\n }\n if (fontSize != null) {\n styles.fontSize = fontSize;\n }\n if (fontWeight != null) {\n styles.fontWeight = fontWeight;\n }\n if (fontStyle != null) {\n styles.fontStyle = fontStyle;\n }\n clean.style = resolve(style, styles);\n if (onPress !== null) {\n clean.onClick = props.onPress;\n }\n if (props.href !== null && props.href !== undefined) {\n var _resolveAssetUri;\n clean.href = (_resolveAssetUri = resolveAssetUri(props.href)) === null || _resolveAssetUri === void 0 ? void 0 : _resolveAssetUri.uri;\n }\n return clean;\n};\n//# sourceMappingURL=prepare.js.map","export function convertInt32ColorToRGBA(color) {\n const r = color >> 16 & 255;\n const g = color >> 8 & 255;\n const b = color & 255;\n const a = (color >> 24 & 255) / 255;\n const alpha = a.toFixed(2);\n return `rgba(${r},${g},${b},${alpha})`;\n}\n//# sourceMappingURL=convertInt32Color.js.map","import { Touchable } from 'react-native';\nconst PRESS_RETENTION_OFFSET = {\n top: 20,\n left: 20,\n right: 20,\n bottom: 30\n};\n// @ts-expect-error: Mixin is not typed\nconst {\n Mixin\n} = Touchable;\nconst {\n touchableHandleStartShouldSetResponder,\n touchableHandleResponderTerminationRequest,\n touchableHandleResponderGrant,\n touchableHandleResponderMove,\n touchableHandleResponderRelease,\n touchableHandleResponderTerminate,\n touchableGetInitialState\n} = Mixin;\nconst SvgTouchableMixin = {\n ...Mixin,\n touchableHandleStartShouldSetResponder(e) {\n const {\n onStartShouldSetResponder\n } = this.props;\n if (onStartShouldSetResponder) {\n return onStartShouldSetResponder(e);\n } else {\n return touchableHandleStartShouldSetResponder.call(this, e);\n }\n },\n touchableHandleResponderTerminationRequest(e) {\n const {\n onResponderTerminationRequest\n } = this.props;\n if (onResponderTerminationRequest) {\n return onResponderTerminationRequest(e);\n } else {\n return touchableHandleResponderTerminationRequest.call(this, e);\n }\n },\n touchableHandleResponderGrant(e) {\n const {\n onResponderGrant\n } = this.props;\n if (onResponderGrant) {\n return onResponderGrant(e);\n } else {\n return touchableHandleResponderGrant.call(this, e);\n }\n },\n touchableHandleResponderMove(e) {\n const {\n onResponderMove\n } = this.props;\n if (onResponderMove) {\n return onResponderMove(e);\n } else {\n return touchableHandleResponderMove.call(this, e);\n }\n },\n touchableHandleResponderRelease(e) {\n const {\n onResponderRelease\n } = this.props;\n if (onResponderRelease) {\n return onResponderRelease(e);\n } else {\n return touchableHandleResponderRelease.call(this, e);\n }\n },\n touchableHandleResponderTerminate(e) {\n const {\n onResponderTerminate\n } = this.props;\n if (onResponderTerminate) {\n return onResponderTerminate(e);\n } else {\n return touchableHandleResponderTerminate.call(this, e);\n }\n },\n touchableHandlePress(e) {\n const {\n onPress\n } = this.props;\n onPress && onPress(e);\n },\n touchableHandleActivePressIn(e) {\n const {\n onPressIn\n } = this.props;\n onPressIn && onPressIn(e);\n },\n touchableHandleActivePressOut(e) {\n const {\n onPressOut\n } = this.props;\n onPressOut && onPressOut(e);\n },\n touchableHandleLongPress(e) {\n const {\n onLongPress\n } = this.props;\n onLongPress && onLongPress(e);\n },\n touchableGetPressRectOffset() {\n const {\n pressRetentionOffset\n } = this.props;\n return pressRetentionOffset || PRESS_RETENTION_OFFSET;\n },\n touchableGetHitSlop() {\n const {\n hitSlop\n } = this.props;\n return hitSlop;\n },\n touchableGetHighlightDelayMS() {\n const {\n delayPressIn\n } = this.props;\n return delayPressIn || 0;\n },\n touchableGetLongPressDelayMS() {\n const {\n delayLongPress\n } = this.props;\n return delayLongPress === 0 ? 0 : delayLongPress || 500;\n },\n touchableGetPressOutDelayMS() {\n const {\n delayPressOut\n } = this.props;\n return delayPressOut || 0;\n }\n};\nconst touchKeys = Object.keys(SvgTouchableMixin);\nconst touchVals = touchKeys.map(key => SvgTouchableMixin[key]);\nconst numTouchKeys = touchKeys.length;\nexport default target => {\n for (let i = 0; i < numTouchKeys; i++) {\n const key = touchKeys[i];\n const val = touchVals[i];\n if (typeof val === 'function') {\n target[key] = val.bind(target);\n } else {\n target[key] = val;\n }\n }\n target.state = touchableGetInitialState();\n};\n//# sourceMappingURL=SvgTouchableMixin.js.map","import React from 'react';\nimport {\n// @ts-ignore it is not seen in exports\nunstable_createElement as createElement } from 'react-native';\nimport { prepare } from './utils/prepare';\nimport { convertInt32ColorToRGBA } from './utils/convertInt32Color';\nimport { getAttributeName, remeasure } from './utils';\nimport { hasTouchableProperty } from './utils/hasProperty';\nimport SvgTouchableMixin from '../lib/SvgTouchableMixin';\nexport class WebShape extends React.Component {\n prepareProps(props) {\n return props;\n }\n elementRef = /*#__PURE__*/React.createRef();\n lastMergedProps = {};\n\n /**\n * disclaimer: I am not sure why the props are wrapped in a `style` attribute here, but that's how reanimated calls it\n */\n setNativeProps(props) {\n const merged = Object.assign({}, this.props, this.lastMergedProps, props.style);\n this.lastMergedProps = merged;\n const clean = prepare(this, this.prepareProps(merged));\n const current = this.elementRef.current;\n if (current) {\n for (const cleanAttribute of Object.keys(clean)) {\n const cleanValue = clean[cleanAttribute];\n switch (cleanAttribute) {\n case 'ref':\n case 'children':\n break;\n case 'style':\n // style can be an object here or an array, so we convert it to an array and assign each element\n for (const partialStyle of [].concat(clean.style ?? [])) {\n Object.assign(current.style, partialStyle);\n }\n break;\n case 'fill':\n if (cleanValue && typeof cleanValue === 'object') {\n const value = cleanValue;\n current.setAttribute('fill', convertInt32ColorToRGBA(value.payload));\n }\n break;\n case 'stroke':\n if (cleanValue && typeof cleanValue === 'object') {\n const value = cleanValue;\n current.setAttribute('stroke', convertInt32ColorToRGBA(value.payload));\n }\n break;\n default:\n // apply all other incoming prop updates as attributes on the node\n // same logic as in https://github.com/software-mansion/react-native-reanimated/blob/d04720c82f5941532991b235787285d36d717247/src/reanimated2/js-reanimated/index.ts#L38-L39\n // @ts-expect-error TODO: fix this\n current.setAttribute(getAttributeName(cleanAttribute), cleanValue);\n break;\n }\n }\n }\n }\n constructor(props) {\n super(props);\n\n // Do not attach touchable mixin handlers if SVG element doesn't have a touchable prop\n if (hasTouchableProperty(props)) {\n SvgTouchableMixin(this);\n }\n this._remeasureMetricsOnActivation = remeasure.bind(this);\n }\n render() {\n if (!this.tag) {\n throw new Error('When extending `WebShape` you need to overwrite either `tag` or `render`!');\n }\n this.lastMergedProps = {};\n return createElement(this.tag, prepare(this, this.prepareProps(this.props)));\n }\n}\n//# sourceMappingURL=WebShape.js.map","import { encodeSvg, getBoundingClientRect } from './web/utils';\nimport { WebShape } from './web/WebShape';\nexport class Circle extends WebShape {\n tag = 'circle';\n}\nexport class ClipPath extends WebShape {\n tag = 'clipPath';\n}\nexport class Defs extends WebShape {\n tag = 'defs';\n}\nexport class Ellipse extends WebShape {\n tag = 'ellipse';\n}\nexport class FeBlend extends WebShape {\n tag = 'feBlend';\n}\nexport class FeColorMatrix extends WebShape {\n tag = 'feColorMatrix';\n}\nexport class FeComponentTransfer extends WebShape {\n tag = 'feComponentTransfer';\n}\nexport class FeComposite extends WebShape {\n tag = 'feComposite';\n}\nexport class FeConvolveMatrix extends WebShape {\n tag = 'feConvolveMatrix';\n}\nexport class FeDiffuseLighting extends WebShape {\n tag = 'feDiffuseLighting';\n}\nexport class FeDisplacementMap extends WebShape {\n tag = 'feDisplacementMap';\n}\nexport class FeDistantLight extends WebShape {\n tag = 'feDistantLight';\n}\nexport class FeDropShadow extends WebShape {\n tag = 'feDropShadow';\n}\nexport class FeFlood extends WebShape {\n tag = 'feFlood';\n}\nexport class FeFuncA extends WebShape {\n tag = 'feFuncA';\n}\nexport class FeFuncB extends WebShape {\n tag = 'feFuncB';\n}\nexport class FeFuncG extends WebShape {\n tag = 'feFuncG';\n}\nexport class FeFuncR extends WebShape {\n tag = 'feFuncR';\n}\nexport class FeGaussianBlur extends WebShape {\n tag = 'feGaussianBlur';\n}\nexport class FeImage extends WebShape {\n tag = 'feImage';\n}\nexport class FeMerge extends WebShape {\n tag = 'feMerge';\n}\nexport class FeMergeNode extends WebShape {\n tag = 'feMergeNode';\n}\nexport class FeMorphology extends WebShape {\n tag = 'feMorphology';\n}\nexport class FeOffset extends WebShape {\n tag = 'feOffset';\n}\nexport class FePointLight extends WebShape {\n tag = 'fePointLight';\n}\nexport class FeSpecularLighting extends WebShape {\n tag = 'feSpecularLighting';\n}\nexport class FeSpotLight extends WebShape {\n tag = 'feSpotLight';\n}\nexport class FeTile extends WebShape {\n tag = 'feTile';\n}\nexport class FeTurbulence extends WebShape {\n tag = 'feTurbulence';\n}\nexport class Filter extends WebShape {\n tag = 'filter';\n}\nexport class ForeignObject extends WebShape {\n tag = 'foreignObject';\n}\nexport class G extends WebShape {\n tag = 'g';\n prepareProps(props) {\n const {\n x,\n y,\n ...rest\n } = props;\n if ((x || y) && !rest.translate) {\n rest.translate = `${x || 0}, ${y || 0}`;\n }\n return rest;\n }\n}\nexport class Image extends WebShape {\n tag = 'image';\n}\nexport class Line extends WebShape {\n tag = 'line';\n}\nexport class LinearGradient extends WebShape {\n tag = 'linearGradient';\n}\nexport class Marker extends WebShape {\n tag = 'marker';\n}\nexport class Mask extends WebShape {\n tag = 'mask';\n}\nexport class Path extends WebShape {\n tag = 'path';\n}\nexport class Pattern extends WebShape {\n tag = 'pattern';\n}\nexport class Polygon extends WebShape {\n tag = 'polygon';\n}\nexport class Polyline extends WebShape {\n tag = 'polyline';\n}\nexport class RadialGradient extends WebShape {\n tag = 'radialGradient';\n}\nexport class Rect extends WebShape {\n tag = 'rect';\n}\nexport class Stop extends WebShape {\n tag = 'stop';\n}\nexport class Svg extends WebShape {\n tag = 'svg';\n toDataURL(callback, options = {}) {\n const ref = this.elementRef.current;\n if (ref === null) {\n return;\n }\n const rect = getBoundingClientRect(ref);\n const width = Number(options.width) || rect.width;\n const height = Number(options.height) || rect.height;\n const svg = document.createElementNS('http://www.w3.org/2000/svg', 'svg');\n svg.setAttribute('viewBox', `0 0 ${rect.width} ${rect.height}`);\n svg.setAttribute('width', String(width));\n svg.setAttribute('height', String(height));\n svg.appendChild(ref.cloneNode(true));\n const img = new window.Image();\n img.onload = () => {\n const canvas = document.createElement('canvas');\n canvas.width = width;\n canvas.height = height;\n const context = canvas.getContext('2d');\n context === null || context === void 0 || context.drawImage(img, 0, 0);\n callback(canvas.toDataURL().replace('data:image/png;base64,', ''));\n };\n img.src = `data:image/svg+xml;utf8,${encodeSvg(new window.XMLSerializer().serializeToString(svg))}`;\n }\n}\nexport class Symbol extends WebShape {\n tag = 'symbol';\n}\nexport class TSpan extends WebShape {\n tag = 'tspan';\n}\nexport class Text extends WebShape {\n tag = 'text';\n}\nexport class TextPath extends WebShape {\n tag = 'textPath';\n}\nexport class Use extends WebShape {\n tag = 'use';\n}\nexport default Svg;\n//# sourceMappingURL=elements.web.js.map","function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }\nimport * as React from 'react';\nimport { Component, useEffect, useMemo, useState } from 'react';\nimport { fetchText } from './utils/fetchData';\nimport { tags } from './xmlTags';\nfunction missingTag() {\n return null;\n}\nexport function SvgAst({\n ast,\n override\n}) {\n if (!ast) {\n return null;\n }\n const {\n props,\n children\n } = ast;\n const Svg = tags.svg;\n return /*#__PURE__*/React.createElement(Svg, _extends({}, props, override), children);\n}\nconst err = console.error.bind(console);\nexport function SvgXml(props) {\n const {\n onError = err,\n xml,\n override,\n fallback\n } = props;\n try {\n const ast = useMemo(() => xml !== null ? parse(xml) : null, [xml]);\n return /*#__PURE__*/React.createElement(SvgAst, {\n ast: ast,\n override: override || props\n });\n } catch (error) {\n onError(error);\n return fallback ?? null;\n }\n}\nexport function SvgUri(props) {\n const {\n onError = err,\n uri,\n onLoad,\n fallback\n } = props;\n const [xml, setXml] = useState(null);\n const [isError, setIsError] = useState(false);\n useEffect(() => {\n uri ? fetchText(uri).then(data => {\n setXml(data);\n isError && setIsError(false);\n onLoad === null || onLoad === void 0 || onLoad();\n }).catch(e => {\n onError(e);\n setIsError(true);\n }) : setXml(null);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [onError, uri, onLoad]);\n if (isError) {\n return fallback ?? null;\n }\n return /*#__PURE__*/React.createElement(SvgXml, {\n xml: xml,\n override: props,\n fallback: fallback\n });\n}\n\n// Extending Component is required for Animated support.\n\nexport class SvgFromXml extends Component {\n state = {\n ast: null\n };\n componentDidMount() {\n this.parse(this.props.xml);\n }\n componentDidUpdate(prevProps) {\n const {\n xml\n } = this.props;\n if (xml !== prevProps.xml) {\n this.parse(xml);\n }\n }\n parse(xml) {\n const {\n onError = err\n } = this.props;\n try {\n this.setState({\n ast: xml ? parse(xml) : null\n });\n } catch (e) {\n const error = e;\n onError({\n ...error,\n message: `[RNSVG] Couldn't parse SVG, reason: ${error.message}`\n });\n }\n }\n render() {\n const {\n props,\n state: {\n ast\n }\n } = this;\n return /*#__PURE__*/React.createElement(SvgAst, {\n ast: ast,\n override: props.override || props\n });\n }\n}\nexport class SvgFromUri extends Component {\n state = {\n xml: null\n };\n componentDidMount() {\n this.fetch(this.props.uri);\n }\n componentDidUpdate(prevProps) {\n const {\n uri\n } = this.props;\n if (uri !== prevProps.uri) {\n this.fetch(uri);\n }\n }\n async fetch(uri) {\n try {\n this.setState({\n xml: uri ? await fetchText(uri) : null\n });\n } catch (e) {\n console.error(e);\n }\n }\n render() {\n const {\n props,\n state: {\n xml\n }\n } = this;\n return /*#__PURE__*/React.createElement(SvgFromXml, {\n xml: xml,\n override: props,\n onError: props.onError\n });\n }\n}\nconst upperCase = (_match, letter) => letter.toUpperCase();\nexport const camelCase = phrase => phrase.replace(/[:-]([a-z])/g, upperCase);\nexport function getStyle(string) {\n const style = {};\n const declarations = string.split(';').filter(v => v.trim());\n const {\n length\n } = declarations;\n for (let i = 0; i < length; i++) {\n const declaration = declarations[i];\n if (declaration.length !== 0) {\n const split = declaration.split(':');\n const property = split[0];\n const value = split[1];\n style[camelCase(property.trim())] = value.trim();\n }\n }\n return style;\n}\nexport function astToReact(value, index) {\n if (typeof value === 'object') {\n const {\n Tag,\n props,\n children\n } = value;\n if (props !== null && props !== void 0 && props.class) {\n props.className = props.class;\n delete props.class;\n }\n return /*#__PURE__*/React.createElement(Tag, _extends({\n key: index\n }, props), children.map(astToReact));\n }\n return value;\n}\n\n// slimmed down parser based on https://github.com/Rich-Harris/svg-parser\n\nfunction repeat(str, i) {\n let result = '';\n while (i--) {\n result += str;\n }\n return result;\n}\nconst toSpaces = tabs => repeat(' ', tabs.length);\nfunction locate(source, i) {\n const lines = source.split('\\n');\n const nLines = lines.length;\n let column = i;\n let line = 0;\n for (; line < nLines; line++) {\n const {\n length\n } = lines[line];\n if (column >= length) {\n column -= length;\n } else {\n break;\n }\n }\n const before = source.slice(0, i).replace(/^\\t+/, toSpaces);\n const beforeExec = /(^|\\n).*$/.exec(before);\n const beforeLine = beforeExec && beforeExec[0] || '';\n const after = source.slice(i);\n const afterExec = /.*(\\n|$)/.exec(after);\n const afterLine = afterExec && afterExec[0];\n const pad = repeat(' ', beforeLine.length);\n const snippet = `${beforeLine}${afterLine}\\n${pad}^`;\n return {\n line,\n column,\n snippet\n };\n}\nconst validNameCharacters = /[a-zA-Z0-9:_-]/;\nconst commentStart = /<!--/;\nconst whitespace = /[\\s\\t\\r\\n]/;\nconst quotemarks = /['\"]/;\nexport function parse(source, middleware) {\n const length = source.length;\n let currentElement = null;\n let state = metadata;\n let children = null;\n let root;\n const stack = [];\n function error(message) {\n const {\n line,\n column,\n snippet\n } = locate(source, i);\n throw new Error(`${message} (${line}:${column}). If this is valid SVG, it's probably a bug. Please raise an issue\\n\\n${snippet}`);\n }\n function metadata() {\n while (i + 1 < length && (source[i] !== '<' || !(validNameCharacters.test(source[i + 1]) || commentStart.test(source.slice(i, i + 4))))) {\n i++;\n }\n return neutral();\n }\n function neutral() {\n let text = '';\n let char;\n while (i < length && (char = source[i]) !== '<') {\n text += char;\n i += 1;\n }\n if (/\\S/.test(text)) {\n children.push(text);\n }\n if (source[i] === '<') {\n return openingTag;\n }\n return neutral;\n }\n function openingTag() {\n const char = source[i];\n if (char === '?') {\n return neutral;\n } // <?xml...\n\n if (char === '!') {\n const start = i + 1;\n if (source.slice(start, i + 3) === '--') {\n return comment;\n }\n const end = i + 8;\n if (source.slice(start, end) === '[CDATA[') {\n return cdata;\n }\n if (/doctype/i.test(source.slice(start, end))) {\n return doctype;\n }\n }\n if (char === '/') {\n return closingTag;\n }\n const tag = getName();\n const props = {};\n const element = {\n tag,\n props,\n children: [],\n parent: currentElement,\n Tag: tags[tag] || missingTag\n };\n if (currentElement) {\n children.push(element);\n } else {\n root = element;\n }\n getAttributes(props);\n const {\n style\n } = props;\n if (typeof style === 'string') {\n element.styles = style;\n props.style = getStyle(style);\n }\n let selfClosing = false;\n if (source[i] === '/') {\n i += 1;\n selfClosing = true;\n }\n if (source[i] !== '>') {\n error('Expected >');\n }\n if (!selfClosing) {\n currentElement = element;\n ({\n children\n } = element);\n stack.push(element);\n }\n return neutral;\n }\n function comment() {\n const index = source.indexOf('-->', i);\n if (!~index) {\n error('expected -->');\n }\n i = index + 2;\n return neutral;\n }\n function cdata() {\n const index = source.indexOf(']]>', i);\n if (!~index) {\n error('expected ]]>');\n }\n children.push(source.slice(i + 7, index));\n i = index + 2;\n return neutral;\n }\n function doctype() {\n const index = source.indexOf('>', i);\n if (index === -1) {\n error('expected >');\n }\n i = index;\n return neutral;\n }\n function closingTag() {\n const tag = getName();\n if (!tag) {\n error('Expected tag name');\n }\n if (currentElement && tag !== currentElement.tag) {\n error(`Expected closing tag </${tag}> to match opening tag <${currentElement.tag}>`);\n }\n allowSpaces();\n if (source[i] !== '>') {\n error('Expected >');\n }\n stack.pop();\n currentElement = stack[stack.length - 1];\n if (currentElement) {\n ({\n children\n } = currentElement);\n }\n return neutral;\n }\n function getName() {\n let name = '';\n let char;\n while (i < length && validNameCharacters.test(char = source[i])) {\n name += char;\n i += 1;\n }\n return name;\n }\n function getAttributes(props) {\n while (i < length) {\n if (!whitespace.test(source[i])) {\n return;\n }\n allowSpaces();\n const name = getName();\n if (!name) {\n return;\n }\n let value = true;\n allowSpaces();\n if (source[i] === '=') {\n i += 1;\n allowSpaces();\n value = getAttributeValue();\n if (name !== 'id' && !isNaN(+value) && value.trim() !== '') {\n value = +value;\n }\n }\n props[camelCase(name)] = value;\n }\n }\n function getAttributeValue() {\n return quotemarks.test(source[i]) ? getQuotedAttributeValue() : getUnquotedAttributeValue();\n }\n function getUnquotedAttributeValue() {\n let value = '';\n do {\n const char = source[i];\n if (char === ' ' || char === '>' || char === '/') {\n return value;\n }\n value += char;\n i += 1;\n } while (i < length);\n return value;\n }\n function getQuotedAttributeValue() {\n const quotemark = source[i++];\n let value = '';\n let escaped = false;\n while (i < length) {\n const char = source[i++];\n if (char === quotemark && !escaped) {\n return value;\n }\n if (char === '\\\\' && !escaped) {\n escaped = true;\n }\n value += escaped ? `\\\\${char}` : char;\n escaped = false;\n }\n return value;\n }\n function allowSpaces() {\n while (i < length && whitespace.test(source[i])) {\n i += 1;\n }\n }\n let i = 0;\n while (i < length) {\n if (!state) {\n error('Unexpected character');\n }\n state = state();\n i += 1;\n }\n if (state !== neutral) {\n error('Unexpected end of input');\n }\n if (root) {\n const xml = (middleware ? middleware(root) : root) || root;\n const ast = xml.children.map(astToReact);\n const jsx = xml;\n jsx.children = ast;\n return jsx;\n }\n return null;\n}\nexport { tags };\n//# sourceMappingURL=xml.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { getTokenValue, getVariable, Text, usePropsAndStyle, } from '@hanzogui/core';\nimport { SizableContext } from '@hanzogui/sizable-context';\nexport { SizableContext };\n// check if props contain media queries ($sm, $md, etc) or other complex hanzogui features\nfunction needsFullStyleResolution(props) {\n for (const key in props) {\n if (key[0] === '$')\n return true;\n }\n return false;\n}\nexport function themed(Component, optsIn = {}) {\n const opts = {\n defaultThemeColor: process.env.DEFAULT_ICON_THEME_COLOR || '$color',\n defaultStrokeWidth: 2,\n fallbackColor: '#000',\n resolveValues: process.env.GUI_ICON_COLOR_RESOLVE || 'auto',\n ...optsIn,\n };\n const IconWrapper = (propsIn) => {\n const styledContext = SizableContext.useStyledContext();\n const needsMedia = needsFullStyleResolution(propsIn);\n const [props, style, theme] = usePropsAndStyle(propsIn, {\n ...opts,\n forComponent: Text,\n resolveValues: opts.resolveValues,\n noMedia: !needsMedia,\n });\n const defaultColor = opts.defaultThemeColor;\n const colorIn = style.color ||\n (defaultColor ? theme[defaultColor] : undefined) ||\n (!props.disableTheme ? theme.color : null) ||\n opts.fallbackColor;\n const color = getVariable(colorIn);\n const size = typeof props.size === 'string'\n ? getTokenValue(props.size, 'size')\n : props.size || (styledContext.size === '$true' ? undefined : styledContext.size);\n const strokeWidth = typeof props.strokeWidth === 'string'\n ? getTokenValue(props.strokeWidth, 'size')\n : (props.strokeWidth ?? `${opts.defaultStrokeWidth}`);\n const finalProps = {\n ...props,\n color,\n size,\n strokeWidth,\n style: style,\n };\n return _jsx(Component, { ...finalProps });\n };\n const wrapped = (propsIn) => {\n return _jsx(IconWrapper, { ...propsIn });\n };\n // add staticConfig so styled() works properly with themed icons\n wrapped['staticConfig'] = {\n isHOC: true,\n acceptsClassName: true,\n };\n return wrapped;\n}\n//# sourceMappingURL=themed.js.map","// Written by scripts/sync-catalogs.sh from catalogs/review.json; test/catalogs.ts holds the two equal.\nexport const REVIEW = ['am', 'ar-MA', 'as', 'az', 'bho', 'ceb', 'ckb', 'fa-AF', 'ha', 'ht', 'hy', 'jv', 'ka', 'kk', 'km', 'ku', 'ky', 'lo', 'mn', 'my', 'ne', 'om', 'or', 'pa', 'pa-PK', 'ps', 'sd', 'si', 'so', 'su', 'tg', 'tk', 'ug', 'uz'];\n//# sourceMappingURL=review.js.map","import { REVIEW } from \"./review.js\";\n/**\n * Every locale the Hanzo ecosystem ships. THE registry: the picker offers it (less what\n * waits for review, `review.ts`), `resolve`\n * negotiates against it, the tools fill and gate it, and `catalogs/` holds one file per\n * entry.\n *\n * Order is the picker's: by English name. `resolve` does not depend on it; where a\n * request names a region we do not ship, `resolve.ts` says which variant serves it.\n * `dir` follows the script: every locale written in Arabic or Hebrew script is `rtl`\n * (`test/registry.ts` derives the script from the tag and holds the two equal).\n *\n * To add one: insert it here, add its loader in `loaders.ts`, generate its catalog, ship.\n */\nconst registry = [\n { code: 'am', name: 'አማርኛ', englishName: 'Amharic', dir: 'ltr' },\n { code: 'ar', name: 'العربية', englishName: 'Arabic', dir: 'rtl' },\n { code: 'ar-EG', name: 'العربية (مصر)', englishName: 'Arabic (Egypt)', dir: 'rtl' },\n { code: 'ar-LB', name: 'العربية (لبنان)', englishName: 'Arabic (Lebanon)', dir: 'rtl' },\n { code: 'ar-MA', name: 'العربية (المغرب)', englishName: 'Arabic (Morocco)', dir: 'rtl' },\n { code: 'ar-SA', name: 'العربية (السعودية)', englishName: 'Arabic (Saudi Arabia)', dir: 'rtl' },\n { code: 'hy', name: 'հայերեն', englishName: 'Armenian', dir: 'ltr' },\n { code: 'as', name: 'অসমীয়া', englishName: 'Assamese', dir: 'ltr' },\n { code: 'az', name: 'azərbaycan', englishName: 'Azerbaijani', dir: 'ltr' },\n { code: 'bn', name: 'বাংলা', englishName: 'Bangla', dir: 'ltr' },\n { code: 'bho', name: 'भोजपुरी', englishName: 'Bhojpuri', dir: 'ltr' },\n { code: 'my', name: 'မြန်မာ', englishName: 'Burmese', dir: 'ltr' },\n { code: 'ceb', name: 'Cebuano', englishName: 'Cebuano', dir: 'ltr' },\n { code: 'ckb', name: 'کوردیی ناوەندی', englishName: 'Central Kurdish', dir: 'rtl' },\n { code: 'zh-HK', name: '中文(香港)', englishName: 'Chinese (Hong Kong)', dir: 'ltr' },\n { code: 'zh-Hans', name: '中文(简体)', englishName: 'Chinese (Simplified)', dir: 'ltr' },\n { code: 'zh-Hant', name: '中文(繁體)', englishName: 'Chinese (Traditional)', dir: 'ltr' },\n { code: 'da', name: 'dansk', englishName: 'Danish', dir: 'ltr' },\n { code: 'fa-AF', name: 'دری', englishName: 'Dari', dir: 'rtl' },\n { code: 'nl', name: 'Nederlands', englishName: 'Dutch', dir: 'ltr' },\n { code: 'en-US', name: 'English (United States)', englishName: 'English (United States)', dir: 'ltr' },\n { code: 'fil', name: 'Filipino', englishName: 'Filipino', dir: 'ltr' },\n { code: 'fi', name: 'suomi', englishName: 'Finnish', dir: 'ltr' },\n { code: 'fr-CA', name: 'français (Canada)', englishName: 'French (Canada)', dir: 'ltr' },\n { code: 'fr-FR', name: 'français (France)', englishName: 'French (France)', dir: 'ltr' },\n { code: 'ka', name: 'ქართული', englishName: 'Georgian', dir: 'ltr' },\n { code: 'de-DE', name: 'Deutsch (Deutschland)', englishName: 'German (Germany)', dir: 'ltr' },\n { code: 'gu', name: 'ગુજરાતી', englishName: 'Gujarati', dir: 'ltr' },\n { code: 'ht', name: 'Kreyòl ayisyen', englishName: 'Haitian Creole', dir: 'ltr' },\n { code: 'ha', name: 'Hausa', englishName: 'Hausa', dir: 'ltr' },\n { code: 'he', name: 'עברית', englishName: 'Hebrew', dir: 'rtl' },\n { code: 'hi-IN', name: 'हिन्दी (भारत)', englishName: 'Hindi (India)', dir: 'ltr' },\n { code: 'id-ID', name: 'Indonesia (Indonesia)', englishName: 'Indonesian (Indonesia)', dir: 'ltr' },\n { code: 'it-IT', name: 'italiano (Italia)', englishName: 'Italian (Italy)', dir: 'ltr' },\n { code: 'ja-JP', name: '日本語 (日本)', englishName: 'Japanese (Japan)', dir: 'ltr' },\n { code: 'jv', name: 'Jawa', englishName: 'Javanese', dir: 'ltr' },\n { code: 'kn', name: 'ಕನ್ನಡ', englishName: 'Kannada', dir: 'ltr' },\n { code: 'kk', name: 'қазақ тілі', englishName: 'Kazakh', dir: 'ltr' },\n { code: 'km', name: 'ខ្មែរ', englishName: 'Khmer', dir: 'ltr' },\n { code: 'ko-KR', name: '한국어(대한민국)', englishName: 'Korean (South Korea)', dir: 'ltr' },\n { code: 'ku', name: 'kurdî (kurmancî)', englishName: 'Kurdish (Kurmanji)', dir: 'ltr' },\n { code: 'ky', name: 'кыргызча', englishName: 'Kyrgyz', dir: 'ltr' },\n { code: 'lo', name: 'ລາວ', englishName: 'Lao', dir: 'ltr' },\n { code: 'ms', name: 'Melayu', englishName: 'Malay', dir: 'ltr' },\n { code: 'ml', name: 'മലയാളം', englishName: 'Malayalam', dir: 'ltr' },\n { code: 'mr', name: 'मराठी', englishName: 'Marathi', dir: 'ltr' },\n { code: 'mn', name: 'монгол', englishName: 'Mongolian', dir: 'ltr' },\n { code: 'ne', name: 'नेपाली', englishName: 'Nepali', dir: 'ltr' },\n { code: 'nb', name: 'norsk bokmål', englishName: 'Norwegian Bokmål', dir: 'ltr' },\n { code: 'or', name: 'ଓଡ଼ିଆ', englishName: 'Odia', dir: 'ltr' },\n { code: 'om', name: 'Oromoo', englishName: 'Oromo', dir: 'ltr' },\n { code: 'ps', name: 'پښتو', englishName: 'Pashto', dir: 'rtl' },\n { code: 'fa', name: 'فارسی', englishName: 'Persian', dir: 'rtl' },\n { code: 'pt-BR', name: 'português (Brasil)', englishName: 'Portuguese (Brazil)', dir: 'ltr' },\n { code: 'pt-PT', name: 'português (Portugal)', englishName: 'Portuguese (Portugal)', dir: 'ltr' },\n { code: 'pa', name: 'ਪੰਜਾਬੀ', englishName: 'Punjabi', dir: 'ltr' },\n { code: 'pa-PK', name: 'پنجابی', englishName: 'Punjabi (Pakistan)', dir: 'rtl' },\n { code: 'ru', name: 'русский', englishName: 'Russian', dir: 'ltr' },\n { code: 'sd', name: 'سنڌي', englishName: 'Sindhi', dir: 'rtl' },\n { code: 'si', name: 'සිංහල', englishName: 'Sinhala', dir: 'ltr' },\n { code: 'so', name: 'Soomaali', englishName: 'Somali', dir: 'ltr' },\n { code: 'es-AR', name: 'español (Argentina)', englishName: 'Spanish (Argentina)', dir: 'ltr' },\n { code: 'es-419', name: 'español (Latinoamérica)', englishName: 'Spanish (Latin America)', dir: 'ltr' },\n { code: 'es-MX', name: 'español (México)', englishName: 'Spanish (Mexico)', dir: 'ltr' },\n { code: 'es-ES', name: 'español (España)', englishName: 'Spanish (Spain)', dir: 'ltr' },\n { code: 'su', name: 'Basa Sunda', englishName: 'Sundanese', dir: 'ltr' },\n { code: 'sw', name: 'Kiswahili', englishName: 'Swahili', dir: 'ltr' },\n { code: 'sv', name: 'svenska', englishName: 'Swedish', dir: 'ltr' },\n { code: 'tg', name: 'тоҷикӣ', englishName: 'Tajik', dir: 'ltr' },\n { code: 'ta', name: 'தமிழ்', englishName: 'Tamil', dir: 'ltr' },\n { code: 'te', name: 'తెలుగు', englishName: 'Telugu', dir: 'ltr' },\n { code: 'th', name: 'ไทย', englishName: 'Thai', dir: 'ltr' },\n { code: 'tr', name: 'Türkçe', englishName: 'Turkish', dir: 'ltr' },\n { code: 'tk', name: 'türkmen dili', englishName: 'Turkmen', dir: 'ltr' },\n { code: 'uk', name: 'українська', englishName: 'Ukrainian', dir: 'ltr' },\n { code: 'ur', name: 'اردو', englishName: 'Urdu', dir: 'rtl' },\n { code: 'ug', name: 'ئۇيغۇرچە', englishName: 'Uyghur', dir: 'rtl' },\n { code: 'uz', name: 'oʻzbek', englishName: 'Uzbek', dir: 'ltr' },\n { code: 'vi', name: 'Tiếng Việt', englishName: 'Vietnamese', dir: 'ltr' },\n];\nexport const locales = registry.map((l) => ({ ...l, review: REVIEW.includes(l.code) }));\n/** The registry's tags, for callers that only negotiate. */\nexport const SUPPORTED_LOCALES = registry.map((l) => l.code);\n/** What a browser's own language may select: everything not waiting for review. */\nexport const OFFERED = registry.filter((l) => !REVIEW.includes(l.code)).map((l) => l.code);\nexport const DEFAULT_LOCALE = 'en-US';\n/**\n * Names spaces — keep in sync with the source/ directory layout.\n */\nexport const NAMESPACES = ['shared', 'exchange', 'wallet', 'chat', 'identity', 'docs'];\n//# sourceMappingURL=locales.js.map","import { DEFAULT_LOCALE, SUPPORTED_LOCALES, locales } from \"./locales.js\";\n/**\n * Turn what a person's device asked for into a locale we actually ship.\n *\n * Every surface needs this and none of them should answer it differently: a web\n * browser sends `navigator.languages`, a phone reports the OS preference list, a\n * server reads Accept-Language, and all three arrive as BCP-47 tags that are\n * usually NOT one of ours — `en-GB`, `es-MX`, `zh-Hant-HK`. Left to each\n * surface, the same person sees a different language depending on which one they\n * opened, which is the failure this exists to make impossible.\n *\n * The rule is RFC 4647 lookup with two additions, applied in order:\n *\n * 1. the exact tag, case-insensitively — `zh-hant` is `zh-Hant`\n * 2. same language AND same script — `zh-TW` finds `zh-Hant`, never `zh-Hans`;\n * `pa-Arab` finds `pa-PK`, never Gurmukhi `pa`. Among those, in order:\n * a. the same region — `es` (Spain, maximized) finds `es-ES`\n * b. the variant that serves that region (`SERVES`) — `es-CO` finds `es-419`,\n * `pt-AO` `pt-PT`, `zh-MO` `zh-HK`, `ar-AE` `ar-SA`\n * c. the variant with no region — `ar-IQ` finds `ar`, `fa-IR` `fa`\n * d. the language's own region — `fr-BE` finds `fr-FR`, as bare `fr` would\n * 3. same language — `en-GB` finds `en-US`\n * 4. the default\n *\n * Script is what step 2 buys, and it is the step a naive implementation skips.\n * Chinese is the case that punishes skipping it: `zh-CN` and `zh-TW` differ by\n * WRITING SYSTEM, so matching on language alone hands a Hong Kong reader\n * simplified characters because `zh-Hans` happens to be listed first. Neither tag\n * says its script out loud, so both sides are maximized (`zh-TW` → `zh-Hant-TW`)\n * before comparing — the platform knows this mapping and we do not restate it.\n */\nexport function resolve(requested, supported = SUPPORTED_LOCALES) {\n const wanted = (typeof requested === 'string' ? [requested] : requested ?? []).filter((tag) => typeof tag === 'string' && tag.trim() !== '');\n // In order: the caller's FIRST preference that we can serve at all beats a\n // later preference we could serve exactly. Someone whose list is [fr, en] is\n // telling us they would rather read approximate French than perfect English.\n for (const tag of wanted) {\n const hit = match(tag.trim().replaceAll('_', '-'), supported);\n if (hit) {\n return hit;\n }\n }\n return DEFAULT_LOCALE;\n}\n/** Which way a locale's text runs, after negotiating it: `rtl` for every locale in Arabic or Hebrew script. */\nexport function direction(requested) {\n const code = resolve(requested);\n return locales.find((l) => l.code === code)?.dir ?? 'ltr';\n}\nfunction match(tag, supported) {\n const exact = supported.find((s) => s.toLowerCase() === tag.toLowerCase());\n if (exact) {\n return exact;\n }\n const want = parse(tag);\n if (!want.language) {\n return undefined;\n }\n const sameLanguage = supported.filter((s) => parse(s).language === want.language);\n if (sameLanguage.length === 0) {\n return undefined;\n }\n const sameScript = want.script ? sameLanguage.filter((s) => parse(s).script === want.script) : [];\n return pick(sameScript.length > 0 ? sameScript : sameLanguage, want.region, parse(want.language).region);\n}\n/**\n * Step 2's order, among tags of one language (and script, when any shares it): the\n * tag stating `wanted` (a region), the variant that serves it, the variant with no\n * region, the language's `own` region, the first. `boot.ts` tabulates the answers.\n */\nexport function pick(near, wanted, own) {\n return (near.find((s) => wanted && region(s) === wanted) ??\n near.find((s) => wanted && SERVES[s]?.includes(wanted)) ??\n near.find((s) => !region(s)) ??\n near.find((s) => own && region(s) === own) ??\n near[0]);\n}\n/**\n * Regions read in a variant other than the one their language falls to. Spanish and\n * Portuguese follow CLDR's parent locales (`es-419` is the parent of every American\n * Spanish, `pt-PT` of every Portuguese outside Brazil); Macau reads Hong Kong's\n * Traditional Chinese; Arabic follows its dialect areas, Gulf, Maghreb and Levant.\n * A region whose own variant ships is matched before this is asked.\n */\nexport const SERVES = {\n 'es-419': ['AR', 'BO', 'BR', 'BZ', 'CL', 'CO', 'CR', 'CU', 'DO', 'EC', 'GT', 'HN', 'MX', 'NI', 'PA', 'PE', 'PR', 'PY', 'SV', 'US', 'UY', 'VE'],\n 'pt-PT': ['AO', 'CH', 'CV', 'FR', 'GQ', 'GW', 'LU', 'MO', 'MZ', 'ST', 'TL'],\n 'zh-HK': ['MO'],\n 'ar-SA': ['AE', 'BH', 'KW', 'OM', 'QA', 'YE'],\n 'ar-MA': ['DZ', 'EH', 'LY', 'MR', 'TN'],\n 'ar-LB': ['JO', 'PS', 'SY'],\n};\n/** The region a tag states, not one `maximize` infers: `ar` names no region, though it maximizes to Egypt. */\nexport function region(tag) {\n try {\n return new Intl.Locale(tag).region;\n }\n catch {\n return undefined;\n }\n}\n/**\n * Languages `Intl` leaves under a name we do not ship. `no` is the Norwegian\n * macrolanguage, which every OS that sends it means as Bokmål. `lah` (Lahnda, what\n * `pnb` canonicalizes to) is the Punjabi of Pakistan, written in Shahmukhi, so it\n * maximizes to Arabic script and finds `pa-PK`. (`tl` → `fil`, `in` → `id`, `iw` →\n * `he` and `prs` → `fa-AF` `Intl` canonicalizes itself.)\n */\nexport const MACRO = { no: 'nb', lah: 'pa' };\n/**\n * The language, script and region of a tag, with script and region filled in\n * where the tag left them implied. `Intl.Locale` holds the likely-subtags data\n * that does the filling, so a runtime that has it answers `zh-TW → Hant` without\n * this file carrying a table that would go stale.\n *\n * A runtime without it still resolves by language, which is step 3 — worse for\n * Chinese, correct for everything else, and never an exception thrown at a person\n * trying to read a page.\n */\nexport function parse(tag) {\n try {\n const loc = new Intl.Locale(tag).maximize();\n return { language: MACRO[loc.language] ?? loc.language, script: loc.script, region: loc.region };\n }\n catch {\n const language = tag.toLowerCase().split('-')[0];\n return { language: MACRO[language] ?? language };\n }\n}\n//# sourceMappingURL=resolve.js.map","export function pieces(messages, source) {\n const text = Object.hasOwn(messages, source) ? messages[source] : source;\n const spaced = (source.match(/^\\s*/)?.[0] ?? '') + text.trim() + (source.match(/\\s*$/)?.[0] ?? '');\n const out = [];\n let at = 0;\n for (const slot of spaced.matchAll(/\\{(\\w+)\\}/g)) {\n if (slot.index > at) {\n out.push(spaced.slice(at, slot.index));\n }\n out.push({ name: slot[1] });\n at = slot.index + slot[0].length;\n }\n if (at < spaced.length) {\n out.push(spaced.slice(at));\n }\n return out;\n}\n/**\n * One authored string, rendered: `{name}` arguments are filled from `values`, and one\n * with no value stays visible rather than rendering empty.\n */\nexport function translate(messages, source, values = {}) {\n return pieces(messages, source)\n .map((piece) => typeof piece === 'string' ? piece : Object.hasOwn(values, piece.name) ? String(values[piece.name]) : `{${piece.name}}`)\n .join('');\n}\n/** The English, with its arguments filled, for a caller that passes no `t`. */\nexport const english = (source, values) => translate({}, source, values);\n/**\n * Text set apart from the direction around it: Unicode's first-strong isolate.\n *\n * A figure dropped into right-to-left prose is reordered with it — `1,150–1,400`\n * reads `1,400–1,150` and `~43 tok/s` reads `tok/s 43~`. Inside an isolate the\n * value takes its own direction (its first strong letter, or left-to-right when it\n * has none, as a number does) and the prose around it is unaffected. Invisible, and\n * what `<bdi>` is in plain text, so it holds in an attribute, a title or a label.\n *\n * Text that is already one isolate is returned as it is, so a figure `format` set\n * apart and then handed to `t` carries one pair of marks, not two.\n */\nexport function isolate(text) {\n return isolated(text) ? text : `\\u2068${text}\\u2069`;\n}\n/** Whether `text` is one first-strong isolate from its first character to its last. */\nfunction isolated(text) {\n if (!text.startsWith('\\u2068') || !text.endsWith('\\u2069')) {\n return false;\n }\n let depth = 0;\n for (let i = 0; i < text.length; i++) {\n const c = text.charCodeAt(i);\n if (c >= 0x2066 && c <= 0x2068) {\n depth++;\n }\n else if (c === 0x2069 && --depth === 0 && i < text.length - 1) {\n return false;\n }\n }\n return depth === 0;\n}\n/**\n * Authored English written as data, translated where it is drawn:\n * `{ label: phrase('Pricing') }`, then `t(item.label)`. It returns its argument; it\n * exists so `i18n-extract` finds the string where no `t` call names it.\n */\nexport function phrase(source) {\n return source;\n}\n/** Where this browser keeps one account's language choice; signed-out visitors share `guest`. */\nexport function preferenceKey(userId) {\n return `hanzo.locale.v1:${encodeURIComponent(userId || 'guest')}`;\n}\n/**\n * The locale this browser's document last showed, written wherever the provider sets\n * `<html lang dir>` and read by `bootScript` (`./boot`) before the next first paint.\n */\nexport const PAINTED = 'hanzo.locale.v1.painted';\n//# sourceMappingURL=message.js.map","import { isolate } from \"./message.js\";\nimport { direction } from \"./resolve.js\";\nconst SECONDS = [\n ['year', 365 * 86400],\n ['month', 30 * 86400],\n ['week', 7 * 86400],\n ['day', 86400],\n ['hour', 3600],\n ['minute', 60],\n ['second', 1],\n];\n/** The helpers for one locale. Formatters are built once per set of options and kept. */\nexport function format(locale) {\n const rtl = direction(locale) === 'rtl';\n const kept = new Map();\n function made(kind, options, make) {\n const key = `${kind}:${JSON.stringify(options)}`;\n let formatter = kept.get(key);\n if (!formatter) {\n formatter = make();\n kept.set(key, formatter);\n }\n return formatter;\n }\n const out = (text) => (rtl ? isolate(text) : text);\n const number = (value, options) => out(made('number', options, () => new Intl.NumberFormat(locale, options)).format(value));\n return {\n number: (value, options = {}) => number(value, options),\n percent: (value, options = {}) => number(value, { ...options, style: 'percent' }),\n money: (amount, currency, options = {}) => number(amount, { ...options, style: 'currency', currency }),\n date: (value, options = {}) => out(made('date', options, () => new Intl.DateTimeFormat(locale, options)).format(moment(value))),\n relative: (value, { now, unit, ...options } = {}) => {\n const span = (moment(value).getTime() - moment(now ?? Date.now()).getTime()) / 1000;\n const [name, size] = SECONDS.find(([u, s]) => (unit ? u === unit : Math.abs(span) >= s)) ?? ['second', 1];\n return out(made('relative', options, () => new Intl.RelativeTimeFormat(locale, options)).format(Math.round(span / size), name));\n },\n list: (items, options = {}) => out(made('list', options, () => new Intl.ListFormat(locale, options)).format(rtl ? items.map(isolate) : items)),\n };\n}\nfunction moment(value) {\n return value instanceof Date ? value : new Date(value);\n}\n//# sourceMappingURL=format.js.map","'use client';\nimport { Fragment, createContext, createElement, useContext, useEffect, useMemo, useRef, useState, useSyncExternalStore, } from 'react';\nimport { loadAccountLocale, saveAccountLocale } from \"./account.js\";\nimport { faces } from \"./faces.js\";\nimport { format } from \"./format.js\";\nimport { DEFAULT_LOCALE, OFFERED, locales } from \"./locales.js\";\nimport { PAINTED, isolate, pieces, preferenceKey, translate } from \"./message.js\";\nimport { direction, resolve } from \"./resolve.js\";\nconst Context = createContext({\n locale: DEFAULT_LOCALE,\n dir: 'ltr',\n messages: {},\n loading: false,\n error: null,\n t: say({}, false),\n format: format(DEFAULT_LOCALE),\n setLocale: async () => {\n throw new Error('Changing language requires I18nProvider');\n },\n});\n/**\n * What the server drew with: the provider's starting locale and no catalog, the words\n * its prerender wrote. A part of the page that hydrates late (a section in a chunk of\n * its own, a Suspense boundary streamed in) hydrates after the provider may have\n * loaded the reader's catalog; reading that, it would draw Arabic where the HTML holds\n * English, and React throws the tree away and draws it again on the client.\n */\nconst Served = createContext(null);\nconst quiet = () => () => { };\nconst client = () => true;\nconst server = () => false;\nexport function I18nProvider({ children, userId, initialLocale = DEFAULT_LOCALE, account, loadCatalog, scope, }) {\n const [state, setState] = useState({\n locale: resolve(initialLocale),\n messages: {},\n });\n const [loading, setLoading] = useState(false);\n const [error, setError] = useState(null);\n const sequence = useRef(0);\n const writes = useRef(Promise.resolve());\n const identity = useRef(userId);\n identity.current = userId;\n const area = useRef(scope);\n area.current = scope;\n /** The scopes asked for the language shown, so each is fetched once per language. */\n const asked = useRef({ locale: DEFAULT_LOCALE, scopes: new Set() });\n /**\n * Load and show `value`. `save` says where the choice is kept: `account` (a person\n * chose it: this browser and IAM), `device` (IAM's choice, mirrored so the next load\n * starts in it), or nowhere (a choice already kept, re-applied).\n */\n async function select(value, save = 'account') {\n const locale = resolve(value);\n const request = ++sequence.current;\n const owner = identity.current;\n setLoading(true);\n setError(null);\n try {\n const part = area.current;\n const loaded = locale === DEFAULT_LOCALE ? {} : await loadCatalog(locale, part);\n if (sequence.current !== request || identity.current !== owner) {\n return;\n }\n const messages = unwrap(loaded);\n // The words wait for the face they are set in (./faces.ts), so a script the\n // page's family lacks appears once, in its companion, and nothing moves after.\n await faces(messages);\n if (sequence.current !== request || identity.current !== owner) {\n return;\n }\n asked.current = { locale, scopes: new Set([part]) };\n setState({ locale, messages });\n document.documentElement.lang = locale;\n document.documentElement.dir = direction(locale);\n try {\n // What the document shows is what bootScript paints first on the next load.\n localStorage.setItem(PAINTED, locale);\n if (save) {\n localStorage.setItem(preferenceKey(owner), locale);\n }\n }\n catch {\n // Private browsing may refuse storage; the choice still holds for this page.\n }\n if (save === 'account' && owner && account?.token) {\n const credentials = account;\n writes.current = writes.current\n .catch(() => { })\n .then(async () => {\n if (identity.current !== owner) {\n return;\n }\n await saveAccountLocale(credentials, locale, AbortSignal.timeout(10000));\n })\n .catch(() => {\n if (sequence.current === request && identity.current === owner) {\n setError('Language saved on this device. Account sync failed; select the language again to retry.');\n }\n });\n }\n }\n catch {\n if (sequence.current === request) {\n setError('Unable to load this language. Please try again.');\n }\n }\n finally {\n if (sequence.current === request) {\n setLoading(false);\n }\n }\n }\n useEffect(() => {\n let saved = null;\n try {\n saved = localStorage.getItem(preferenceKey(userId));\n }\n catch {\n // Storage is optional.\n }\n // A saved choice is honoured by code, review or not. A browser language only\n // selects what the picker offers. A different account never inherits the\n // preceding account's choice, so a signed-in first visit starts at initialLocale.\n void select(saved || (userId ? initialLocale : resolve(navigator.languages ?? [navigator.language], OFFERED)), false);\n const changed = (event) => {\n if (event.key === preferenceKey(userId)) {\n void select(event.newValue || initialLocale, false);\n }\n };\n window.addEventListener('storage', changed);\n return () => {\n ++sequence.current;\n window.removeEventListener('storage', changed);\n };\n }, [userId, initialLocale]);\n useEffect(() => {\n if (!userId || !account?.token) {\n return;\n }\n const stop = new AbortController();\n const before = sequence.current;\n loadAccountLocale(account, stop.signal)\n .then((locale) => {\n if (locale && sequence.current === before && !stop.signal.aborted) {\n void select(locale, 'device');\n }\n })\n .catch(() => { }); // The device's choice stays usable offline.\n return () => stop.abort();\n }, [userId, account?.base, account?.token]);\n // A move to another part of the site: fetch that part once for the language shown and\n // add it to what is shown. A failure leaves the English, as a missing key does.\n useEffect(() => {\n const { locale } = state;\n if (locale === DEFAULT_LOCALE || asked.current.locale !== locale || asked.current.scopes.has(scope)) {\n return;\n }\n asked.current.scopes.add(scope);\n loadCatalog(locale, scope)\n .then(async (loaded) => {\n const more = unwrap(loaded);\n await faces(more);\n setState((shown) => (shown.locale === locale ? { locale, messages: { ...shown.messages, ...more } } : shown));\n })\n .catch(() => asked.current.locale === locale && asked.current.scopes.delete(scope));\n }, [scope, state.locale]);\n const formats = useMemo(() => format(state.locale), [state.locale]);\n // The starting locale, as the prerender drew it (`Served`), and nothing loaded.\n const first = useRef(resolve(initialLocale)).current;\n const served = useMemo(() => ({\n locale: first,\n dir: direction(first),\n messages: {},\n loading: false,\n error: null,\n setLocale: select,\n t: say({}, direction(first) === 'rtl'),\n format: format(first),\n }), [first]);\n const value = useMemo(() => ({\n ...state,\n dir: direction(state.locale),\n loading,\n error,\n setLocale: select,\n t: say(state.messages, direction(state.locale) === 'rtl'),\n format: formats,\n }), [state, formats, loading, error, userId, account?.base, account?.token]);\n return createElement(Served.Provider, { value: served }, createElement(Context.Provider, { value }, children));\n}\n/** A catalog as a loader hands it back: the messages, or a module whose default they are. */\nconst unwrap = (loaded) => ('default' in loaded ? loaded.default : loaded);\n/**\n * The provider's language, and what the server drew while a part hydrates.\n *\n * `useSyncExternalStore` answers its server snapshot while a component hydrates and\n * the client's after, and re-renders the component when the two differ. So a part that\n * hydrates after the reader's catalog arrived first draws the words its HTML holds,\n * then the reader's; a part mounted on the client draws the reader's at once.\n */\nexport function useI18n() {\n const value = useContext(Context);\n const served = useContext(Served);\n const hydrated = useSyncExternalStore(quiet, client, server);\n return hydrated || !served ? value : served;\n}\n/** `<T>Settings</T>` — `t` as an element. */\nexport function T({ children, values }) {\n return useI18n().t(children, values ?? {});\n}\n/** `t` over one catalog: a string while every argument is text, a node once one is not. */\nfunction say(messages, rtl) {\n return ((source, values = {}) => {\n const text = Object.values(values).every((v) => typeof v === 'string' || typeof v === 'number');\n if (text) {\n const plain = values;\n return translate(messages, source, rtl ? Object.fromEntries(Object.entries(plain).map(([k, v]) => [k, isolate(String(v))])) : plain);\n }\n const parts = pieces(messages, source).map((piece) => {\n if (typeof piece === 'string') {\n return piece;\n }\n if (!Object.hasOwn(values, piece.name)) {\n return `{${piece.name}}`;\n }\n const value = values[piece.name];\n if (!rtl) {\n return value;\n }\n return typeof value === 'string' || typeof value === 'number' ? isolate(String(value)) : createElement('bdi', null, value);\n });\n return createElement(Fragment, null, ...parts);\n });\n}\nexport function LanguagePicker({ className, style, review = false }) {\n const { locale, setLocale, t, loading, error } = useI18n();\n const offered = locales.filter((l) => review || !l.review || l.code === locale);\n return createElement('label', { className, style: { display: 'inline-flex', flexDirection: 'column', gap: 4, maxWidth: '100%', ...style } }, createElement('span', null, t('Language')), createElement('select', {\n 'aria-label': t('Language'),\n 'aria-busy': loading,\n value: locale,\n onChange: (event) => void setLocale(event.target.value),\n style: {\n maxWidth: '100%',\n minHeight: 36,\n color: 'inherit',\n background: 'var(--background, Canvas)',\n border: '1px solid var(--border, GrayText)',\n borderRadius: 6,\n paddingInline: 8,\n font: 'inherit',\n },\n }, offered.map((item) => createElement('option', { key: item.code, value: item.code, lang: item.code, dir: item.dir }, item.name))), error && createElement('span', { role: 'alert' }, t(error)));\n}\n//# sourceMappingURL=react.js.map","'use client';\n// The ONE place a shared component says what a user just did.\n//\n// Instrumenting the COMPONENT beats instrumenting 100 apps: a product that\n// renders `DataTable`, `PrimaryButton`, `SlideOver`, `ConfirmDelete`, `Field*`,\n// `ComboBox`, `Segmented`, `SearchInput`, `OrgSwitcher`, `MenuItemView`,\n// `EmptyState` or `ThemeToggle` reports the SAME interaction vocabulary with\n// zero app code. Nothing to wire, nothing to remember, nothing to drift.\n//\n// import { emit, useEmit, InstrumentSurface } from '@hanzo/ui/product'\n// <InstrumentSurface value=\"billing\">…</InstrumentSurface> // optional context\n//\n// This is the CURATED half. `<Hanzo analytics>` already reports every click,\n// change, submit and route change on its own, annotated with the component it\n// happened on — what autocapture cannot know is that a click WAS a checkout.\n// That is what this names. Same client, same stream, same entry point.\n//\n// ONE event name, structured properties — the taxonomy in @hanzo/event is a\n// CLOSED set, and its own rule for a product-specific moment is \"the `action`\n// property, never a new event name\". So every UI interaction is\n// EVENTS.FEATURE_USED carrying { component, action, surface, id, value }.\n// Funnel moments (signup, checkout, deploy) keep their own dedicated names and\n// are emitted by the surface that owns them, not by a button.\n//\n// One stream: `track` from @hanzogui/telemetry — already a dependency of this\n// package and already THE entry point (POST api.hanzo.ai/v1/event). No second\n// client, no CDN script, no `window` poking. It is SSR-safe, consent-aware,\n// honors DNT/GPC, and is fail-soft by construction, so this module inherits all\n// of that and adds no error policy of its own.\nimport { createContext, useCallback, useContext } from 'react';\n// ONE dependency edge: @hanzogui/telemetry owns the transport AND re-exports the\n// @hanzo/event vocabulary, so this package never names a second source of truth.\nimport { EVENTS, track } from '@hanzogui/telemetry';\n/** The enclosing product area (route/module). Optional: with no provider the\n * events still carry component+action, and the product+path already come from\n * the telemetry client. */\nconst SurfaceContext = createContext(undefined);\n/** Names the product area every shared component inside it reports under.\n * Plain provider, no element — it must not perturb any layout. */\nexport const InstrumentSurface = SurfaceContext.Provider;\n/** The current product area, or undefined outside a provider. */\nexport const useSurface = () => useContext(SurfaceContext);\n/** Report an interaction. Callable from anywhere (module scope, event handler,\n * a non-React host) — the ambient telemetry client is built on first use. */\nexport function emit(e) {\n track(EVENTS.FEATURE_USED, {\n component: e.component,\n action: e.action,\n ...(e.id !== undefined ? { id: e.id } : null),\n ...(e.value !== undefined ? { value: e.value } : null),\n ...(e.surface !== undefined ? { surface: e.surface } : null),\n });\n}\n/** `emit` with the surrounding `<InstrumentSurface/>` already bound — what the\n * shared components themselves use, so an app never labels a surface twice. */\nexport function useEmit() {\n const surface = useSurface();\n return useCallback((e) => emit(surface !== undefined && e.surface === undefined ? { ...e, surface } : e), [surface]);\n}\n/** A component's own children ARE its identity — \"Deploy\", \"Log in with Hanzo\n * Cloud\". React hands them over as a string, or as an ARRAY when the label is\n * interpolated (`Log in with {brand}`), which is the common case; flattening the\n * string parts is the difference between a named event and an anonymous one.\n * Anything non-textual (an icon element) yields undefined rather than a guess. */\nexport function labelOf(children) {\n if (typeof children === 'string')\n return children.trim() || undefined;\n if (Array.isArray(children)) {\n const text = children.filter((c) => typeof c === 'string' || typeof c === 'number').join('');\n return text.trim() || undefined;\n }\n return undefined;\n}\n/** Free text (a search box, a text field) is reported as its LENGTH — the shape\n * of the behaviour without the content. One helper so no component invents its\n * own idea of \"safe to send\". */\nexport const textSize = (s) => (s ? s.length : 0);\n//# sourceMappingURL=instrument.js.map"],"x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241],"mappings":"kFAWA,IAAI,EAAqB,OAAO,IAAI,4BAA4B,EAC9D,EAAoB,OAAO,IAAI,cAAc,EAC7C,EAAsB,OAAO,IAAI,gBAAgB,EACjD,EAAyB,OAAO,IAAI,mBAAmB,EACvD,EAAsB,OAAO,IAAI,gBAAgB,EACjD,EAAsB,OAAO,IAAI,gBAAgB,EACjD,EA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