@plitzi/sdk-elements 0.39.12 → 0.39.14

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 (109) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/dist/Element/PluginManager.mjs +13 -13
  3. package/dist/Element/hooks/useElementState.d.ts +1 -1
  4. package/dist/Element/hooks/useFullscreenInteractions.d.ts +11 -0
  5. package/dist/Element/hooks/useFullscreenInteractions.mjs +14 -0
  6. package/dist/Element/hooks/useRootElementInteractions.mjs +93 -87
  7. package/dist/builder/ruleFields.d.ts +1 -1
  8. package/dist/builder/ruleFields.mjs +5 -0
  9. package/dist/dataSource/GlobalSources.mjs +121 -104
  10. package/dist/dataSource/useAudienceScope.mjs +2 -1
  11. package/dist/dataSource/usePageClock.d.ts +12 -0
  12. package/dist/dataSource/usePageClock.mjs +19 -0
  13. package/dist/elements/basic/Countdown/Countdown.d.ts +23 -0
  14. package/dist/elements/basic/Countdown/Countdown.mjs +58 -0
  15. package/dist/elements/basic/Countdown/Settings.d.ts +12 -0
  16. package/dist/elements/basic/Countdown/Settings.mjs +94 -0
  17. package/dist/elements/basic/Countdown/declaration.d.ts +72 -0
  18. package/dist/elements/basic/Countdown/declaration.mjs +58 -0
  19. package/dist/elements/basic/Countdown/index.d.ts +69 -0
  20. package/dist/elements/basic/Countdown/index.mjs +5 -0
  21. package/dist/elements/declarations/index.d.ts +508 -7
  22. package/dist/elements/declarations/index.mjs +84 -72
  23. package/dist/elements/index.d.ts +13 -3
  24. package/dist/elements/index.mjs +76 -66
  25. package/dist/elements/media/Image/Image.d.ts +6 -1
  26. package/dist/elements/media/Image/Image.mjs +44 -35
  27. package/dist/elements/media/Image/Settings.d.ts +2 -1
  28. package/dist/elements/media/Image/Settings.mjs +26 -19
  29. package/dist/elements/media/Image/declaration.d.ts +2 -0
  30. package/dist/elements/media/Image/declaration.mjs +2 -1
  31. package/dist/elements/media/Image/index.d.ts +2 -0
  32. package/dist/elements/settings.mjs +92 -80
  33. package/dist/elements/structure/Container/Container.d.ts +2 -4
  34. package/dist/elements/structure/Container/Container.mjs +5 -6
  35. package/dist/elements/structure/Container/Settings.d.ts +1 -2
  36. package/dist/elements/structure/Container/Settings.mjs +5 -19
  37. package/dist/elements/structure/Container/declaration.d.ts +1 -2
  38. package/dist/elements/structure/Container/declaration.mjs +1 -3
  39. package/dist/elements/structure/Container/index.d.ts +1 -2
  40. package/dist/elements/structure/Disclosure/Disclosure.d.ts +26 -0
  41. package/dist/elements/structure/Disclosure/Disclosure.mjs +49 -0
  42. package/dist/elements/structure/Disclosure/DisclosureSummary/DisclosureSummary.d.ts +16 -0
  43. package/dist/elements/structure/Disclosure/DisclosureSummary/DisclosureSummary.mjs +19 -0
  44. package/dist/elements/structure/Disclosure/DisclosureSummary/Settings.d.ts +7 -0
  45. package/dist/elements/structure/Disclosure/DisclosureSummary/Settings.mjs +20 -0
  46. package/dist/elements/structure/Disclosure/DisclosureSummary/declaration.d.ts +59 -0
  47. package/dist/elements/structure/Disclosure/DisclosureSummary/declaration.mjs +47 -0
  48. package/dist/elements/structure/Disclosure/DisclosureSummary/index.d.ts +57 -0
  49. package/dist/elements/structure/Disclosure/DisclosureSummary/index.mjs +5 -0
  50. package/dist/elements/structure/Disclosure/Settings.d.ts +10 -0
  51. package/dist/elements/structure/Disclosure/Settings.mjs +47 -0
  52. package/dist/elements/structure/Disclosure/declaration.d.ts +66 -0
  53. package/dist/elements/structure/Disclosure/declaration.mjs +55 -0
  54. package/dist/elements/structure/Disclosure/index.d.ts +121 -0
  55. package/dist/elements/structure/Disclosure/index.mjs +9 -0
  56. package/dist/elements/structure/Disclosure/useDetails.d.ts +27 -0
  57. package/dist/elements/structure/Disclosure/useDetails.mjs +49 -0
  58. package/dist/elements/structure/TimeWindow/TimeWindow.mjs +29 -25
  59. package/dist/elements/structure/TimeWindow/TimeWindowContext.d.ts +6 -0
  60. package/dist/elements/structure/TimeWindow/TimeWindowContext.mjs +4 -0
  61. package/dist/elements/{testing → structure}/Variants/Settings.mjs +1 -1
  62. package/dist/elements/{testing → structure}/Variants/VariantItem/Settings.mjs +1 -1
  63. package/dist/elements/{testing → structure}/Variants/VariantItem/VariantItem.mjs +1 -1
  64. package/dist/elements/{testing → structure}/Variants/VariantItem/declaration.d.ts +1 -1
  65. package/dist/elements/{testing → structure}/Variants/VariantItem/declaration.mjs +2 -2
  66. package/dist/elements/{testing → structure}/Variants/VariantItem/index.d.ts +1 -1
  67. package/dist/elements/{testing → structure}/Variants/VariantItem/index.mjs +1 -1
  68. package/dist/elements/{testing → structure}/Variants/Variants.mjs +12 -12
  69. package/dist/elements/{testing → structure/Variants}/childOfItem.mjs +1 -1
  70. package/dist/elements/{testing → structure}/Variants/declaration.d.ts +1 -1
  71. package/dist/elements/{testing → structure}/Variants/declaration.mjs +3 -3
  72. package/dist/elements/{testing → structure}/Variants/index.d.ts +2 -2
  73. package/dist/elements/{testing → structure}/Variants/index.mjs +1 -1
  74. package/dist/elements/user/Account/Account.d.ts +25 -0
  75. package/dist/elements/user/Account/Account.mjs +104 -0
  76. package/dist/elements/user/Account/Settings.d.ts +10 -0
  77. package/dist/elements/user/Account/Settings.mjs +47 -0
  78. package/dist/elements/user/Account/declaration.d.ts +143 -0
  79. package/dist/elements/user/Account/declaration.mjs +123 -0
  80. package/dist/elements/user/Account/index.d.ts +141 -0
  81. package/dist/elements/user/Account/index.mjs +5 -0
  82. package/dist/elements/user/Avatar/Avatar.d.ts +19 -0
  83. package/dist/elements/user/Avatar/Avatar.mjs +26 -0
  84. package/dist/elements/user/Avatar/AvatarFace.d.ts +15 -0
  85. package/dist/elements/user/Avatar/AvatarFace.mjs +28 -0
  86. package/dist/elements/user/Avatar/Settings.d.ts +9 -0
  87. package/dist/elements/user/Avatar/Settings.mjs +38 -0
  88. package/dist/elements/user/Avatar/declaration.d.ts +65 -0
  89. package/dist/elements/user/Avatar/declaration.mjs +53 -0
  90. package/dist/elements/user/Avatar/faces.d.ts +10 -0
  91. package/dist/elements/user/Avatar/faces.mjs +10 -0
  92. package/dist/elements/user/Avatar/index.d.ts +63 -0
  93. package/dist/elements/user/Avatar/index.mjs +5 -0
  94. package/dist/elements/user/SignInForm/Settings.d.ts +16 -0
  95. package/dist/elements/user/SignInForm/Settings.mjs +64 -0
  96. package/dist/elements/user/SignInForm/SignInForm.d.ts +34 -0
  97. package/dist/elements/user/SignInForm/SignInForm.mjs +112 -0
  98. package/dist/elements/user/SignInForm/declaration.d.ts +120 -0
  99. package/dist/elements/user/SignInForm/declaration.mjs +99 -0
  100. package/dist/elements/user/SignInForm/index.d.ts +118 -0
  101. package/dist/elements/user/SignInForm/index.mjs +5 -0
  102. package/dist/index.d.ts +514 -6
  103. package/dist/index.mjs +84 -74
  104. package/package.json +7 -7
  105. /package/dist/elements/{testing → structure}/Variants/Settings.d.ts +0 -0
  106. /package/dist/elements/{testing → structure}/Variants/VariantItem/Settings.d.ts +0 -0
  107. /package/dist/elements/{testing → structure}/Variants/VariantItem/VariantItem.d.ts +0 -0
  108. /package/dist/elements/{testing → structure}/Variants/Variants.d.ts +0 -0
  109. /package/dist/elements/{testing → structure/Variants}/childOfItem.d.ts +0 -0
@@ -5,95 +5,107 @@ import r from "../advanced/NodeHtml/declaration.mjs";
5
5
  import i from "../advanced/PlitziSdk/declaration.mjs";
6
6
  import a from "../advanced/Reference/declaration.mjs";
7
7
  import o from "../basic/Button/declaration.mjs";
8
- import s from "../basic/Dropdown/declaration.mjs";
9
- import c from "../basic/Dropdown/DropdownPopup/declaration.mjs";
10
- import l from "../basic/Heading/declaration.mjs";
11
- import u from "../basic/Link/declaration.mjs";
12
- import d from "../basic/Markdown/declaration.mjs";
13
- import f from "../basic/Paragraph/declaration.mjs";
14
- import p from "../basic/RichText/declaration.mjs";
15
- import m from "../basic/Text/declaration.mjs";
16
- import h from "../basic/ThemeToggle/declaration.mjs";
17
- import g from "../form/Form/declaration.mjs";
18
- import _ from "../form/FormControl/declaration.mjs";
19
- import v from "../internal/LayoutContainer/declaration.mjs";
20
- import y from "../internal/Loading/declaration.mjs";
21
- import b from "../internal/NotFound/declaration.mjs";
22
- import x, { DOCUMENT_SCROLLS as S, isDocumentScroll as ee } from "../internal/Page/declaration.mjs";
8
+ import s from "../basic/Countdown/declaration.mjs";
9
+ import c from "../basic/Dropdown/declaration.mjs";
10
+ import l from "../basic/Dropdown/DropdownPopup/declaration.mjs";
11
+ import u from "../basic/Heading/declaration.mjs";
12
+ import d from "../basic/Link/declaration.mjs";
13
+ import f from "../basic/Markdown/declaration.mjs";
14
+ import p from "../basic/Paragraph/declaration.mjs";
15
+ import m from "../basic/RichText/declaration.mjs";
16
+ import h from "../basic/Text/declaration.mjs";
17
+ import g from "../basic/ThemeToggle/declaration.mjs";
18
+ import _ from "../form/Form/declaration.mjs";
19
+ import v from "../form/FormControl/declaration.mjs";
20
+ import y from "../internal/LayoutContainer/declaration.mjs";
21
+ import b from "../internal/Loading/declaration.mjs";
22
+ import x from "../internal/NotFound/declaration.mjs";
23
+ import S, { DOCUMENT_SCROLLS as ee, isDocumentScroll as te } from "../internal/Page/declaration.mjs";
23
24
  import C from "../media/Chart/declaration.mjs";
24
25
  import w from "../media/Embed/declaration.mjs";
25
26
  import T from "../media/FontAwesome/declaration.mjs";
26
27
  import E from "../media/Image/declaration.mjs";
27
28
  import D from "../media/Svg/declaration.mjs";
28
29
  import O from "../media/Video/declaration.mjs";
29
- import k from "../provider/ApiContainer/declaration.mjs";
30
- import A from "../provider/Channel/declaration.mjs";
31
- import j from "../structure/Carousel/CarouselTrack/declaration.mjs";
32
- import M from "../structure/Carousel/declaration.mjs";
33
- import N, { NAMEABLE_CONTAINER_TAGS as te } from "../structure/Container/declaration.mjs";
34
- import P from "../structure/DialogContainer/declaration.mjs";
35
- import F from "../structure/FocusGroup/declaration.mjs";
36
- import I from "../structure/List/declaration.mjs";
37
- import L from "../structure/List/ListItem/declaration.mjs";
38
- import R from "../structure/ModalContainer/declaration.mjs";
39
- import z from "../structure/Pagination/declaration.mjs";
40
- import B from "../structure/TabContainer/declaration.mjs";
41
- import V from "../structure/TabContainer/TabContainerBody/declaration.mjs";
42
- import H from "../structure/TabContainer/TabContainerHeader/declaration.mjs";
43
- import U from "../structure/TabContainer/TabContainerItem/declaration.mjs";
44
- import W from "../structure/TimeWindow/declaration.mjs";
45
- import G from "../testing/Variants/declaration.mjs";
46
- import K from "../testing/Variants/VariantItem/declaration.mjs";
47
- import { interactionBasicTriggers as q } from "../../Element/helpers/elementConstants.mjs";
48
- import { HTML_TAG_PARTS as J } from "../basic/RichText/classHtmlParts.mjs";
49
- import { isSvgMarkup as Y } from "../media/Svg/sanitizeSvg.mjs";
30
+ import ne from "../provider/ApiContainer/declaration.mjs";
31
+ import k from "../provider/Channel/declaration.mjs";
32
+ import A from "../structure/Carousel/CarouselTrack/declaration.mjs";
33
+ import j from "../structure/Carousel/declaration.mjs";
34
+ import M, { NAMEABLE_CONTAINER_TAGS as re } from "../structure/Container/declaration.mjs";
35
+ import N from "../structure/DialogContainer/declaration.mjs";
36
+ import P from "../structure/Disclosure/declaration.mjs";
37
+ import F from "../structure/Disclosure/DisclosureSummary/declaration.mjs";
38
+ import I from "../structure/FocusGroup/declaration.mjs";
39
+ import L from "../structure/List/declaration.mjs";
40
+ import R from "../structure/List/ListItem/declaration.mjs";
41
+ import z from "../structure/ModalContainer/declaration.mjs";
42
+ import B from "../structure/Pagination/declaration.mjs";
43
+ import V from "../structure/TabContainer/declaration.mjs";
44
+ import H from "../structure/TabContainer/TabContainerBody/declaration.mjs";
45
+ import U from "../structure/TabContainer/TabContainerHeader/declaration.mjs";
46
+ import W from "../structure/TabContainer/TabContainerItem/declaration.mjs";
47
+ import G from "../structure/TimeWindow/declaration.mjs";
48
+ import K from "../structure/Variants/declaration.mjs";
49
+ import q from "../structure/Variants/VariantItem/declaration.mjs";
50
+ import J from "../user/Account/declaration.mjs";
51
+ import Y from "../user/Avatar/declaration.mjs";
52
+ import X from "../user/SignInForm/declaration.mjs";
53
+ import { interactionBasicTriggers as ie } from "../../Element/helpers/elementConstants.mjs";
54
+ import { HTML_TAG_PARTS as ae } from "../basic/RichText/classHtmlParts.mjs";
55
+ import { isSvgMarkup as oe } from "../media/Svg/sanitizeSvg.mjs";
50
56
  // src/elements/declarations/index.ts
51
- var X = {
52
- ApiContainer: k,
57
+ var Z = {
58
+ ApiContainer: ne,
53
59
  BlockHtml: e,
54
60
  BlockJsx: t,
55
61
  Button: o,
56
- Carousel: M,
57
- CarouselTrack: j,
58
- Channel: A,
59
- Container: N,
62
+ Countdown: s,
63
+ Carousel: j,
64
+ CarouselTrack: A,
65
+ Channel: k,
66
+ Container: M,
60
67
  Custom: n,
61
- DialogContainer: P,
62
- FocusGroup: F,
63
- Dropdown: s,
64
- DropdownPopup: c,
68
+ DialogContainer: N,
69
+ Disclosure: P,
70
+ DisclosureSummary: F,
71
+ FocusGroup: I,
72
+ Dropdown: c,
73
+ DropdownPopup: l,
65
74
  Embed: w,
66
75
  FontAwesome: T,
67
- Form: g,
68
- FormControl: _,
69
- Heading: l,
76
+ Form: _,
77
+ FormControl: v,
78
+ Heading: u,
70
79
  Image: E,
71
- LayoutContainer: v,
72
- Link: u,
73
- List: I,
74
- ListItem: L,
75
- Loading: y,
76
- Markdown: d,
77
- ModalContainer: R,
80
+ LayoutContainer: y,
81
+ Link: d,
82
+ List: L,
83
+ ListItem: R,
84
+ Loading: b,
85
+ Markdown: f,
86
+ ModalContainer: z,
78
87
  NodeHtml: r,
79
- NotFound: b,
80
- Page: x,
81
- Pagination: z,
82
- Paragraph: f,
88
+ NotFound: x,
89
+ Page: S,
90
+ Pagination: B,
91
+ Paragraph: p,
83
92
  PlitziSdk: i,
84
93
  Reference: a,
85
- RichText: p,
94
+ RichText: m,
86
95
  Chart: C,
87
96
  Svg: D,
88
- TabContainer: B,
89
- TabContainerBody: V,
90
- TabContainerHeader: H,
91
- TabContainerItem: U,
92
- Text: m,
93
- ThemeToggle: h,
94
- TimeWindow: W,
95
- Variants: G,
96
- VariantItem: K,
97
+ TabContainer: V,
98
+ TabContainerBody: H,
99
+ TabContainerHeader: U,
100
+ TabContainerItem: W,
101
+ Text: h,
102
+ ThemeToggle: g,
103
+ TimeWindow: G,
104
+ Variants: K,
105
+ VariantItem: q,
106
+ Account: J,
107
+ Avatar: Y,
108
+ SignInForm: X,
97
109
  Video: O
98
- }, Z = Object.fromEntries(Object.values(X).flatMap((e) => "serverTemplates" in e ? [[e.type, e.serverTemplates]] : [])), Q = Object.fromEntries(Object.values(X).flatMap((e) => "contentAttributes" in e ? [[e.type, e.contentAttributes]] : [])), ne = (e) => Q[e] ?? [], $ = Object.fromEntries(Object.values(X).flatMap((e) => "ancestorType" in e ? [[e.type, e.ancestorType]] : [])), re = (e) => $[e];
99
- export { k as ApiContainerDeclaration, e as BlockHtmlDeclaration, t as BlockJsxDeclaration, o as ButtonDeclaration, M as CarouselDeclaration, j as CarouselTrackDeclaration, A as ChannelDeclaration, C as ChartDeclaration, N as ContainerDeclaration, n as CustomDeclaration, S as DOCUMENT_SCROLLS, P as DialogContainerDeclaration, s as DropdownDeclaration, c as DropdownPopupDeclaration, w as EmbedDeclaration, F as FocusGroupDeclaration, T as FontAwesomeDeclaration, _ as FormControlDeclaration, g as FormDeclaration, J as HTML_TAG_PARTS, l as HeadingDeclaration, E as ImageDeclaration, v as LayoutContainerDeclaration, u as LinkDeclaration, I as ListDeclaration, L as ListItemDeclaration, y as LoadingDeclaration, d as MarkdownDeclaration, R as ModalContainerDeclaration, te as NAMEABLE_CONTAINER_TAGS, r as NodeHtmlDeclaration, b as NotFoundDeclaration, x as PageDeclaration, z as PaginationDeclaration, f as ParagraphDeclaration, i as PlitziSdkDeclaration, a as ReferenceDeclaration, p as RichTextDeclaration, D as SvgDeclaration, V as TabContainerBodyDeclaration, B as TabContainerDeclaration, H as TabContainerHeaderDeclaration, U as TabContainerItemDeclaration, m as TextDeclaration, h as ThemeToggleDeclaration, W as TimeWindowDeclaration, K as VariantItemDeclaration, G as VariantsDeclaration, O as VideoDeclaration, $ as ancestorTypeByType, re as ancestorTypeOf, Q as contentAttributesByType, ne as contentAttributesOf, X as elementDeclarations, q as interactionBasicTriggers, ee as isDocumentScroll, Y as isSvgMarkup, Z as serverTemplatesByType };
110
+ }, se = Object.fromEntries(Object.values(Z).flatMap((e) => "serverTemplates" in e ? [[e.type, e.serverTemplates]] : [])), Q = Object.fromEntries(Object.values(Z).flatMap((e) => "contentAttributes" in e ? [[e.type, e.contentAttributes]] : [])), ce = (e) => Q[e] ?? [], $ = Object.fromEntries(Object.values(Z).flatMap((e) => "ancestorType" in e ? [[e.type, e.ancestorType]] : [])), le = (e) => $[e];
111
+ export { J as AccountDeclaration, ne as ApiContainerDeclaration, Y as AvatarDeclaration, e as BlockHtmlDeclaration, t as BlockJsxDeclaration, o as ButtonDeclaration, j as CarouselDeclaration, A as CarouselTrackDeclaration, k as ChannelDeclaration, C as ChartDeclaration, M as ContainerDeclaration, s as CountdownDeclaration, n as CustomDeclaration, ee as DOCUMENT_SCROLLS, N as DialogContainerDeclaration, P as DisclosureDeclaration, F as DisclosureSummaryDeclaration, c as DropdownDeclaration, l as DropdownPopupDeclaration, w as EmbedDeclaration, I as FocusGroupDeclaration, T as FontAwesomeDeclaration, v as FormControlDeclaration, _ as FormDeclaration, ae as HTML_TAG_PARTS, u as HeadingDeclaration, E as ImageDeclaration, y as LayoutContainerDeclaration, d as LinkDeclaration, L as ListDeclaration, R as ListItemDeclaration, b as LoadingDeclaration, f as MarkdownDeclaration, z as ModalContainerDeclaration, re as NAMEABLE_CONTAINER_TAGS, r as NodeHtmlDeclaration, x as NotFoundDeclaration, S as PageDeclaration, B as PaginationDeclaration, p as ParagraphDeclaration, i as PlitziSdkDeclaration, a as ReferenceDeclaration, m as RichTextDeclaration, X as SignInFormDeclaration, D as SvgDeclaration, H as TabContainerBodyDeclaration, V as TabContainerDeclaration, U as TabContainerHeaderDeclaration, W as TabContainerItemDeclaration, h as TextDeclaration, g as ThemeToggleDeclaration, G as TimeWindowDeclaration, q as VariantItemDeclaration, K as VariantsDeclaration, O as VideoDeclaration, $ as ancestorTypeByType, le as ancestorTypeOf, Q as contentAttributesByType, ce as contentAttributesOf, Z as elementDeclarations, ie as interactionBasicTriggers, te as isDocumentScroll, oe as isSvgMarkup, se as serverTemplatesByType };
@@ -4,6 +4,7 @@ import { default as Custom } from './advanced/Custom';
4
4
  import { default as NodeHtml } from './advanced/NodeHtml';
5
5
  import { default as Reference } from './advanced/Reference';
6
6
  import { default as Button } from './basic/Button';
7
+ import { default as Countdown } from './basic/Countdown';
7
8
  import { default as Dropdown } from './basic/Dropdown';
8
9
  import { default as Heading } from './basic/Heading';
9
10
  import { default as Link } from './basic/Link';
@@ -29,19 +30,24 @@ import { default as Channel } from './provider/Channel';
29
30
  import { default as Carousel } from './structure/Carousel';
30
31
  import { default as Container } from './structure/Container';
31
32
  import { default as DialogContainer } from './structure/DialogContainer';
33
+ import { default as Disclosure } from './structure/Disclosure';
32
34
  import { default as FocusGroup } from './structure/FocusGroup';
33
35
  import { default as List } from './structure/List';
34
36
  import { default as ModalContainer } from './structure/ModalContainer';
35
37
  import { default as Pagination } from './structure/Pagination';
36
38
  import { default as TabContainer } from './structure/TabContainer';
37
39
  import { default as TimeWindow } from './structure/TimeWindow';
38
- import { default as Variants } from './testing/Variants';
40
+ import { default as Variants } from './structure/Variants';
41
+ import { default as Account } from './user/Account';
42
+ import { default as Avatar } from './user/Avatar';
43
+ import { default as SignInForm } from './user/SignInForm';
39
44
  export * from './advanced/BlockHtml';
40
45
  export * from './advanced/BlockJsx';
41
46
  export * from './advanced/Custom';
42
47
  export * from './advanced/Reference';
43
48
  export * from './advanced/NodeHtml';
44
49
  export * from './basic/Button';
50
+ export * from './basic/Countdown';
45
51
  export * from './basic/Dropdown';
46
52
  export * from './basic/Heading';
47
53
  export * from './basic/Link';
@@ -65,6 +71,7 @@ export * from './provider/ApiContainer';
65
71
  export * from './provider/Channel';
66
72
  export * from './structure/Container';
67
73
  export * from './structure/DialogContainer';
74
+ export * from './structure/Disclosure';
68
75
  export * from './structure/FocusGroup';
69
76
  export * from './structure/List';
70
77
  export * from './structure/ModalContainer';
@@ -72,5 +79,8 @@ export * from './structure/Pagination';
72
79
  export * from './structure/Carousel';
73
80
  export * from './structure/TabContainer';
74
81
  export * from './structure/TimeWindow';
75
- export * from './testing/Variants';
76
- export { NodeHtml, Dropdown, NotFound, Loading, Custom, Reference, BlockHtml, BlockJsx, Page, Container, FocusGroup, LayoutContainer, DialogContainer, ModalContainer, TabContainer, TimeWindow, Variants, Carousel, Heading, Image, Video, Embed, Chart, Svg, FontAwesome, Button, Paragraph, RichText, Text, ThemeToggle, List, Link, Markdown, Pagination, Form, FormControl, ApiContainer, Channel };
82
+ export * from './structure/Variants';
83
+ export * from './user/Account';
84
+ export * from './user/Avatar';
85
+ export * from './user/SignInForm';
86
+ export { NodeHtml, Dropdown, NotFound, Loading, Custom, Reference, BlockHtml, BlockJsx, Page, Container, FocusGroup, LayoutContainer, DialogContainer, Disclosure, ModalContainer, TabContainer, TimeWindow, Variants, Account, Avatar, SignInForm, Carousel, Heading, Image, Video, Embed, Chart, Svg, FontAwesome, Button, Countdown, Paragraph, RichText, Text, ThemeToggle, List, Link, Markdown, Pagination, Form, FormControl, ApiContainer, Channel };
@@ -5,77 +5,87 @@ import r from "./advanced/Custom/index.mjs";
5
5
  import i from "./advanced/NodeHtml/index.mjs";
6
6
  import a from "./advanced/Reference/index.mjs";
7
7
  import o from "./basic/Button/index.mjs";
8
- import s from "./basic/Dropdown/index.mjs";
9
- import c from "./basic/Heading/index.mjs";
10
- import l from "./basic/Link/index.mjs";
11
- import u from "./basic/Markdown/index.mjs";
12
- import d from "./basic/Paragraph/index.mjs";
13
- import f from "./basic/RichText/index.mjs";
14
- import p from "./basic/Text/index.mjs";
15
- import m from "./basic/ThemeToggle/index.mjs";
16
- import h from "./form/Form/index.mjs";
17
- import g from "./form/FormControl/index.mjs";
18
- import _ from "./internal/LayoutContainer/index.mjs";
19
- import v from "./internal/Loading/index.mjs";
20
- import { NotFound as y } from "./internal/NotFound/index.mjs";
21
- import b from "./internal/Page/index.mjs";
22
- import x from "./media/Chart/index.mjs";
23
- import S from "./media/Embed/index.mjs";
24
- import C from "./media/FontAwesome/index.mjs";
25
- import w from "./media/Image/index.mjs";
26
- import T from "./media/Svg/index.mjs";
27
- import E from "./media/Video/index.mjs";
28
- import D from "./provider/ApiContainer/index.mjs";
29
- import O from "./provider/Channel/index.mjs";
30
- import k from "./structure/Carousel/index.mjs";
31
- import A from "./structure/Container/index.mjs";
32
- import j from "./structure/DialogContainer/index.mjs";
33
- import M from "./structure/FocusGroup/index.mjs";
34
- import N from "./structure/List/index.mjs";
35
- import P from "./structure/ModalContainer/index.mjs";
36
- import F from "./structure/Pagination/index.mjs";
37
- import I from "./structure/TabContainer/index.mjs";
38
- import L from "./structure/TimeWindow/index.mjs";
39
- import R from "./testing/Variants/index.mjs";
8
+ import s from "./basic/Countdown/index.mjs";
9
+ import c from "./basic/Dropdown/index.mjs";
10
+ import l from "./basic/Heading/index.mjs";
11
+ import u from "./basic/Link/index.mjs";
12
+ import d from "./basic/Markdown/index.mjs";
13
+ import f from "./basic/Paragraph/index.mjs";
14
+ import p from "./basic/RichText/index.mjs";
15
+ import m from "./basic/Text/index.mjs";
16
+ import h from "./basic/ThemeToggle/index.mjs";
17
+ import g from "./form/Form/index.mjs";
18
+ import _ from "./form/FormControl/index.mjs";
19
+ import v from "./internal/LayoutContainer/index.mjs";
20
+ import y from "./internal/Loading/index.mjs";
21
+ import { NotFound as b } from "./internal/NotFound/index.mjs";
22
+ import x from "./internal/Page/index.mjs";
23
+ import S from "./media/Chart/index.mjs";
24
+ import C from "./media/Embed/index.mjs";
25
+ import w from "./media/FontAwesome/index.mjs";
26
+ import T from "./media/Image/index.mjs";
27
+ import E from "./media/Svg/index.mjs";
28
+ import D from "./media/Video/index.mjs";
29
+ import O from "./provider/ApiContainer/index.mjs";
30
+ import k from "./provider/Channel/index.mjs";
31
+ import A from "./structure/Carousel/index.mjs";
32
+ import j from "./structure/Container/index.mjs";
33
+ import M from "./structure/DialogContainer/index.mjs";
34
+ import N from "./structure/Disclosure/index.mjs";
35
+ import P from "./structure/FocusGroup/index.mjs";
36
+ import F from "./structure/List/index.mjs";
37
+ import I from "./structure/ModalContainer/index.mjs";
38
+ import L from "./structure/Pagination/index.mjs";
39
+ import R from "./structure/TabContainer/index.mjs";
40
+ import z from "./structure/TimeWindow/index.mjs";
41
+ import B from "./structure/Variants/index.mjs";
42
+ import V from "./user/Account/index.mjs";
43
+ import H from "./user/Avatar/index.mjs";
44
+ import U from "./user/SignInForm/index.mjs";
40
45
  // src/elements/index.ts
41
- var z = /* @__PURE__ */ e({
42
- ApiContainer: () => D,
46
+ var W = /* @__PURE__ */ e({
47
+ Account: () => V,
48
+ ApiContainer: () => O,
49
+ Avatar: () => H,
43
50
  BlockHtml: () => t,
44
51
  BlockJsx: () => n,
45
52
  Button: () => o,
46
- Carousel: () => k,
47
- Channel: () => O,
48
- Chart: () => x,
49
- Container: () => A,
53
+ Carousel: () => A,
54
+ Channel: () => k,
55
+ Chart: () => S,
56
+ Container: () => j,
57
+ Countdown: () => s,
50
58
  Custom: () => r,
51
- DialogContainer: () => j,
52
- Dropdown: () => s,
53
- Embed: () => S,
54
- FocusGroup: () => M,
55
- FontAwesome: () => C,
56
- Form: () => h,
57
- FormControl: () => g,
58
- Heading: () => c,
59
- Image: () => w,
60
- LayoutContainer: () => _,
61
- Link: () => l,
62
- List: () => N,
63
- Loading: () => v,
64
- Markdown: () => u,
65
- ModalContainer: () => P,
59
+ DialogContainer: () => M,
60
+ Disclosure: () => N,
61
+ Dropdown: () => c,
62
+ Embed: () => C,
63
+ FocusGroup: () => P,
64
+ FontAwesome: () => w,
65
+ Form: () => g,
66
+ FormControl: () => _,
67
+ Heading: () => l,
68
+ Image: () => T,
69
+ LayoutContainer: () => v,
70
+ Link: () => u,
71
+ List: () => F,
72
+ Loading: () => y,
73
+ Markdown: () => d,
74
+ ModalContainer: () => I,
66
75
  NodeHtml: () => i,
67
- NotFound: () => y,
68
- Page: () => b,
69
- Pagination: () => F,
70
- Paragraph: () => d,
76
+ NotFound: () => b,
77
+ Page: () => x,
78
+ Pagination: () => L,
79
+ Paragraph: () => f,
71
80
  Reference: () => a,
72
- RichText: () => f,
73
- Svg: () => T,
74
- TabContainer: () => I,
75
- Text: () => p,
76
- ThemeToggle: () => m,
77
- TimeWindow: () => L,
78
- Variants: () => R,
79
- Video: () => E
81
+ RichText: () => p,
82
+ SignInForm: () => U,
83
+ Svg: () => E,
84
+ TabContainer: () => R,
85
+ Text: () => m,
86
+ ThemeToggle: () => h,
87
+ TimeWindow: () => z,
88
+ Variants: () => B,
89
+ Video: () => D
80
90
  });
81
- export { D as ApiContainer, t as BlockHtml, n as BlockJsx, o as Button, k as Carousel, O as Channel, x as Chart, A as Container, r as Custom, j as DialogContainer, s as Dropdown, S as Embed, M as FocusGroup, C as FontAwesome, h as Form, g as FormControl, c as Heading, w as Image, _ as LayoutContainer, l as Link, N as List, v as Loading, u as Markdown, P as ModalContainer, i as NodeHtml, y as NotFound, b as Page, F as Pagination, d as Paragraph, a as Reference, f as RichText, T as Svg, I as TabContainer, p as Text, m as ThemeToggle, L as TimeWindow, R as Variants, E as Video, z as elements_exports };
91
+ export { V as Account, O as ApiContainer, H as Avatar, t as BlockHtml, n as BlockJsx, o as Button, A as Carousel, k as Channel, S as Chart, j as Container, s as Countdown, r as Custom, M as DialogContainer, N as Disclosure, c as Dropdown, C as Embed, P as FocusGroup, w as FontAwesome, g as Form, _ as FormControl, l as Heading, T as Image, v as LayoutContainer, u as Link, F as List, y as Loading, d as Markdown, I as ModalContainer, i as NodeHtml, b as NotFound, x as Page, L as Pagination, f as Paragraph, a as Reference, p as RichText, U as SignInForm, E as Svg, R as TabContainer, m as Text, h as ThemeToggle, z as TimeWindow, B as Variants, D as Video, W as elements_exports };
@@ -3,6 +3,11 @@ export type ImageProps = {
3
3
  ref?: RefObject<HTMLElement>;
4
4
  className?: string;
5
5
  src?: string;
6
+ /**
7
+ * What is shown when `src` is empty or does not load — the brand's placeholder for a product, a generic portrait. When
8
+ * that fails too, or none is given, the SDK's own placeholder.
9
+ */
10
+ fallbackSrc?: string;
6
11
  /**
7
12
  * What the picture shows, in words — read by screen readers and browser agents in its place, and shown when it
8
13
  * cannot load. Say what it is for on this page, not what file it is: "Maya presenting the roadmap", not "photo".
@@ -34,7 +39,7 @@ export type ImageProps = {
34
39
  */
35
40
  resize?: boolean;
36
41
  };
37
- declare const Image: ({ ref, className, src: srcProp, alt: altProp, decorative, fetchPriority, loadMode, sizes, width, height, resize }: ImageProps) => import('react').JSX.Element;
42
+ declare const Image: ({ ref, className, src: srcProp, fallbackSrc, alt: altProp, decorative, fetchPriority, loadMode, sizes, width, height, resize }: ImageProps) => import('react').JSX.Element;
38
43
  declare const _default: import('react').FC<import('../../..').WithElementProps<ImageProps>>;
39
44
  export default _default;
40
45
  export { Image };
@@ -2,46 +2,55 @@ import { getFallbackSVGBase64 as e } from "./ImageHelper.mjs";
2
2
  import t from "../../../Element/hocs/withElement.mjs";
3
3
  import { emptyMark as n } from "../../../Element/hooks/useEditableContent.mjs";
4
4
  import { RootElement as r } from "../../../Element/RootElement.mjs";
5
- import { useCallback as i, useState as a } from "react";
6
- import { usePlitzi as o } from "@plitzi/sdk-shared/hooks";
7
- import { imageSrcSet as s, imageUrl as c, isResizableImage as l } from "@plitzi/sdk-shared/helpers";
8
- import { useCommonStore as u } from "@plitzi/sdk-shared/store";
9
- import { jsx as d } from "react/jsx-runtime";
10
- import f from "clsx";
5
+ import { useCallback as i, useEffect as a, useRef as o, useState as s } from "react";
6
+ import { usePlitzi as c } from "@plitzi/sdk-shared/hooks";
7
+ import { imageSrcSet as l, imageUrl as u, isResizableImage as d } from "@plitzi/sdk-shared/helpers";
8
+ import { useCommonStore as f } from "@plitzi/sdk-shared/store";
9
+ import { jsx as p } from "react/jsx-runtime";
10
+ import m from "clsx";
11
11
  // src/elements/media/Image/Image.tsx
12
- var p = 1280, m = e(), h = ({ ref: e, className: t = "", src: h, alt: g = "", decorative: _ = !1, fetchPriority: v = "auto", loadMode: y, sizes: b = "100vw", width: x, height: S, resize: C = !0 }) => {
13
- let { settings: { previewMode: w } } = o(), T = h || m, E = _ ? "" : g, [D, O] = a(void 0), k = D === T, A = i(() => O(T), [T]), j = k ? m : T, M = k ? { "data-plitzi-failed": T } : n(w === !0 && !h), N = y === "auto" ? void 0 : y, [P] = u("images.endpoint"), F = w && P && C && !k && l(T) ? {
14
- src: c(P, T, p),
15
- srcSet: s(P, T),
16
- sizes: b
17
- } : { src: j }, I = {
18
- ...x ? { width: x } : {},
19
- ...S ? { height: S } : {}
12
+ var h = 1280, g = e(), _ = ({ ref: e, className: t = "", src: _, fallbackSrc: v = "", alt: y = "", decorative: b = !1, fetchPriority: x = "auto", loadMode: S, sizes: C = "100vw", width: w, height: T, resize: E = !0 }) => {
13
+ let { settings: { previewMode: D } } = c(), O = b ? "" : y, [k, A] = s([]), j = [_, v].find((e) => e && !k.includes(e)) ?? g, M = !!_ && k.includes(_ ?? ""), N = j === g, P = i(() => A((e) => e.includes(j) ? e : [...e, j]), [j]), F = o(null), I = e ?? F;
14
+ a(() => {
15
+ let e = I.current, t = e instanceof HTMLImageElement ? e : e?.querySelector("img");
16
+ t?.complete && t.naturalWidth === 0 && !N && P();
17
+ }, [
18
+ I,
19
+ P,
20
+ N
21
+ ]);
22
+ let L = M ? { "data-plitzi-failed": _ } : n(D === !0 && !_), R = S === "auto" ? void 0 : S, [z] = f("images.endpoint"), B = D && z && E && !N && d(j) ? {
23
+ src: u(z, j, h),
24
+ srcSet: l(z, j),
25
+ sizes: C
26
+ } : { src: j }, V = {
27
+ ...w ? { width: w } : {},
28
+ ...T ? { height: T } : {}
20
29
  };
21
- return w ? /* @__PURE__ */ d(r, {
30
+ return D ? /* @__PURE__ */ p(r, {
22
31
  tag: "img",
23
32
  draggable: !1,
24
- ref: e,
25
- className: f("plitzi-component__image", t),
26
- ...F,
27
- ...I,
28
- alt: E,
29
- loading: N,
30
- fetchPriority: v,
31
- onError: k ? void 0 : A,
32
- ...M
33
- }) : /* @__PURE__ */ d(r, {
34
- ref: e,
35
- className: f("plitzi-component__image image--edit-mode", t),
36
- children: /* @__PURE__ */ d("img", {
33
+ ref: I,
34
+ className: m("plitzi-component__image", t),
35
+ ...B,
36
+ ...V,
37
+ alt: O,
38
+ loading: R,
39
+ fetchPriority: x,
40
+ onError: N ? void 0 : P,
41
+ ...L
42
+ }) : /* @__PURE__ */ p(r, {
43
+ ref: I,
44
+ className: m("plitzi-component__image image--edit-mode", t),
45
+ children: /* @__PURE__ */ p("img", {
37
46
  draggable: !1,
38
47
  src: j,
39
- alt: E,
40
- loading: N,
41
- fetchPriority: v,
42
- onError: k ? void 0 : A,
43
- ...M
48
+ alt: O,
49
+ loading: R,
50
+ fetchPriority: x,
51
+ onError: N ? void 0 : P,
52
+ ...L
44
53
  })
45
54
  });
46
- }, g = t(h);
47
- export { h as Image, g as default };
55
+ }, v = t(_);
56
+ export { _ as Image, v as default };
@@ -1,5 +1,6 @@
1
1
  type SettingsProps = {
2
2
  src?: string;
3
+ fallbackSrc?: string;
3
4
  alt?: string;
4
5
  decorative?: boolean;
5
6
  fetchPriority?: 'high' | 'low' | 'auto';
@@ -10,5 +11,5 @@ type SettingsProps = {
10
11
  variables?: Record<string, string>;
11
12
  onUpdate?: (key: string, value: string | boolean | number) => void;
12
13
  };
13
- declare const Settings: ({ src, alt, decorative, variables, fetchPriority, loadMode, sizes, width, height, onUpdate }: SettingsProps) => import('react').JSX.Element;
14
+ declare const Settings: ({ src, fallbackSrc, alt, decorative, variables, fetchPriority, loadMode, sizes, width, height, onUpdate }: SettingsProps) => import('react').JSX.Element;
14
15
  export default Settings;