@riverbankcms/sdk 0.107.0 → 0.109.0
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 +21 -1
- package/dist/{PreviewEditorSidebar-DpAbAl08.mjs → PreviewEditorSidebar-DWqwfy3_.mjs} +48 -28
- package/dist/{PreviewEditorUI-O7cn6Xxv.mjs → PreviewEditorUI-B7OL4sfR.mjs} +10 -9
- package/dist/{PreviewQueryProvider-D0tnKl0t.mjs → PreviewQueryProvider-D0y2l8JN.mjs} +1 -1
- package/dist/{SdkPreviewModeRuntime-CVB7urtl.mjs → SdkPreviewModeRuntime-D8Gt9Gbe.mjs} +633 -220
- package/dist/{SiteChromeCustomizeContext-C_sizso-.mjs → SiteChromeCustomizeContext-DUpalEdL.mjs} +5764 -1556
- package/dist/_dts/ai/src/contracts/proposals.d.ts +15383 -11388
- package/dist/_dts/api/src/blocks.d.ts +41 -7
- package/dist/_dts/api/src/bookingAdjustments.d.ts +5 -0
- package/dist/_dts/api/src/bookingOperations.d.ts +4 -0
- package/dist/_dts/api/src/bookingRecords.d.ts +177 -127
- package/dist/_dts/api/src/bookingRefundOutcomes.d.ts +6 -6
- package/dist/_dts/api/src/cache-tags.d.ts +3 -0
- package/dist/_dts/api/src/common/envelope.d.ts +7 -0
- package/dist/_dts/api/src/contentRuntime.d.ts +19 -1
- package/dist/_dts/api/src/courses.d.ts +1 -0
- package/dist/_dts/api/src/customerMembershipOutcomes.d.ts +5 -5
- package/dist/_dts/api/src/endpoints.d.ts +134 -0
- package/dist/_dts/api/src/footer-settings.d.ts +1 -0
- package/dist/_dts/api/src/footerSettings.d.ts +8 -0
- package/dist/_dts/api/src/index.d.ts +7 -4
- package/dist/_dts/api/src/navigation/contracts.d.ts +3 -3
- package/dist/_dts/api/src/participantMessaging.d.ts +18 -12
- package/dist/_dts/api/src/previewContentContract.d.ts +4 -0
- package/dist/_dts/api/src/publicExperienceEndpoints.d.ts +1 -0
- package/dist/_dts/api/src/sdkContracts.d.ts +309 -1
- package/dist/_dts/api/src/siteBanner.d.ts +2 -2
- package/dist/_dts/api/src/siteInfrastructure.d.ts +13 -0
- package/dist/_dts/api/src/siteManagementEndpoints.d.ts +144 -60
- package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +35 -1
- package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +74 -28
- package/dist/_dts/block-form/src/widgets/BackgroundGradientWidget/BackgroundGradientField.d.ts +9 -0
- package/dist/_dts/block-form/src/widgets/BackgroundGradientWidget/BackgroundGradientWidget.d.ts +3 -4
- package/dist/_dts/blocks/src/contracts/proof-block-islands.d.ts +4 -4
- package/dist/_dts/blocks/src/index.d.ts +1 -1
- package/dist/_dts/blocks/src/primitives/layout/Section.d.ts +0 -1
- package/dist/_dts/blocks/src/rendering/server.d.ts +1 -0
- package/dist/_dts/blocks/src/system/blocks/audio-player.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/body-text.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/contact-newsletter.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/course-registration.d.ts +1 -22
- package/dist/_dts/blocks/src/system/blocks/cta-full.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/event-registration.d.ts +1 -22
- package/dist/_dts/blocks/src/system/blocks/file-download.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/form.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/image-gallery.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/media-text.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/newsletter-signup.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/site-footer-runtime.d.ts +50 -0
- package/dist/_dts/blocks/src/system/blocks/site-footer.d.ts +9 -48
- package/dist/_dts/blocks/src/system/blocks/site-header.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/team-members.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/testimonials.d.ts +3 -0
- package/dist/_dts/blocks/src/system/blocks/video-grid.d.ts +3 -0
- package/dist/_dts/blocks/src/system/constants/background.d.ts +1 -1
- package/dist/_dts/blocks/src/system/customize/backgrounds.d.ts +16 -6
- package/dist/_dts/blocks/src/system/defineBlock.d.ts +9 -1
- package/dist/_dts/blocks/src/system/fields/ctas.d.ts +8 -0
- package/dist/_dts/blocks/src/system/icons/registry.d.ts +2 -1
- package/dist/_dts/blocks/src/system/icons/social.d.ts +5 -0
- package/dist/_dts/blocks/src/system/icons/svg.d.ts +1 -0
- package/dist/_dts/blocks/src/system/manifest/schema.d.ts +33 -2
- package/dist/_dts/blocks/src/system/node/fragments/backgroundLayer.d.ts +13 -0
- package/dist/_dts/blocks/src/system/node/fragments/footerNav.d.ts +2 -0
- package/dist/_dts/blocks/src/system/node/fragments/styledContainer.d.ts +4 -4
- package/dist/_dts/blocks/src/system/node/fragments/styledSection.d.ts +3 -12
- package/dist/_dts/blocks/src/system/node/validation-constants.d.ts +1 -1
- package/dist/_dts/blocks/src/system/runtime/components/registry.client.d.ts +6 -6
- package/dist/_dts/blocks/src/system/runtime/components/runtime-backed-blocks.d.ts +3 -3
- package/dist/_dts/blocks/src/system/runtime/nodes/shared/contract-schemas.d.ts +2 -2
- package/dist/_dts/blocks/src/system/types/link.d.ts +3 -3
- package/dist/_dts/content-editor/src/FooterComposerPanel.d.ts +14 -0
- package/dist/_dts/content-editor/src/controller/EntryControllerProvider.d.ts +27 -8
- package/dist/_dts/content-editor/src/footerComposer.d.ts +56 -0
- package/dist/_dts/content-editor/src/hooks/useEntryActions.d.ts +1 -1
- package/dist/_dts/content-editor/src/hooks/useEntryMutations.d.ts +5 -5
- package/dist/_dts/content-editor/src/index.d.ts +2 -0
- package/dist/_dts/content-editor/src/primitives/PreviewRichTextEditor.d.ts +3 -1
- package/dist/_dts/content-editor/src/services/contentEntryServices.d.ts +20 -36
- package/dist/_dts/content-editor/src/ui/editorSnapshot.d.ts +5 -1
- package/dist/_dts/content-editor/src/ui/editorUiStore.d.ts +11 -0
- package/dist/_dts/content-model/src/content-types/entryValidation.d.ts +31 -0
- package/dist/_dts/content-model/src/content-types/scaffold.d.ts +58 -0
- package/dist/_dts/content-model/src/content-types/schema.d.ts +1 -1
- package/dist/_dts/content-model/src/content-types/sentinels.d.ts +36 -0
- package/dist/_dts/content-model/src/definitions/shared.d.ts +3 -0
- package/dist/_dts/content-model/src/index.d.ts +3 -0
- package/dist/_dts/core/src/booking-date-time.d.ts +8 -0
- package/dist/_dts/core/src/branded.d.ts +3 -0
- package/dist/_dts/core/src/editor-state.d.ts +4 -0
- package/dist/_dts/core/src/footer-composition.d.ts +143 -0
- package/dist/_dts/core/src/index.d.ts +2 -0
- package/dist/_dts/core/src/public-profile.d.ts +73 -0
- package/dist/_dts/db/src/generated/supabase/database.types.d.ts +221 -205
- package/dist/_dts/db/src/schemas/forms.d.ts +10 -10
- package/dist/_dts/editor/src/primitives/rich-text/RichTextEditorSurface.d.ts +5 -0
- package/dist/_dts/editor-blocks/src/BlockEditor.d.ts +1 -0
- package/dist/_dts/editor-blocks/src/block-editor/hooks/useBlockCreation.d.ts +2 -1
- package/dist/_dts/editor-blocks/src/block-editor/hooks/useBlockDuplication.d.ts +2 -1
- package/dist/_dts/editor-blocks/src/block-editor/hooks/useBlockReorder.d.ts +2 -1
- package/dist/_dts/editor-blocks/src/block-editor/owner.d.ts +10 -0
- package/dist/_dts/editor-blocks/src/block-editor/types.d.ts +1 -0
- package/dist/_dts/media-core/src/fileMimeDetection.d.ts +16 -0
- package/dist/_dts/media-core/src/fileStorage.d.ts +8 -0
- package/dist/_dts/media-core/src/storagePathDomain.d.ts +2 -0
- package/dist/_dts/media-core/src/uploadVerificationContract.d.ts +3 -0
- package/dist/_dts/path-utils/src/index.d.ts +5 -0
- package/dist/_dts/preview-next/src/client/blocks/BlockToolbar.d.ts +2 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewChromeLayer.d.ts +5 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewEditorSidebar.d.ts +2 -1
- package/dist/_dts/preview-next/src/client/preview/PreviewEntryControllerProvider.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +2 -1
- package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +2 -1
- package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +1 -0
- package/dist/_dts/preview-next/src/client/preview/previewErrorMessages.d.ts +4 -0
- package/dist/_dts/preview-next/src/client/preview/styleConfiguratorApplyPayload.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/audit.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/compare.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/deploy.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/drafts.d.ts +18 -0
- package/dist/_dts/sdk/src/cli/commands/entry.d.ts +15 -0
- package/dist/_dts/sdk/src/cli/commands/init-docs.d.ts +2 -2
- package/dist/_dts/sdk/src/cli/commands/publish-all.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/pull.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/commands/push/execute/diff.d.ts +1 -1
- package/dist/_dts/sdk/src/cli/commands/push/options.d.ts +3 -0
- package/dist/_dts/sdk/src/cli/commands/push-execute.d.ts +12 -1
- package/dist/_dts/sdk/src/cli/commands/setup.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/commands/verify.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/content/reader.d.ts +1 -0
- package/dist/_dts/sdk/src/cli/helpers.d.ts +22 -1
- package/dist/_dts/sdk/src/cli/index.d.ts +4 -0
- package/dist/_dts/sdk/src/cli/output.d.ts +88 -0
- package/dist/_dts/sdk/src/cli/program.d.ts +29 -0
- package/dist/_dts/sdk/src/cli/push-config.d.ts +1 -1
- package/dist/_dts/sdk/src/client/management/blocks.d.ts +14 -1
- package/dist/_dts/sdk/src/client/management/catalog.d.ts +10 -0
- package/dist/_dts/sdk/src/client/management/http.d.ts +7 -1
- package/dist/_dts/sdk/src/client/management/index.d.ts +2 -1
- package/dist/_dts/sdk/src/client/management/types.d.ts +58 -20
- package/dist/_dts/sdk/src/config/content-types.d.ts +2 -0
- package/dist/_dts/sdk/src/config/content-validation.d.ts +4 -0
- package/dist/_dts/sdk/src/date-time/index.d.ts +68 -0
- package/dist/_dts/sdk/src/navigation/index.d.ts +2 -0
- package/dist/_dts/sdk/src/public-api/contracts.d.ts +5 -2
- package/dist/_dts/sdk/src/rendering/components/Layout.d.ts +2 -1
- package/dist/_dts/sdk/src/rendering/helpers/loadContent.d.ts +1 -1
- package/dist/_dts/sdk/src/version.d.ts +1 -1
- package/dist/_dts/site-commands/src/commands.d.ts +900 -827
- package/dist/_dts/theme-core/src/accordions/types.d.ts +2 -2
- package/dist/_dts/theme-core/src/buttons/core.d.ts +15 -46
- package/dist/_dts/theme-core/src/buttons/effectClassification.d.ts +147 -0
- package/dist/_dts/theme-core/src/buttons/effects/types.d.ts +2 -3
- package/dist/_dts/theme-core/src/buttons/generateDefaultButtonSystem.d.ts +1 -1
- package/dist/_dts/theme-core/src/buttons/index.d.ts +1 -0
- package/dist/_dts/theme-core/src/buttons/personalities/index.d.ts +11 -0
- package/dist/_dts/theme-core/src/buttons/personalities/two-tone-pill.d.ts +17 -0
- package/dist/_dts/theme-core/src/buttons/personalities/types.d.ts +45 -33
- package/dist/_dts/theme-core/src/buttons/presets.d.ts +4 -25
- package/dist/_dts/theme-core/src/buttons/resolveButtonColourStates.d.ts +100 -0
- package/dist/_dts/theme-core/src/buttons/resolvedButtonCss.d.ts +16 -0
- package/dist/_dts/theme-core/src/buttons/types.d.ts +104 -86
- package/dist/_dts/theme-core/src/cards/types.d.ts +16 -16
- package/dist/_dts/theme-core/src/footer/mode.d.ts +15 -0
- package/dist/_dts/theme-core/src/generated/containerResponsiveThemeCss.d.ts +1 -1
- package/dist/_dts/theme-core/src/gradients/presets.d.ts +200 -8
- package/dist/_dts/theme-core/src/gradients/utils.d.ts +6 -2
- package/dist/_dts/theme-core/src/interactive/baseSchema.d.ts +1 -1
- package/dist/_dts/theme-core/src/mock-themes/all.d.ts +117 -150
- package/dist/_dts/theme-core/src/mock-themes/modern-minimal.d.ts +1 -1
- package/dist/_dts/theme-core/src/navigation/types.d.ts +3 -3
- package/dist/_dts/theme-core/src/palette/curated/index.d.ts +2 -2
- package/dist/_dts/theme-core/src/palette/curated/types.d.ts +5 -8
- package/dist/_dts/theme-core/src/palette/index.d.ts +0 -1
- package/dist/_dts/theme-core/src/schema.d.ts +1264 -138
- package/dist/_dts/theme-core/src/site-styles/backgroundAppearance.d.ts +2 -2
- package/dist/_dts/theme-core/src/site-styles/designState.d.ts +10 -10
- package/dist/_dts/theme-core/src/site-styles/headerLooks.d.ts +12 -1
- package/dist/_dts/theme-core/src/site-styles/pageDesignEditorModel.d.ts +3 -2
- package/dist/_dts/theme-core/src/site-styles/pageDesignIntent.d.ts +13 -6
- package/dist/_dts/theme-core/src/site-styles/runtimeCompiler.d.ts +29 -8
- package/dist/_dts/theme-core/src/site-styles/siteChromeNavPreferences.d.ts +15 -0
- package/dist/_dts/theme-core/src/site-styles/styleTags.d.ts +2 -2
- package/dist/cli/index.mjs +68552 -66955
- package/dist/cli/init-docs/content/cli-reference.md +50 -7
- package/dist/cli/init-docs/content/content-management.md +7 -4
- package/dist/cli/init-docs/content/workflow-publish.md +5 -1
- package/dist/client/{DiscountCodeDisclosure-BwGkvmVH.mjs → DiscountCodeDisclosure-DU1ygxU2.mjs} +1 -1
- package/dist/client/{EventCombined.client-JnWE6Hzc.mjs → EventCombined.client-DB5zagCo.mjs} +3 -3
- package/dist/client/{EventListing.client-DQewc_kg.mjs → EventListing.client-CTX9JHBL.mjs} +2 -2
- package/dist/client/{LeafletStaticMap-DPAU3SFt.mjs → LeafletStaticMap-BYImhgiB.mjs} +1 -1
- package/dist/client/{MagicLinkForm-D4kpWCbW.mjs → MagicLinkForm-CRkw_M3l.mjs} +2 -2
- package/dist/client/{StepIndicator-CBlkb4rA.mjs → StepIndicator-BnmVBJJh.mjs} +2 -2
- package/dist/client/{accordion-DAIBVpTS.mjs → accordion-CeGreumd.mjs} +1 -1
- package/dist/client/{bookingForm-DZ-4l5_1.mjs → bookingForm-CSzFNrpN.mjs} +6 -6
- package/dist/client/bookings.mjs +637 -328
- package/dist/client/{buttons-DJgynGHQ.mjs → buttons-DoFV7KDL.mjs} +618 -306
- package/dist/client/{carousel-D-SLfX8r.mjs → carousel-B2jDtogf.mjs} +1 -1
- package/dist/client/{cart-CEgbgJhX.mjs → cart-D-jZ-vaY.mjs} +3 -3
- package/dist/client/{checkout-CXWrCRAA.mjs → checkout-Dza-LA7N.mjs} +3 -3
- package/dist/client/client.mjs +2497 -1216
- package/dist/client/{colorStyles-jZS6KfkP.mjs → colorStyles-CrgzoXsm.mjs} +1 -30
- package/dist/client/{courseRegistration-DVmLrRVz.mjs → courseRegistration-TYkNychb.mjs} +7 -7
- package/dist/client/{eventCalendar-DCuyPY_c.mjs → eventCalendar-BI_90SsT.mjs} +5 -5
- package/dist/client/{eventCombined-kP2CA2D4.mjs → eventCombined-mNrpryE9.mjs} +2 -2
- package/dist/client/{eventDetails-DU0LeF5e.mjs → eventDetails-D4GVlCIY.mjs} +3 -3
- package/dist/client/{eventListing-CcHF87BI.mjs → eventListing-YhKN018y.mjs} +2 -2
- package/dist/client/{eventRegistration-DJnR0yFH.mjs → eventRegistration-CdHGtilr.mjs} +7 -7
- package/dist/client/foregroundContract-xICPq59x.mjs +31 -0
- package/dist/client/{form-CH1lCusH.mjs → form-AcAL45rA.mjs} +2 -2
- package/dist/client/{headerSection-CBPFZoku.mjs → headerSection-uEC52ueD.mjs} +3 -3
- package/dist/client/hooks.mjs +1249 -841
- package/dist/client/{locationMap-Cx1hBg5n.mjs → locationMap-_wJDSUYe.mjs} +3 -3
- package/dist/client/{media-DHtSxS5V.mjs → media-BK0O3b-U.mjs} +3 -2
- package/dist/client/{newsletterForm-1ZL_ti9u.mjs → newsletterForm-DrArsb2B.mjs} +2 -2
- package/dist/client/{pricing-BIbzmV0G.mjs → pricing-BSYVghwo.mjs} +1 -1
- package/dist/client/{productDetail-BTh5gHBV.mjs → productDetail-Dyk90sMs.mjs} +3 -3
- package/dist/client/{productList-Cc7OMrqN.mjs → productList-BCKThwAI.mjs} +3 -3
- package/dist/client/{propsDecoder-oR-M-ISN.mjs → propsDecoder-CkXxkdSR.mjs} +96 -33
- package/dist/client/rendering/client.mjs +1278 -523
- package/dist/client/rendering/islands.mjs +19 -19
- package/dist/client/rendering.mjs +2308 -1028
- package/dist/client/{shop-CQ_YbCnn.mjs → shop-DeltVH10.mjs} +6 -6
- package/dist/client/{shop-commerce-BM-AoD3M.mjs → shop-commerce-BD9Jsm2Z.mjs} +6 -6
- package/dist/client/{shop-commerce-store-DFMQhU5p.mjs → shop-commerce-store-CmXD6FDS.mjs} +1 -1
- package/dist/client/{shopShared-D0SKO2Cu.mjs → shopShared-B8v-lH_F.mjs} +2 -2
- package/dist/client/{useDiscountCodeUi-CrG4_ARt.mjs → useDiscountCodeUi-DbWJN8ld.mjs} +1 -1
- package/dist/client/{useEventFilters-CxK8Fekl.mjs → useEventFilters-EJIMUnqT.mjs} +46 -69
- package/dist/client/{usePolling-jcVryNgZ.mjs → usePolling-Cmh14fc7.mjs} +2 -2
- package/dist/preview-next/before-render.mjs +213 -0
- package/dist/preview-next/client/runtime.mjs +4 -4
- package/dist/preview-next/middleware.mjs +213 -0
- package/dist/{previewAuthStore-BPcJPzdz.mjs → previewAuthStore-CTO7CRPk.mjs} +213 -0
- package/dist/{sdk-runtime-C39Rsk-x.mjs → sdk-runtime-Dou0GAav.mjs} +2 -2
- package/dist/{separator-BoMSQnsP.mjs → separator-CI5wZNXT.mjs} +1 -1
- package/dist/server/components.mjs +2370 -1132
- package/dist/server/config-validation.mjs +1256 -842
- package/dist/server/config.mjs +1256 -843
- package/dist/server/data.mjs +1249 -841
- package/dist/server/date-time.mjs +386 -0
- package/dist/server/index.mjs +214 -1
- package/dist/server/navigation.mjs +9 -3
- package/dist/server/next.mjs +3421 -1949
- package/dist/server/page-converter.mjs +1236 -659
- package/dist/server/prebuild.mjs +1 -1
- package/dist/server/rendering/server.mjs +2074 -1060
- package/dist/server/rendering.mjs +2370 -1132
- package/dist/server/routing.mjs +1543 -1062
- package/dist/server/server.mjs +1464 -843
- package/dist/server/theme-bridge.mjs +1581 -474
- package/dist/server/theme.mjs +614 -305
- package/dist/styles/index.css +12 -1
- package/package.json +7 -1
- package/dist/_dts/theme-core/src/buttons/presets/types.d.ts +0 -88
- package/dist/_dts/theme-core/src/buttons/utils/contrast.d.ts +0 -38
- package/dist/_dts/theme-core/src/palette/themePaletteCompatibility.d.ts +0 -57
|
@@ -1,5 +1,111 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { t as parseColorTokenParts } from "./colorTokenParts-CMugwvX_.mjs";
|
|
2
|
+
import { $ as themeColorTokenSchema, Q as parseThemeColorToken } from "./propsDecoder-CkXxkdSR.mjs";
|
|
2
3
|
import { z as z$1 } from "zod";
|
|
4
|
+
//#region ../theme-core/src/buttons/effectClassification.ts
|
|
5
|
+
/**
|
|
6
|
+
* Exhaustive live policy for every registered effect id.
|
|
7
|
+
*
|
|
8
|
+
* The resolver consumes the transition payload directly, so adding an effect
|
|
9
|
+
* cannot update classification without also defining its runtime behavior.
|
|
10
|
+
*/
|
|
11
|
+
const BUTTON_EFFECT_POLICIES = {
|
|
12
|
+
"darken-background": {
|
|
13
|
+
classification: "colour-transition",
|
|
14
|
+
transition: {
|
|
15
|
+
kind: "adjust-shade",
|
|
16
|
+
direction: "darker"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
"lighten-background": {
|
|
20
|
+
classification: "colour-transition",
|
|
21
|
+
transition: {
|
|
22
|
+
kind: "adjust-shade",
|
|
23
|
+
direction: "lighter"
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"background-on-hover": {
|
|
27
|
+
classification: "colour-transition",
|
|
28
|
+
transition: { kind: "replace-background" }
|
|
29
|
+
},
|
|
30
|
+
"background-on-hover-alpha": {
|
|
31
|
+
classification: "unsupported-colour",
|
|
32
|
+
reason: "alpha_requires_surface"
|
|
33
|
+
},
|
|
34
|
+
"fade-background": {
|
|
35
|
+
classification: "unsupported-colour",
|
|
36
|
+
reason: "changes_element_opacity"
|
|
37
|
+
},
|
|
38
|
+
"opacity-reduce": {
|
|
39
|
+
classification: "unsupported-colour",
|
|
40
|
+
reason: "changes_element_opacity"
|
|
41
|
+
},
|
|
42
|
+
"gradient-text": {
|
|
43
|
+
classification: "unsupported-colour",
|
|
44
|
+
reason: "changes_foreground"
|
|
45
|
+
},
|
|
46
|
+
"text-color-change": {
|
|
47
|
+
classification: "unsupported-colour",
|
|
48
|
+
reason: "changes_foreground"
|
|
49
|
+
},
|
|
50
|
+
"border-color-change": {
|
|
51
|
+
classification: "unsupported-colour",
|
|
52
|
+
reason: "changes_border"
|
|
53
|
+
},
|
|
54
|
+
"aurora-glow": {
|
|
55
|
+
classification: "unsupported-background-overlay",
|
|
56
|
+
reason: "unresolved_background_overlay"
|
|
57
|
+
},
|
|
58
|
+
"cosmic-stardust": {
|
|
59
|
+
classification: "unsupported-background-overlay",
|
|
60
|
+
reason: "unresolved_background_overlay"
|
|
61
|
+
},
|
|
62
|
+
"gradient-border-fill": {
|
|
63
|
+
classification: "unsupported-background-overlay",
|
|
64
|
+
reason: "unresolved_background_overlay"
|
|
65
|
+
},
|
|
66
|
+
"animated-gradient-border-fill": {
|
|
67
|
+
classification: "unsupported-background-overlay",
|
|
68
|
+
reason: "unresolved_background_overlay"
|
|
69
|
+
},
|
|
70
|
+
"nav-underline": {
|
|
71
|
+
classification: "not-button",
|
|
72
|
+
reason: "not_button_effect"
|
|
73
|
+
},
|
|
74
|
+
"nav-frosted-base": {
|
|
75
|
+
classification: "not-button",
|
|
76
|
+
reason: "not_button_effect"
|
|
77
|
+
},
|
|
78
|
+
"nav-frosted-hover": {
|
|
79
|
+
classification: "not-button",
|
|
80
|
+
reason: "not_button_effect"
|
|
81
|
+
},
|
|
82
|
+
"nav-frosted-active": {
|
|
83
|
+
classification: "not-button",
|
|
84
|
+
reason: "not_button_effect"
|
|
85
|
+
},
|
|
86
|
+
"animated-gradient": { classification: "non-colour" },
|
|
87
|
+
"border-glow": { classification: "non-colour" },
|
|
88
|
+
"drop-shadow": { classification: "non-colour" },
|
|
89
|
+
"inner-shadow": { classification: "non-colour" },
|
|
90
|
+
"neumorphic-shadow": { classification: "non-colour" },
|
|
91
|
+
"outer-glow": { classification: "non-colour" },
|
|
92
|
+
"retro-3d-shadow": { classification: "non-colour" },
|
|
93
|
+
"scale-up": { classification: "non-colour" },
|
|
94
|
+
"scale-down": { classification: "non-colour" },
|
|
95
|
+
lift: { classification: "non-colour" },
|
|
96
|
+
"press-down": { classification: "non-colour" },
|
|
97
|
+
pop: { classification: "non-colour" },
|
|
98
|
+
"border-bottom-grow": { classification: "non-colour" },
|
|
99
|
+
"sketchy-border": { classification: "non-colour" },
|
|
100
|
+
"pulse-animation": { classification: "non-colour" }
|
|
101
|
+
};
|
|
102
|
+
function getButtonEffectPolicy(effectId) {
|
|
103
|
+
return Object.prototype.hasOwnProperty.call(BUTTON_EFFECT_POLICIES, effectId) ? BUTTON_EFFECT_POLICIES[effectId] : null;
|
|
104
|
+
}
|
|
105
|
+
function classifyButtonEffectId(effectId) {
|
|
106
|
+
return getButtonEffectPolicy(effectId)?.classification ?? "unknown";
|
|
107
|
+
}
|
|
108
|
+
//#endregion
|
|
3
109
|
//#region ../theme-core/src/buttons/types.ts
|
|
4
110
|
/**
|
|
5
111
|
* Standard semantic variant roles a theme exposes.
|
|
@@ -16,6 +122,20 @@ const VARIANT_ROLES = [
|
|
|
16
122
|
"tertiary",
|
|
17
123
|
"accent"
|
|
18
124
|
];
|
|
125
|
+
function parseOpaqueButtonColourToken(value) {
|
|
126
|
+
const token = parseThemeColorToken(value);
|
|
127
|
+
if (token === null) return null;
|
|
128
|
+
const parts = parseColorTokenParts(token);
|
|
129
|
+
return parts.kind === "token" && parts.opacityPercent === null ? token : null;
|
|
130
|
+
}
|
|
131
|
+
function unsafeAsOpaqueButtonColourToken(value) {
|
|
132
|
+
return value;
|
|
133
|
+
}
|
|
134
|
+
const opaqueButtonColourTokenSchema = themeColorTokenSchema.refine((value) => parseOpaqueButtonColourToken(value) !== null, "Button colour tokens must be opaque").transform((value) => {
|
|
135
|
+
const token = parseOpaqueButtonColourToken(value);
|
|
136
|
+
if (token === null) throw new Error("Invariant: opaque button token passed its schema");
|
|
137
|
+
return token;
|
|
138
|
+
});
|
|
19
139
|
const cornerStyleSchema = z$1.enum([
|
|
20
140
|
"square",
|
|
21
141
|
"rounded",
|
|
@@ -117,7 +237,7 @@ const buttonSizesSchema = z$1.object({
|
|
|
117
237
|
lg,
|
|
118
238
|
xl: xl ?? lg
|
|
119
239
|
}));
|
|
120
|
-
const
|
|
240
|
+
const canonicalButtonGlobalSettingsSchema = z$1.object({
|
|
121
241
|
cornerStyle: cornerStyleSchema,
|
|
122
242
|
cornerRadius: z$1.number().min(0).max(24).optional(),
|
|
123
243
|
/**
|
|
@@ -148,11 +268,12 @@ const buttonGlobalSettingsSchema = z$1.object({
|
|
|
148
268
|
paddingPreset: buttonPaddingPresetSchema.optional(),
|
|
149
269
|
hoverTransform: hoverTransformSchema,
|
|
150
270
|
hoverColor: hoverColorSchema,
|
|
151
|
-
hoverColorToken:
|
|
271
|
+
hoverColorToken: opaqueButtonColourTokenSchema.optional(),
|
|
152
272
|
gradientStyle: gradientStyleSchema.optional(),
|
|
153
273
|
gradientAngle: z$1.number().min(0).max(360).optional(),
|
|
154
274
|
gradientSharpness: gradientSharpnessSchema.optional()
|
|
155
275
|
});
|
|
276
|
+
const buttonGlobalSettingsSchema = z$1.preprocess(normalizeLegacyButtonGlobalInput, canonicalButtonGlobalSettingsSchema);
|
|
156
277
|
const gradientDirectionSchema = z$1.enum([
|
|
157
278
|
"to-r",
|
|
158
279
|
"to-l",
|
|
@@ -166,27 +287,33 @@ const gradientDirectionSchema = z$1.enum([
|
|
|
166
287
|
const buttonBackgroundSchema = z$1.discriminatedUnion("type", [
|
|
167
288
|
z$1.object({
|
|
168
289
|
type: z$1.literal("solid"),
|
|
169
|
-
colorToken:
|
|
290
|
+
colorToken: opaqueButtonColourTokenSchema
|
|
170
291
|
}),
|
|
171
292
|
z$1.object({
|
|
172
293
|
type: z$1.literal("gradient"),
|
|
173
|
-
stops: z$1.array(
|
|
174
|
-
|
|
294
|
+
stops: z$1.array(opaqueButtonColourTokenSchema).min(2).transform((stops) => {
|
|
295
|
+
const [first, second, ...rest] = stops;
|
|
296
|
+
if (first === void 0 || second === void 0) throw new Error("Invariant: gradient stops passed the minimum length schema");
|
|
297
|
+
return [
|
|
298
|
+
first,
|
|
299
|
+
second,
|
|
300
|
+
...rest
|
|
301
|
+
];
|
|
302
|
+
}),
|
|
303
|
+
direction: gradientDirectionSchema,
|
|
304
|
+
foregroundToken: opaqueButtonColourTokenSchema
|
|
175
305
|
}),
|
|
176
|
-
z$1.object({
|
|
306
|
+
z$1.object({
|
|
307
|
+
type: z$1.literal("surface"),
|
|
308
|
+
role: z$1.literal("link")
|
|
309
|
+
})
|
|
177
310
|
]);
|
|
178
311
|
const effectApplicationSchema = z$1.object({
|
|
179
312
|
effectId: z$1.string(),
|
|
180
|
-
options: z$1.record(z$1.string(), z$1.
|
|
181
|
-
});
|
|
182
|
-
const buttonBorderSchema = z$1.object({
|
|
183
|
-
widthClass: z$1.string(),
|
|
184
|
-
colorToken: themeColorTokenSchema
|
|
185
|
-
});
|
|
186
|
-
const buttonVariantAffordanceSchema = z$1.object({
|
|
187
|
-
iconId: z$1.string().min(1),
|
|
188
|
-
colorToken: themeColorTokenSchema.optional()
|
|
313
|
+
options: z$1.record(z$1.string(), z$1.json()).optional()
|
|
189
314
|
});
|
|
315
|
+
const buttonBorderSchema = z$1.object({ widthClass: z$1.string() });
|
|
316
|
+
const buttonVariantAffordanceSchema = z$1.object({ iconId: z$1.string().min(1) });
|
|
190
317
|
const variantShadowSchema = z$1.object({
|
|
191
318
|
elevation: z$1.enum([
|
|
192
319
|
"none",
|
|
@@ -227,27 +354,170 @@ const variantSizeOverridesSchema = z$1.object({
|
|
|
227
354
|
* default (e.g. link-style variants declaring zero horizontal padding at
|
|
228
355
|
* every size).
|
|
229
356
|
*/
|
|
230
|
-
const
|
|
357
|
+
const canonicalButtonVariantSchema = z$1.object({
|
|
231
358
|
id: z$1.string(),
|
|
232
359
|
name: z$1.string().min(1).max(20),
|
|
233
360
|
enabled: z$1.boolean(),
|
|
234
361
|
priority: prioritySchema,
|
|
235
362
|
background: buttonBackgroundSchema,
|
|
236
|
-
textColorToken: themeColorTokenSchema,
|
|
237
363
|
/** Tailwind radius token (e.g. `'rounded-md'`). Omit to inherit from `global.cornerStyle`. */
|
|
238
364
|
borderRadius: z$1.string().optional(),
|
|
239
365
|
shadow: variantShadowSchema.optional(),
|
|
240
366
|
border: buttonBorderSchema.optional(),
|
|
241
|
-
hoverBackgroundToken:
|
|
367
|
+
hoverBackgroundToken: opaqueButtonColourTokenSchema.optional(),
|
|
242
368
|
effects: variantEffectsSchema.optional(),
|
|
243
369
|
sizes: variantSizeOverridesSchema.optional(),
|
|
244
370
|
affordance: buttonVariantAffordanceSchema.optional()
|
|
245
371
|
});
|
|
372
|
+
/**
|
|
373
|
+
* Temporary persisted-theme admission boundary for issue #1206.
|
|
374
|
+
*
|
|
375
|
+
* Production inventory on 2026-07-22 found 22 rows using the old independent
|
|
376
|
+
* `textColorToken`/border colour shape. New source and all downstream code use
|
|
377
|
+
* only the canonical relationship. Delete this preprocessor after the reviewed
|
|
378
|
+
* production rewrite reports zero legacy rows.
|
|
379
|
+
*/
|
|
380
|
+
const buttonVariantSchema = z$1.preprocess(normalizeLegacyButtonVariantInput, canonicalButtonVariantSchema);
|
|
246
381
|
const buttonSystemSchema = z$1.object({
|
|
247
382
|
global: buttonGlobalSettingsSchema,
|
|
248
383
|
variants: z$1.array(buttonVariantSchema).min(1).max(6),
|
|
249
384
|
sizes: buttonSizesSchema.optional()
|
|
250
385
|
});
|
|
386
|
+
function normalizeLegacyButtonVariantInput(input) {
|
|
387
|
+
if (!isUnknownRecord(input)) return input;
|
|
388
|
+
const background = input.background;
|
|
389
|
+
if (!isUnknownRecord(background)) return input;
|
|
390
|
+
if (!(background.type === "transparent" || Object.prototype.hasOwnProperty.call(input, "textColorToken") || isUnknownRecord(input.border) && Object.prototype.hasOwnProperty.call(input.border, "colorToken") || hasLegacyButtonEffects(input.effects) || hasLegacyAlphaToken(input, background))) return input;
|
|
391
|
+
const { textColorToken, ...withoutLegacyText } = input;
|
|
392
|
+
const normalizedBorder = isUnknownRecord(input.border) && typeof input.border.widthClass === "string" ? { widthClass: input.border.widthClass } : input.border;
|
|
393
|
+
const normalizedAffordance = isUnknownRecord(input.affordance) && typeof input.affordance.iconId === "string" ? { iconId: input.affordance.iconId } : input.affordance;
|
|
394
|
+
const normalizedEffects = normalizeLegacyButtonEffects(input.effects, background.type);
|
|
395
|
+
const hoverBackgroundToken = stripLegacyTokenAlpha(input.hoverBackgroundToken);
|
|
396
|
+
if (background.type === "transparent") return {
|
|
397
|
+
...withoutLegacyText,
|
|
398
|
+
background: {
|
|
399
|
+
type: "surface",
|
|
400
|
+
role: "link"
|
|
401
|
+
},
|
|
402
|
+
border: normalizedBorder,
|
|
403
|
+
affordance: normalizedAffordance,
|
|
404
|
+
effects: normalizedEffects,
|
|
405
|
+
hoverBackgroundToken
|
|
406
|
+
};
|
|
407
|
+
if (background.type === "gradient") {
|
|
408
|
+
const stops = Array.isArray(background.stops) ? background.stops.map(stripLegacyTokenAlpha) : background.stops;
|
|
409
|
+
return {
|
|
410
|
+
...withoutLegacyText,
|
|
411
|
+
background: {
|
|
412
|
+
...background,
|
|
413
|
+
stops,
|
|
414
|
+
foregroundToken: stripLegacyTokenAlpha(background.foregroundToken ?? textColorToken)
|
|
415
|
+
},
|
|
416
|
+
border: normalizedBorder,
|
|
417
|
+
affordance: normalizedAffordance,
|
|
418
|
+
effects: normalizedEffects,
|
|
419
|
+
hoverBackgroundToken
|
|
420
|
+
};
|
|
421
|
+
}
|
|
422
|
+
return {
|
|
423
|
+
...withoutLegacyText,
|
|
424
|
+
background: background.type === "solid" ? {
|
|
425
|
+
...background,
|
|
426
|
+
colorToken: stripLegacyTokenAlpha(background.colorToken)
|
|
427
|
+
} : background,
|
|
428
|
+
border: normalizedBorder,
|
|
429
|
+
affordance: normalizedAffordance,
|
|
430
|
+
effects: normalizedEffects,
|
|
431
|
+
hoverBackgroundToken
|
|
432
|
+
};
|
|
433
|
+
}
|
|
434
|
+
function normalizeLegacyButtonGlobalInput(input) {
|
|
435
|
+
if (!isUnknownRecord(input)) return input;
|
|
436
|
+
const hoverColorToken = stripLegacyTokenAlpha(input.hoverColorToken);
|
|
437
|
+
return hoverColorToken === input.hoverColorToken ? input : {
|
|
438
|
+
...input,
|
|
439
|
+
hoverColorToken
|
|
440
|
+
};
|
|
441
|
+
}
|
|
442
|
+
function hasLegacyAlphaToken(input, background) {
|
|
443
|
+
const stops = isUnknownArray(background.stops) ? background.stops : [];
|
|
444
|
+
return [
|
|
445
|
+
input.hoverBackgroundToken,
|
|
446
|
+
background.colorToken,
|
|
447
|
+
background.foregroundToken,
|
|
448
|
+
...stops
|
|
449
|
+
].some((token) => stripLegacyTokenAlpha(token) !== token);
|
|
450
|
+
}
|
|
451
|
+
function stripLegacyTokenAlpha(value) {
|
|
452
|
+
if (typeof value !== "string") return value;
|
|
453
|
+
const slashIndex = value.indexOf("/");
|
|
454
|
+
return slashIndex < 0 ? value : value.slice(0, slashIndex);
|
|
455
|
+
}
|
|
456
|
+
function hasLegacyButtonEffects(input) {
|
|
457
|
+
if (!isUnknownRecord(input)) return false;
|
|
458
|
+
return [
|
|
459
|
+
"base",
|
|
460
|
+
"hover",
|
|
461
|
+
"active",
|
|
462
|
+
"focus"
|
|
463
|
+
].some((state) => {
|
|
464
|
+
const effects = input[state];
|
|
465
|
+
return Array.isArray(effects) && effects.some((effect) => {
|
|
466
|
+
if (!isUnknownRecord(effect) || typeof effect.effectId !== "string") return true;
|
|
467
|
+
const classification = classifyButtonEffectId(effect.effectId);
|
|
468
|
+
if (classification !== "colour-transition" && classification !== "non-colour") return true;
|
|
469
|
+
return effect.effectId === "background-on-hover" && isUnknownRecord(effect.options) && stripLegacyTokenAlpha(effect.options.colorToken) !== effect.options.colorToken;
|
|
470
|
+
});
|
|
471
|
+
});
|
|
472
|
+
}
|
|
473
|
+
function normalizeLegacyButtonEffects(input, backgroundType) {
|
|
474
|
+
if (!isUnknownRecord(input)) return input;
|
|
475
|
+
const normalized = {};
|
|
476
|
+
for (const state of [
|
|
477
|
+
"base",
|
|
478
|
+
"hover",
|
|
479
|
+
"active",
|
|
480
|
+
"focus"
|
|
481
|
+
]) {
|
|
482
|
+
const effects = input[state];
|
|
483
|
+
if (!Array.isArray(effects)) continue;
|
|
484
|
+
const safeEffects = effects.flatMap((effect) => {
|
|
485
|
+
if (!isUnknownRecord(effect) || typeof effect.effectId !== "string") return [];
|
|
486
|
+
const classification = classifyButtonEffectId(effect.effectId);
|
|
487
|
+
if (classification === "non-colour") return [effect];
|
|
488
|
+
if (classification !== "colour-transition") return [];
|
|
489
|
+
if (effect.effectId === "background-on-hover") {
|
|
490
|
+
const options = isUnknownRecord(effect.options) ? effect.options : null;
|
|
491
|
+
const colorToken = options === null ? null : parseOpaqueButtonColourToken(stripLegacyTokenAlpha(options.colorToken));
|
|
492
|
+
return colorToken === null ? [] : [{
|
|
493
|
+
...effect,
|
|
494
|
+
options: {
|
|
495
|
+
...options,
|
|
496
|
+
colorToken
|
|
497
|
+
}
|
|
498
|
+
}];
|
|
499
|
+
}
|
|
500
|
+
if (backgroundType !== "solid") return [];
|
|
501
|
+
const rawAmount = isUnknownRecord(effect.options) ? effect.options.amount : void 0;
|
|
502
|
+
const amount = typeof rawAmount === "number" && rawAmount > 0 ? Math.max(100, Math.round(rawAmount / 100) * 100) : 100;
|
|
503
|
+
return [{
|
|
504
|
+
...effect,
|
|
505
|
+
options: {
|
|
506
|
+
...isUnknownRecord(effect.options) ? effect.options : {},
|
|
507
|
+
amount
|
|
508
|
+
}
|
|
509
|
+
}];
|
|
510
|
+
});
|
|
511
|
+
if (safeEffects.length > 0) normalized[state] = safeEffects;
|
|
512
|
+
}
|
|
513
|
+
return Object.keys(normalized).length === 0 ? void 0 : normalized;
|
|
514
|
+
}
|
|
515
|
+
function isUnknownRecord(value) {
|
|
516
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
517
|
+
}
|
|
518
|
+
function isUnknownArray(value) {
|
|
519
|
+
return Array.isArray(value);
|
|
520
|
+
}
|
|
251
521
|
//#endregion
|
|
252
522
|
//#region ../theme-core/src/buttons/classNames.ts
|
|
253
523
|
function themeButtonVariantClassNames(variant) {
|
|
@@ -264,6 +534,29 @@ function themeButtonClassName(spec) {
|
|
|
264
534
|
spec.extraClassName
|
|
265
535
|
].filter(Boolean).join(" ");
|
|
266
536
|
}
|
|
537
|
+
//#endregion
|
|
538
|
+
//#region ../theme-core/src/palette/utils/colorConversion.ts
|
|
539
|
+
function hexToRgb(hex) {
|
|
540
|
+
const h = hex.replace(/^#/, "");
|
|
541
|
+
const m = h.length === 3 ? h.split("").map((c) => c + c).join("") : h;
|
|
542
|
+
if (m.length !== 6) throw new Error("Bad hex");
|
|
543
|
+
const int = parseInt(m, 16);
|
|
544
|
+
return {
|
|
545
|
+
r: int >> 16 & 255,
|
|
546
|
+
g: int >> 8 & 255,
|
|
547
|
+
b: int & 255
|
|
548
|
+
};
|
|
549
|
+
}
|
|
550
|
+
function srgbToLinear(u) {
|
|
551
|
+
const x = u / 255;
|
|
552
|
+
return x <= .04045 ? x / 12.92 : Math.pow((x + .055) / 1.055, 2.4);
|
|
553
|
+
}
|
|
554
|
+
//#endregion
|
|
555
|
+
//#region ../theme-core/src/palette/utils/contrast.ts
|
|
556
|
+
function relativeLuminance(r, g, b) {
|
|
557
|
+
const R = srgbToLinear(r), G = srgbToLinear(g), B = srgbToLinear(b);
|
|
558
|
+
return .2126 * R + .7152 * G + .0722 * B;
|
|
559
|
+
}
|
|
267
560
|
buttonSizeNameSchema.options;
|
|
268
561
|
//#endregion
|
|
269
562
|
//#region ../theme-core/src/site-styles/styleTags.ts
|
|
@@ -323,7 +616,7 @@ function defineButtonPersonality(input) {
|
|
|
323
616
|
name: input.name,
|
|
324
617
|
description: input.description,
|
|
325
618
|
tags: input.tags,
|
|
326
|
-
buttonSystem: input.buttonSystem
|
|
619
|
+
buttonSystem: buttonSystemSchema.parse(input.buttonSystem)
|
|
327
620
|
};
|
|
328
621
|
}
|
|
329
622
|
//#endregion
|
|
@@ -376,19 +669,15 @@ const brushedWash = defineButtonPersonality({
|
|
|
376
669
|
background: {
|
|
377
670
|
type: "gradient",
|
|
378
671
|
stops: ["primary", "accent"],
|
|
379
|
-
direction: "to-r"
|
|
672
|
+
direction: "to-r",
|
|
673
|
+
foregroundToken: "primaryForeground"
|
|
380
674
|
},
|
|
381
|
-
textColorToken: "primaryForeground",
|
|
382
675
|
borderRadius: "rounded-lg",
|
|
383
676
|
shadow: {
|
|
384
677
|
elevation: "low",
|
|
385
678
|
softness: "soft",
|
|
386
679
|
position: "bottom"
|
|
387
|
-
}
|
|
388
|
-
effects: { hover: [{
|
|
389
|
-
effectId: "opacity-reduce",
|
|
390
|
-
options: { reduction: -15 }
|
|
391
|
-
}] }
|
|
680
|
+
}
|
|
392
681
|
},
|
|
393
682
|
{
|
|
394
683
|
id: "secondary",
|
|
@@ -398,32 +687,27 @@ const brushedWash = defineButtonPersonality({
|
|
|
398
687
|
background: {
|
|
399
688
|
type: "gradient",
|
|
400
689
|
stops: ["secondary", "accent"],
|
|
401
|
-
direction: "to-br"
|
|
690
|
+
direction: "to-br",
|
|
691
|
+
foregroundToken: "primaryForeground"
|
|
402
692
|
},
|
|
403
|
-
textColorToken: "primaryForeground",
|
|
404
693
|
borderRadius: "rounded-lg",
|
|
405
694
|
shadow: {
|
|
406
695
|
elevation: "low",
|
|
407
696
|
softness: "soft",
|
|
408
697
|
position: "bottom"
|
|
409
|
-
}
|
|
410
|
-
effects: { hover: [{
|
|
411
|
-
effectId: "opacity-reduce",
|
|
412
|
-
options: { reduction: -15 }
|
|
413
|
-
}] }
|
|
698
|
+
}
|
|
414
699
|
},
|
|
415
700
|
{
|
|
416
701
|
id: "outline",
|
|
417
702
|
name: "Outline",
|
|
418
703
|
enabled: true,
|
|
419
704
|
priority: 3,
|
|
420
|
-
background: {
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
border: {
|
|
424
|
-
widthClass: "border",
|
|
425
|
-
colorToken: "primary"
|
|
705
|
+
background: {
|
|
706
|
+
type: "surface",
|
|
707
|
+
role: "link"
|
|
426
708
|
},
|
|
709
|
+
borderRadius: "rounded-lg",
|
|
710
|
+
border: { widthClass: "border" },
|
|
427
711
|
effects: { hover: [{
|
|
428
712
|
effectId: "background-on-hover",
|
|
429
713
|
options: { colorToken: "surface" }
|
|
@@ -434,8 +718,10 @@ const brushedWash = defineButtonPersonality({
|
|
|
434
718
|
name: "Ghost",
|
|
435
719
|
enabled: true,
|
|
436
720
|
priority: 3,
|
|
437
|
-
background: {
|
|
438
|
-
|
|
721
|
+
background: {
|
|
722
|
+
type: "surface",
|
|
723
|
+
role: "link"
|
|
724
|
+
},
|
|
439
725
|
borderRadius: "rounded-lg",
|
|
440
726
|
effects: { hover: [{
|
|
441
727
|
effectId: "background-on-hover",
|
|
@@ -481,7 +767,6 @@ const confidentChip = defineButtonPersonality({
|
|
|
481
767
|
type: "solid",
|
|
482
768
|
colorToken: "primary"
|
|
483
769
|
},
|
|
484
|
-
textColorToken: "primaryForeground",
|
|
485
770
|
borderRadius: "rounded-md",
|
|
486
771
|
shadow: {
|
|
487
772
|
elevation: "medium",
|
|
@@ -491,7 +776,7 @@ const confidentChip = defineButtonPersonality({
|
|
|
491
776
|
effects: {
|
|
492
777
|
hover: [{
|
|
493
778
|
effectId: "darken-background",
|
|
494
|
-
options: { amount:
|
|
779
|
+
options: { amount: 100 }
|
|
495
780
|
}],
|
|
496
781
|
active: [{
|
|
497
782
|
effectId: "scale-down",
|
|
@@ -508,12 +793,8 @@ const confidentChip = defineButtonPersonality({
|
|
|
508
793
|
type: "solid",
|
|
509
794
|
colorToken: "surface"
|
|
510
795
|
},
|
|
511
|
-
textColorToken: "text",
|
|
512
796
|
borderRadius: "rounded-md",
|
|
513
|
-
border: {
|
|
514
|
-
widthClass: "border",
|
|
515
|
-
colorToken: "border"
|
|
516
|
-
},
|
|
797
|
+
border: { widthClass: "border" },
|
|
517
798
|
effects: { hover: [{
|
|
518
799
|
effectId: "background-on-hover",
|
|
519
800
|
options: { colorToken: "background" }
|
|
@@ -524,13 +805,12 @@ const confidentChip = defineButtonPersonality({
|
|
|
524
805
|
name: "Outline",
|
|
525
806
|
enabled: true,
|
|
526
807
|
priority: 3,
|
|
527
|
-
background: {
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
border: {
|
|
531
|
-
widthClass: "border",
|
|
532
|
-
colorToken: "primary"
|
|
808
|
+
background: {
|
|
809
|
+
type: "surface",
|
|
810
|
+
role: "link"
|
|
533
811
|
},
|
|
812
|
+
borderRadius: "rounded-md",
|
|
813
|
+
border: { widthClass: "border" },
|
|
534
814
|
effects: { hover: [{
|
|
535
815
|
effectId: "background-on-hover",
|
|
536
816
|
options: { colorToken: "surface" }
|
|
@@ -541,8 +821,10 @@ const confidentChip = defineButtonPersonality({
|
|
|
541
821
|
name: "Ghost",
|
|
542
822
|
enabled: true,
|
|
543
823
|
priority: 3,
|
|
544
|
-
background: {
|
|
545
|
-
|
|
824
|
+
background: {
|
|
825
|
+
type: "surface",
|
|
826
|
+
role: "link"
|
|
827
|
+
},
|
|
546
828
|
borderRadius: "rounded-md",
|
|
547
829
|
effects: { hover: [{
|
|
548
830
|
effectId: "background-on-hover",
|
|
@@ -605,7 +887,6 @@ const earthPill = defineButtonPersonality({
|
|
|
605
887
|
type: "solid",
|
|
606
888
|
colorToken: "primary"
|
|
607
889
|
},
|
|
608
|
-
textColorToken: "primaryForeground",
|
|
609
890
|
borderRadius: "rounded-full",
|
|
610
891
|
shadow: {
|
|
611
892
|
elevation: "low",
|
|
@@ -631,13 +912,12 @@ const earthPill = defineButtonPersonality({
|
|
|
631
912
|
name: "Secondary",
|
|
632
913
|
enabled: true,
|
|
633
914
|
priority: 2,
|
|
634
|
-
background: {
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
border: {
|
|
638
|
-
widthClass: "border",
|
|
639
|
-
colorToken: "primary"
|
|
915
|
+
background: {
|
|
916
|
+
type: "surface",
|
|
917
|
+
role: "link"
|
|
640
918
|
},
|
|
919
|
+
borderRadius: "rounded-full",
|
|
920
|
+
border: { widthClass: "border" },
|
|
641
921
|
effects: { hover: [{
|
|
642
922
|
effectId: "background-on-hover",
|
|
643
923
|
options: { colorToken: "muted" }
|
|
@@ -648,13 +928,12 @@ const earthPill = defineButtonPersonality({
|
|
|
648
928
|
name: "Outline",
|
|
649
929
|
enabled: true,
|
|
650
930
|
priority: 3,
|
|
651
|
-
background: {
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
border: {
|
|
655
|
-
widthClass: "border",
|
|
656
|
-
colorToken: "border"
|
|
931
|
+
background: {
|
|
932
|
+
type: "surface",
|
|
933
|
+
role: "link"
|
|
657
934
|
},
|
|
935
|
+
borderRadius: "rounded-full",
|
|
936
|
+
border: { widthClass: "border" },
|
|
658
937
|
effects: { hover: [{
|
|
659
938
|
effectId: "background-on-hover",
|
|
660
939
|
options: { colorToken: "surfaceAlt" }
|
|
@@ -665,8 +944,10 @@ const earthPill = defineButtonPersonality({
|
|
|
665
944
|
name: "Ghost",
|
|
666
945
|
enabled: true,
|
|
667
946
|
priority: 3,
|
|
668
|
-
background: {
|
|
669
|
-
|
|
947
|
+
background: {
|
|
948
|
+
type: "surface",
|
|
949
|
+
role: "link"
|
|
950
|
+
},
|
|
670
951
|
borderRadius: "rounded-full",
|
|
671
952
|
shadow: {
|
|
672
953
|
elevation: "none",
|
|
@@ -687,11 +968,7 @@ const earthPill = defineButtonPersonality({
|
|
|
687
968
|
padding: "0.625rem 0",
|
|
688
969
|
fontSize: "text-xl"
|
|
689
970
|
}
|
|
690
|
-
}
|
|
691
|
-
effects: { hover: [{
|
|
692
|
-
effectId: "opacity-reduce",
|
|
693
|
-
options: { reduction: 25 }
|
|
694
|
-
}] }
|
|
971
|
+
}
|
|
695
972
|
}
|
|
696
973
|
]
|
|
697
974
|
}
|
|
@@ -727,8 +1004,10 @@ const editorialLink = defineButtonPersonality({
|
|
|
727
1004
|
name: "Primary",
|
|
728
1005
|
enabled: true,
|
|
729
1006
|
priority: 1,
|
|
730
|
-
background: {
|
|
731
|
-
|
|
1007
|
+
background: {
|
|
1008
|
+
type: "surface",
|
|
1009
|
+
role: "link"
|
|
1010
|
+
},
|
|
732
1011
|
borderRadius: "rounded-none",
|
|
733
1012
|
sizes: {
|
|
734
1013
|
sm: { padding: "0.25rem 0" },
|
|
@@ -750,8 +1029,10 @@ const editorialLink = defineButtonPersonality({
|
|
|
750
1029
|
name: "Secondary",
|
|
751
1030
|
enabled: true,
|
|
752
1031
|
priority: 2,
|
|
753
|
-
background: {
|
|
754
|
-
|
|
1032
|
+
background: {
|
|
1033
|
+
type: "surface",
|
|
1034
|
+
role: "link"
|
|
1035
|
+
},
|
|
755
1036
|
borderRadius: "rounded-none",
|
|
756
1037
|
sizes: {
|
|
757
1038
|
sm: { padding: "0.25rem 0" },
|
|
@@ -773,8 +1054,10 @@ const editorialLink = defineButtonPersonality({
|
|
|
773
1054
|
name: "Outline",
|
|
774
1055
|
enabled: true,
|
|
775
1056
|
priority: 3,
|
|
776
|
-
background: {
|
|
777
|
-
|
|
1057
|
+
background: {
|
|
1058
|
+
type: "surface",
|
|
1059
|
+
role: "link"
|
|
1060
|
+
},
|
|
778
1061
|
borderRadius: "rounded-none",
|
|
779
1062
|
sizes: {
|
|
780
1063
|
sm: { padding: "0.25rem 0" },
|
|
@@ -796,19 +1079,17 @@ const editorialLink = defineButtonPersonality({
|
|
|
796
1079
|
name: "Ghost",
|
|
797
1080
|
enabled: true,
|
|
798
1081
|
priority: 3,
|
|
799
|
-
background: {
|
|
800
|
-
|
|
1082
|
+
background: {
|
|
1083
|
+
type: "surface",
|
|
1084
|
+
role: "link"
|
|
1085
|
+
},
|
|
801
1086
|
borderRadius: "rounded-none",
|
|
802
1087
|
sizes: {
|
|
803
1088
|
sm: { padding: "0.25rem 0" },
|
|
804
1089
|
md: { padding: "0.5rem 0" },
|
|
805
1090
|
lg: { padding: "0.625rem 0" },
|
|
806
1091
|
xl: { padding: "0.75rem 0" }
|
|
807
|
-
}
|
|
808
|
-
effects: { hover: [{
|
|
809
|
-
effectId: "opacity-reduce",
|
|
810
|
-
options: { reduction: -20 }
|
|
811
|
-
}] }
|
|
1092
|
+
}
|
|
812
1093
|
}
|
|
813
1094
|
]
|
|
814
1095
|
}
|
|
@@ -870,12 +1151,8 @@ const flatInk = defineButtonPersonality({
|
|
|
870
1151
|
type: "solid",
|
|
871
1152
|
colorToken: "primary"
|
|
872
1153
|
},
|
|
873
|
-
textColorToken: "primaryForeground",
|
|
874
1154
|
borderRadius: "rounded-lg",
|
|
875
|
-
affordance: {
|
|
876
|
-
iconId: "ArrowRight",
|
|
877
|
-
colorToken: "accent"
|
|
878
|
-
},
|
|
1155
|
+
affordance: { iconId: "ArrowRight" },
|
|
879
1156
|
effects: { hover: [{
|
|
880
1157
|
effectId: "lift",
|
|
881
1158
|
options: { translateY: "-2px" }
|
|
@@ -889,13 +1166,12 @@ const flatInk = defineButtonPersonality({
|
|
|
889
1166
|
name: "Secondary",
|
|
890
1167
|
enabled: true,
|
|
891
1168
|
priority: 2,
|
|
892
|
-
background: {
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
border: {
|
|
896
|
-
widthClass: "border",
|
|
897
|
-
colorToken: "border"
|
|
1169
|
+
background: {
|
|
1170
|
+
type: "surface",
|
|
1171
|
+
role: "link"
|
|
898
1172
|
},
|
|
1173
|
+
borderRadius: "rounded-lg",
|
|
1174
|
+
border: { widthClass: "border" },
|
|
899
1175
|
effects: { hover: [{
|
|
900
1176
|
effectId: "lift",
|
|
901
1177
|
options: { translateY: "-2px" }
|
|
@@ -913,12 +1189,8 @@ const flatInk = defineButtonPersonality({
|
|
|
913
1189
|
type: "solid",
|
|
914
1190
|
colorToken: "accent"
|
|
915
1191
|
},
|
|
916
|
-
textColorToken: "accentForeground",
|
|
917
1192
|
borderRadius: "rounded-lg",
|
|
918
|
-
affordance: {
|
|
919
|
-
iconId: "ArrowRight",
|
|
920
|
-
colorToken: "accentForeground"
|
|
921
|
-
},
|
|
1193
|
+
affordance: { iconId: "ArrowRight" },
|
|
922
1194
|
effects: { hover: [{
|
|
923
1195
|
effectId: "lift",
|
|
924
1196
|
options: { translateY: "-2px" }
|
|
@@ -981,7 +1253,6 @@ const inkStamp = defineButtonPersonality({
|
|
|
981
1253
|
type: "solid",
|
|
982
1254
|
colorToken: "primary"
|
|
983
1255
|
},
|
|
984
|
-
textColorToken: "primaryForeground",
|
|
985
1256
|
borderRadius: "rounded-md",
|
|
986
1257
|
effects: {
|
|
987
1258
|
hover: [{
|
|
@@ -1002,13 +1273,12 @@ const inkStamp = defineButtonPersonality({
|
|
|
1002
1273
|
name: "Secondary",
|
|
1003
1274
|
enabled: true,
|
|
1004
1275
|
priority: 2,
|
|
1005
|
-
background: {
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
border: {
|
|
1009
|
-
widthClass: "border-2",
|
|
1010
|
-
colorToken: "primary"
|
|
1276
|
+
background: {
|
|
1277
|
+
type: "surface",
|
|
1278
|
+
role: "link"
|
|
1011
1279
|
},
|
|
1280
|
+
borderRadius: "rounded-md",
|
|
1281
|
+
border: { widthClass: "border-2" },
|
|
1012
1282
|
effects: { hover: [{
|
|
1013
1283
|
effectId: "background-on-hover",
|
|
1014
1284
|
options: { colorToken: "surface" }
|
|
@@ -1019,13 +1289,12 @@ const inkStamp = defineButtonPersonality({
|
|
|
1019
1289
|
name: "Outline",
|
|
1020
1290
|
enabled: true,
|
|
1021
1291
|
priority: 3,
|
|
1022
|
-
background: {
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
border: {
|
|
1026
|
-
widthClass: "border-2",
|
|
1027
|
-
colorToken: "border"
|
|
1292
|
+
background: {
|
|
1293
|
+
type: "surface",
|
|
1294
|
+
role: "link"
|
|
1028
1295
|
},
|
|
1296
|
+
borderRadius: "rounded-md",
|
|
1297
|
+
border: { widthClass: "border-2" },
|
|
1029
1298
|
effects: { hover: [{
|
|
1030
1299
|
effectId: "background-on-hover",
|
|
1031
1300
|
options: { colorToken: "surface" }
|
|
@@ -1036,8 +1305,10 @@ const inkStamp = defineButtonPersonality({
|
|
|
1036
1305
|
name: "Ghost",
|
|
1037
1306
|
enabled: true,
|
|
1038
1307
|
priority: 3,
|
|
1039
|
-
background: {
|
|
1040
|
-
|
|
1308
|
+
background: {
|
|
1309
|
+
type: "surface",
|
|
1310
|
+
role: "link"
|
|
1311
|
+
},
|
|
1041
1312
|
borderRadius: "rounded-none",
|
|
1042
1313
|
sizes: {
|
|
1043
1314
|
sm: {
|
|
@@ -1130,7 +1401,6 @@ const joyStamp = defineButtonPersonality({
|
|
|
1130
1401
|
type: "solid",
|
|
1131
1402
|
colorToken: "primary"
|
|
1132
1403
|
},
|
|
1133
|
-
textColorToken: "primaryForeground",
|
|
1134
1404
|
borderRadius: "rounded-full",
|
|
1135
1405
|
shadow: {
|
|
1136
1406
|
elevation: "high",
|
|
@@ -1144,13 +1414,12 @@ const joyStamp = defineButtonPersonality({
|
|
|
1144
1414
|
name: "Secondary",
|
|
1145
1415
|
enabled: true,
|
|
1146
1416
|
priority: 2,
|
|
1147
|
-
background: {
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
border: {
|
|
1151
|
-
widthClass: "border-2",
|
|
1152
|
-
colorToken: "text"
|
|
1417
|
+
background: {
|
|
1418
|
+
type: "surface",
|
|
1419
|
+
role: "link"
|
|
1153
1420
|
},
|
|
1421
|
+
borderRadius: "rounded-full",
|
|
1422
|
+
border: { widthClass: "border-2" },
|
|
1154
1423
|
shadow: {
|
|
1155
1424
|
elevation: "high",
|
|
1156
1425
|
softness: "hard",
|
|
@@ -1215,12 +1484,8 @@ const ornateRitual = defineButtonPersonality({
|
|
|
1215
1484
|
type: "solid",
|
|
1216
1485
|
colorToken: "primary"
|
|
1217
1486
|
},
|
|
1218
|
-
textColorToken: "primaryForeground",
|
|
1219
1487
|
borderRadius: "rounded-md",
|
|
1220
|
-
border: {
|
|
1221
|
-
widthClass: "border",
|
|
1222
|
-
colorToken: "primary"
|
|
1223
|
-
},
|
|
1488
|
+
border: { widthClass: "border" },
|
|
1224
1489
|
effects: {
|
|
1225
1490
|
hover: [{
|
|
1226
1491
|
effectId: "background-on-hover",
|
|
@@ -1241,12 +1506,8 @@ const ornateRitual = defineButtonPersonality({
|
|
|
1241
1506
|
type: "solid",
|
|
1242
1507
|
colorToken: "secondary"
|
|
1243
1508
|
},
|
|
1244
|
-
textColorToken: "primaryForeground",
|
|
1245
1509
|
borderRadius: "rounded-md",
|
|
1246
|
-
border: {
|
|
1247
|
-
widthClass: "border",
|
|
1248
|
-
colorToken: "primary"
|
|
1249
|
-
},
|
|
1510
|
+
border: { widthClass: "border" },
|
|
1250
1511
|
effects: { hover: [{
|
|
1251
1512
|
effectId: "background-on-hover",
|
|
1252
1513
|
options: { colorToken: "surface" }
|
|
@@ -1257,13 +1518,12 @@ const ornateRitual = defineButtonPersonality({
|
|
|
1257
1518
|
name: "Outline",
|
|
1258
1519
|
enabled: true,
|
|
1259
1520
|
priority: 3,
|
|
1260
|
-
background: {
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
border: {
|
|
1264
|
-
widthClass: "border",
|
|
1265
|
-
colorToken: "primary"
|
|
1521
|
+
background: {
|
|
1522
|
+
type: "surface",
|
|
1523
|
+
role: "link"
|
|
1266
1524
|
},
|
|
1525
|
+
borderRadius: "rounded-md",
|
|
1526
|
+
border: { widthClass: "border" },
|
|
1267
1527
|
effects: { hover: [{
|
|
1268
1528
|
effectId: "background-on-hover",
|
|
1269
1529
|
options: { colorToken: "muted" }
|
|
@@ -1274,8 +1534,10 @@ const ornateRitual = defineButtonPersonality({
|
|
|
1274
1534
|
name: "Ghost",
|
|
1275
1535
|
enabled: true,
|
|
1276
1536
|
priority: 3,
|
|
1277
|
-
background: {
|
|
1278
|
-
|
|
1537
|
+
background: {
|
|
1538
|
+
type: "surface",
|
|
1539
|
+
role: "link"
|
|
1540
|
+
},
|
|
1279
1541
|
borderRadius: "rounded-none",
|
|
1280
1542
|
sizes: {
|
|
1281
1543
|
sm: {
|
|
@@ -1357,14 +1619,10 @@ const pebble = defineButtonPersonality({
|
|
|
1357
1619
|
type: "solid",
|
|
1358
1620
|
colorToken: "primary"
|
|
1359
1621
|
},
|
|
1360
|
-
textColorToken: "primaryForeground",
|
|
1361
1622
|
borderRadius: "rounded-full",
|
|
1362
1623
|
effects: { hover: [{
|
|
1363
|
-
effectId: "background
|
|
1364
|
-
options: {
|
|
1365
|
-
colorToken: "primary",
|
|
1366
|
-
opacity: 88
|
|
1367
|
-
}
|
|
1624
|
+
effectId: "darken-background",
|
|
1625
|
+
options: { amount: 100 }
|
|
1368
1626
|
}] }
|
|
1369
1627
|
},
|
|
1370
1628
|
{
|
|
@@ -1372,13 +1630,12 @@ const pebble = defineButtonPersonality({
|
|
|
1372
1630
|
name: "Secondary",
|
|
1373
1631
|
enabled: true,
|
|
1374
1632
|
priority: 2,
|
|
1375
|
-
background: {
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
border: {
|
|
1379
|
-
widthClass: "border-2",
|
|
1380
|
-
colorToken: "accent"
|
|
1633
|
+
background: {
|
|
1634
|
+
type: "surface",
|
|
1635
|
+
role: "link"
|
|
1381
1636
|
},
|
|
1637
|
+
borderRadius: "rounded-full",
|
|
1638
|
+
border: { widthClass: "border-2" },
|
|
1382
1639
|
effects: { hover: [{
|
|
1383
1640
|
effectId: "background-on-hover",
|
|
1384
1641
|
options: { colorToken: "accent" }
|
|
@@ -1389,13 +1646,12 @@ const pebble = defineButtonPersonality({
|
|
|
1389
1646
|
name: "Outline",
|
|
1390
1647
|
enabled: true,
|
|
1391
1648
|
priority: 3,
|
|
1392
|
-
background: {
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
border: {
|
|
1396
|
-
widthClass: "border",
|
|
1397
|
-
colorToken: "border"
|
|
1649
|
+
background: {
|
|
1650
|
+
type: "surface",
|
|
1651
|
+
role: "link"
|
|
1398
1652
|
},
|
|
1653
|
+
borderRadius: "rounded-full",
|
|
1654
|
+
border: { widthClass: "border" },
|
|
1399
1655
|
effects: { hover: [{
|
|
1400
1656
|
effectId: "background-on-hover",
|
|
1401
1657
|
options: { colorToken: "surface" }
|
|
@@ -1406,8 +1662,10 @@ const pebble = defineButtonPersonality({
|
|
|
1406
1662
|
name: "Ghost",
|
|
1407
1663
|
enabled: true,
|
|
1408
1664
|
priority: 3,
|
|
1409
|
-
background: {
|
|
1410
|
-
|
|
1665
|
+
background: {
|
|
1666
|
+
type: "surface",
|
|
1667
|
+
role: "link"
|
|
1668
|
+
},
|
|
1411
1669
|
borderRadius: "rounded-full",
|
|
1412
1670
|
sizes: {
|
|
1413
1671
|
sm: {
|
|
@@ -1423,11 +1681,7 @@ const pebble = defineButtonPersonality({
|
|
|
1423
1681
|
padding: "0.75rem 1.5rem",
|
|
1424
1682
|
fontSize: "text-xl"
|
|
1425
1683
|
}
|
|
1426
|
-
}
|
|
1427
|
-
effects: { hover: [{
|
|
1428
|
-
effectId: "opacity-reduce",
|
|
1429
|
-
options: { reduction: 30 }
|
|
1430
|
-
}] }
|
|
1684
|
+
}
|
|
1431
1685
|
}
|
|
1432
1686
|
]
|
|
1433
1687
|
}
|
|
@@ -1489,15 +1743,11 @@ const quietArrow = defineButtonPersonality({
|
|
|
1489
1743
|
type: "solid",
|
|
1490
1744
|
colorToken: "primary"
|
|
1491
1745
|
},
|
|
1492
|
-
textColorToken: "primaryForeground",
|
|
1493
1746
|
borderRadius: "rounded-xl",
|
|
1494
1747
|
affordance: { iconId: "ArrowRight" },
|
|
1495
1748
|
effects: { hover: [{
|
|
1496
|
-
effectId: "background
|
|
1497
|
-
options: {
|
|
1498
|
-
colorToken: "primary",
|
|
1499
|
-
opacity: 90
|
|
1500
|
-
}
|
|
1749
|
+
effectId: "darken-background",
|
|
1750
|
+
options: { amount: 100 }
|
|
1501
1751
|
}] }
|
|
1502
1752
|
},
|
|
1503
1753
|
{
|
|
@@ -1505,13 +1755,12 @@ const quietArrow = defineButtonPersonality({
|
|
|
1505
1755
|
name: "Secondary",
|
|
1506
1756
|
enabled: true,
|
|
1507
1757
|
priority: 2,
|
|
1508
|
-
background: {
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
border: {
|
|
1512
|
-
widthClass: "border",
|
|
1513
|
-
colorToken: "primary"
|
|
1758
|
+
background: {
|
|
1759
|
+
type: "surface",
|
|
1760
|
+
role: "link"
|
|
1514
1761
|
},
|
|
1762
|
+
borderRadius: "rounded-xl",
|
|
1763
|
+
border: { widthClass: "border" },
|
|
1515
1764
|
affordance: { iconId: "ArrowRight" },
|
|
1516
1765
|
effects: { hover: [{
|
|
1517
1766
|
effectId: "background-on-hover",
|
|
@@ -1523,21 +1772,22 @@ const quietArrow = defineButtonPersonality({
|
|
|
1523
1772
|
name: "Outline",
|
|
1524
1773
|
enabled: true,
|
|
1525
1774
|
priority: 3,
|
|
1526
|
-
background: {
|
|
1527
|
-
|
|
1775
|
+
background: {
|
|
1776
|
+
type: "surface",
|
|
1777
|
+
role: "link"
|
|
1778
|
+
},
|
|
1528
1779
|
borderRadius: "rounded-xl",
|
|
1529
|
-
border: {
|
|
1530
|
-
widthClass: "border",
|
|
1531
|
-
colorToken: "primary"
|
|
1532
|
-
}
|
|
1780
|
+
border: { widthClass: "border" }
|
|
1533
1781
|
},
|
|
1534
1782
|
{
|
|
1535
1783
|
id: "ghost",
|
|
1536
1784
|
name: "Ghost",
|
|
1537
1785
|
enabled: true,
|
|
1538
1786
|
priority: 3,
|
|
1539
|
-
background: {
|
|
1540
|
-
|
|
1787
|
+
background: {
|
|
1788
|
+
type: "surface",
|
|
1789
|
+
role: "link"
|
|
1790
|
+
},
|
|
1541
1791
|
borderRadius: "rounded-xl"
|
|
1542
1792
|
}
|
|
1543
1793
|
]
|
|
@@ -1601,7 +1851,6 @@ const showtimePill = defineButtonPersonality({
|
|
|
1601
1851
|
type: "solid",
|
|
1602
1852
|
colorToken: "primary"
|
|
1603
1853
|
},
|
|
1604
|
-
textColorToken: "background",
|
|
1605
1854
|
borderRadius: "rounded-full",
|
|
1606
1855
|
effects: { hover: [{ effectId: "pop" }] }
|
|
1607
1856
|
},
|
|
@@ -1610,13 +1859,12 @@ const showtimePill = defineButtonPersonality({
|
|
|
1610
1859
|
name: "Secondary",
|
|
1611
1860
|
enabled: true,
|
|
1612
1861
|
priority: 2,
|
|
1613
|
-
background: {
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
border: {
|
|
1617
|
-
widthClass: "border-2",
|
|
1618
|
-
colorToken: "primary"
|
|
1862
|
+
background: {
|
|
1863
|
+
type: "surface",
|
|
1864
|
+
role: "link"
|
|
1619
1865
|
},
|
|
1866
|
+
borderRadius: "rounded-full",
|
|
1867
|
+
border: { widthClass: "border-2" },
|
|
1620
1868
|
effects: { hover: [{ effectId: "pop" }] }
|
|
1621
1869
|
},
|
|
1622
1870
|
{
|
|
@@ -1628,7 +1876,6 @@ const showtimePill = defineButtonPersonality({
|
|
|
1628
1876
|
type: "solid",
|
|
1629
1877
|
colorToken: "secondary"
|
|
1630
1878
|
},
|
|
1631
|
-
textColorToken: "primary",
|
|
1632
1879
|
borderRadius: "rounded-full",
|
|
1633
1880
|
effects: { hover: [{ effectId: "pop" }] }
|
|
1634
1881
|
},
|
|
@@ -1641,12 +1888,8 @@ const showtimePill = defineButtonPersonality({
|
|
|
1641
1888
|
type: "solid",
|
|
1642
1889
|
colorToken: "background"
|
|
1643
1890
|
},
|
|
1644
|
-
textColorToken: "primary",
|
|
1645
1891
|
borderRadius: "rounded-full",
|
|
1646
|
-
border: {
|
|
1647
|
-
widthClass: "border-2",
|
|
1648
|
-
colorToken: "primary"
|
|
1649
|
-
},
|
|
1892
|
+
border: { widthClass: "border-2" },
|
|
1650
1893
|
effects: { hover: [{
|
|
1651
1894
|
effectId: "background-on-hover",
|
|
1652
1895
|
options: { colorToken: "surface" }
|
|
@@ -1657,13 +1900,12 @@ const showtimePill = defineButtonPersonality({
|
|
|
1657
1900
|
name: "Outline",
|
|
1658
1901
|
enabled: true,
|
|
1659
1902
|
priority: 3,
|
|
1660
|
-
background: {
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
border: {
|
|
1664
|
-
widthClass: "border-2",
|
|
1665
|
-
colorToken: "primary"
|
|
1903
|
+
background: {
|
|
1904
|
+
type: "surface",
|
|
1905
|
+
role: "link"
|
|
1666
1906
|
},
|
|
1907
|
+
borderRadius: "rounded-full",
|
|
1908
|
+
border: { widthClass: "border-2" },
|
|
1667
1909
|
effects: { hover: [{
|
|
1668
1910
|
effectId: "background-on-hover",
|
|
1669
1911
|
options: { colorToken: "background" }
|
|
@@ -1674,8 +1916,10 @@ const showtimePill = defineButtonPersonality({
|
|
|
1674
1916
|
name: "Ghost",
|
|
1675
1917
|
enabled: true,
|
|
1676
1918
|
priority: 3,
|
|
1677
|
-
background: {
|
|
1678
|
-
|
|
1919
|
+
background: {
|
|
1920
|
+
type: "surface",
|
|
1921
|
+
role: "link"
|
|
1922
|
+
},
|
|
1679
1923
|
borderRadius: "rounded-full",
|
|
1680
1924
|
effects: { hover: [{
|
|
1681
1925
|
effectId: "background-on-hover",
|
|
@@ -1686,104 +1930,151 @@ const showtimePill = defineButtonPersonality({
|
|
|
1686
1930
|
}
|
|
1687
1931
|
});
|
|
1688
1932
|
//#endregion
|
|
1689
|
-
//#region ../theme-core/src/buttons/personalities/
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1933
|
+
//#region ../theme-core/src/buttons/personalities/soft-pill.ts
|
|
1934
|
+
/**
|
|
1935
|
+
* Soft Pill — rounded-full pill buttons with a hover lift. The default for
|
|
1936
|
+
* Calm Studio and Modern Wellness; reads as quietly modern and welcoming.
|
|
1937
|
+
*/
|
|
1938
|
+
const softPill = defineButtonPersonality({
|
|
1939
|
+
id: "soft-pill",
|
|
1940
|
+
name: "Soft Pill",
|
|
1941
|
+
description: "Rounded pills with a gentle lift on hover. Quietly modern.",
|
|
1942
|
+
tags: {
|
|
1943
|
+
tone: "classic",
|
|
1944
|
+
energy: "calm",
|
|
1945
|
+
motion: "subtle",
|
|
1946
|
+
era: "organic"
|
|
1947
|
+
},
|
|
1948
|
+
buttonSystem: {
|
|
1949
|
+
global: {
|
|
1950
|
+
cornerStyle: "pill",
|
|
1951
|
+
shadow: "low",
|
|
1952
|
+
textTransform: "none",
|
|
1953
|
+
fontWeight: 500,
|
|
1954
|
+
borderWidth: 2,
|
|
1955
|
+
hoverTransform: "lift",
|
|
1956
|
+
hoverColor: "none"
|
|
1700
1957
|
},
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1958
|
+
variants: [
|
|
1959
|
+
{
|
|
1960
|
+
id: "primary",
|
|
1961
|
+
name: "Primary",
|
|
1962
|
+
enabled: true,
|
|
1963
|
+
priority: 1,
|
|
1964
|
+
background: {
|
|
1965
|
+
type: "solid",
|
|
1966
|
+
colorToken: "primary"
|
|
1967
|
+
},
|
|
1968
|
+
borderRadius: "rounded-full",
|
|
1969
|
+
shadow: {
|
|
1970
|
+
elevation: "low",
|
|
1971
|
+
softness: "soft",
|
|
1972
|
+
position: "bottom"
|
|
1973
|
+
},
|
|
1974
|
+
effects: {
|
|
1975
|
+
hover: [{
|
|
1976
|
+
effectId: "lift",
|
|
1977
|
+
options: { translateY: "-1px" }
|
|
1978
|
+
}],
|
|
1979
|
+
active: [{
|
|
1980
|
+
effectId: "scale-down",
|
|
1981
|
+
options: { scale: "0.98" }
|
|
1982
|
+
}]
|
|
1983
|
+
}
|
|
1710
1984
|
},
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
colorToken: "primary"
|
|
1720
|
-
},
|
|
1721
|
-
textColorToken: "primaryForeground",
|
|
1722
|
-
borderRadius: "rounded-full",
|
|
1723
|
-
shadow: {
|
|
1724
|
-
elevation: "low",
|
|
1725
|
-
softness: "soft",
|
|
1726
|
-
position: "bottom"
|
|
1727
|
-
},
|
|
1728
|
-
effects: {
|
|
1729
|
-
hover: [{
|
|
1730
|
-
effectId: "lift",
|
|
1731
|
-
options: { translateY: "-1px" }
|
|
1732
|
-
}],
|
|
1733
|
-
active: [{
|
|
1734
|
-
effectId: "scale-down",
|
|
1735
|
-
options: { scale: "0.98" }
|
|
1736
|
-
}]
|
|
1737
|
-
}
|
|
1985
|
+
{
|
|
1986
|
+
id: "secondary",
|
|
1987
|
+
name: "Secondary",
|
|
1988
|
+
enabled: true,
|
|
1989
|
+
priority: 2,
|
|
1990
|
+
background: {
|
|
1991
|
+
type: "surface",
|
|
1992
|
+
role: "link"
|
|
1738
1993
|
},
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
}] }
|
|
1994
|
+
borderRadius: "rounded-full",
|
|
1995
|
+
border: { widthClass: "border-2" },
|
|
1996
|
+
effects: { hover: [{
|
|
1997
|
+
effectId: "background-on-hover",
|
|
1998
|
+
options: { colorToken: "surface" }
|
|
1999
|
+
}] }
|
|
2000
|
+
},
|
|
2001
|
+
{
|
|
2002
|
+
id: "outline",
|
|
2003
|
+
name: "Outline",
|
|
2004
|
+
enabled: true,
|
|
2005
|
+
priority: 3,
|
|
2006
|
+
background: {
|
|
2007
|
+
type: "surface",
|
|
2008
|
+
role: "link"
|
|
1755
2009
|
},
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
}] }
|
|
2010
|
+
borderRadius: "rounded-full",
|
|
2011
|
+
border: { widthClass: "border" },
|
|
2012
|
+
effects: { hover: [{
|
|
2013
|
+
effectId: "background-on-hover",
|
|
2014
|
+
options: { colorToken: "surface" }
|
|
2015
|
+
}] }
|
|
2016
|
+
},
|
|
2017
|
+
{
|
|
2018
|
+
id: "ghost",
|
|
2019
|
+
name: "Ghost",
|
|
2020
|
+
enabled: true,
|
|
2021
|
+
priority: 3,
|
|
2022
|
+
background: {
|
|
2023
|
+
type: "surface",
|
|
2024
|
+
role: "link"
|
|
1772
2025
|
},
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
2026
|
+
borderRadius: "rounded-full",
|
|
2027
|
+
effects: { hover: [{
|
|
2028
|
+
effectId: "background-on-hover",
|
|
2029
|
+
options: { colorToken: "surface" }
|
|
2030
|
+
}] }
|
|
2031
|
+
}
|
|
2032
|
+
]
|
|
2033
|
+
}
|
|
2034
|
+
});
|
|
2035
|
+
//#endregion
|
|
2036
|
+
//#region ../theme-core/src/buttons/personalities/two-tone-pill.ts
|
|
2037
|
+
const solidSecondary = {
|
|
2038
|
+
id: "secondary",
|
|
2039
|
+
name: "Secondary",
|
|
2040
|
+
enabled: true,
|
|
2041
|
+
priority: 2,
|
|
2042
|
+
background: {
|
|
2043
|
+
type: "solid",
|
|
2044
|
+
colorToken: unsafeAsOpaqueButtonColourToken("secondary")
|
|
2045
|
+
},
|
|
2046
|
+
borderRadius: "rounded-full",
|
|
2047
|
+
shadow: {
|
|
2048
|
+
elevation: "none",
|
|
2049
|
+
softness: null,
|
|
2050
|
+
position: "bottom"
|
|
2051
|
+
},
|
|
2052
|
+
effects: {
|
|
2053
|
+
hover: [{
|
|
2054
|
+
effectId: "background-on-hover-alpha",
|
|
2055
|
+
options: {
|
|
2056
|
+
colorToken: "secondary",
|
|
2057
|
+
opacity: 88
|
|
2058
|
+
}
|
|
2059
|
+
}],
|
|
2060
|
+
active: [{
|
|
2061
|
+
effectId: "scale-down",
|
|
2062
|
+
options: { scale: "0.98" }
|
|
2063
|
+
}]
|
|
2064
|
+
}
|
|
2065
|
+
};
|
|
2066
|
+
//#endregion
|
|
2067
|
+
//#region ../theme-core/src/buttons/personalities/index.ts
|
|
2068
|
+
const buttonPersonalities = [
|
|
2069
|
+
softPill,
|
|
2070
|
+
defineButtonPersonality({
|
|
2071
|
+
id: "two-tone-pill",
|
|
2072
|
+
name: "Two-tone Pill",
|
|
2073
|
+
description: "Rounded pills with distinct solid primary and secondary brand colours.",
|
|
2074
|
+
tags: softPill.tags,
|
|
2075
|
+
buttonSystem: {
|
|
2076
|
+
...softPill.buttonSystem,
|
|
2077
|
+
variants: softPill.buttonSystem.variants.map((variant) => variant.id === "secondary" ? solidSecondary : variant)
|
|
1787
2078
|
}
|
|
1788
2079
|
}),
|
|
1789
2080
|
earthPill,
|
|
@@ -1799,5 +2090,26 @@ const buttonPersonalities = [
|
|
|
1799
2090
|
quietArrow
|
|
1800
2091
|
];
|
|
1801
2092
|
new Map(buttonPersonalities.map((p) => [p.id, p]));
|
|
2093
|
+
buttonPersonalities.map((personality) => ({
|
|
2094
|
+
id: personality.id,
|
|
2095
|
+
name: personality.name,
|
|
2096
|
+
description: personality.description,
|
|
2097
|
+
category: presetCategory(personality),
|
|
2098
|
+
buttonSystem: personality.buttonSystem,
|
|
2099
|
+
compatibility: {
|
|
2100
|
+
...personality.tags.tone ? { tones: [personality.tags.tone] } : {},
|
|
2101
|
+
...personality.tags.energy ? { energies: [personality.tags.energy] } : {}
|
|
2102
|
+
}
|
|
2103
|
+
}));
|
|
2104
|
+
function presetCategory(personality) {
|
|
2105
|
+
switch (personality.tags.era) {
|
|
2106
|
+
case "retro": return "retro";
|
|
2107
|
+
case "editorial": return "minimal";
|
|
2108
|
+
case "organic": return "artistic";
|
|
2109
|
+
case "modern": return personality.tags.tone === "bold" ? "modern" : "technical";
|
|
2110
|
+
case "technical": return "technical";
|
|
2111
|
+
case void 0: return "modern";
|
|
2112
|
+
}
|
|
2113
|
+
}
|
|
1802
2114
|
//#endregion
|
|
1803
|
-
export { themeButtonClassName as t };
|
|
2115
|
+
export { hexToRgb as n, themeButtonClassName as r, relativeLuminance as t };
|