@orangelogic/design-system 2.197.0 → 2.198.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 (29) hide show
  1. package/library/chunks/{asset-link-format.B1YOFow9.js → asset-link-format.B_Im2jz7.js} +129 -128
  2. package/library/chunks/{color-swatch-group.C0BXFL4I.js → color-swatch-group.DyOxAUOC.js} +2 -2
  3. package/library/chunks/{document-viewer.C5IT7M61.js → document-viewer.CRuqeIIg.js} +2 -2
  4. package/library/chunks/{header.CWlWNree.js → header.Cbu_nxls.js} +1 -1
  5. package/library/chunks/{image.BSvc6eti.js → image.ZANuNTs8.js} +1 -1
  6. package/library/chunks/{toast.COzwhRI6.js → toast.hZJztBTm.js} +1 -1
  7. package/library/chunks/transformation.DHEr6Kf3.js +385 -0
  8. package/library/components/asset-link-format.js +2 -2
  9. package/library/components/atoms.js +3 -3
  10. package/library/components/color-swatch-group.js +3 -3
  11. package/library/components/document-viewer.js +2 -2
  12. package/library/components/header.js +1 -1
  13. package/library/components/image.js +1 -1
  14. package/library/components/masonry.js +1 -1
  15. package/library/components/organisms.js +2 -2
  16. package/library/components/types.js +13234 -13303
  17. package/library/components/video.js +1 -1
  18. package/library/package.json +1 -1
  19. package/library/packages/organisms/src/content-builder/blocks/image/image.d.ts +2 -0
  20. package/library/packages/organisms/src/content-builder/blocks/video/video.d.ts +1 -0
  21. package/library/packages/organisms/src/content-builder/components/config-manager/config-manager.d.ts +0 -25
  22. package/library/packages/organisms/src/content-builder/content-builder.d.ts +39 -25
  23. package/library/packages/organisms/src/content-builder/plugins/plugin-factory.d.ts +0 -5
  24. package/library/packages/types/src/content-builder.d.ts +0 -5
  25. package/library/packages/utils/src/transformation/transformation.d.ts +10 -29
  26. package/library/react-web-component.d.ts +6 -6
  27. package/library/utils.js +94 -95
  28. package/package.json +1 -1
  29. package/library/chunks/transformation.CkEA7Ymz.js +0 -392
@@ -1,7 +1,7 @@
1
1
  import { _ as kd, a as Sa, b as Be, c as Je } from "../chunks/inheritsLoose.BuSn_CvZ.js";
2
2
  import { c as ps, a as Bn } from "../chunks/_commonjsHelpers.DQNKXVTB.js";
3
3
  import { r as Sb } from "../chunks/___vite-browser-external_commonjs-proxy.C2tf3HsQ.js";
4
- import { C as Cb } from "../chunks/image.BSvc6eti.js";
4
+ import { C as Cb } from "../chunks/image.ZANuNTs8.js";
5
5
  import Mb from "./resize-observer.js";
6
6
  import { r as Db, R as Pb, a as Rp, b as Lb } from "../chunks/resizable-component.styles.CAfXABBc.js";
7
7
  import { c as Rb } from "../chunks/component.styles.CRO4Odto.js";
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@orangelogic/design-system",
3
3
  "type": "module",
4
- "version": "2.197.0",
4
+ "version": "2.198.0",
5
5
  "license": "UNLICENSED",
6
6
  "types": "library/types.d.ts",
7
7
  "scripts": {
@@ -48,6 +48,8 @@ export default class CxSbImage extends CxImage {
48
48
  retryOnError: boolean;
49
49
  /** Content-builder images keep their measured box visible while the asset loads. */
50
50
  skeleton: boolean;
51
+ /** Content-builder blocks hold the box without an animated sheen. */
52
+ protected placeholderSkeletonEffect: "none";
51
53
  /**
52
54
  * The path to the image to load in dark mode.
53
55
  */
@@ -193,6 +193,7 @@ export default class CxSbVideo extends CxVideo {
193
193
  */
194
194
  private resolveClickSpace;
195
195
  handleThumbnailChange(): void;
196
+ handlePosterChange(): Promise<void>;
196
197
  handleFetchedAssetDataChange(): void;
197
198
  handleSrcChange(): Promise<void>;
198
199
  /**
@@ -66,31 +66,6 @@ export default class CxConfigManager extends CortexElement {
66
66
  * @default false
67
67
  */
68
68
  enableFontFamilyControls: boolean;
69
- /**
70
- * Default asset format applied to image blocks.
71
- * @default 'TRX'
72
- */
73
- defaultImageFormat: string;
74
- /**
75
- * Default asset format applied to video poster (thumbnail) blocks.
76
- * @default 'TRX'
77
- */
78
- defaultVideoPosterFormat: string;
79
- /**
80
- * Default asset format applied to gallery blocks.
81
- * @default 'TRX'
82
- */
83
- defaultGalleryFormat: string;
84
- /**
85
- * Default asset format applied to carousel blocks.
86
- * @default 'TRX'
87
- */
88
- defaultCarouselFormat: string;
89
- /**
90
- * Default asset format applied to timeline blocks.
91
- * @default 'TRX'
92
- */
93
- defaultTimelineFormat: string;
94
69
  /**
95
70
  * Root folder ids the folder-picker controls are restricted to (forwarded to
96
71
  * cx-config-form). Sourced from the space's configured root folders.
@@ -18,11 +18,10 @@ import { CxRTEBubbleMenu, CxRTETableGenerator } from './plugins';
18
18
  * download-format, and asset-format-picker controls on image, video, gallery,
19
19
  * carousel, and timeline blocks. Off by default.
20
20
  *
21
- * `default-image-format`, `default-video-poster-format`,
22
- * `default-gallery-format`, `default-carousel-format`, and
23
- * `default-timeline-format` set the initial format for their respective block
24
- * type. All apply regardless of `enable-asset-format-controls`, and act as the
25
- * fallback when a block has not had its format explicitly configured.
21
+ * `default-image-format`, `default-video-poster-format`, `default-timeline-format`,
22
+ * `default-gallery-format` and `default-carousel-format` are retained for backward
23
+ * compatibility but no longer do anything: every block type now starts in `Auto` and
24
+ * derives its proxy from the asset's own file extension.
26
25
  *
27
26
  * @event cx-change - Emitted when the content builder changes.
28
27
  */
@@ -121,38 +120,53 @@ export default class CxContentBuilder extends CortexElement {
121
120
  */
122
121
  enableMetrics: boolean;
123
122
  /**
124
- * Default asset format applied to image blocks.
125
- * Used as the initial format when a block is added, whether or not
126
- * `enable-asset-format-controls` is on.
127
- * @default 'TR1'
123
+ * Retained for backward compatibility; it no longer changes how image blocks resolve.
124
+ *
125
+ * Image blocks always start in `Auto` now: no format is stored on creation or on pick, so
126
+ * each one derives its proxy from the asset's own file extension. Setting this attribute
127
+ * is accepted and reflected, but nothing reads it.
128
+ *
129
+ * @deprecated Image format is resolved from the asset; this value is ignored.
128
130
  */
129
131
  defaultImageFormat: string;
130
132
  /**
131
- * Default asset format applied to video poster (thumbnail) blocks.
132
- * Used as the initial format when a block is added, whether or not
133
- * `enable-asset-format-controls` is on.
134
- * @default 'TR1'
133
+ * Retained for backward compatibility; it no longer changes how video posters resolve.
134
+ *
135
+ * A video poster always starts in `Auto` now: no thumbnail format is stored on creation
136
+ * or on pick, so the proxy is derived from the picked asset. Setting this attribute is
137
+ * accepted and reflected, but nothing reads it.
138
+ *
139
+ * @deprecated Poster format is resolved from the asset; this value is ignored.
135
140
  */
136
141
  defaultVideoPosterFormat: string;
137
142
  /**
138
- * Default asset format applied to gallery blocks.
139
- * Used as the initial format when a block is added, whether or not
140
- * `enable-asset-format-controls` is on.
141
- * @default 'TR1'
143
+ * Retained for backward compatibility; it no longer changes how galleries resolve.
144
+ *
145
+ * A gallery always starts in `Auto` now: no format is stored on creation, and switching
146
+ * source resets back to `Auto`, so each item derives its proxy from its own file
147
+ * extension. Setting this attribute is accepted and reflected, but nothing reads it.
148
+ *
149
+ * @deprecated Format is resolved per item from the asset; this value is ignored.
142
150
  */
143
151
  defaultGalleryFormat: string;
144
152
  /**
145
- * Default asset format applied to carousel blocks.
146
- * Used as the initial format when a block is added, whether or not
147
- * `enable-asset-format-controls` is on.
148
- * @default 'TR1'
153
+ * Retained for backward compatibility; it no longer changes how carousels resolve.
154
+ *
155
+ * A carousel always starts in `Auto` now: no format is stored on creation, and switching
156
+ * source resets back to `Auto`, so each item derives its proxy from its own file
157
+ * extension. Setting this attribute is accepted and reflected, but nothing reads it.
158
+ *
159
+ * @deprecated Format is resolved per item from the asset; this value is ignored.
149
160
  */
150
161
  defaultCarouselFormat: string;
151
162
  /**
152
- * Default asset format applied to timeline blocks.
153
- * Used as the initial format when a block is added, whether or not
154
- * `enable-asset-format-controls` is on.
155
- * @default 'TR1'
163
+ * Retained for backward compatibility; it no longer changes how timelines resolve.
164
+ *
165
+ * Timeline thumbnails always start in `Auto` now: no format is stored on creation, so
166
+ * each item derives its proxy from its own file extension. Setting this attribute is
167
+ * accepted and reflected, but nothing reads it.
168
+ *
169
+ * @deprecated Timeline format is resolved per item from the asset; this value is ignored.
156
170
  */
157
171
  defaultTimelineFormat: string;
158
172
  /**
@@ -4,11 +4,6 @@ import { LocalizeController } from '../../../../utils/src/custom-element/i18n';
4
4
  import { Component, ComponentDefinition, ComponentView, ComponentViewDefinition, Editor } from 'grapesjs';
5
5
 
6
6
  export type EditorPluginOptions = {
7
- defaultCarouselFormat?: string;
8
- defaultGalleryFormat?: string;
9
- defaultImageFormat?: string;
10
- defaultTimelineFormat?: string;
11
- defaultVideoPosterFormat?: string;
12
7
  enableAssetFormatControls?: boolean;
13
8
  localize: LocalizeController;
14
9
  multiLanguage?: boolean;
@@ -372,11 +372,6 @@ export declare enum DataSourceId {
372
372
  TranslatableTexts = "TRANSLATABLE_TEXTS"
373
373
  }
374
374
  export type ConfigsOptions = {
375
- defaultCarouselFormat?: string;
376
- defaultGalleryFormat?: string;
377
- defaultImageFormat?: string;
378
- defaultTimelineFormat?: string;
379
- defaultVideoPosterFormat?: string;
380
375
  enableAssetFormatControls?: boolean;
381
376
  enableFontFamilyControls?: boolean;
382
377
  };
@@ -18,6 +18,11 @@ export declare function buildTransformationString({ asset, baseUrl, extension, o
18
18
  transformations?: Transformation[];
19
19
  useSession?: string;
20
20
  }): string;
21
+ /**
22
+ * Extension marker that asks the backend to serve whichever rendition suits the asset,
23
+ * rather than the exact file the delivery URL names.
24
+ */
25
+ export declare const AUTO_FORMAT_EXTENSION = ".auto";
21
26
  /**
22
27
  * Applies transformations to a (possibly finished) asset URL and returns the display URL.
23
28
  *
@@ -25,7 +30,11 @@ export declare function buildTransformationString({ asset, baseUrl, extension, o
25
30
  * URLs the transform is anchored right after the access key (before any prettyName/ext tail)
26
31
  * and merged into an existing `/t/`. Other URLs keep the plain append behavior.
27
32
  */
28
- export declare function applyTransformationsToUrl(url: string, transformations: Transformation[]): string;
33
+ export declare function applyTransformationsToUrl(url: string, transformations: Transformation[], options?: {
34
+ autoFormat?: boolean;
35
+ extension?: string | null;
36
+ format?: string;
37
+ }): string;
29
38
  /**
30
39
  * Inserts a width-only resize into an asset-link URL, preserving any transformations
31
40
  * already present.
@@ -97,34 +106,6 @@ export declare function resolveAutoMaxWidth(manualFormat: boolean, proxyWidth: s
97
106
  * silently downgrades an image away from its original.
98
107
  */
99
108
  export declare function resolveAutoFormat(extension: string | null | undefined, size?: string | number | null): string;
100
- /**
101
- * Extension marker that asks the backend to serve whichever rendition suits the asset,
102
- * rather than the exact file the delivery URL names.
103
- */
104
- export declare const AUTO_FORMAT_EXTENSION = ".auto";
105
- /**
106
- * Appends the `.auto` marker to an asset-link URL, letting the backend pick a rendition
107
- * suited to the source instead of returning the file exactly as named.
108
- *
109
- * The existing extension is kept (`photo.jpg` becomes `photo.jpg.auto`): the URL names a
110
- * real proxy file, and rewriting that name is the backend's business, not ours. Only the
111
- * final path segment is touched, so the access key and any `/t/` transform segment are
112
- * preserved and a configured crop or resize still applies.
113
- *
114
- * An animated GIF served as the original file is left alone: whatever rendition the
115
- * backend picked instead would be a still frame, so the marker would cost the animation.
116
- * A GIF under any other format is already a rendered still, so it has nothing left to
117
- * lose and takes the marker like anything else — the same distinction `buildAssetSrcset`
118
- * draws before it resizes.
119
- *
120
- * Returns the URL unchanged when it is not an asset link (arbitrary external sources are
121
- * never rewritten), when there is no final segment to append to, or when the marker is
122
- * already present, so the call is safe to repeat.
123
- */
124
- export declare function applyAutoFormatToAssetUrl(url: string, options?: {
125
- extension?: string | null;
126
- format?: string;
127
- }): string;
128
109
  /**
129
110
  * Builds a `srcset` value for an asset-link URL by emitting one width-only resize
130
111
  * candidate per ladder entry, letting the browser fetch and decode only the pixels
@@ -9819,7 +9819,7 @@
9819
9819
  preRender?: boolean;
9820
9820
  }
9821
9821
  /**
9822
- * The `cx-content-builder` component is used to create and manage content blocks in a CMS.<br/> Set `enable-asset-format-controls` to expose the asset format, transformation, download-format, and asset-format-picker controls on image, video, gallery, carousel, and timeline blocks. Off by default.<br/> `default-image-format`, `default-video-poster-format`, `default-gallery-format`, `default-carousel-format`, and `default-timeline-format` set the initial format for their respective block type. All apply regardless of `enable-asset-format-controls`, and act as the fallback when a block has not had its format explicitly configured.
9822
+ * The `cx-content-builder` component is used to create and manage content blocks in a CMS.<br/> Set `enable-asset-format-controls` to expose the asset format, transformation, download-format, and asset-format-picker controls on image, video, gallery, carousel, and timeline blocks. Off by default.<br/> `default-image-format`, `default-video-poster-format`, `default-timeline-format`, `default-gallery-format` and `default-carousel-format` are retained for backward compatibility but no longer do anything: every block type now starts in `Auto` and derives its proxy from the asset's own file extension.
9823
9823
  */
9824
9824
  interface CxContentBuilderAttributes extends HTMLAttributes<CxContentBuilder> {
9825
9825
 
@@ -9864,23 +9864,23 @@
9864
9864
  */
9865
9865
  enableMetrics?: boolean;
9866
9866
  /**
9867
- * Default asset format applied to image blocks. Used as the initial format when a block is added, whether or not `enable-asset-format-controls` is on. <br/>@default 'TR1'
9867
+ * Retained for backward compatibility; it no longer changes how image blocks resolve. <br/> Image blocks always start in `Auto` now: no format is stored on creation or on pick, so each one derives its proxy from the asset's own file extension. Setting this attribute is accepted and reflected, but nothing reads it. <br/> <br/>@deprecated Image format is resolved from the asset; this value is ignored.
9868
9868
  */
9869
9869
  defaultImageFormat?: string;
9870
9870
  /**
9871
- * Default asset format applied to video poster (thumbnail) blocks. Used as the initial format when a block is added, whether or not `enable-asset-format-controls` is on. <br/>@default 'TR1'
9871
+ * Retained for backward compatibility; it no longer changes how video posters resolve. <br/> A video poster always starts in `Auto` now: no thumbnail format is stored on creation or on pick, so the proxy is derived from the picked asset. Setting this attribute is accepted and reflected, but nothing reads it. <br/> <br/>@deprecated Poster format is resolved from the asset; this value is ignored.
9872
9872
  */
9873
9873
  defaultVideoPosterFormat?: string;
9874
9874
  /**
9875
- * Default asset format applied to gallery blocks. Used as the initial format when a block is added, whether or not `enable-asset-format-controls` is on. <br/>@default 'TR1'
9875
+ * Retained for backward compatibility; it no longer changes how galleries resolve. <br/> A gallery always starts in `Auto` now: no format is stored on creation, and switching source resets back to `Auto`, so each item derives its proxy from its own file extension. Setting this attribute is accepted and reflected, but nothing reads it. <br/> <br/>@deprecated Format is resolved per item from the asset; this value is ignored.
9876
9876
  */
9877
9877
  defaultGalleryFormat?: string;
9878
9878
  /**
9879
- * Default asset format applied to carousel blocks. Used as the initial format when a block is added, whether or not `enable-asset-format-controls` is on. <br/>@default 'TR1'
9879
+ * Retained for backward compatibility; it no longer changes how carousels resolve. <br/> A carousel always starts in `Auto` now: no format is stored on creation, and switching source resets back to `Auto`, so each item derives its proxy from its own file extension. Setting this attribute is accepted and reflected, but nothing reads it. <br/> <br/>@deprecated Format is resolved per item from the asset; this value is ignored.
9880
9880
  */
9881
9881
  defaultCarouselFormat?: string;
9882
9882
  /**
9883
- * Default asset format applied to timeline blocks. Used as the initial format when a block is added, whether or not `enable-asset-format-controls` is on. <br/>@default 'TR1'
9883
+ * Retained for backward compatibility; it no longer changes how timelines resolve. <br/> Timeline thumbnails always start in `Auto` now: no format is stored on creation, so each item derives its proxy from its own file extension. Setting this attribute is accepted and reflected, but nothing reads it. <br/> <br/>@deprecated Timeline format is resolved per item from the asset; this value is ignored.
9884
9884
  */
9885
9885
  defaultTimelineFormat?: string;
9886
9886
  /**