@starci/grammar 0.3.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +74 -39
- package/dist/common/conformance.d.ts +31 -0
- package/dist/common/conformance.d.ts.map +1 -0
- package/dist/common/conformance.js +33 -0
- package/dist/common/conformance.js.map +1 -0
- package/dist/common/index.d.ts +5 -5
- package/dist/common/index.d.ts.map +1 -1
- package/dist/common/index.js +5 -10
- package/dist/common/index.js.map +1 -1
- package/dist/common/registry.d.ts +79 -0
- package/dist/common/registry.d.ts.map +1 -0
- package/dist/common/registry.js +34 -0
- package/dist/common/registry.js.map +1 -0
- package/dist/common/renderers.d.ts +41 -0
- package/dist/common/renderers.d.ts.map +1 -0
- package/dist/common/renderers.js +44 -0
- package/dist/common/renderers.js.map +1 -0
- package/dist/common/rule-catalog.generated.d.ts +40 -0
- package/dist/common/rule-catalog.generated.d.ts.map +1 -0
- package/dist/common/rule-catalog.generated.js +230 -0
- package/dist/common/rule-catalog.generated.js.map +1 -0
- package/dist/common/spacing.d.ts +20 -0
- package/dist/common/spacing.d.ts.map +1 -0
- package/dist/common/spacing.js +18 -0
- package/dist/common/spacing.js.map +1 -0
- package/dist/common/state.d.ts +6 -0
- package/dist/common/state.d.ts.map +1 -0
- package/dist/common/state.js +11 -0
- package/dist/common/state.js.map +1 -0
- package/dist/common/styles.css +1566 -2
- package/dist/core/OtpInput.d.ts.map +1 -1
- package/dist/core/OtpInput.js +2 -1
- package/dist/core/OtpInput.js.map +1 -1
- package/dist/core/branch/MarkdownArticle/index.d.ts.map +1 -1
- package/dist/core/branch/MarkdownArticle/index.js +2 -2
- package/dist/core/branch/MarkdownArticle/index.js.map +1 -1
- package/dist/core/branch/Rail/classNames.d.ts.map +1 -1
- package/dist/core/branch/Rail/classNames.js +4 -4
- package/dist/core/branch/Rail/classNames.js.map +1 -1
- package/dist/core/branch/Rail/index.d.ts +4 -0
- package/dist/core/branch/Rail/index.d.ts.map +1 -1
- package/dist/core/branch/Rail/index.js +12 -2
- package/dist/core/branch/Rail/index.js.map +1 -1
- package/dist/core/branch/Subnav/classNames.d.ts +8 -0
- package/dist/core/branch/Subnav/classNames.d.ts.map +1 -0
- package/dist/core/branch/Subnav/classNames.js +9 -0
- package/dist/core/branch/Subnav/classNames.js.map +1 -0
- package/dist/core/branch/Subnav/index.d.ts +17 -0
- package/dist/core/branch/Subnav/index.d.ts.map +1 -0
- package/dist/core/branch/Subnav/index.js +6 -0
- package/dist/core/branch/Subnav/index.js.map +1 -0
- package/dist/core/branch/SurfaceAccordionCard/classNames.d.ts +6 -2
- package/dist/core/branch/SurfaceAccordionCard/classNames.d.ts.map +1 -1
- package/dist/core/branch/SurfaceAccordionCard/classNames.js +14 -9
- package/dist/core/branch/SurfaceAccordionCard/classNames.js.map +1 -1
- package/dist/core/branch/SurfaceAccordionCard/index.d.ts +8 -1
- package/dist/core/branch/SurfaceAccordionCard/index.d.ts.map +1 -1
- package/dist/core/branch/SurfaceAccordionCard/index.js +29 -11
- package/dist/core/branch/SurfaceAccordionCard/index.js.map +1 -1
- package/dist/core/branch/SurfaceCard/classNames.d.ts +11 -1
- package/dist/core/branch/SurfaceCard/classNames.d.ts.map +1 -1
- package/dist/core/branch/SurfaceCard/classNames.js +16 -7
- package/dist/core/branch/SurfaceCard/classNames.js.map +1 -1
- package/dist/core/branch/SurfaceCard/index.d.ts +11 -1
- package/dist/core/branch/SurfaceCard/index.d.ts.map +1 -1
- package/dist/core/branch/SurfaceCard/index.js +15 -4
- package/dist/core/branch/SurfaceCard/index.js.map +1 -1
- package/dist/core/branch/SurfaceListCard/classNames.d.ts +2 -0
- package/dist/core/branch/SurfaceListCard/classNames.d.ts.map +1 -1
- package/dist/core/branch/SurfaceListCard/classNames.js +7 -5
- package/dist/core/branch/SurfaceListCard/classNames.js.map +1 -1
- package/dist/core/branch/SurfaceListCard/index.d.ts.map +1 -1
- package/dist/core/branch/SurfaceListCard/index.js +3 -2
- package/dist/core/branch/SurfaceListCard/index.js.map +1 -1
- package/dist/core/branch/Tabs/classNames.d.ts +11 -0
- package/dist/core/branch/Tabs/classNames.d.ts.map +1 -0
- package/dist/core/branch/Tabs/classNames.js +13 -0
- package/dist/core/branch/Tabs/classNames.js.map +1 -0
- package/dist/core/branch/Tabs/index.d.ts +22 -0
- package/dist/core/branch/Tabs/index.d.ts.map +1 -0
- package/dist/core/branch/Tabs/index.js +28 -0
- package/dist/core/branch/Tabs/index.js.map +1 -0
- package/dist/core/branch/Tooltip/classNames.d.ts +3 -0
- package/dist/core/branch/Tooltip/classNames.d.ts.map +1 -0
- package/dist/core/branch/Tooltip/classNames.js +4 -0
- package/dist/core/branch/Tooltip/classNames.js.map +1 -0
- package/dist/core/branch/Tooltip/index.d.ts +18 -0
- package/dist/core/branch/Tooltip/index.d.ts.map +1 -0
- package/dist/core/branch/Tooltip/index.js +14 -0
- package/dist/core/branch/Tooltip/index.js.map +1 -0
- package/dist/core/classNames.d.ts.map +1 -1
- package/dist/core/classNames.js +3 -3
- package/dist/core/classNames.js.map +1 -1
- package/dist/core/composite/EmptyNotice/index.d.ts +17 -0
- package/dist/core/composite/EmptyNotice/index.d.ts.map +1 -0
- package/dist/core/composite/EmptyNotice/index.js +7 -0
- package/dist/core/composite/EmptyNotice/index.js.map +1 -0
- package/dist/core/composite/HorizontalScrollRegion/index.d.ts +2 -0
- package/dist/core/composite/HorizontalScrollRegion/index.d.ts.map +1 -1
- package/dist/core/composite/HorizontalScrollRegion/index.js +5 -2
- package/dist/core/composite/HorizontalScrollRegion/index.js.map +1 -1
- package/dist/core/composite/StaticStateRow/index.d.ts.map +1 -1
- package/dist/core/composite/StaticStateRow/index.js +1 -1
- package/dist/core/composite/StaticStateRow/index.js.map +1 -1
- package/dist/core/composite/VerticalScrollRegion/index.d.ts +2 -0
- package/dist/core/composite/VerticalScrollRegion/index.d.ts.map +1 -1
- package/dist/core/composite/VerticalScrollRegion/index.js +2 -2
- package/dist/core/composite/VerticalScrollRegion/index.js.map +1 -1
- package/dist/core/composition/ChatWorkspace/classNames.d.ts +30 -0
- package/dist/core/composition/ChatWorkspace/classNames.d.ts.map +1 -0
- package/dist/core/composition/ChatWorkspace/classNames.js +31 -0
- package/dist/core/composition/ChatWorkspace/classNames.js.map +1 -0
- package/dist/core/composition/ChatWorkspace/index.d.ts +48 -0
- package/dist/core/composition/ChatWorkspace/index.d.ts.map +1 -0
- package/dist/core/composition/ChatWorkspace/index.js +40 -0
- package/dist/core/composition/ChatWorkspace/index.js.map +1 -0
- package/dist/core/composition/NavigationFeatureNav/classNames.d.ts +9 -0
- package/dist/core/composition/NavigationFeatureNav/classNames.d.ts.map +1 -0
- package/dist/core/composition/NavigationFeatureNav/classNames.js +10 -0
- package/dist/core/composition/NavigationFeatureNav/classNames.js.map +1 -0
- package/dist/core/composition/NavigationFeatureNav/index.d.ts +26 -0
- package/dist/core/composition/NavigationFeatureNav/index.d.ts.map +1 -0
- package/dist/core/composition/NavigationFeatureNav/index.js +13 -0
- package/dist/core/composition/NavigationFeatureNav/index.js.map +1 -0
- package/dist/core/composition/PrimaryRailLayout/index.d.ts +14 -0
- package/dist/core/composition/PrimaryRailLayout/index.d.ts.map +1 -0
- package/dist/core/composition/PrimaryRailLayout/index.js +8 -0
- package/dist/core/composition/PrimaryRailLayout/index.js.map +1 -0
- package/dist/core/composition/Sidebar/index.d.ts +31 -0
- package/dist/core/composition/Sidebar/index.d.ts.map +1 -0
- package/dist/core/composition/Sidebar/index.js +40 -0
- package/dist/core/composition/Sidebar/index.js.map +1 -0
- package/dist/core/composition/WorkspaceShell/classNames.d.ts +11 -0
- package/dist/core/composition/WorkspaceShell/classNames.d.ts.map +1 -0
- package/dist/core/composition/WorkspaceShell/classNames.js +12 -0
- package/dist/core/composition/WorkspaceShell/classNames.js.map +1 -0
- package/dist/core/composition/WorkspaceShell/index.d.ts +67 -0
- package/dist/core/composition/WorkspaceShell/index.d.ts.map +1 -0
- package/dist/core/composition/WorkspaceShell/index.js +20 -0
- package/dist/core/composition/WorkspaceShell/index.js.map +1 -0
- package/dist/core/dna.d.ts +180 -0
- package/dist/core/dna.d.ts.map +1 -0
- package/dist/core/dna.js +175 -0
- package/dist/core/dna.js.map +1 -0
- package/dist/core/index.d.ts +58 -11
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js +27 -11
- package/dist/core/index.js.map +1 -1
- package/dist/core/primitive/Badge/index.d.ts +12 -0
- package/dist/core/primitive/Badge/index.d.ts.map +1 -0
- package/dist/core/primitive/Badge/index.js +15 -0
- package/dist/core/primitive/Badge/index.js.map +1 -0
- package/dist/core/primitive/Button/index.d.ts +52 -0
- package/dist/core/primitive/Button/index.d.ts.map +1 -0
- package/dist/core/primitive/Button/index.js +26 -0
- package/dist/core/primitive/Button/index.js.map +1 -0
- package/dist/core/primitive/Divider/index.d.ts +7 -0
- package/dist/core/primitive/Divider/index.d.ts.map +1 -0
- package/dist/core/primitive/Divider/index.js +5 -0
- package/dist/core/primitive/Divider/index.js.map +1 -0
- package/dist/core/primitive/GrammarRoot/index.d.ts +10 -0
- package/dist/core/primitive/GrammarRoot/index.d.ts.map +1 -0
- package/dist/core/primitive/GrammarRoot/index.js +5 -0
- package/dist/core/primitive/GrammarRoot/index.js.map +1 -0
- package/dist/core/primitive/Heading/index.d.ts +15 -0
- package/dist/core/primitive/Heading/index.d.ts.map +1 -0
- package/dist/core/primitive/Heading/index.js +26 -0
- package/dist/core/primitive/Heading/index.js.map +1 -0
- package/dist/core/primitive/Icon/index.d.ts +31 -0
- package/dist/core/primitive/Icon/index.d.ts.map +1 -0
- package/dist/core/primitive/Icon/index.js +23 -0
- package/dist/core/primitive/Icon/index.js.map +1 -0
- package/dist/core/primitive/IconButton/index.d.ts +13 -0
- package/dist/core/primitive/IconButton/index.d.ts.map +1 -0
- package/dist/core/primitive/IconButton/index.js +9 -0
- package/dist/core/primitive/IconButton/index.js.map +1 -0
- package/dist/core/primitive/IconTile/index.d.ts +17 -0
- package/dist/core/primitive/IconTile/index.d.ts.map +1 -0
- package/dist/core/primitive/IconTile/index.js +32 -0
- package/dist/core/primitive/IconTile/index.js.map +1 -0
- package/dist/core/primitive/IncludedMark/index.d.ts +10 -0
- package/dist/core/primitive/IncludedMark/index.d.ts.map +1 -0
- package/dist/core/primitive/IncludedMark/index.js +8 -0
- package/dist/core/primitive/IncludedMark/index.js.map +1 -0
- package/dist/core/primitive/Input/index.d.ts +31 -0
- package/dist/core/primitive/Input/index.d.ts.map +1 -0
- package/dist/core/primitive/Input/index.js +27 -0
- package/dist/core/primitive/Input/index.js.map +1 -0
- package/dist/core/primitive/Label/classNames.d.ts +12 -0
- package/dist/core/primitive/Label/classNames.d.ts.map +1 -0
- package/dist/core/primitive/Label/classNames.js +13 -0
- package/dist/core/primitive/Label/classNames.js.map +1 -0
- package/dist/core/primitive/Label/index.d.ts +11 -0
- package/dist/core/primitive/Label/index.d.ts.map +1 -0
- package/dist/core/primitive/Label/index.js +14 -0
- package/dist/core/primitive/Label/index.js.map +1 -0
- package/dist/core/primitive/MediaFrame/index.d.ts +15 -0
- package/dist/core/primitive/MediaFrame/index.d.ts.map +1 -0
- package/dist/core/primitive/MediaFrame/index.js +8 -0
- package/dist/core/primitive/MediaFrame/index.js.map +1 -0
- package/dist/core/primitive/PageContainer/index.d.ts +9 -0
- package/dist/core/primitive/PageContainer/index.d.ts.map +1 -0
- package/dist/core/primitive/PageContainer/index.js +8 -0
- package/dist/core/primitive/PageContainer/index.js.map +1 -0
- package/dist/core/primitive/Progress/index.d.ts +11 -0
- package/dist/core/primitive/Progress/index.d.ts.map +1 -0
- package/dist/core/primitive/Progress/index.js +13 -0
- package/dist/core/primitive/Progress/index.js.map +1 -0
- package/dist/core/primitive/RankArtwork/index.d.ts +12 -0
- package/dist/core/primitive/RankArtwork/index.d.ts.map +1 -0
- package/dist/core/primitive/RankArtwork/index.js +14 -0
- package/dist/core/primitive/RankArtwork/index.js.map +1 -0
- package/dist/core/primitive/SectionHeader/index.d.ts +15 -0
- package/dist/core/primitive/SectionHeader/index.d.ts.map +1 -0
- package/dist/core/primitive/SectionHeader/index.js +6 -0
- package/dist/core/primitive/SectionHeader/index.js.map +1 -0
- package/dist/core/primitive/SurfaceCopyGroup/index.d.ts +7 -0
- package/dist/core/primitive/SurfaceCopyGroup/index.d.ts.map +1 -0
- package/dist/core/primitive/SurfaceCopyGroup/index.js +5 -0
- package/dist/core/primitive/SurfaceCopyGroup/index.js.map +1 -0
- package/dist/core/primitive/Text/index.d.ts +25 -0
- package/dist/core/primitive/Text/index.d.ts.map +1 -0
- package/dist/core/primitive/Text/index.js +57 -0
- package/dist/core/primitive/Text/index.js.map +1 -0
- package/dist/core/primitive/TextAction/index.d.ts +45 -0
- package/dist/core/primitive/TextAction/index.d.ts.map +1 -0
- package/dist/core/primitive/TextAction/index.js +112 -0
- package/dist/core/primitive/TextAction/index.js.map +1 -0
- package/dist/core/primitive/actionStyles.d.ts +5 -0
- package/dist/core/primitive/actionStyles.d.ts.map +1 -0
- package/dist/core/primitive/actionStyles.js +19 -0
- package/dist/core/primitive/actionStyles.js.map +1 -0
- package/dist/core/state.d.ts +2 -2
- package/dist/core/state.js +1 -1
- package/dist/core/styles.css +163 -592
- package/dist/heritage/index.d.ts +27 -0
- package/dist/heritage/index.d.ts.map +1 -0
- package/dist/heritage/index.js +44 -0
- package/dist/heritage/index.js.map +1 -0
- package/dist/heritage/styles.css +165 -0
- package/dist/offset-pop/index.d.ts +12 -0
- package/dist/offset-pop/index.d.ts.map +1 -0
- package/dist/offset-pop/index.js +41 -0
- package/dist/offset-pop/index.js.map +1 -0
- package/dist/offset-pop/styles.css +292 -393
- package/package.json +78 -68
- package/dist/core/scrollable-surfaces.spec.d.ts +0 -2
- package/dist/core/scrollable-surfaces.spec.d.ts.map +0 -1
- package/dist/core/scrollable-surfaces.spec.js +0 -37
- package/dist/core/scrollable-surfaces.spec.js.map +0 -1
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { type GrammarRootProps } from "../common/index.js";
|
|
2
|
+
/** Resolved institutional identity; destination behavior remains with the consumer. */
|
|
3
|
+
export type HeritageBrandProps = {
|
|
4
|
+
readonly name: string;
|
|
5
|
+
readonly descriptor: string;
|
|
6
|
+
readonly logo: {
|
|
7
|
+
readonly src: string;
|
|
8
|
+
readonly width: number;
|
|
9
|
+
readonly height: number;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
/** Official product-neutral Heritage family contract. */
|
|
13
|
+
export declare const heritageGrammar: import("../common/registry.js").GrammarFamilyContract<"heritage", {
|
|
14
|
+
readonly Brand: import("react").FunctionComponent<HeritageBrandProps>;
|
|
15
|
+
}>;
|
|
16
|
+
export declare const heritageRuleConformance: Readonly<{
|
|
17
|
+
familyId: string;
|
|
18
|
+
inheritedCommonRules: readonly string[];
|
|
19
|
+
familyEvidence: Readonly<{
|
|
20
|
+
[x: string]: readonly string[];
|
|
21
|
+
}>;
|
|
22
|
+
}>;
|
|
23
|
+
export declare const HeritageGrammarRoot: ({ className, theme, ...props }: GrammarRootProps) => import("react").JSX.Element;
|
|
24
|
+
export declare const HeritageButton: (props: import("../common/renderers.js").ButtonProps) => import("react").JSX.Element;
|
|
25
|
+
export declare const HeritageHeading: ({ children, level, scale, isSkeleton, isVisuallyHidden, }: import("../common/renderers.js").HeadingProps) => import("react").JSX.Element;
|
|
26
|
+
export declare const HeritageBrand: import("react").FunctionComponent<HeritageBrandProps>;
|
|
27
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/heritage/index.tsx"],"names":[],"mappings":"AAEA,OAAO,EAMH,KAAK,gBAAgB,EACxB,MAAM,oBAAoB,CAAA;AAG3B,uFAAuF;AACvF,MAAM,MAAM,kBAAkB,GAAG;IAC7B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,QAAQ,CAAC,IAAI,EAAE;QACX,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;QACpB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;QACtB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;KAC1B,CAAA;CACJ,CAAA;AAoBD,yDAAyD;AACzD,eAAO,MAAM,eAAe;;EAc1B,CAAA;AAWF,eAAO,MAAM,uBAAuB;;;;;;EAIlC,CAAA;AAEF,eAAO,MAAM,mBAAmB,mFAAyC,CAAA;AACzE,eAAO,MAAM,cAAc,sFAAoC,CAAA;AAC/D,eAAO,MAAM,eAAe,2IAAqC,CAAA;AACjE,eAAO,MAAM,aAAa,uDAAmC,CAAA"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { COMMON_GRAMMAR_COMPONENTS, COMMON_UI_RULE_IDS, defineGrammarFamily, defineGrammarRuleConformance, } from "../common/index.js";
|
|
4
|
+
import { createElement } from "react";
|
|
5
|
+
const HeritageGrammarRootRenderer = (props) => {
|
|
6
|
+
const CommonGrammarRoot = COMMON_GRAMMAR_COMPONENTS.GrammarRoot;
|
|
7
|
+
return createElement(CommonGrammarRoot, { ...props, "data-grammar-family": "heritage" });
|
|
8
|
+
};
|
|
9
|
+
/** Family extension for non-interactive brand content inside a consumer-owned destination. */
|
|
10
|
+
const HeritageBrandRenderer = ({ name, descriptor, logo }) => (_jsxs("span", { "data-family-component": "Brand", children: [_jsx("span", { "data-family-part": "brand-mark", "aria-hidden": "true", children: _jsx("img", { src: logo.src, alt: "", width: logo.width, height: logo.height }) }), _jsxs("span", { "data-family-part": "brand-copy", children: [_jsx("strong", { children: name }), _jsx("span", { children: descriptor })] })] }));
|
|
11
|
+
/** Official product-neutral Heritage family contract. */
|
|
12
|
+
export const heritageGrammar = defineGrammarFamily({
|
|
13
|
+
id: "heritage",
|
|
14
|
+
styles: {
|
|
15
|
+
entrypoint: "@starci/grammar/heritage/styles.css",
|
|
16
|
+
scope: { attribute: "data-grammar-family", value: "heritage" },
|
|
17
|
+
},
|
|
18
|
+
components: {
|
|
19
|
+
replacements: {
|
|
20
|
+
GrammarRoot: HeritageGrammarRootRenderer,
|
|
21
|
+
},
|
|
22
|
+
extensions: {
|
|
23
|
+
Brand: HeritageBrandRenderer,
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
});
|
|
27
|
+
const HERITAGE_FAMILY_EVIDENCE = {
|
|
28
|
+
"A11Y-4": ["Brand is non-interactive and its supplied image is decorative."],
|
|
29
|
+
"BOUNDARY-1": ["Heritage surfaces bind material only through emitted Common surface hooks."],
|
|
30
|
+
"COLOR-5": ["Heritage owns scoped light, dark, system, and forced-color variables."],
|
|
31
|
+
"FOCUS-1": ["Heritage binds the shared visible focus variable without replacing focus ownership."],
|
|
32
|
+
"GAP-2": ["Brand anatomy uses the invariant Common spacing tokens."],
|
|
33
|
+
"MEDIA-6": ["Brand receives approved logo identity; asset generation remains outside Grammar."],
|
|
34
|
+
};
|
|
35
|
+
export const heritageRuleConformance = defineGrammarRuleConformance({
|
|
36
|
+
familyId: "heritage",
|
|
37
|
+
inheritedCommonRules: COMMON_UI_RULE_IDS.filter((rule) => !(rule in HERITAGE_FAMILY_EVIDENCE)),
|
|
38
|
+
familyEvidence: HERITAGE_FAMILY_EVIDENCE,
|
|
39
|
+
});
|
|
40
|
+
export const HeritageGrammarRoot = heritageGrammar.components.GrammarRoot;
|
|
41
|
+
export const HeritageButton = heritageGrammar.components.Button;
|
|
42
|
+
export const HeritageHeading = heritageGrammar.components.Heading;
|
|
43
|
+
export const HeritageBrand = heritageGrammar.components.Brand;
|
|
44
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/heritage/index.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;;AAEZ,OAAO,EACH,yBAAyB,EACzB,kBAAkB,EAClB,mBAAmB,EACnB,4BAA4B,GAG/B,MAAM,oBAAoB,CAAA;AAC3B,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAA;AAarC,MAAM,2BAA2B,GAA+C,CAAC,KAAK,EAAE,EAAE;IACtF,MAAM,iBAAiB,GAAG,yBAAyB,CAAC,WAAW,CAAA;IAC/D,OAAO,aAAa,CAAC,iBAAiB,EAAE,EAAE,GAAG,KAAK,EAAE,qBAAqB,EAAE,UAAU,EAAE,CAAC,CAAA;AAC5F,CAAC,CAAA;AAED,8FAA8F;AAC9F,MAAM,qBAAqB,GAAiD,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,CACxG,yCAA4B,OAAO,aAC/B,mCAAuB,YAAY,iBAAa,MAAM,YAClD,cAAK,GAAG,EAAE,IAAI,CAAC,GAAG,EAAE,GAAG,EAAC,EAAE,EAAC,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,CAAC,MAAM,GAAI,GAClE,EACP,oCAAuB,YAAY,aAC/B,2BAAS,IAAI,GAAU,EACvB,yBAAO,UAAU,GAAQ,IACtB,IACJ,CACV,CAAA;AAED,yDAAyD;AACzD,MAAM,CAAC,MAAM,eAAe,GAAG,mBAAmB,CAAC;IAC/C,EAAE,EAAE,UAAU;IACd,MAAM,EAAE;QACJ,UAAU,EAAE,qCAAqC;QACjD,KAAK,EAAE,EAAE,SAAS,EAAE,qBAAqB,EAAE,KAAK,EAAE,UAAU,EAAE;KACjE;IACD,UAAU,EAAE;QACR,YAAY,EAAE;YACV,WAAW,EAAE,2BAA2B;SAC3C;QACD,UAAU,EAAE;YACR,KAAK,EAAE,qBAAqB;SAC/B;KACJ;CACJ,CAAC,CAAA;AAEF,MAAM,wBAAwB,GAAG;IAC7B,QAAQ,EAAE,CAAC,gEAAgE,CAAC;IAC5E,YAAY,EAAE,CAAC,4EAA4E,CAAC;IAC5F,SAAS,EAAE,CAAC,uEAAuE,CAAC;IACpF,SAAS,EAAE,CAAC,qFAAqF,CAAC;IAClG,OAAO,EAAE,CAAC,yDAAyD,CAAC;IACpE,SAAS,EAAE,CAAC,kFAAkF,CAAC;CACzF,CAAA;AAEV,MAAM,CAAC,MAAM,uBAAuB,GAAG,4BAA4B,CAAC;IAChE,QAAQ,EAAE,UAAU;IACpB,oBAAoB,EAAE,kBAAkB,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,IAAI,wBAAwB,CAAC,CAAC;IAC9F,cAAc,EAAE,wBAAwB;CAC3C,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAG,eAAe,CAAC,UAAU,CAAC,WAAW,CAAA;AACzE,MAAM,CAAC,MAAM,cAAc,GAAG,eAAe,CAAC,UAAU,CAAC,MAAM,CAAA;AAC/D,MAAM,CAAC,MAAM,eAAe,GAAG,eAAe,CAAC,UAAU,CAAC,OAAO,CAAA;AACjE,MAAM,CAAC,MAAM,aAAa,GAAG,eAAe,CAAC,UAAU,CAAC,KAAK,CAAA"}
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
@import "../common/styles.css";
|
|
2
|
+
|
|
3
|
+
@layer starci-grammar-heritage {
|
|
4
|
+
.grammar-common-root[data-grammar-family="heritage"] {
|
|
5
|
+
color-scheme: light;
|
|
6
|
+
|
|
7
|
+
--heritage-green-900: oklch(29% 0.085 147);
|
|
8
|
+
--heritage-green-700: oklch(42% 0.12 147);
|
|
9
|
+
--heritage-ink: oklch(18% 0.018 145);
|
|
10
|
+
--heritage-muted: oklch(49% 0.018 145);
|
|
11
|
+
--heritage-ivory: oklch(97.5% 0.014 96);
|
|
12
|
+
--heritage-paper: oklch(99.3% 0.005 96);
|
|
13
|
+
--heritage-line: oklch(88% 0.012 110);
|
|
14
|
+
--heritage-display: Georgia, "Times New Roman", serif;
|
|
15
|
+
--heritage-sans: "Segoe UI", Arial, ui-sans-serif, system-ui, sans-serif;
|
|
16
|
+
|
|
17
|
+
--accent: var(--heritage-green-700);
|
|
18
|
+
--accent-foreground: white;
|
|
19
|
+
--focus: var(--heritage-green-700);
|
|
20
|
+
--background: var(--heritage-ivory);
|
|
21
|
+
--foreground: var(--heritage-ink);
|
|
22
|
+
--surface: var(--heritage-paper);
|
|
23
|
+
--surface-foreground: var(--heritage-ink);
|
|
24
|
+
--surface-secondary: var(--heritage-ivory);
|
|
25
|
+
--surface-secondary-foreground: var(--heritage-ink);
|
|
26
|
+
--muted: var(--heritage-muted);
|
|
27
|
+
--border: var(--heritage-line);
|
|
28
|
+
--separator: var(--heritage-line);
|
|
29
|
+
--success: var(--heritage-green-700);
|
|
30
|
+
--success-foreground: white;
|
|
31
|
+
--warning: oklch(76% 0.13 82);
|
|
32
|
+
--warning-foreground: var(--heritage-ink);
|
|
33
|
+
--danger: oklch(55% 0.18 28);
|
|
34
|
+
--danger-foreground: white;
|
|
35
|
+
--info: oklch(70% 0.09 235);
|
|
36
|
+
--info-foreground: var(--heritage-ink);
|
|
37
|
+
--field-background: var(--heritage-paper);
|
|
38
|
+
--field-border: var(--heritage-line);
|
|
39
|
+
--field-foreground: var(--heritage-ink);
|
|
40
|
+
--field-placeholder: var(--heritage-muted);
|
|
41
|
+
--radius: 0;
|
|
42
|
+
--field-radius: 0;
|
|
43
|
+
--shadow-surface: 0 1.5rem 4rem rgb(16 68 37 / 12%);
|
|
44
|
+
|
|
45
|
+
color: var(--foreground);
|
|
46
|
+
background: var(--background);
|
|
47
|
+
font-family: var(--heritage-sans);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.grammar-common-root[data-grammar-family="heritage"][data-grammar-theme="dark"] {
|
|
51
|
+
color-scheme: dark;
|
|
52
|
+
|
|
53
|
+
--heritage-green-900: oklch(88% 0.08 147);
|
|
54
|
+
--heritage-green-700: oklch(74% 0.12 147);
|
|
55
|
+
--heritage-ink: oklch(96% 0.01 96);
|
|
56
|
+
--heritage-muted: oklch(75% 0.018 110);
|
|
57
|
+
--heritage-ivory: oklch(16% 0.018 145);
|
|
58
|
+
--heritage-paper: oklch(21% 0.018 145);
|
|
59
|
+
--heritage-line: oklch(38% 0.025 145);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-grammar-surface-card][data-slot="card"] {
|
|
63
|
+
border: 0;
|
|
64
|
+
background: transparent;
|
|
65
|
+
box-shadow: none;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-grammar-surface-card][data-slot="card"] [data-grammar-frame="bounded"][data-slot="card-content"],
|
|
69
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-grammar-surface] {
|
|
70
|
+
border: 1px solid var(--border);
|
|
71
|
+
border-radius: var(--radius);
|
|
72
|
+
background: var(--surface);
|
|
73
|
+
box-shadow: var(--shadow-surface);
|
|
74
|
+
color: var(--surface-foreground);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-grammar-surface-card][data-slot="card"] [data-grammar-frame="bounded"][data-slot="card-content"][data-grammar-surface-depth="nested"],
|
|
78
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-grammar-surface][data-grammar-surface-depth="nested"] {
|
|
79
|
+
background: var(--surface-secondary);
|
|
80
|
+
box-shadow: none;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-grammar-surface-label] {
|
|
84
|
+
color: var(--heritage-green-900);
|
|
85
|
+
font-family: var(--heritage-display);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-family-component="Brand"] {
|
|
89
|
+
display: inline-flex;
|
|
90
|
+
min-height: 3.5rem;
|
|
91
|
+
align-items: center;
|
|
92
|
+
gap: var(--grammar-row-gap);
|
|
93
|
+
text-align: start;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-family-part="brand-mark"] {
|
|
97
|
+
display: grid;
|
|
98
|
+
inline-size: 3.5rem;
|
|
99
|
+
block-size: 3.5rem;
|
|
100
|
+
overflow: hidden;
|
|
101
|
+
flex: 0 0 auto;
|
|
102
|
+
place-items: center;
|
|
103
|
+
border-radius: 50%;
|
|
104
|
+
background: white;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-family-part="brand-mark"] img {
|
|
108
|
+
inline-size: 100%;
|
|
109
|
+
block-size: 100%;
|
|
110
|
+
object-fit: cover;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-family-part="brand-copy"] {
|
|
114
|
+
display: grid;
|
|
115
|
+
gap: 0.125rem;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-family-part="brand-copy"] strong {
|
|
119
|
+
color: var(--heritage-green-900);
|
|
120
|
+
font-family: var(--heritage-display);
|
|
121
|
+
font-size: 1rem;
|
|
122
|
+
font-weight: 800;
|
|
123
|
+
letter-spacing: .125em;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-family-part="brand-copy"] span {
|
|
127
|
+
color: var(--heritage-muted);
|
|
128
|
+
font-size: .75rem;
|
|
129
|
+
font-weight: 650;
|
|
130
|
+
letter-spacing: .0625em;
|
|
131
|
+
text-transform: uppercase;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
@media (prefers-color-scheme: dark) {
|
|
135
|
+
.grammar-common-root[data-grammar-family="heritage"][data-grammar-theme="system"] {
|
|
136
|
+
color-scheme: dark;
|
|
137
|
+
|
|
138
|
+
--heritage-green-900: oklch(88% 0.08 147);
|
|
139
|
+
--heritage-green-700: oklch(74% 0.12 147);
|
|
140
|
+
--heritage-ink: oklch(96% 0.01 96);
|
|
141
|
+
--heritage-muted: oklch(75% 0.018 110);
|
|
142
|
+
--heritage-ivory: oklch(16% 0.018 145);
|
|
143
|
+
--heritage-paper: oklch(21% 0.018 145);
|
|
144
|
+
--heritage-line: oklch(38% 0.025 145);
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
@media (forced-colors: active) {
|
|
149
|
+
.grammar-common-root[data-grammar-family="heritage"] {
|
|
150
|
+
--heritage-green-900: CanvasText;
|
|
151
|
+
--heritage-green-700: Highlight;
|
|
152
|
+
--heritage-ink: CanvasText;
|
|
153
|
+
--heritage-muted: GrayText;
|
|
154
|
+
--heritage-ivory: Canvas;
|
|
155
|
+
--heritage-paper: Canvas;
|
|
156
|
+
--heritage-line: CanvasText;
|
|
157
|
+
--shadow-surface: none;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.grammar-common-root[data-grammar-family="heritage"] [data-family-part="brand-mark"] {
|
|
161
|
+
border: 1px solid CanvasText;
|
|
162
|
+
background: Canvas;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type GrammarRootProps } from "../common/index.js";
|
|
2
|
+
/** Official product-neutral Offset Pop sibling family over the Common contract. */
|
|
3
|
+
export declare const offsetPopGrammar: import("../common/registry.js").GrammarFamilyContract<"offset-pop", {}>;
|
|
4
|
+
export declare const offsetPopRuleConformance: Readonly<{
|
|
5
|
+
familyId: string;
|
|
6
|
+
inheritedCommonRules: readonly string[];
|
|
7
|
+
familyEvidence: Readonly<{
|
|
8
|
+
[x: string]: readonly string[];
|
|
9
|
+
}>;
|
|
10
|
+
}>;
|
|
11
|
+
export declare const OffsetPopGrammarRoot: ({ className, theme, ...props }: GrammarRootProps) => import("react").JSX.Element;
|
|
12
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/offset-pop/index.tsx"],"names":[],"mappings":"AAEA,OAAO,EAMH,KAAK,gBAAgB,EACxB,MAAM,oBAAoB,CAAA;AAS3B,mFAAmF;AACnF,eAAO,MAAM,gBAAgB,yEAY3B,CAAA;AAeF,eAAO,MAAM,wBAAwB;;;;;;EAInC,CAAA;AAEF,eAAO,MAAM,oBAAoB,mFAA0C,CAAA"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { COMMON_GRAMMAR_COMPONENTS, COMMON_UI_RULE_IDS, defineGrammarFamily, defineGrammarRuleConformance, } from "../common/index.js";
|
|
3
|
+
import { createElement } from "react";
|
|
4
|
+
/** Installs the Offset Pop scope without changing Common root props or behavior. */
|
|
5
|
+
const OffsetPopGrammarRootRenderer = (props) => {
|
|
6
|
+
const CommonGrammarRoot = COMMON_GRAMMAR_COMPONENTS.GrammarRoot;
|
|
7
|
+
return createElement(CommonGrammarRoot, { ...props, "data-grammar-family": "offset-pop" });
|
|
8
|
+
};
|
|
9
|
+
/** Official product-neutral Offset Pop sibling family over the Common contract. */
|
|
10
|
+
export const offsetPopGrammar = defineGrammarFamily({
|
|
11
|
+
id: "offset-pop",
|
|
12
|
+
styles: {
|
|
13
|
+
entrypoint: "@starci/grammar/offset-pop/styles.css",
|
|
14
|
+
scope: { attribute: "data-grammar-family", value: "offset-pop" },
|
|
15
|
+
},
|
|
16
|
+
components: {
|
|
17
|
+
replacements: {
|
|
18
|
+
GrammarRoot: OffsetPopGrammarRootRenderer,
|
|
19
|
+
},
|
|
20
|
+
extensions: {},
|
|
21
|
+
},
|
|
22
|
+
});
|
|
23
|
+
const OFFSET_POP_FAMILY_EVIDENCE = {
|
|
24
|
+
"ACCENT-1": ["Offset Pop binds one scoped pink decision accent."],
|
|
25
|
+
"BOUNDARY-1": ["Offset Pop material targets emitted Common surface and frame hooks."],
|
|
26
|
+
"COLOR-5": ["Offset Pop owns scoped light, dark, system, and forced-color variables."],
|
|
27
|
+
"FOCUS-1": ["Offset Pop keeps Common focus ownership and supplies a visible family focus color."],
|
|
28
|
+
"GAP-2": ["Family geometry uses the invariant Common spacing scale."],
|
|
29
|
+
"MOTION-2": ["Reduced motion removes Offset Pop transforms and transition duration."],
|
|
30
|
+
"PADDING-3": ["Offset Pop does not add a second inset owner to Common surface content."],
|
|
31
|
+
"RESPONSIVE-4": ["Narrow viewports retain content and reduce only family shadow geometry."],
|
|
32
|
+
"STATE-2": ["Pending and loading remain Common-owned; family CSS only reads emitted state hooks."],
|
|
33
|
+
"SURFACE-1": ["Top and nested surface treatments preserve Common surface roles."],
|
|
34
|
+
};
|
|
35
|
+
export const offsetPopRuleConformance = defineGrammarRuleConformance({
|
|
36
|
+
familyId: "offset-pop",
|
|
37
|
+
inheritedCommonRules: COMMON_UI_RULE_IDS.filter((rule) => !(rule in OFFSET_POP_FAMILY_EVIDENCE)),
|
|
38
|
+
familyEvidence: OFFSET_POP_FAMILY_EVIDENCE,
|
|
39
|
+
});
|
|
40
|
+
export const OffsetPopGrammarRoot = offsetPopGrammar.components.GrammarRoot;
|
|
41
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/offset-pop/index.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAA;AAEZ,OAAO,EACH,yBAAyB,EACzB,kBAAkB,EAClB,mBAAmB,EACnB,4BAA4B,GAG/B,MAAM,oBAAoB,CAAA;AAC3B,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAA;AAErC,oFAAoF;AACpF,MAAM,4BAA4B,GAA+C,CAAC,KAAK,EAAE,EAAE;IACvF,MAAM,iBAAiB,GAAG,yBAAyB,CAAC,WAAW,CAAA;IAC/D,OAAO,aAAa,CAAC,iBAAiB,EAAE,EAAE,GAAG,KAAK,EAAE,qBAAqB,EAAE,YAAY,EAAE,CAAC,CAAA;AAC9F,CAAC,CAAA;AAED,mFAAmF;AACnF,MAAM,CAAC,MAAM,gBAAgB,GAAG,mBAAmB,CAAC;IAChD,EAAE,EAAE,YAAY;IAChB,MAAM,EAAE;QACJ,UAAU,EAAE,uCAAuC;QACnD,KAAK,EAAE,EAAE,SAAS,EAAE,qBAAqB,EAAE,KAAK,EAAE,YAAY,EAAE;KACnE;IACD,UAAU,EAAE;QACR,YAAY,EAAE;YACV,WAAW,EAAE,4BAA4B;SAC5C;QACD,UAAU,EAAE,EAAE;KACjB;CACJ,CAAC,CAAA;AAEF,MAAM,0BAA0B,GAAG;IAC/B,UAAU,EAAE,CAAC,mDAAmD,CAAC;IACjE,YAAY,EAAE,CAAC,qEAAqE,CAAC;IACrF,SAAS,EAAE,CAAC,yEAAyE,CAAC;IACtF,SAAS,EAAE,CAAC,oFAAoF,CAAC;IACjG,OAAO,EAAE,CAAC,0DAA0D,CAAC;IACrE,UAAU,EAAE,CAAC,uEAAuE,CAAC;IACrF,WAAW,EAAE,CAAC,yEAAyE,CAAC;IACxF,cAAc,EAAE,CAAC,yEAAyE,CAAC;IAC3F,SAAS,EAAE,CAAC,qFAAqF,CAAC;IAClG,WAAW,EAAE,CAAC,kEAAkE,CAAC;CAC3E,CAAA;AAEV,MAAM,CAAC,MAAM,wBAAwB,GAAG,4BAA4B,CAAC;IACjE,QAAQ,EAAE,YAAY;IACtB,oBAAoB,EAAE,kBAAkB,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,IAAI,0BAA0B,CAAC,CAAC;IAChG,cAAc,EAAE,0BAA0B;CAC7C,CAAC,CAAA;AAEF,MAAM,CAAC,MAAM,oBAAoB,GAAG,gBAAgB,CAAC,UAAU,CAAC,WAAW,CAAA"}
|