@kickstartds/ds-agency-premium 1.6.0--canary.19.1102.0 → 1.6.0--canary.19.1115.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{HtmlProps-8e3e725a.d.ts → HtmlProps-8e95ed81.d.ts} +7 -1
- package/dist/SectionProps-7a46a8ad.d.ts +1 -1
- package/dist/components/blog-overview/blog-overview.schema.dereffed.json +26 -1
- package/dist/components/blog-post/blog-post.schema.dereffed.json +26 -1
- package/dist/components/blog-post/index.d.ts +1 -1
- package/dist/components/html/Html.client.d.ts +5 -0
- package/dist/components/html/Html.client.js +41 -0
- package/dist/components/html/html.css +48 -0
- package/dist/components/html/html.schema.dereffed.json +26 -1
- package/dist/components/html/html.schema.json +28 -1
- package/dist/components/html/index.d.ts +1 -1
- package/dist/components/html/index.js +18 -30
- package/dist/components/index/index.d.ts +1 -1
- package/dist/components/page/page.schema.dereffed.json +26 -1
- package/dist/components/page-wrapper/tokens.css +1 -1
- package/dist/components/presets.json +40 -0
- package/dist/components/section/section.schema.dereffed.json +26 -1
- package/dist/tokens/themes.css +4 -4
- package/dist/tokens/tokens.css +1 -1
- package/dist/tokens/tokens.js +1 -1
- package/package.json +1 -1
- /package/dist/{BlogPostProps-6b3cff22.d.ts → BlogPostProps-d9decb7c.d.ts} +0 -0
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* and run json-schema-to-typescript to regenerate this file.
|
|
5
5
|
*/
|
|
6
6
|
type HTMLString = string;
|
|
7
|
+
type ShowHTMLAfterConsent = boolean;
|
|
7
8
|
/**
|
|
8
9
|
* Add additional css classes that should be applied to the element
|
|
9
10
|
*/
|
|
@@ -17,7 +18,12 @@ type KsComponentAttribute = string;
|
|
|
17
18
|
*/
|
|
18
19
|
interface HtmlProps {
|
|
19
20
|
html?: HTMLString;
|
|
21
|
+
consent?: ShowHTMLAfterConsent;
|
|
22
|
+
consentText?: string;
|
|
23
|
+
consentButtonLabel?: string;
|
|
24
|
+
consentBackgroundImage?: string;
|
|
25
|
+
consentAspectRatio?: "16:9" | "16:10" | "4:3" | "1:1";
|
|
20
26
|
className?: AdditionalClasses;
|
|
21
27
|
component?: KsComponentAttribute;
|
|
22
28
|
}
|
|
23
|
-
export { HTMLString, AdditionalClasses, KsComponentAttribute, HtmlProps };
|
|
29
|
+
export { HTMLString, ShowHTMLAfterConsent, AdditionalClasses, KsComponentAttribute, HtmlProps };
|
|
@@ -9,7 +9,7 @@ import { FaqProps } from "./FaqProps-ad618cd5.js";
|
|
|
9
9
|
import { FeaturesProps } from "./FeaturesProps-b05859d6.js";
|
|
10
10
|
import { GalleryProps } from "./GalleryProps-76e7de44.js";
|
|
11
11
|
import { HeroProps } from "./HeroProps-cf82a16d.js";
|
|
12
|
-
import { HtmlProps } from "./HtmlProps-
|
|
12
|
+
import { HtmlProps } from "./HtmlProps-8e95ed81.js";
|
|
13
13
|
import { ImageStoryProps } from "./ImageStoryProps-e853e1e7.js";
|
|
14
14
|
import { ImageTextProps } from "./ImageTextProps-9286cca4.js";
|
|
15
15
|
import { LogosProps } from "./LogosProps-f9474fe2.js";
|
|
@@ -902,9 +902,34 @@
|
|
|
902
902
|
"title": "HTML string",
|
|
903
903
|
"type": "string",
|
|
904
904
|
"examples": [
|
|
905
|
-
"<p>Hello
|
|
905
|
+
"<p style=\"color: var(--ks-text-color-default);\">Hello World</p>"
|
|
906
906
|
]
|
|
907
907
|
},
|
|
908
|
+
"consent": {
|
|
909
|
+
"title": "Show HTML after consent",
|
|
910
|
+
"type": "boolean",
|
|
911
|
+
"default": false
|
|
912
|
+
},
|
|
913
|
+
"consentText": {
|
|
914
|
+
"type": "string"
|
|
915
|
+
},
|
|
916
|
+
"consentButtonLabel": {
|
|
917
|
+
"type": "string"
|
|
918
|
+
},
|
|
919
|
+
"consentBackgroundImage": {
|
|
920
|
+
"type": "string",
|
|
921
|
+
"format": "image"
|
|
922
|
+
},
|
|
923
|
+
"consentAspectRatio": {
|
|
924
|
+
"type": "string",
|
|
925
|
+
"enum": [
|
|
926
|
+
"16:9",
|
|
927
|
+
"16:10",
|
|
928
|
+
"4:3",
|
|
929
|
+
"1:1"
|
|
930
|
+
],
|
|
931
|
+
"default": "16:9"
|
|
932
|
+
},
|
|
908
933
|
"className": {
|
|
909
934
|
"title": "Additional Classes",
|
|
910
935
|
"description": "Add additional css classes that should be applied to the element",
|
|
@@ -1170,9 +1170,34 @@
|
|
|
1170
1170
|
"title": "HTML string",
|
|
1171
1171
|
"type": "string",
|
|
1172
1172
|
"examples": [
|
|
1173
|
-
"<p>Hello
|
|
1173
|
+
"<p style=\"color: var(--ks-text-color-default);\">Hello World</p>"
|
|
1174
1174
|
]
|
|
1175
1175
|
},
|
|
1176
|
+
"consent": {
|
|
1177
|
+
"title": "Show HTML after consent",
|
|
1178
|
+
"type": "boolean",
|
|
1179
|
+
"default": false
|
|
1180
|
+
},
|
|
1181
|
+
"consentText": {
|
|
1182
|
+
"type": "string"
|
|
1183
|
+
},
|
|
1184
|
+
"consentButtonLabel": {
|
|
1185
|
+
"type": "string"
|
|
1186
|
+
},
|
|
1187
|
+
"consentBackgroundImage": {
|
|
1188
|
+
"type": "string",
|
|
1189
|
+
"format": "image"
|
|
1190
|
+
},
|
|
1191
|
+
"consentAspectRatio": {
|
|
1192
|
+
"type": "string",
|
|
1193
|
+
"enum": [
|
|
1194
|
+
"16:9",
|
|
1195
|
+
"16:10",
|
|
1196
|
+
"4:3",
|
|
1197
|
+
"1:1"
|
|
1198
|
+
],
|
|
1199
|
+
"default": "16:9"
|
|
1200
|
+
},
|
|
1176
1201
|
"className": {
|
|
1177
1202
|
"title": "Additional Classes",
|
|
1178
1203
|
"description": "Add additional css classes that should be applied to the element",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BlogPostProps } from "../../BlogPostProps-
|
|
1
|
+
import { BlogPostProps } from "../../BlogPostProps-d9decb7c.js";
|
|
2
2
|
import { FC, PropsWithChildren } from "react";
|
|
3
3
|
declare const BlogPost: FC<PropsWithChildren<BlogPostProps>>;
|
|
4
4
|
export type { BlogPostProps };
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { define, Component } from '@kickstartds/core/lib/component';
|
|
2
|
+
|
|
3
|
+
const consentButtonSelector = ".dsa-html__consent-button";
|
|
4
|
+
const copyScriptTag = (original) => {
|
|
5
|
+
if (original.tagName === "SCRIPT") {
|
|
6
|
+
const copy = document.createElement("script");
|
|
7
|
+
for (const attr of original.attributes) {
|
|
8
|
+
copy.setAttribute(attr.name, attr.value);
|
|
9
|
+
}
|
|
10
|
+
copy.textContent = original.textContent;
|
|
11
|
+
return copy;
|
|
12
|
+
}
|
|
13
|
+
return original;
|
|
14
|
+
};
|
|
15
|
+
class Html extends Component {
|
|
16
|
+
constructor(element) {
|
|
17
|
+
super(element);
|
|
18
|
+
const consentButton = element.querySelector(consentButtonSelector);
|
|
19
|
+
const replaceHtml = () => {
|
|
20
|
+
const template = element.querySelector("template");
|
|
21
|
+
if (template) {
|
|
22
|
+
const elements = [...template.content.children].map(copyScriptTag);
|
|
23
|
+
element.replaceChildren(...elements);
|
|
24
|
+
consentButton?.removeEventListener("click", replaceHtml);
|
|
25
|
+
}
|
|
26
|
+
};
|
|
27
|
+
if (consentButton) {
|
|
28
|
+
consentButton.addEventListener("click", replaceHtml);
|
|
29
|
+
this.onDisconnect(() => {
|
|
30
|
+
consentButton.removeEventListener("click", replaceHtml);
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
else {
|
|
34
|
+
replaceHtml();
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
Html.identifier = "dsa.html";
|
|
39
|
+
define(Html.identifier, Html);
|
|
40
|
+
|
|
41
|
+
export { Html as default };
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
.dsa-html {
|
|
2
|
+
--dsa-html__consent--color: var(--ks-text-color-display);
|
|
3
|
+
--dsa-html__consent--font: var(--ks-font-copy-m);
|
|
4
|
+
--dsa-html__consent--background: var(--ks-color-fg-inverted-alpha-4);
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.dsa-html__consent {
|
|
8
|
+
position: relative;
|
|
9
|
+
width: 100%;
|
|
10
|
+
height: 100%;
|
|
11
|
+
gap: var(--ks-spacing-stack-s);
|
|
12
|
+
display: flex;
|
|
13
|
+
align-items: center;
|
|
14
|
+
flex-direction: column;
|
|
15
|
+
justify-content: center;
|
|
16
|
+
background-position: center;
|
|
17
|
+
background-size: cover;
|
|
18
|
+
}
|
|
19
|
+
.dsa-html__consent .c-rich-text {
|
|
20
|
+
color: var(--dsa-html__consent--color, var(--ks-text-color-display));
|
|
21
|
+
font: var(--dsa-html__consent--font, var(--ks-font-interface-m));
|
|
22
|
+
}
|
|
23
|
+
.dsa-html__consent:after {
|
|
24
|
+
content: "";
|
|
25
|
+
width: 100%;
|
|
26
|
+
height: 100%;
|
|
27
|
+
position: absolute;
|
|
28
|
+
top: 0;
|
|
29
|
+
background-color: var(--dsa-html__consent--background, var(--ks-color-fg-inverted-alpha-6));
|
|
30
|
+
}
|
|
31
|
+
.dsa-html__consent > * {
|
|
32
|
+
z-index: 1;
|
|
33
|
+
}
|
|
34
|
+
.dsa-html__consent .l-container {
|
|
35
|
+
container-type: normal;
|
|
36
|
+
}
|
|
37
|
+
.dsa-html__consent--sixteen-to-nine {
|
|
38
|
+
aspect-ratio: 16/9;
|
|
39
|
+
}
|
|
40
|
+
.dsa-html__consent--sixteen-to-ten {
|
|
41
|
+
aspect-ratio: 16/10;
|
|
42
|
+
}
|
|
43
|
+
.dsa-html__consent--four-to-three {
|
|
44
|
+
aspect-ratio: 4/3;
|
|
45
|
+
}
|
|
46
|
+
.dsa-html__consent--square {
|
|
47
|
+
aspect-ratio: 1;
|
|
48
|
+
}
|
|
@@ -9,9 +9,34 @@
|
|
|
9
9
|
"title": "HTML string",
|
|
10
10
|
"type": "string",
|
|
11
11
|
"examples": [
|
|
12
|
-
"<p>Hello
|
|
12
|
+
"<p style=\"color: var(--ks-text-color-default);\">Hello World</p>"
|
|
13
13
|
]
|
|
14
14
|
},
|
|
15
|
+
"consent": {
|
|
16
|
+
"title": "Show HTML after consent",
|
|
17
|
+
"type": "boolean",
|
|
18
|
+
"default": false
|
|
19
|
+
},
|
|
20
|
+
"consentText": {
|
|
21
|
+
"type": "string"
|
|
22
|
+
},
|
|
23
|
+
"consentButtonLabel": {
|
|
24
|
+
"type": "string"
|
|
25
|
+
},
|
|
26
|
+
"consentBackgroundImage": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"format": "image"
|
|
29
|
+
},
|
|
30
|
+
"consentAspectRatio": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"enum": [
|
|
33
|
+
"16:9",
|
|
34
|
+
"16:10",
|
|
35
|
+
"4:3",
|
|
36
|
+
"1:1"
|
|
37
|
+
],
|
|
38
|
+
"default": "16:9"
|
|
39
|
+
},
|
|
15
40
|
"className": {
|
|
16
41
|
"title": "Additional Classes",
|
|
17
42
|
"description": "Add additional css classes that should be applied to the element",
|
|
@@ -8,7 +8,34 @@
|
|
|
8
8
|
"html": {
|
|
9
9
|
"title": "HTML string",
|
|
10
10
|
"type": "string",
|
|
11
|
-
"examples": [
|
|
11
|
+
"examples": [
|
|
12
|
+
"<p style=\"color: var(--ks-text-color-default);\">Hello World</p>"
|
|
13
|
+
]
|
|
14
|
+
},
|
|
15
|
+
"consent": {
|
|
16
|
+
"title": "Show HTML after consent",
|
|
17
|
+
"type": "boolean",
|
|
18
|
+
"default": false
|
|
19
|
+
},
|
|
20
|
+
"consentText": {
|
|
21
|
+
"type": "string"
|
|
22
|
+
},
|
|
23
|
+
"consentButtonLabel": {
|
|
24
|
+
"type": "string"
|
|
25
|
+
},
|
|
26
|
+
"consentBackgroundImage": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"format": "image"
|
|
29
|
+
},
|
|
30
|
+
"consentAspectRatio": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"enum": [
|
|
33
|
+
"16:9",
|
|
34
|
+
"16:10",
|
|
35
|
+
"4:3",
|
|
36
|
+
"1:1"
|
|
37
|
+
],
|
|
38
|
+
"default": "16:9"
|
|
12
39
|
},
|
|
13
40
|
"className": {
|
|
14
41
|
"title": "Additional Classes",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { HTMLAttributes } from "react";
|
|
3
|
-
import { HtmlProps } from "../../HtmlProps-
|
|
3
|
+
import { HtmlProps } from "../../HtmlProps-8e95ed81.js";
|
|
4
4
|
declare const HtmlContextDefault: import("react").ForwardRefExoticComponent<HtmlProps & HTMLAttributes<HTMLDivElement> & import("react").RefAttributes<HTMLDivElement>>;
|
|
5
5
|
declare const HtmlContext: import("react").Context<import("react").ForwardRefExoticComponent<HtmlProps & HTMLAttributes<HTMLDivElement> & import("react").RefAttributes<HTMLDivElement>>>;
|
|
6
6
|
declare const Html: import("react").ForwardRefExoticComponent<HtmlProps & HTMLAttributes<HTMLDivElement> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,35 +1,23 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import "./html.css";
|
|
2
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
3
|
+
import { forwardRef, createContext, useContext } from 'react';
|
|
3
4
|
import classnames from 'classnames';
|
|
5
|
+
import { Button } from '@kickstartds/base/lib/button';
|
|
6
|
+
import { RichText } from '@kickstartds/base/lib/rich-text';
|
|
7
|
+
import './Html.client.js';
|
|
8
|
+
import '@kickstartds/core/lib/component';
|
|
4
9
|
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
};
|
|
16
|
-
const HtmlContextDefault = forwardRef(({ html, className, component, ...props }, forwardedRef) => {
|
|
17
|
-
const ref = useRef(null);
|
|
18
|
-
useImperativeHandle(forwardedRef, () => ref.current);
|
|
19
|
-
useEffect(() => {
|
|
20
|
-
if (html && ref.current) {
|
|
21
|
-
const parser = new DOMParser();
|
|
22
|
-
const doc = parser.parseFromString(html, "text/html");
|
|
23
|
-
const elements = [...doc.head.children, ...doc.body.children];
|
|
24
|
-
const insertedElements = elements.map((element) => ref.current.appendChild(copyScriptTag(element)));
|
|
25
|
-
return () => {
|
|
26
|
-
for (const insertedElement of insertedElements) {
|
|
27
|
-
insertedElement?.remove();
|
|
28
|
-
}
|
|
29
|
-
};
|
|
30
|
-
}
|
|
31
|
-
}, [html, ref.current]);
|
|
32
|
-
return (jsx("div", { ref: ref, className: classnames("c-html", className), "ks-component": component, ...props }));
|
|
10
|
+
const HtmlContextDefault = forwardRef(({ html, consent, consentText, consentBackgroundImage, consentButtonLabel, consentAspectRatio = "16:9", className, component = "dsa.html", ...props }, ref) => {
|
|
11
|
+
return (jsxs("div", { ref: ref, className: classnames("dsa-html", className), "ks-component": component, ...props, children: [jsx("template", { dangerouslySetInnerHTML: { __html: html } }), consent && (jsxs("div", { style: {
|
|
12
|
+
backgroundImage: consentBackgroundImage
|
|
13
|
+
? `url(${consentBackgroundImage})`
|
|
14
|
+
: undefined,
|
|
15
|
+
}, className: classnames("dsa-html__consent", {
|
|
16
|
+
"dsa-html__consent--sixteen-to-nine": consentAspectRatio === "16:9",
|
|
17
|
+
"dsa-html__consent--sixteen-to-ten": consentAspectRatio === "16:10",
|
|
18
|
+
"dsa-html__consent--four-to-three": consentAspectRatio === "4:3",
|
|
19
|
+
"dsa-html__consent--square": consentAspectRatio === "1:1",
|
|
20
|
+
}), children: [consentText && jsx(RichText, { text: consentText }), jsx(Button, { type: "button", label: consentButtonLabel, className: "dsa-html__consent-button", variant: "tertiary" })] }))] }));
|
|
33
21
|
});
|
|
34
22
|
const HtmlContext = createContext(HtmlContextDefault);
|
|
35
23
|
const Html = forwardRef((props, ref) => {
|
|
@@ -24,7 +24,7 @@ interface SettingsProps {
|
|
|
24
24
|
*/
|
|
25
25
|
seo: SeoProps;
|
|
26
26
|
}
|
|
27
|
-
export * from "../../BlogPostProps-
|
|
27
|
+
export * from "../../BlogPostProps-d9decb7c.js";
|
|
28
28
|
export * from "../../BlogOverviewProps-9f207f1c.js";
|
|
29
29
|
export * from "../../PageProps-aa29c554.js";
|
|
30
30
|
export { SettingsProps };
|
|
@@ -902,9 +902,34 @@
|
|
|
902
902
|
"title": "HTML string",
|
|
903
903
|
"type": "string",
|
|
904
904
|
"examples": [
|
|
905
|
-
"<p>Hello
|
|
905
|
+
"<p style=\"color: var(--ks-text-color-default);\">Hello World</p>"
|
|
906
906
|
]
|
|
907
907
|
},
|
|
908
|
+
"consent": {
|
|
909
|
+
"title": "Show HTML after consent",
|
|
910
|
+
"type": "boolean",
|
|
911
|
+
"default": false
|
|
912
|
+
},
|
|
913
|
+
"consentText": {
|
|
914
|
+
"type": "string"
|
|
915
|
+
},
|
|
916
|
+
"consentButtonLabel": {
|
|
917
|
+
"type": "string"
|
|
918
|
+
},
|
|
919
|
+
"consentBackgroundImage": {
|
|
920
|
+
"type": "string",
|
|
921
|
+
"format": "image"
|
|
922
|
+
},
|
|
923
|
+
"consentAspectRatio": {
|
|
924
|
+
"type": "string",
|
|
925
|
+
"enum": [
|
|
926
|
+
"16:9",
|
|
927
|
+
"16:10",
|
|
928
|
+
"4:3",
|
|
929
|
+
"1:1"
|
|
930
|
+
],
|
|
931
|
+
"default": "16:9"
|
|
932
|
+
},
|
|
908
933
|
"className": {
|
|
909
934
|
"title": "Additional Classes",
|
|
910
935
|
"description": "Add additional css classes that should be applied to the element",
|
|
@@ -2153,6 +2153,46 @@
|
|
|
2153
2153
|
},
|
|
2154
2154
|
"screenshot": "img/screenshots/components-hero--text-box-on-full-screen.png"
|
|
2155
2155
|
},
|
|
2156
|
+
{
|
|
2157
|
+
"id": "components-html--html",
|
|
2158
|
+
"group": "Components/HTML",
|
|
2159
|
+
"name": "HTML",
|
|
2160
|
+
"code": "<Html\n consentAspectRatio=\"16:9\"\n html=\"<p style="color: var(--ks-text-color-default);">Hello World</p>\"\n/>",
|
|
2161
|
+
"args": {
|
|
2162
|
+
"html": "<p style=\"color: var(--ks-text-color-default);\">Hello World</p>",
|
|
2163
|
+
"consent": false,
|
|
2164
|
+
"consentAspectRatio": "16:9"
|
|
2165
|
+
},
|
|
2166
|
+
"screenshot": "img/screenshots/components-html--html.png"
|
|
2167
|
+
},
|
|
2168
|
+
{
|
|
2169
|
+
"id": "components-html--with-consent",
|
|
2170
|
+
"group": "Components/HTML",
|
|
2171
|
+
"name": "WithConsent",
|
|
2172
|
+
"code": "<Html\n consent\n consentAspectRatio=\"16:9\"\n consentBackgroundImage=\"img/02.jpg\"\n consentButtonLabel=\"yes!\"\n consentText=\"would you like to watch the youtube video?\"\n html=\"<iframe width="560" height="315" src="https://www.youtube-nocookie.com/embed/oGGIkuGY-7U?si=Y5_JHflGsNwRCLu_" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>\"\n/>",
|
|
2173
|
+
"args": {
|
|
2174
|
+
"html": "<iframe width=\"560\" height=\"315\" src=\"https://www.youtube-nocookie.com/embed/oGGIkuGY-7U?si=Y5_JHflGsNwRCLu_\" title=\"YouTube video player\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen></iframe>",
|
|
2175
|
+
"consent": true,
|
|
2176
|
+
"consentAspectRatio": "16:9",
|
|
2177
|
+
"consentText": "would you like to watch the youtube video?",
|
|
2178
|
+
"consentButtonLabel": "yes!",
|
|
2179
|
+
"consentBackgroundImage": "img/02.jpg"
|
|
2180
|
+
},
|
|
2181
|
+
"screenshot": "img/screenshots/components-html--with-consent.png"
|
|
2182
|
+
},
|
|
2183
|
+
{
|
|
2184
|
+
"id": "components-html--with-script",
|
|
2185
|
+
"group": "Components/HTML",
|
|
2186
|
+
"name": "WithScript",
|
|
2187
|
+
"code": "<Html\n consent\n consentAspectRatio=\"16:9\"\n consentButtonLabel=\"Say hello\"\n html=\"<script>alert("Hello :)")</script><p style="color: var(--ks-text-color-default);">Nice to meet you!</p>\"\n/>",
|
|
2188
|
+
"args": {
|
|
2189
|
+
"html": "<script>alert(\"Hello :)\")</script><p style=\"color: var(--ks-text-color-default);\">Nice to meet you!</p>",
|
|
2190
|
+
"consent": true,
|
|
2191
|
+
"consentAspectRatio": "16:9",
|
|
2192
|
+
"consentButtonLabel": "Say hello"
|
|
2193
|
+
},
|
|
2194
|
+
"screenshot": "img/screenshots/components-html--with-script.png"
|
|
2195
|
+
},
|
|
2156
2196
|
{
|
|
2157
2197
|
"id": "components-image-story--sticky-image-next-to-scrolling-text",
|
|
2158
2198
|
"group": "Components/Image Story",
|
|
@@ -888,9 +888,34 @@
|
|
|
888
888
|
"title": "HTML string",
|
|
889
889
|
"type": "string",
|
|
890
890
|
"examples": [
|
|
891
|
-
"<p>Hello
|
|
891
|
+
"<p style=\"color: var(--ks-text-color-default);\">Hello World</p>"
|
|
892
892
|
]
|
|
893
893
|
},
|
|
894
|
+
"consent": {
|
|
895
|
+
"title": "Show HTML after consent",
|
|
896
|
+
"type": "boolean",
|
|
897
|
+
"default": false
|
|
898
|
+
},
|
|
899
|
+
"consentText": {
|
|
900
|
+
"type": "string"
|
|
901
|
+
},
|
|
902
|
+
"consentButtonLabel": {
|
|
903
|
+
"type": "string"
|
|
904
|
+
},
|
|
905
|
+
"consentBackgroundImage": {
|
|
906
|
+
"type": "string",
|
|
907
|
+
"format": "image"
|
|
908
|
+
},
|
|
909
|
+
"consentAspectRatio": {
|
|
910
|
+
"type": "string",
|
|
911
|
+
"enum": [
|
|
912
|
+
"16:9",
|
|
913
|
+
"16:10",
|
|
914
|
+
"4:3",
|
|
915
|
+
"1:1"
|
|
916
|
+
],
|
|
917
|
+
"default": "16:9"
|
|
918
|
+
},
|
|
894
919
|
"className": {
|
|
895
920
|
"title": "Additional Classes",
|
|
896
921
|
"description": "Add additional css classes that should be applied to the element",
|
package/dist/tokens/themes.css
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Do not edit directly
|
|
3
|
-
* Generated on
|
|
3
|
+
* Generated on Fri, 25 Oct 2024 09:37:24 GMT
|
|
4
4
|
*/
|
|
5
5
|
:root [ks-theme=business] {
|
|
6
6
|
--ks-background-color-accent-base: var(--ks-color-primary-to-bg-8-base);
|
|
@@ -2727,7 +2727,7 @@
|
|
|
2727
2727
|
}
|
|
2728
2728
|
/**
|
|
2729
2729
|
* Do not edit directly
|
|
2730
|
-
* Generated on
|
|
2730
|
+
* Generated on Fri, 25 Oct 2024 09:37:29 GMT
|
|
2731
2731
|
*/
|
|
2732
2732
|
:root [ks-theme=google] {
|
|
2733
2733
|
--ks-background-color-accent-base: var(--ks-color-primary-to-bg-8-base);
|
|
@@ -5458,7 +5458,7 @@
|
|
|
5458
5458
|
}
|
|
5459
5459
|
/**
|
|
5460
5460
|
* Do not edit directly
|
|
5461
|
-
* Generated on
|
|
5461
|
+
* Generated on Fri, 25 Oct 2024 09:37:26 GMT
|
|
5462
5462
|
*/
|
|
5463
5463
|
:root [ks-theme=ngo] {
|
|
5464
5464
|
--ks-background-color-accent-base: var(--ks-color-primary-to-bg-8-base);
|
|
@@ -8459,7 +8459,7 @@
|
|
|
8459
8459
|
}
|
|
8460
8460
|
/**
|
|
8461
8461
|
* Do not edit directly
|
|
8462
|
-
* Generated on
|
|
8462
|
+
* Generated on Fri, 25 Oct 2024 09:37:31 GMT
|
|
8463
8463
|
*/
|
|
8464
8464
|
:root [ks-theme=telekom] {
|
|
8465
8465
|
--ks-background-color-accent-base: var(--ks-color-primary-to-bg-8-base);
|
package/dist/tokens/tokens.css
CHANGED
package/dist/tokens/tokens.js
CHANGED
package/package.json
CHANGED
|
File without changes
|