@rulecms/widget-angular 0.1.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.
Files changed (165) hide show
  1. package/LICENSE +7 -0
  2. package/README.md +125 -0
  3. package/fesm2022/rulecms-widget-angular.mjs +3465 -0
  4. package/fesm2022/rulecms-widget-angular.mjs.map +1 -0
  5. package/index.d.ts +6 -0
  6. package/lib/fetch/fetch-rule-cms-widget.d.ts +23 -0
  7. package/lib/fetch/fetch-rule-cms-widget.d.ts.map +1 -0
  8. package/lib/fetch/resolve-widget-libraries.d.ts +16 -0
  9. package/lib/fetch/resolve-widget-libraries.d.ts.map +1 -0
  10. package/lib/helpers/background-image-types.d.ts +24 -0
  11. package/lib/helpers/background-image-types.d.ts.map +1 -0
  12. package/lib/helpers/border-types.d.ts +22 -0
  13. package/lib/helpers/border-types.d.ts.map +1 -0
  14. package/lib/helpers/box-shadow-types.d.ts +25 -0
  15. package/lib/helpers/box-shadow-types.d.ts.map +1 -0
  16. package/lib/helpers/box-spacing-style-attribute-entries.d.ts +4 -0
  17. package/lib/helpers/box-spacing-style-attribute-entries.d.ts.map +1 -0
  18. package/lib/helpers/box-spacing-types.d.ts +31 -0
  19. package/lib/helpers/box-spacing-types.d.ts.map +1 -0
  20. package/lib/helpers/cloudinary-image-url.d.ts +20 -0
  21. package/lib/helpers/cloudinary-image-url.d.ts.map +1 -0
  22. package/lib/helpers/collect-component-instance-paths.d.ts +16 -0
  23. package/lib/helpers/collect-component-instance-paths.d.ts.map +1 -0
  24. package/lib/helpers/constants.d.ts +5 -0
  25. package/lib/helpers/constants.d.ts.map +1 -0
  26. package/lib/helpers/css-classes.d.ts +13 -0
  27. package/lib/helpers/css-classes.d.ts.map +1 -0
  28. package/lib/helpers/css-color-types.d.ts +18 -0
  29. package/lib/helpers/css-color-types.d.ts.map +1 -0
  30. package/lib/helpers/css-enum-types.d.ts +41 -0
  31. package/lib/helpers/css-enum-types.d.ts.map +1 -0
  32. package/lib/helpers/css-variable-types.d.ts +33 -0
  33. package/lib/helpers/css-variable-types.d.ts.map +1 -0
  34. package/lib/helpers/derive-display-flex-if-needed.d.ts +13 -0
  35. package/lib/helpers/derive-display-flex-if-needed.d.ts.map +1 -0
  36. package/lib/helpers/format-background-image-styles.d.ts +12 -0
  37. package/lib/helpers/format-background-image-styles.d.ts.map +1 -0
  38. package/lib/helpers/format-border-styles.d.ts +9 -0
  39. package/lib/helpers/format-border-styles.d.ts.map +1 -0
  40. package/lib/helpers/format-box-shadow-styles.d.ts +8 -0
  41. package/lib/helpers/format-box-shadow-styles.d.ts.map +1 -0
  42. package/lib/helpers/format-box-spacing-styles.d.ts +11 -0
  43. package/lib/helpers/format-box-spacing-styles.d.ts.map +1 -0
  44. package/lib/helpers/format-css-color-styles.d.ts +8 -0
  45. package/lib/helpers/format-css-color-styles.d.ts.map +1 -0
  46. package/lib/helpers/format-css-enum-styles.d.ts +7 -0
  47. package/lib/helpers/format-css-enum-styles.d.ts.map +1 -0
  48. package/lib/helpers/format-css-length-styles.d.ts +9 -0
  49. package/lib/helpers/format-css-length-styles.d.ts.map +1 -0
  50. package/lib/helpers/format-line-height-styles.d.ts +8 -0
  51. package/lib/helpers/format-line-height-styles.d.ts.map +1 -0
  52. package/lib/helpers/format-opacity-styles.d.ts +8 -0
  53. package/lib/helpers/format-opacity-styles.d.ts.map +1 -0
  54. package/lib/helpers/format-spacing-side-value.d.ts +4 -0
  55. package/lib/helpers/format-spacing-side-value.d.ts.map +1 -0
  56. package/lib/helpers/get-column-attributes.d.ts +26 -0
  57. package/lib/helpers/get-column-attributes.d.ts.map +1 -0
  58. package/lib/helpers/get-component-attributes-and-styles.d.ts +23 -0
  59. package/lib/helpers/get-component-attributes-and-styles.d.ts.map +1 -0
  60. package/lib/helpers/get-default-dimension-attributes.d.ts +9 -0
  61. package/lib/helpers/get-default-dimension-attributes.d.ts.map +1 -0
  62. package/lib/helpers/get-device-type-based-attributes.d.ts +10 -0
  63. package/lib/helpers/get-device-type-based-attributes.d.ts.map +1 -0
  64. package/lib/helpers/get-merged-attributes.d.ts +11 -0
  65. package/lib/helpers/get-merged-attributes.d.ts.map +1 -0
  66. package/lib/helpers/has-items.d.ts +3 -0
  67. package/lib/helpers/has-items.d.ts.map +1 -0
  68. package/lib/helpers/index.d.ts +40 -0
  69. package/lib/helpers/index.d.ts.map +1 -0
  70. package/lib/helpers/line-height-types.d.ts +12 -0
  71. package/lib/helpers/line-height-types.d.ts.map +1 -0
  72. package/lib/helpers/object-style-attribute-registry.d.ts +44 -0
  73. package/lib/helpers/object-style-attribute-registry.d.ts.map +1 -0
  74. package/lib/helpers/opacity-types.d.ts +9 -0
  75. package/lib/helpers/opacity-types.d.ts.map +1 -0
  76. package/lib/helpers/resolve-row-styles.d.ts +23 -0
  77. package/lib/helpers/resolve-row-styles.d.ts.map +1 -0
  78. package/lib/helpers/resolve-widget-container-styles.d.ts +55 -0
  79. package/lib/helpers/resolve-widget-container-styles.d.ts.map +1 -0
  80. package/lib/helpers/resolve-widget-instance-props.d.ts +18 -0
  81. package/lib/helpers/resolve-widget-instance-props.d.ts.map +1 -0
  82. package/lib/helpers/types.d.ts +131 -0
  83. package/lib/helpers/types.d.ts.map +1 -0
  84. package/lib/helpers/warn-unmatched-component-props.d.ts +30 -0
  85. package/lib/helpers/warn-unmatched-component-props.d.ts.map +1 -0
  86. package/lib/helpers-display/dimension-wrapper-styles.d.ts +7 -0
  87. package/lib/helpers-display/dimension-wrapper-styles.d.ts.map +1 -0
  88. package/lib/helpers-display/resolve-no-container.d.ts +14 -0
  89. package/lib/helpers-display/resolve-no-container.d.ts.map +1 -0
  90. package/lib/helpers-display/resolve-renders-own-element.d.ts +15 -0
  91. package/lib/helpers-display/resolve-renders-own-element.d.ts.map +1 -0
  92. package/lib/id-utils/collection-col-type-prefix.d.ts +2 -0
  93. package/lib/id-utils/collection-col-type-prefix.d.ts.map +1 -0
  94. package/lib/id-utils/dev-client-token.d.ts +33 -0
  95. package/lib/id-utils/dev-client-token.d.ts.map +1 -0
  96. package/lib/id-utils/drag-item-id-helper.d.ts +9 -0
  97. package/lib/id-utils/drag-item-id-helper.d.ts.map +1 -0
  98. package/lib/id-utils/get-collection-id-for-collection-type.d.ts +2 -0
  99. package/lib/id-utils/get-collection-id-for-collection-type.d.ts.map +1 -0
  100. package/lib/id-utils/get-name-and-instance-id-from-widget-key.d.ts +6 -0
  101. package/lib/id-utils/get-name-and-instance-id-from-widget-key.d.ts.map +1 -0
  102. package/lib/id-utils/get-name-for-widget-key.d.ts +5 -0
  103. package/lib/id-utils/get-name-for-widget-key.d.ts.map +1 -0
  104. package/lib/id-utils/get-widget-key-for-collection.d.ts +16 -0
  105. package/lib/id-utils/get-widget-key-for-collection.d.ts.map +1 -0
  106. package/lib/id-utils/index.d.ts +11 -0
  107. package/lib/id-utils/index.d.ts.map +1 -0
  108. package/lib/id-utils/published-key-utilities.d.ts +24 -0
  109. package/lib/id-utils/published-key-utilities.d.ts.map +1 -0
  110. package/lib/id-utils/types.d.ts +25 -0
  111. package/lib/id-utils/types.d.ts.map +1 -0
  112. package/lib/id-utils/version-utilities.d.ts +7 -0
  113. package/lib/id-utils/version-utilities.d.ts.map +1 -0
  114. package/lib/library-registry/ComponentLibraryRegistry.d.ts +17 -0
  115. package/lib/library-registry/ComponentLibraryRegistry.d.ts.map +1 -0
  116. package/lib/library-registry/collect-referenced-library-ids.d.ts +20 -0
  117. package/lib/library-registry/collect-referenced-library-ids.d.ts.map +1 -0
  118. package/lib/library-registry/index.d.ts +5 -0
  119. package/lib/library-registry/index.d.ts.map +1 -0
  120. package/lib/library-registry/resolve-key.d.ts +16 -0
  121. package/lib/library-registry/resolve-key.d.ts.map +1 -0
  122. package/lib/library-registry/types.d.ts +142 -0
  123. package/lib/library-registry/types.d.ts.map +1 -0
  124. package/lib/provider/rule-cms-widget-context.service.d.ts +11 -0
  125. package/lib/provider/rule-cms-widget-context.service.d.ts.map +1 -0
  126. package/lib/provider/rule-cms-widget-provider.component.d.ts +26 -0
  127. package/lib/provider/rule-cms-widget-provider.component.d.ts.map +1 -0
  128. package/lib/render/breakpoint-variant-render.component.d.ts +21 -0
  129. package/lib/render/breakpoint-variant-render.component.d.ts.map +1 -0
  130. package/lib/render/breakpoint-variant-styles.d.ts +2 -0
  131. package/lib/render/breakpoint-variant-styles.d.ts.map +1 -0
  132. package/lib/render/display-component.component.d.ts +27 -0
  133. package/lib/render/display-component.component.d.ts.map +1 -0
  134. package/lib/render/display-device-type.d.ts +5 -0
  135. package/lib/render/display-device-type.d.ts.map +1 -0
  136. package/lib/render/embed-in-row.component.d.ts +21 -0
  137. package/lib/render/embed-in-row.component.d.ts.map +1 -0
  138. package/lib/render/embed-in-vertical-container.component.d.ts +24 -0
  139. package/lib/render/embed-in-vertical-container.component.d.ts.map +1 -0
  140. package/lib/render/get-components-plugin-from-plugins.d.ts +11 -0
  141. package/lib/render/get-components-plugin-from-plugins.d.ts.map +1 -0
  142. package/lib/render/has-device-divergent-values.d.ts +6 -0
  143. package/lib/render/has-device-divergent-values.d.ts.map +1 -0
  144. package/lib/render/render-components-for-device.component.d.ts +20 -0
  145. package/lib/render/render-components-for-device.component.d.ts.map +1 -0
  146. package/lib/render/render-components-inner.component.d.ts +33 -0
  147. package/lib/render/render-components-inner.component.d.ts.map +1 -0
  148. package/lib/render/render-components.component.d.ts +26 -0
  149. package/lib/render/render-components.component.d.ts.map +1 -0
  150. package/lib/render/types.d.ts +43 -0
  151. package/lib/render/types.d.ts.map +1 -0
  152. package/lib/widget/prepare-rule-cms-widget-data.d.ts +4 -0
  153. package/lib/widget/prepare-rule-cms-widget-data.d.ts.map +1 -0
  154. package/lib/widget/resolve-source-components-plugin.d.ts +19 -0
  155. package/lib/widget/resolve-source-components-plugin.d.ts.map +1 -0
  156. package/lib/widget/rule-cms-widget.component.d.ts +66 -0
  157. package/lib/widget/rule-cms-widget.component.d.ts.map +1 -0
  158. package/lib/widget/rule-cms-widget.styles.d.ts +9 -0
  159. package/lib/widget/rule-cms-widget.styles.d.ts.map +1 -0
  160. package/lib/widget/widget-data.types.d.ts +47 -0
  161. package/lib/widget/widget-data.types.d.ts.map +1 -0
  162. package/package.json +43 -0
  163. package/public-api.d.ts +22 -0
  164. package/public-api.d.ts.map +1 -0
  165. package/rulecms-widget-angular.d.ts.map +1 -0
package/index.d.ts ADDED
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Generated bundle index. Do not edit.
3
+ */
4
+ /// <amd-module name="@rulecms/widget-angular" />
5
+ export * from './public-api';
6
+ //# sourceMappingURL=rulecms-widget-angular.d.ts.map
@@ -0,0 +1,23 @@
1
+ import { RuleCMSWidgetData } from '../widget/widget-data.types';
2
+ export interface FetchRuleCMSWidgetParams {
3
+ /**
4
+ * Published key for staging/production tokens, or the live widget key when
5
+ * using a `dev.`-prefixed Development token.
6
+ */
7
+ publishedKey: string;
8
+ token: string;
9
+ /**
10
+ * Optional API origin override. Omit in apps — defaults to rulecms.com for
11
+ * `dev.` tokens and widget-cache for published tokens.
12
+ */
13
+ endpoint?: string;
14
+ fetchOptions?: RequestInit;
15
+ }
16
+ export declare class FetchRuleCMSWidgetError extends Error {
17
+ readonly status?: number;
18
+ constructor(message: string, status?: number);
19
+ }
20
+ /** Fetch widget JSON on the server (or at build time) and return render-ready data. */
21
+ export declare function fetchRuleCMSWidget(params: FetchRuleCMSWidgetParams): Promise<RuleCMSWidgetData>;
22
+ export type { RuleCMSWidgetData };
23
+ //# sourceMappingURL=fetch-rule-cms-widget.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fetch-rule-cms-widget.d.ts","sourceRoot":"","sources":["../../../src/lib/fetch/fetch-rule-cms-widget.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAGhE,MAAM,WAAW,wBAAwB;IACvC;;;OAGG;IACH,YAAY,EAAE,MAAM,CAAC;IACrB,KAAK,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,WAAW,CAAC;CAC5B;AAED,qBAAa,uBAAwB,SAAQ,KAAK;IAChD,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;gBAEb,OAAO,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM;CAK7C;AAED,uFAAuF;AACvF,wBAAsB,kBAAkB,CACtC,MAAM,EAAE,wBAAwB,GAC/B,OAAO,CAAC,iBAAiB,CAAC,CAmC5B;AAED,YAAY,EAAE,iBAAiB,EAAE,CAAC"}
@@ -0,0 +1,16 @@
1
+ import { LibraryRegistrationMap, SourceComponentsPlugin } from '../library-registry/types';
2
+ import { RuleCMSWidgetData } from '../widget/widget-data.types';
3
+ export interface ResolveWidgetLibrariesParams {
4
+ data: RuleCMSWidgetData;
5
+ libraries: LibraryRegistrationMap;
6
+ }
7
+ /**
8
+ * Server-side resolve helper: loads only the component libraries the given
9
+ * widget config references and returns the composed plugin.
10
+ *
11
+ * The result contains Angular component classes and must not be serialized
12
+ * across a process boundary. For pre-fetched SSR pages, register eagerly
13
+ * imported modules via `RuleCMSWidgetProvider` / inputs instead.
14
+ */
15
+ export declare function resolveWidgetLibraries(params: ResolveWidgetLibrariesParams): Promise<SourceComponentsPlugin>;
16
+ //# sourceMappingURL=resolve-widget-libraries.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resolve-widget-libraries.d.ts","sourceRoot":"","sources":["../../../src/lib/fetch/resolve-widget-libraries.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,sBAAsB,EACtB,sBAAsB,EACvB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAEhE,MAAM,WAAW,4BAA4B;IAC3C,IAAI,EAAE,iBAAiB,CAAC;IACxB,SAAS,EAAE,sBAAsB,CAAC;CACnC;AAED;;;;;;;GAOG;AACH,wBAAsB,sBAAsB,CAC1C,MAAM,EAAE,4BAA4B,GACnC,OAAO,CAAC,sBAAsB,CAAC,CAQjC"}
@@ -0,0 +1,24 @@
1
+ import { CssVariableCarrier, CssVariableValue } from './css-variable-types';
2
+ /**
3
+ * Stored background image leaf.
4
+ *
5
+ * `cloudinary` is what the composer's media picker writes — a public id, the
6
+ * same thing every other image attribute stores, so the asset stays resolvable
7
+ * if delivery URLs ever change. `url` covers an image hosted elsewhere. `none`
8
+ * explicitly clears a background that a component default supplied, which an
9
+ * absent attribute cannot express.
10
+ */
11
+ export type BackgroundImageLiteralValue = {
12
+ source: 'cloudinary';
13
+ publicId: string;
14
+ cloudName?: string;
15
+ transformations?: string;
16
+ } | {
17
+ source: 'url';
18
+ url: string;
19
+ } | {
20
+ source: 'none';
21
+ };
22
+ export type BackgroundImageValue = (BackgroundImageLiteralValue & CssVariableCarrier) | CssVariableValue;
23
+ export declare const isBackgroundImageValue: (value: unknown) => value is BackgroundImageValue;
24
+ //# sourceMappingURL=background-image-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"background-image-types.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/background-image-types.ts"],"names":[],"mappings":"AAMA,OAAO,EACL,kBAAkB,EAClB,gBAAgB,EAGjB,MAAM,sBAAsB,CAAC;AAE9B;;;;;;;;GAQG;AACH,MAAM,MAAM,2BAA2B,GACnC;IACE,MAAM,EAAE,YAAY,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B,GACD;IAAE,MAAM,EAAE,KAAK,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,GAC9B;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC;AAEvB,MAAM,MAAM,oBAAoB,GAC5B,CAAC,2BAA2B,GAAG,kBAAkB,CAAC,GAClD,gBAAgB,CAAC;AAErB,eAAO,MAAM,sBAAsB,UAAW,OAAO,KAAG,KAAK,IAAI,oBAiDhE,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { SpacingSideValue } from './box-spacing-types';
2
+ import { CssColorValue } from './css-color-types';
3
+ import { CssVariableName, CssVariableValue } from './css-variable-types';
4
+ export type BorderStyleKeyword = 'none' | 'solid' | 'dashed' | 'dotted' | 'double' | 'groove' | 'ridge' | 'inset' | 'outset';
5
+ export declare const borderStyleKeywords: BorderStyleKeyword[];
6
+ /**
7
+ * Uniform border leaf. Emit longhands only (borderWidth/Style/Color) — never
8
+ * the `border` shorthand — so React does not warn when styles are merged
9
+ * (see rulecms PATTERN_CSS_BORDER_STYLE_PROPERTIES.md). The one exception is a
10
+ * leaf-level `cssVariable`: design systems ship whole-border tokens like
11
+ * `--border-hairline: 1px solid #ddd`, which cannot be split into longhands, so
12
+ * that case emits the `border` shorthand and nothing else.
13
+ */
14
+ export type BorderValue = {
15
+ width?: SpacingSideValue;
16
+ style?: BorderStyleKeyword | CssVariableValue;
17
+ color?: CssColorValue;
18
+ cssVariable?: CssVariableName;
19
+ };
20
+ export declare const isBorderStyleValue: (value: unknown) => boolean;
21
+ export declare const isBorderValue: (value: unknown) => value is BorderValue;
22
+ //# sourceMappingURL=border-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"border-types.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/border-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsB,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC3E,OAAO,EAAE,aAAa,EAAmB,MAAM,mBAAmB,CAAC;AACnE,OAAO,EACL,eAAe,EACf,gBAAgB,EAGjB,MAAM,sBAAsB,CAAC;AAE9B,MAAM,MAAM,kBAAkB,GAC1B,MAAM,GACN,OAAO,GACP,QAAQ,GACR,QAAQ,GACR,QAAQ,GACR,QAAQ,GACR,OAAO,GACP,OAAO,GACP,QAAQ,CAAC;AAEb,eAAO,MAAM,mBAAmB,EAAE,kBAAkB,EAUnD,CAAC;AAEF;;;;;;;GAOG;AACH,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,CAAC,EAAE,gBAAgB,CAAC;IACzB,KAAK,CAAC,EAAE,kBAAkB,GAAG,gBAAgB,CAAC;IAC9C,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB,WAAW,CAAC,EAAE,eAAe,CAAC;CAC/B,CAAC;AAEF,eAAO,MAAM,kBAAkB,UAAW,OAAO,KAAG,OAKnD,CAAC;AAEF,eAAO,MAAM,aAAa,UAAW,OAAO,KAAG,KAAK,IAAI,WAgCvD,CAAC"}
@@ -0,0 +1,25 @@
1
+ import { SpacingSideValue } from './box-spacing-types';
2
+ import { CssColorValue } from './css-color-types';
3
+ import { CssVariableName } from './css-variable-types';
4
+ /**
5
+ * One box-shadow leaf. Missing lengths render as 0px so a partially filled
6
+ * value still produces a shadow. `inset` flips the shadow inside the box. A
7
+ * leaf-level `cssVariable` names a whole-shadow design token (the usual way
8
+ * shadows are tokenised) and wins over every part.
9
+ */
10
+ export type BoxShadowValue = {
11
+ offsetX?: SpacingSideValue;
12
+ offsetY?: SpacingSideValue;
13
+ blur?: SpacingSideValue;
14
+ spread?: SpacingSideValue;
15
+ color?: CssColorValue;
16
+ inset?: boolean;
17
+ cssVariable?: CssVariableName;
18
+ };
19
+ export declare const isBoxShadowValue: (value: unknown) => value is BoxShadowValue;
20
+ /**
21
+ * A leaf renders a shadow only when at least one length or the color is set;
22
+ * `inset` alone describes nothing visible.
23
+ */
24
+ export declare const hasBoxShadowLeaf: (value?: BoxShadowValue) => boolean;
25
+ //# sourceMappingURL=box-shadow-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"box-shadow-types.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/box-shadow-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsB,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAC3E,OAAO,EAAE,aAAa,EAAmB,MAAM,mBAAmB,CAAC;AACnE,OAAO,EACL,eAAe,EAGhB,MAAM,sBAAsB,CAAC;AAiB9B;;;;;GAKG;AACH,MAAM,MAAM,cAAc,GAAG;IAC3B,OAAO,CAAC,EAAE,gBAAgB,CAAC;IAC3B,OAAO,CAAC,EAAE,gBAAgB,CAAC;IAC3B,IAAI,CAAC,EAAE,gBAAgB,CAAC;IACxB,MAAM,CAAC,EAAE,gBAAgB,CAAC;IAC1B,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,WAAW,CAAC,EAAE,eAAe,CAAC;CAC/B,CAAC;AAEF,eAAO,MAAM,gBAAgB,UAAW,OAAO,KAAG,KAAK,IAAI,cAkD1D,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,gBAAgB,WAAY,cAAc,KAAG,OAezD,CAAC"}
@@ -0,0 +1,4 @@
1
+ export declare const boxSpacingStyleAttributeEntries: {
2
+ [attributeName: string]: string;
3
+ };
4
+ //# sourceMappingURL=box-spacing-style-attribute-entries.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"box-spacing-style-attribute-entries.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/box-spacing-style-attribute-entries.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,+BAA+B,EAAE;IAAE,CAAC,aAAa,EAAE,MAAM,GAAG,MAAM,CAAA;CAQ5E,CAAC"}
@@ -0,0 +1,31 @@
1
+ import { CssVariableCarrier, CssVariableValue } from './css-variable-types';
2
+ export type SpacingLengthUnit = 'px' | '%' | 'em' | 'rem' | 'vh' | 'vw';
3
+ export declare const spacingLengthUnits: SpacingLengthUnit[];
4
+ export type SpacingKeyword = 'inherit' | 'unset';
5
+ export declare const spacingKeywords: SpacingKeyword[];
6
+ export type SpacingSideLiteralValue = {
7
+ unit: 'auto';
8
+ } | {
9
+ unit: 'keyword';
10
+ keyword: SpacingKeyword;
11
+ } | {
12
+ unit: SpacingLengthUnit;
13
+ value: number;
14
+ };
15
+ export type SpacingSideValue = (SpacingSideLiteralValue & CssVariableCarrier) | CssVariableValue;
16
+ export type BoxSpacingValue = {
17
+ allSides?: SpacingSideValue;
18
+ top?: SpacingSideValue;
19
+ right?: SpacingSideValue;
20
+ bottom?: SpacingSideValue;
21
+ left?: SpacingSideValue;
22
+ };
23
+ export type SpacingCapabilities = {
24
+ allowAuto?: boolean;
25
+ allowKeywords?: boolean;
26
+ allowNegative?: boolean;
27
+ };
28
+ export declare const boxSpacingSideKeys: readonly ["allSides", "top", "right", "bottom", "left"];
29
+ export declare const isSpacingSideValue: (value: unknown, capabilities?: SpacingCapabilities) => value is SpacingSideValue;
30
+ export declare const isBoxSpacingValue: (value: unknown, capabilities?: SpacingCapabilities) => value is BoxSpacingValue;
31
+ //# sourceMappingURL=box-spacing-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"box-spacing-types.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/box-spacing-types.ts"],"names":[],"mappings":"AAKA,OAAO,EACL,kBAAkB,EAClB,gBAAgB,EAGjB,MAAM,sBAAsB,CAAC;AAE9B,MAAM,MAAM,iBAAiB,GAAG,IAAI,GAAG,GAAG,GAAG,IAAI,GAAG,KAAK,GAAG,IAAI,GAAG,IAAI,CAAC;AAExE,eAAO,MAAM,kBAAkB,EAAE,iBAAiB,EAAyC,CAAC;AAK5F,MAAM,MAAM,cAAc,GAAG,SAAS,GAAG,OAAO,CAAC;AAEjD,eAAO,MAAM,eAAe,EAAE,cAAc,EAAyB,CAAC;AAEtE,MAAM,MAAM,uBAAuB,GAC/B;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,GAChB;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,OAAO,EAAE,cAAc,CAAA;CAAE,GAC5C;IAAE,IAAI,EAAE,iBAAiB,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAE/C,MAAM,MAAM,gBAAgB,GACxB,CAAC,uBAAuB,GAAG,kBAAkB,CAAC,GAC9C,gBAAgB,CAAC;AAErB,MAAM,MAAM,eAAe,GAAG;IAC5B,QAAQ,CAAC,EAAE,gBAAgB,CAAC;IAC5B,GAAG,CAAC,EAAE,gBAAgB,CAAC;IACvB,KAAK,CAAC,EAAE,gBAAgB,CAAC;IACzB,MAAM,CAAC,EAAE,gBAAgB,CAAC;IAC1B,IAAI,CAAC,EAAE,gBAAgB,CAAC;CACzB,CAAC;AAIF,MAAM,MAAM,mBAAmB,GAAG;IAChC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB,CAAC;AAEF,eAAO,MAAM,kBAAkB,yDAA0D,CAAC;AAE1F,eAAO,MAAM,kBAAkB,UACtB,OAAO,iBACA,mBAAmB,KAChC,KAAK,IAAI,gBAsCX,CAAC;AAKF,eAAO,MAAM,iBAAiB,UACrB,OAAO,iBACA,mBAAmB,KAChC,KAAK,IAAI,eAeX,CAAC"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * A Cloudinary transformation component as an object, e.g.
3
+ * `{ c: 'fill', g: 'auto' }` serializes to `c_fill,g_auto`.
4
+ */
5
+ export type CloudinaryTransformations = {
6
+ [key: string]: string | number;
7
+ };
8
+ /** The cloud that hosts both team uploads and the shared RuleCMS library. */
9
+ export declare const DEFAULT_CLOUDINARY_CLOUD_NAME = "rulecms";
10
+ export declare const isCloudinaryPublicId: (value: unknown) => value is string;
11
+ export declare const isCloudinaryCloudName: (value: unknown) => value is string;
12
+ export declare const isSafeImageUrl: (value: unknown) => value is string;
13
+ export declare const isCloudinaryTransformationString: (value: unknown) => value is string;
14
+ export declare const buildCloudinaryBackgroundUrl: ({ publicId, cloudName, transformations, width, }: {
15
+ publicId: string;
16
+ cloudName?: string;
17
+ transformations?: CloudinaryTransformations | string;
18
+ width?: number;
19
+ }) => string;
20
+ //# sourceMappingURL=cloudinary-image-url.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cloudinary-image-url.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/cloudinary-image-url.ts"],"names":[],"mappings":"AASA;;;GAGG;AACH,MAAM,MAAM,yBAAyB,GAAG;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAAA;CAAE,CAAC;AAE3E,6EAA6E;AAC7E,eAAO,MAAM,6BAA6B,YAAY,CAAC;AAiCvD,eAAO,MAAM,oBAAoB,UAAW,OAAO,KAAG,KAAK,IAAI,MAGrB,CAAC;AAE3C,eAAO,MAAM,qBAAqB,UAAW,OAAO,KAAG,KAAK,IAAI,MAGrB,CAAC;AAE5C,eAAO,MAAM,cAAc,UAAW,OAAO,KAAG,KAAK,IAAI,MAGrB,CAAC;AAErC,eAAO,MAAM,gCAAgC,UAAW,OAAO,KAAG,KAAK,IAAI,MAGhC,CAAC;AAuB5C,eAAO,MAAM,4BAA4B,qDAKtC;IACD,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,yBAAyB,GAAG,MAAM,CAAC;IACrD,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,KAAG,MAmBH,CAAC"}
@@ -0,0 +1,16 @@
1
+ import { Items, WidgetCollection } from './types';
2
+ /**
3
+ * Every component instance in a config, as the `/`-joined column-id path that
4
+ * `componentProps` keys are matched against. Collections contribute their
5
+ * holding column to the path rather than a path of their own.
6
+ *
7
+ * Only used to tell a host that a key it supplied addresses nothing; the
8
+ * render path resolves props directly and never needs this list.
9
+ */
10
+ export declare function collectComponentInstancePaths({ displayItemList, widgetCollections, }: {
11
+ displayItemList: Items | undefined;
12
+ widgetCollections: {
13
+ [key: string]: WidgetCollection;
14
+ } | undefined;
15
+ }): string[];
16
+ //# sourceMappingURL=collect-component-instance-paths.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"collect-component-instance-paths.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/collect-component-instance-paths.ts"],"names":[],"mappings":"AAEA,OAAO,EAAoB,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEpE;;;;;;;GAOG;AACH,wBAAgB,6BAA6B,CAAC,EAC5C,eAAe,EACf,iBAAiB,GAClB,EAAE;IACD,eAAe,EAAE,KAAK,GAAG,SAAS,CAAC;IACnC,iBAAiB,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,gBAAgB,CAAA;KAAE,GAAG,SAAS,CAAC;CACpE,GAAG,MAAM,EAAE,CAoCX"}
@@ -0,0 +1,5 @@
1
+ export declare const defaultPageWidth = "1200px";
2
+ export declare const phoneModeWidth = "500px";
3
+ export declare const tabletModeWidth = "820px";
4
+ export declare const desktopModeWidth = "1200px";
5
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/constants.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,gBAAgB,WAAW,CAAC;AACzC,eAAO,MAAM,cAAc,UAAU,CAAC;AACtC,eAAO,MAAM,eAAe,UAAU,CAAC;AACvC,eAAO,MAAM,gBAAgB,WAAmB,CAAC"}
@@ -0,0 +1,13 @@
1
+ export declare const CSS_CLASSES_ATTRIBUTE_NAME = "css-classes-3-resolutions";
2
+ /**
3
+ * Untrusted leaf from a persisted payload -> a safe class string, or undefined.
4
+ *
5
+ * This is a passthrough, not a validator: RuleCMS forms no opinion about what a
6
+ * host app's class names look like, so tokens are never checked against a
7
+ * pattern. The only work done here is hygiene — whitespace, de-duplication,
8
+ * and a length cap — so the same string can be trusted to sit in a `className`
9
+ * attribute. Never throws and never logs; anything that isn't a non-empty
10
+ * string after normalization becomes `undefined`.
11
+ */
12
+ export declare const normalizeCssClasses: (value: unknown) => string | undefined;
13
+ //# sourceMappingURL=css-classes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"css-classes.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/css-classes.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,0BAA0B,8BAA8B,CAAC;AAOtE;;;;;;;;;GASG;AACH,eAAO,MAAM,mBAAmB,UAAW,OAAO,KAAG,MAAM,GAAG,SAoC7D,CAAC"}
@@ -0,0 +1,18 @@
1
+ import { SpacingKeyword } from './box-spacing-types';
2
+ import { CssVariableCarrier, CssVariableValue } from './css-variable-types';
3
+ /**
4
+ * Stored color leaf for style attributes. Prefer structured keywords so the
5
+ * editor can pick them; allow a validated CSS color string for hex/rgb/hsl, or
6
+ * a design token from the embedding application.
7
+ */
8
+ export type CssColorLiteralValue = {
9
+ unit: 'keyword';
10
+ keyword: SpacingKeyword | 'transparent' | 'currentColor';
11
+ } | {
12
+ unit: 'color';
13
+ value: string;
14
+ };
15
+ export type CssColorValue = (CssColorLiteralValue & CssVariableCarrier) | CssVariableValue;
16
+ export declare const isCssColorValue: (value: unknown) => value is CssColorValue;
17
+ export declare const formatCssColorValue: (value: CssColorValue) => string;
18
+ //# sourceMappingURL=css-color-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"css-color-types.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/css-color-types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAmB,MAAM,qBAAqB,CAAC;AACtE,OAAO,EACL,kBAAkB,EAClB,gBAAgB,EAIjB,MAAM,sBAAsB,CAAC;AAE9B;;;;GAIG;AACH,MAAM,MAAM,oBAAoB,GAC5B;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,OAAO,EAAE,cAAc,GAAG,aAAa,GAAG,cAAc,CAAA;CAAE,GAC7E;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAErC,MAAM,MAAM,aAAa,GAAG,CAAC,oBAAoB,GAAG,kBAAkB,CAAC,GAAG,gBAAgB,CAAC;AAQ3F,eAAO,MAAM,eAAe,UAAW,OAAO,KAAG,KAAK,IAAI,aAwBzD,CAAC;AAEF,eAAO,MAAM,mBAAmB,UAAW,aAAa,KAAG,MAY1D,CAAC"}
@@ -0,0 +1,41 @@
1
+ import { CssVariableValue } from './css-variable-types';
2
+ /**
3
+ * Enum-style leaf: a value from the attribute's allowlist, a CSS-wide keyword,
4
+ * or a design token from the embedding application. Allowlist values stay plain
5
+ * strings for picker-friendly editors; a token has no string form to share with
6
+ * them, so it arrives as `{ cssVariable }`.
7
+ */
8
+ export type CssEnumValue = string | CssVariableValue;
9
+ export declare const isCssEnumValue: (value: unknown, allowedValues: readonly string[]) => value is CssEnumValue;
10
+ export declare const fontFamilyAllowlist: readonly ["system-ui, -apple-system, BlinkMacSystemFont, \"Segoe UI\", sans-serif", "Georgia, \"Times New Roman\", Times, serif", "ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace", "Arial, Helvetica, sans-serif", "\"Helvetica Neue\", Helvetica, Arial, sans-serif", "Verdana, Geneva, sans-serif"];
11
+ export declare const fontWeightAllowlist: readonly ["normal", "bold", "100", "200", "300", "400", "500", "600", "700", "800", "900"];
12
+ export declare const fontStyleAllowlist: readonly ["normal", "italic", "oblique"];
13
+ export declare const textAlignAllowlist: readonly ["left", "center", "right", "justify", "start", "end"];
14
+ export declare const textDecorationAllowlist: readonly ["none", "underline", "line-through", "overline"];
15
+ export declare const textTransformAllowlist: readonly ["none", "uppercase", "lowercase", "capitalize"];
16
+ /** Shared by overflow / overflow-x / overflow-y. */
17
+ export declare const overflowAllowlist: readonly ["visible", "hidden", "scroll", "auto", "clip"];
18
+ /** Column flex layout — matches row Horizontal Alignment options. */
19
+ export declare const justifyContentAllowlist: readonly ["flex-start", "flex-end", "center", "space-between", "space-around", "space-evenly"];
20
+ /** Column flex layout — matches row Vertical Alignment options. */
21
+ export declare const alignItemsAllowlist: readonly ["flex-start", "flex-end", "center", "baseline", "stretch"];
22
+ export declare const flexWrapAllowlist: readonly ["wrap", "nowrap"];
23
+ /** Column flex layout — matches row Align Content options. */
24
+ export declare const alignContentAllowlist: readonly ["flex-start", "flex-end", "center", "space-between", "space-around", "space-evenly", "stretch"];
25
+ export declare const flexDirectionAllowlist: readonly ["row", "row-reverse", "column", "column-reverse"];
26
+ /**
27
+ * Background painting, set alongside background-image. Keyword-only: a
28
+ * background without `cover`/`center` usually reads as broken, and these are the
29
+ * choices that fix it. Lengths and percentages are deliberately out of scope so
30
+ * the editor stays a picker.
31
+ */
32
+ export declare const backgroundSizeAllowlist: readonly ["cover", "contain", "auto"];
33
+ export declare const backgroundPositionAllowlist: readonly ["center center", "center top", "center bottom", "left center", "left top", "left bottom", "right center", "right top", "right bottom"];
34
+ export declare const backgroundRepeatAllowlist: readonly ["no-repeat", "repeat", "repeat-x", "repeat-y", "space", "round"];
35
+ /**
36
+ * Style keys that, when present on the flattened column styles, cause
37
+ * `display: flex` to be derived at render time. Gap alone is intentionally
38
+ * excluded — it does not force flex.
39
+ */
40
+ export declare const FLEX_LAYOUT_STYLE_KEYS_THAT_DERIVE_DISPLAY: readonly ["justifyContent", "alignItems", "flexWrap", "alignContent", "flexDirection"];
41
+ //# sourceMappingURL=css-enum-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"css-enum-types.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/css-enum-types.ts"],"names":[],"mappings":"AACA,OAAO,EACL,gBAAgB,EAGjB,MAAM,sBAAsB,CAAC;AAE9B;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,gBAAgB,CAAC;AAErD,eAAO,MAAM,cAAc,UAClB,OAAO,iBACC,SAAS,MAAM,EAAE,KAC/B,KAAK,IAAI,YAWX,CAAC;AAGF,eAAO,MAAM,mBAAmB,0TAOtB,CAAC;AAEX,eAAO,MAAM,mBAAmB,4FAYtB,CAAC;AAEX,eAAO,MAAM,kBAAkB,0CAA2C,CAAC;AAE3E,eAAO,MAAM,kBAAkB,iEAOrB,CAAC;AAEX,eAAO,MAAM,uBAAuB,4DAK1B,CAAC;AAEX,eAAO,MAAM,sBAAsB,2DAKzB,CAAC;AAEX,oDAAoD;AACpD,eAAO,MAAM,iBAAiB,0DAMpB,CAAC;AAEX,qEAAqE;AACrE,eAAO,MAAM,uBAAuB,gGAO1B,CAAC;AAEX,mEAAmE;AACnE,eAAO,MAAM,mBAAmB,sEAMtB,CAAC;AAEX,eAAO,MAAM,iBAAiB,6BAA8B,CAAC;AAE7D,8DAA8D;AAC9D,eAAO,MAAM,qBAAqB,2GAQxB,CAAC;AAEX,eAAO,MAAM,sBAAsB,6DAKzB,CAAC;AAEX;;;;;GAKG;AACH,eAAO,MAAM,uBAAuB,uCAAwC,CAAC;AAE7E,eAAO,MAAM,2BAA2B,kJAU9B,CAAC;AAEX,eAAO,MAAM,yBAAyB,4EAO5B,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,0CAA0C,wFAM7C,CAAC"}
@@ -0,0 +1,33 @@
1
+ /** A bare custom property name, e.g. `--brand-space-md`. */
2
+ export type CssVariableName = string;
3
+ export declare const CSS_VARIABLE_NAME_PATTERN: RegExp;
4
+ export declare const CSS_VARIABLE_NAME_MAX_LENGTH = 200;
5
+ /** Mix-in for leaves that also carry a literal value. */
6
+ export type CssVariableCarrier = {
7
+ cssVariable?: CssVariableName;
8
+ };
9
+ /** Leaf that is only a token — nothing literal has been entered yet. */
10
+ export type CssVariableValue = {
11
+ cssVariable: CssVariableName;
12
+ };
13
+ export declare const isCssVariableName: (value: unknown) => value is CssVariableName;
14
+ /** `--brand-space-md` → `var(--brand-space-md)` */
15
+ export declare const formatCssVariable: (name: CssVariableName) => string;
16
+ /**
17
+ * Reads the token off any leaf shape. Returns undefined when the leaf carries
18
+ * no token; `null` counts as absent the same way it does elsewhere in this
19
+ * pipeline.
20
+ */
21
+ export declare const getCssVariableFromLeaf: (leaf: unknown) => CssVariableName | undefined;
22
+ /**
23
+ * True when a leaf declares a `cssVariable` that fails validation. Such leaves
24
+ * are rejected outright instead of silently falling back to the literal value:
25
+ * a typo in a token should drop the property, not resurrect a number the user
26
+ * thought they had replaced.
27
+ */
28
+ export declare const hasInvalidCssVariable: (leaf: unknown) => boolean;
29
+ /** One React style entry from a leaf's token, or undefined when it has none. */
30
+ export declare const formatCssVariableStyles: (leaf: unknown, cssProperty: string) => {
31
+ [styleKey: string]: string;
32
+ } | undefined;
33
+ //# sourceMappingURL=css-variable-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"css-variable-types.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/css-variable-types.ts"],"names":[],"mappings":"AAaA,4DAA4D;AAC5D,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC;AAErC,eAAO,MAAM,yBAAyB,QAAuB,CAAC;AAI9D,eAAO,MAAM,4BAA4B,MAAM,CAAC;AAEhD,yDAAyD;AACzD,MAAM,MAAM,kBAAkB,GAAG;IAAE,WAAW,CAAC,EAAE,eAAe,CAAA;CAAE,CAAC;AAEnE,wEAAwE;AACxE,MAAM,MAAM,gBAAgB,GAAG;IAAE,WAAW,EAAE,eAAe,CAAA;CAAE,CAAC;AAEhE,eAAO,MAAM,iBAAiB,UAAW,OAAO,KAAG,KAAK,IAAI,eAQ3D,CAAC;AAEF,mDAAmD;AACnD,eAAO,MAAM,iBAAiB,SAAU,eAAe,KAAG,MAA+B,CAAC;AAE1F;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,SAAU,OAAO,KAAG,eAAe,GAAG,SASxE,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,qBAAqB,SAAU,OAAO,KAAG,OASrD,CAAC;AAEF,gFAAgF;AAChF,eAAO,MAAM,uBAAuB,SAC5B,OAAO,eACA,MAAM,KAClB;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CAAE,GAAG,SAGnC,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * When a column has any flex-layout style (justify-content, align-items,
3
+ * flex-wrap, align-content, flex-direction), ensure `display: flex` so those
4
+ * properties take effect. Gap alone does not force flex.
5
+ *
6
+ * Pure / non-mutating: returns a new object when display is added.
7
+ */
8
+ export declare const deriveDisplayFlexIfNeeded: (styles: {
9
+ [key: string]: unknown;
10
+ } | undefined) => {
11
+ [key: string]: unknown;
12
+ };
13
+ //# sourceMappingURL=derive-display-flex-if-needed.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"derive-display-flex-if-needed.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/derive-display-flex-if-needed.ts"],"names":[],"mappings":"AAKA;;;;;;GAMG;AACH,eAAO,MAAM,yBAAyB,WAC5B;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;CAAE,GAAG,SAAS,KAC7C;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;CAkB1B,CAAC"}
@@ -0,0 +1,12 @@
1
+ /**
2
+ * One validated background image leaf into a `backgroundImage` style entry.
3
+ * Returns {} for anything malformed so an old or hand-edited payload drops the
4
+ * property rather than throwing inside a customer's app.
5
+ *
6
+ * The guard has already rejected anything that could close the `url()` call or
7
+ * its quotes, so the value is safe to interpolate.
8
+ */
9
+ export declare const formatBackgroundImageStyles: (value: unknown) => {
10
+ [styleKey: string]: string;
11
+ };
12
+ //# sourceMappingURL=format-background-image-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-background-image-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-background-image-styles.ts"],"names":[],"mappings":"AAOA;;;;;;;GAOG;AACH,eAAO,MAAM,2BAA2B,UAC/B,OAAO,KACb;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CA4B9B,CAAC"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Border object → longhand React style keys only. Malformed values return {}.
3
+ * A whole-border design token is the sole shorthand case: it emits `border`
4
+ * alone, so shorthand and longhands never land in the same style object.
5
+ */
6
+ export declare const formatBorderStyles: (value: unknown) => {
7
+ [styleKey: string]: string;
8
+ };
9
+ //# sourceMappingURL=format-border-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-border-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-border-styles.ts"],"names":[],"mappings":"AAKA;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,UAAW,OAAO,KAAG;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CAsB/E,CAAC"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Box-shadow object → the boxShadow style key. Missing lengths default to
3
+ * 0px so a partially filled leaf still renders. Malformed values return {}.
4
+ */
5
+ export declare const formatBoxShadowStyles: (value: unknown) => {
6
+ [styleKey: string]: string;
7
+ };
8
+ //# sourceMappingURL=format-box-shadow-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-box-shadow-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-box-shadow-styles.ts"],"names":[],"mappings":"AASA;;;GAGG;AACH,eAAO,MAAM,qBAAqB,UAAW,OAAO,KAAG;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CAuBlF,CAAC"}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Converts a stored box-spacing object into React style entries for the given
3
+ * CSS property, e.g. formatBoxSpacingStyles(value, 'margin') returns
4
+ * { margin } (when allSides is set) or { marginTop, marginRight, ... } for the
5
+ * sides that are defined. Invalid/malformed values return {} so old or
6
+ * corrupted payloads degrade gracefully instead of crashing the renderer.
7
+ */
8
+ export declare const formatBoxSpacingStyles: (value: unknown, cssProperty: string) => {
9
+ [styleKey: string]: string;
10
+ };
11
+ //# sourceMappingURL=format-box-spacing-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-box-spacing-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-box-spacing-styles.ts"],"names":[],"mappings":"AAKA;;;;;;GAMG;AACH,eAAO,MAAM,sBAAsB,UAC1B,OAAO,eACD,MAAM,KAClB;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CAmB9B,CAAC"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Color leaf → one React style entry (backgroundColor, color, ...).
3
+ * Malformed values return {}.
4
+ */
5
+ export declare const formatCssColorStyles: (value: unknown, cssProperty: string) => {
6
+ [styleKey: string]: string;
7
+ };
8
+ //# sourceMappingURL=format-css-color-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-css-color-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-css-color-styles.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,eAAO,MAAM,oBAAoB,UACxB,OAAO,eACD,MAAM,KAClB;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CAK9B,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Enum / keyword leaf → one React style entry. Malformed values return {}.
3
+ */
4
+ export declare const formatCssEnumStyles: (value: unknown, cssProperty: string, allowedValues: readonly string[]) => {
5
+ [styleKey: string]: string;
6
+ };
7
+ //# sourceMappingURL=format-css-enum-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-css-enum-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-css-enum-styles.ts"],"names":[],"mappings":"AAGA;;GAEG;AACH,eAAO,MAAM,mBAAmB,UACvB,OAAO,eACD,MAAM,iBACJ,SAAS,MAAM,EAAE,KAC/B;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CAS9B,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { SpacingCapabilities } from './box-spacing-types';
2
+ /**
3
+ * Single length/keyword leaf → one React style entry
4
+ * (width, height, gap, borderRadius, ...). Malformed values return {}.
5
+ */
6
+ export declare const formatCssLengthStyles: (value: unknown, cssProperty: string, capabilities?: SpacingCapabilities) => {
7
+ [styleKey: string]: string;
8
+ };
9
+ //# sourceMappingURL=format-css-length-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-css-length-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-css-length-styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAsB,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAG9E;;;GAGG;AACH,eAAO,MAAM,qBAAqB,UACzB,OAAO,eACD,MAAM,iBACL,mBAAmB,KAChC;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;CAK9B,CAAC"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Line-height leaf → React `lineHeight` (number for unitless, string for lengths
3
+ * and design tokens).
4
+ */
5
+ export declare const formatLineHeightStyles: (value: unknown) => {
6
+ [styleKey: string]: string | number;
7
+ };
8
+ //# sourceMappingURL=format-line-height-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-line-height-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-line-height-styles.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,eAAO,MAAM,sBAAsB,UAC1B,OAAO,KACb;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAAA;CAYvC,CAAC"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Opacity leaf is a finite number in [0, 1] or a design token.
3
+ * Malformed values return {}.
4
+ */
5
+ export declare const formatOpacityStyles: (value: unknown) => {
6
+ [styleKey: string]: string | number;
7
+ };
8
+ //# sourceMappingURL=format-opacity-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-opacity-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-opacity-styles.ts"],"names":[],"mappings":"AAGA;;;GAGG;AACH,eAAO,MAAM,mBAAmB,UAAW,OAAO,KAAG;IAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAAA;CASzF,CAAC"}
@@ -0,0 +1,4 @@
1
+ import { SpacingSideValue } from './box-spacing-types';
2
+ /** Formats one validated SpacingSideValue into a CSS length/keyword string. */
3
+ export declare const formatSpacingSideValue: (side: SpacingSideValue) => string;
4
+ //# sourceMappingURL=format-spacing-side-value.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"format-spacing-side-value.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/format-spacing-side-value.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAGvD,+EAA+E;AAC/E,eAAO,MAAM,sBAAsB,SAAU,gBAAgB,KAAG,MAe/D,CAAC"}
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Reads a column's persisted attribute map during the persisted-key
3
+ * migration from `widgetAttributes` to `componentAttributes`.
4
+ *
5
+ * Published payloads historically stored per-column attributes under
6
+ * `widgetAttributes`; the composer now writes `componentAttributes` for
7
+ * new/edited content while old payloads keep `widgetAttributes` forever.
8
+ * Every read of the persisted field must go through this helper so both
9
+ * generations of payloads render.
10
+ *
11
+ * Precedence is per-column and wholesale: when `componentAttributes` is
12
+ * present it wins outright — values from a stale `widgetAttributes` on the
13
+ * same column must NOT leak through, so there is no key-by-key merging.
14
+ */
15
+ export declare function getColumnAttributes(col: {
16
+ componentAttributes?: {
17
+ [key: string]: any;
18
+ };
19
+ /** @deprecated Legacy persisted field name; read as fallback only. */
20
+ widgetAttributes?: {
21
+ [key: string]: any;
22
+ };
23
+ }): {
24
+ [key: string]: any;
25
+ } | undefined;
26
+ //# sourceMappingURL=get-column-attributes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-column-attributes.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/get-column-attributes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAAE;IACvC,mBAAmB,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;IAC7C,sEAAsE;IACtE,gBAAgB,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;CAC3C,GAAG;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;CAAE,GAAG,SAAS,CAErC"}
@@ -0,0 +1,23 @@
1
+ import { DeviceDisplayTypes } from './types';
2
+ import { SourceComponentsPlugin } from '../library-registry/types';
3
+ interface GetComponentAttributesAndStylesParams {
4
+ col: {
5
+ componentAttributes?: any;
6
+ /** @deprecated Legacy persisted field name; componentAttributes wins when both are set. */
7
+ widgetAttributes?: any;
8
+ type: string;
9
+ libraryId?: string;
10
+ };
11
+ deviceDisplayType: keyof typeof DeviceDisplayTypes;
12
+ isComposeMode: boolean;
13
+ sourceComponentsPlugin: SourceComponentsPlugin;
14
+ }
15
+ interface GetComponentAttributesAndStylesResult {
16
+ componentAttributesBasedOnDevice: any;
17
+ componentStyles: {
18
+ [key: string]: any;
19
+ };
20
+ }
21
+ export declare function getComponentAttributesAndStyles({ col, deviceDisplayType, isComposeMode, sourceComponentsPlugin, }: GetComponentAttributesAndStylesParams): GetComponentAttributesAndStylesResult;
22
+ export {};
23
+ //# sourceMappingURL=get-component-attributes-and-styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-component-attributes-and-styles.d.ts","sourceRoot":"","sources":["../../../src/lib/helpers/get-component-attributes-and-styles.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAE7C,OAAO,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AAEnE,UAAU,qCAAqC;IAC7C,GAAG,EAAE;QAEH,mBAAmB,CAAC,EAAE,GAAG,CAAC;QAC1B,2FAA2F;QAC3F,gBAAgB,CAAC,EAAE,GAAG,CAAC;QACvB,IAAI,EAAE,MAAM,CAAC;QACb,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;IACF,iBAAiB,EAAE,MAAM,OAAO,kBAAkB,CAAC;IACnD,aAAa,EAAE,OAAO,CAAC;IACvB,sBAAsB,EAAE,sBAAsB,CAAC;CAChD;AAED,UAAU,qCAAqC;IAC7C,gCAAgC,EAAE,GAAG,CAAC;IACtC,eAAe,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;CACzC;AAED,wBAAgB,+BAA+B,CAAC,EAC9C,GAAG,EACH,iBAAiB,EACjB,aAAa,EACb,sBAAsB,GACvB,EAAE,qCAAqC,GAAG,qCAAqC,CA8D/E"}
@@ -0,0 +1,9 @@
1
+ import { SourceComponentsPlugin } from '../library-registry/types';
2
+ export declare const getDefaultDimensionAttributes: ({ dbEntryType, libraryId, sourceComponentsPlugin, }: {
3
+ dbEntryType: string | undefined;
4
+ libraryId?: string;
5
+ sourceComponentsPlugin: SourceComponentsPlugin;
6
+ }) => {
7
+ [x: string]: any;
8
+ } | undefined;
9
+ //# sourceMappingURL=get-default-dimension-attributes.d.ts.map