@repobit/dex-system-design 0.23.71 → 0.23.73
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/CHANGELOG.md +18 -0
- package/package.json +6 -4
- package/src/components/cards/card.css.js +2 -0
- package/src/components/features-tab/features-tab.css.js +104 -0
- package/src/components/features-tab/features-tab.js +84 -0
- package/src/components/features-tab/features-tab.stories.js +443 -0
- package/src/components/tabs/tabs.js +3 -3
- package/src/components/tabsComponentFamily/tabsComponentFamily.css.js +181 -0
- package/src/components/tabsComponentFamily/tabsComponentFamily.js +180 -0
- package/src/components/tabsComponentFamily/tabsComponentFamily.stories.js +319 -0
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
import { LitElement, html } from "lit";
|
|
2
|
+
import { keyed } from "lit/directives/keyed.js";
|
|
3
|
+
import { tokens } from "../../tokens/tokens.js";
|
|
4
|
+
import "../button/button.js";
|
|
5
|
+
import "../heading/heading.js";
|
|
6
|
+
import "../highlight/highlight.js";
|
|
7
|
+
import "../paragraph/paragraph.js";
|
|
8
|
+
import tabsChildCSS from "./tabsComponentFamily.css.js";
|
|
9
|
+
|
|
10
|
+
class BdTabContentPanelFamily extends HTMLElement {
|
|
11
|
+
connectedCallback() {
|
|
12
|
+
this.style.display = "none";
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
customElements.define("bd-tab-content-panel-family", BdTabContentPanelFamily);
|
|
16
|
+
|
|
17
|
+
class TabsComponentFamily extends LitElement {
|
|
18
|
+
static properties = {
|
|
19
|
+
title : { type: String },
|
|
20
|
+
subtitle : { type: String },
|
|
21
|
+
highlightText : { type: String, attribute: "highlight-text" },
|
|
22
|
+
selectedTab : { type: Number, state: true },
|
|
23
|
+
_panelMinHeight: { type: Number, state: true }
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
static styles = [tokens, tabsChildCSS];
|
|
27
|
+
|
|
28
|
+
constructor() {
|
|
29
|
+
super();
|
|
30
|
+
this.title = "";
|
|
31
|
+
this.subtitle = "";
|
|
32
|
+
this.highlightText = "";
|
|
33
|
+
this.selectedTab = 0;
|
|
34
|
+
this._panelMinHeight = 0;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
_getPanels() {
|
|
38
|
+
return Array.from(this.querySelectorAll(":scope > bd-tab-content-panel-family"));
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
selectTab(index) {
|
|
42
|
+
this.selectedTab = index;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
async firstUpdated() {
|
|
46
|
+
await this.updateComplete;
|
|
47
|
+
await this._measureAllPanels();
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
async _measureAllPanels() {
|
|
51
|
+
const panels = this._getPanels();
|
|
52
|
+
const wrapper = this.renderRoot.querySelector(".bd-panel-wrapper");
|
|
53
|
+
if (!wrapper || !panels.length) return;
|
|
54
|
+
|
|
55
|
+
const originalTab = this.selectedTab;
|
|
56
|
+
let maxHeight = 0;
|
|
57
|
+
|
|
58
|
+
for (let i = 0; i < panels.length; i++) {
|
|
59
|
+
this.selectedTab = i;
|
|
60
|
+
await this.updateComplete;
|
|
61
|
+
await new Promise(r => requestAnimationFrame(r));
|
|
62
|
+
await new Promise(r => requestAnimationFrame(r));
|
|
63
|
+
|
|
64
|
+
const h = wrapper.scrollHeight;
|
|
65
|
+
if (h > maxHeight) maxHeight = h;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
this.selectedTab = originalTab;
|
|
69
|
+
await this.updateComplete;
|
|
70
|
+
this._panelMinHeight = maxHeight;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
_renderPanel(panel) {
|
|
74
|
+
const headingEl = panel.querySelector("[slot='heading']");
|
|
75
|
+
const contentEl = panel.querySelector("[slot='content']");
|
|
76
|
+
const imageEl = panel.querySelector("[slot='image']");
|
|
77
|
+
const ctaEl = panel.querySelector("[slot='cta']");
|
|
78
|
+
|
|
79
|
+
const heading = panel.getAttribute("heading");
|
|
80
|
+
const imageSrc = panel.getAttribute("image-src");
|
|
81
|
+
const imageAlt = panel.getAttribute("image-alt") || "";
|
|
82
|
+
const ctaLabel = panel.getAttribute("cta-label");
|
|
83
|
+
const ctaHref = panel.getAttribute("cta-href") || "#";
|
|
84
|
+
const ctaKind = panel.getAttribute("cta-kind") || "danger";
|
|
85
|
+
const ctaSize = panel.getAttribute("cta-size") || "md";
|
|
86
|
+
|
|
87
|
+
return html`
|
|
88
|
+
<div class="bd-card-container">
|
|
89
|
+
|
|
90
|
+
<div class="bd-left">
|
|
91
|
+
${headingEl
|
|
92
|
+
? headingEl.cloneNode(true)
|
|
93
|
+
: heading
|
|
94
|
+
? html`<bd-h as="h3" color="var(--color-blue-600)">${heading}</bd-h>`
|
|
95
|
+
: ""}
|
|
96
|
+
|
|
97
|
+
${contentEl
|
|
98
|
+
? html`<div class="bd-panel-content">${contentEl.cloneNode(true)}</div>`
|
|
99
|
+
: ""}
|
|
100
|
+
|
|
101
|
+
${ctaEl
|
|
102
|
+
? ctaEl.cloneNode(true)
|
|
103
|
+
: ctaLabel
|
|
104
|
+
? html`
|
|
105
|
+
<bd-button-link
|
|
106
|
+
href="${ctaHref}"
|
|
107
|
+
kind="${ctaKind}"
|
|
108
|
+
size="${ctaSize}"
|
|
109
|
+
label="${ctaLabel}"
|
|
110
|
+
strong="true"
|
|
111
|
+
>
|
|
112
|
+
${ctaLabel}
|
|
113
|
+
</bd-button-link>`
|
|
114
|
+
: ""}
|
|
115
|
+
</div>
|
|
116
|
+
|
|
117
|
+
<div class="bd-right">
|
|
118
|
+
${imageEl
|
|
119
|
+
? imageEl.cloneNode(true)
|
|
120
|
+
: imageSrc
|
|
121
|
+
? html`<img src="${imageSrc}" alt="${imageAlt}" class="bd-panel-image" loading="lazy" />`
|
|
122
|
+
: ""}
|
|
123
|
+
</div>
|
|
124
|
+
|
|
125
|
+
</div>
|
|
126
|
+
`;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
render() {
|
|
130
|
+
const panels = this._getPanels();
|
|
131
|
+
const activePanel = panels[this.selectedTab];
|
|
132
|
+
|
|
133
|
+
return html`
|
|
134
|
+
<div class="bd-tabs-component">
|
|
135
|
+
|
|
136
|
+
${this.title
|
|
137
|
+
? html`<bd-highlight highlight-text="${this.highlightText}">${this.title}</bd-highlight>`
|
|
138
|
+
: ""}
|
|
139
|
+
|
|
140
|
+
${this.subtitle
|
|
141
|
+
? html`<bd-p kind="regular" class="bd-tabs-subtitle">${this.subtitle}</bd-p>`
|
|
142
|
+
: ""}
|
|
143
|
+
|
|
144
|
+
<div class="bd-tabs-container" role="tablist">
|
|
145
|
+
${panels.map((panel, index) => {
|
|
146
|
+
const icon = panel.getAttribute("icon");
|
|
147
|
+
return html`
|
|
148
|
+
<button
|
|
149
|
+
role="tab"
|
|
150
|
+
aria-selected="${this.selectedTab === index ? "true" : "false"}"
|
|
151
|
+
aria-controls="tab-panel-${index}"
|
|
152
|
+
id="tab-btn-${index}"
|
|
153
|
+
class="bd-tab-button ${this.selectedTab === index ? "bd-selected" : ""}"
|
|
154
|
+
@click=${() => this.selectTab(index)}
|
|
155
|
+
>
|
|
156
|
+
${icon ? html`<img src="${icon}" alt="" class="bd-tab-icon" />` : ""}
|
|
157
|
+
<span class="bd-tab-label">${panel.getAttribute("title")}</span>
|
|
158
|
+
</button>
|
|
159
|
+
`;
|
|
160
|
+
})}
|
|
161
|
+
</div>
|
|
162
|
+
|
|
163
|
+
<div
|
|
164
|
+
id="tab-panel-${this.selectedTab}"
|
|
165
|
+
role="tabpanel"
|
|
166
|
+
aria-labelledby="tab-btn-${this.selectedTab}"
|
|
167
|
+
class="bd-panel-wrapper"
|
|
168
|
+
style="${this._panelMinHeight ? `min-height: ${this._panelMinHeight}px;` : ""}"
|
|
169
|
+
>
|
|
170
|
+
${activePanel
|
|
171
|
+
? keyed(this.selectedTab, this._renderPanel(activePanel))
|
|
172
|
+
: ""}
|
|
173
|
+
</div>
|
|
174
|
+
|
|
175
|
+
</div>
|
|
176
|
+
`;
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
customElements.define("bd-tabs-component-family", TabsComponentFamily);
|
|
@@ -0,0 +1,319 @@
|
|
|
1
|
+
import { html } from 'lit';
|
|
2
|
+
import './tabsComponentFamily.js';
|
|
3
|
+
|
|
4
|
+
export default {
|
|
5
|
+
title : 'Components/TabsComponentFamily',
|
|
6
|
+
tags : ['autodocs'],
|
|
7
|
+
parameters: {
|
|
8
|
+
docs: {
|
|
9
|
+
description: {
|
|
10
|
+
component: `
|
|
11
|
+
**TabsComponentFamily** is a fully slotted Lit component for a tab-based content showcase with left content and right image.
|
|
12
|
+
|
|
13
|
+
### Usage
|
|
14
|
+
\`\`\`html
|
|
15
|
+
<bd-tabs-component-family
|
|
16
|
+
title="Customized online protection for each family member"
|
|
17
|
+
highlight-text="family member"
|
|
18
|
+
subtitle="Your subtitle here."
|
|
19
|
+
>
|
|
20
|
+
<bd-tab-content-panel-family
|
|
21
|
+
title="Admin"
|
|
22
|
+
image-alt="Description"
|
|
23
|
+
cta-label="Stay worry free"
|
|
24
|
+
cta-href="#"
|
|
25
|
+
>
|
|
26
|
+
<bd-h as="h3" slot="heading">Your heading here.</bd-h>
|
|
27
|
+
<div slot="content">
|
|
28
|
+
<bd-p kind="small">Your content here.</bd-p>
|
|
29
|
+
</div>
|
|
30
|
+
<img slot="image" src="/assets/image.png" alt="Description" loading="lazy" />
|
|
31
|
+
</bd-tab-content-panel-family>
|
|
32
|
+
</bd-tabs-component-family>
|
|
33
|
+
\`\`\`
|
|
34
|
+
|
|
35
|
+
### Atribute \`bd-tab-content-panel-family\`
|
|
36
|
+
| Atribut | Tip | Descriere |
|
|
37
|
+
|---|---|---|
|
|
38
|
+
| \`title\` | String | Label-ul butonului de tab |
|
|
39
|
+
| \`icon\` | String | Cale imagine icon lângă label (opțional) |
|
|
40
|
+
| \`image-src\` | String | Imaginea din dreapta (fallback când nu există slot="image") |
|
|
41
|
+
| \`image-alt\` | String | Alt text imagine |
|
|
42
|
+
| \`cta-label\` | String | Text buton CTA (alternativă la slot) |
|
|
43
|
+
| \`cta-href\` | String | Href buton CTA |
|
|
44
|
+
| \`cta-kind\` | String | Kind buton CTA (default: danger) |
|
|
45
|
+
| \`cta-size\` | String | Size buton CTA (default: md) |
|
|
46
|
+
|
|
47
|
+
### Slot-uri \`bd-tab-content-panel-family\`
|
|
48
|
+
| Slot | Descriere |
|
|
49
|
+
|---|---|
|
|
50
|
+
| \`heading\` | Heading custom |
|
|
51
|
+
| \`content\` | Orice conținut: paragrafe, liste, etc. |
|
|
52
|
+
| \`image\` | Imagine custom — suprascrie \`image-src\` |
|
|
53
|
+
| \`cta\` | Buton/link custom — suprascrie \`cta-label\` |
|
|
54
|
+
`
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
argTypes: {
|
|
59
|
+
title: {
|
|
60
|
+
control : 'text',
|
|
61
|
+
description: 'Titlul principal al componentei',
|
|
62
|
+
table : { type: { summary: 'string' }, category: 'TabsComponentFamily' }
|
|
63
|
+
},
|
|
64
|
+
subtitle: {
|
|
65
|
+
control : 'text',
|
|
66
|
+
description: 'Subtitlul componentei',
|
|
67
|
+
table : { type: { summary: 'string' }, category: 'TabsComponentFamily' }
|
|
68
|
+
},
|
|
69
|
+
highlightText: {
|
|
70
|
+
control : 'text',
|
|
71
|
+
description: 'Textul care se highlightează în titlu',
|
|
72
|
+
table : { type: { summary: 'string' }, category: 'TabsComponentFamily' }
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
const panels = [
|
|
78
|
+
{
|
|
79
|
+
title : 'Admin',
|
|
80
|
+
imageSrc: '/assets/tabs-img1.png',
|
|
81
|
+
imageAlt: 'Admin using laptop',
|
|
82
|
+
heading : 'Keep your loved ones protected.',
|
|
83
|
+
content : 'As the Subscription Manager, you can oversee and adjust online safety through an intuitive dashboard. Effortlessly manage settings, monitor real-time alerts, and maintain control without compromising simplicity or security.',
|
|
84
|
+
ctaLabel: 'Stay worry free',
|
|
85
|
+
ctaHref : '#admin'
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
title : 'Adult',
|
|
89
|
+
imageSrc: '/assets/tabs-img2.png',
|
|
90
|
+
imageAlt: 'Adult protection',
|
|
91
|
+
heading : 'Stay safe online, every day.',
|
|
92
|
+
content : 'Advanced privacy and security tools tailored for adults. Browse safely, protect your identity, and keep your data private at all times.',
|
|
93
|
+
ctaLabel: 'Learn more',
|
|
94
|
+
ctaHref : '#adult'
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
title : 'Teen',
|
|
98
|
+
imageSrc: '/assets/tabs-img3.png',
|
|
99
|
+
imageAlt: 'Teen protection',
|
|
100
|
+
heading : 'Safe browsing for teens.',
|
|
101
|
+
content : 'Give teens the freedom to explore online while keeping them protected from inappropriate content, cyberbullying, and online threats.',
|
|
102
|
+
ctaLabel: 'Explore features',
|
|
103
|
+
ctaHref : '#teen'
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
title : 'Child',
|
|
107
|
+
imageSrc: '/assets/tabs-img3.png',
|
|
108
|
+
imageAlt: 'Child protection',
|
|
109
|
+
heading : 'A safe digital world for children.',
|
|
110
|
+
content : 'Comprehensive parental controls and content filtering ensure your child has a safe, age-appropriate online experience every time they connect.',
|
|
111
|
+
ctaLabel: 'Protect your child',
|
|
112
|
+
ctaHref : '#child'
|
|
113
|
+
}
|
|
114
|
+
];
|
|
115
|
+
|
|
116
|
+
const renderPanels = () => panels.map(p => html`
|
|
117
|
+
<bd-tab-content-panel-family
|
|
118
|
+
title="${p.title}"
|
|
119
|
+
image-src="${p.imageSrc}"
|
|
120
|
+
image-alt="${p.imageAlt}"
|
|
121
|
+
cta-label="${p.ctaLabel}"
|
|
122
|
+
cta-href="${p.ctaHref}"
|
|
123
|
+
>
|
|
124
|
+
<bd-h as="h3" slot="heading" style="color: var(--color-blue-600);">${p.heading}</bd-h>
|
|
125
|
+
<div slot="content">
|
|
126
|
+
<bd-p kind="small">${p.content}</bd-p>
|
|
127
|
+
</div>
|
|
128
|
+
</bd-tab-content-panel-family>
|
|
129
|
+
`);
|
|
130
|
+
|
|
131
|
+
export const Default = {
|
|
132
|
+
name : 'Default (4 tabs)',
|
|
133
|
+
render: () => html`
|
|
134
|
+
<bd-tabs-component-family
|
|
135
|
+
title="Customized online protection for each family member – Smart, Private & Safe"
|
|
136
|
+
highlight-text="family member"
|
|
137
|
+
subtitle="Your family is unique and so should be your online security. Our family protection plan adapts to each member's needs, offering the ideal mix of privacy, freedom, and safety."
|
|
138
|
+
>
|
|
139
|
+
${renderPanels()}
|
|
140
|
+
</bd-tabs-component-family>
|
|
141
|
+
`,
|
|
142
|
+
parameters: { docs: { description: { story: 'Default cu 4 tab-uri și conținut complet.' } } }
|
|
143
|
+
};
|
|
144
|
+
|
|
145
|
+
export const WithImageSlot = {
|
|
146
|
+
name : 'Cu slot="image" (picture element)',
|
|
147
|
+
render: () => html`
|
|
148
|
+
<bd-tabs-component-family
|
|
149
|
+
title="Customized online protection for each family member – Smart, Private & Safe"
|
|
150
|
+
highlight-text="family member"
|
|
151
|
+
subtitle="Folosind slot='image' pentru control complet asupra imaginii."
|
|
152
|
+
>
|
|
153
|
+
${panels.map(p => html`
|
|
154
|
+
<bd-tab-content-panel-family
|
|
155
|
+
title="${p.title}"
|
|
156
|
+
cta-label="${p.ctaLabel}"
|
|
157
|
+
cta-href="${p.ctaHref}"
|
|
158
|
+
>
|
|
159
|
+
<bd-h as="h3" slot="heading" style="color: var(--color-blue-600);">${p.heading}</bd-h>
|
|
160
|
+
<div slot="content">
|
|
161
|
+
<bd-p kind="small">${p.content}</bd-p>
|
|
162
|
+
</div>
|
|
163
|
+
<picture slot="image" style="display:block;">
|
|
164
|
+
<source type="image/webp" srcset="${p.imageSrc}?width=2000&format=webp&optimize=medium" media="(min-width: 600px)" />
|
|
165
|
+
<source type="image/webp" srcset="${p.imageSrc}?width=750&format=webp&optimize=medium" />
|
|
166
|
+
<img
|
|
167
|
+
src="${p.imageSrc}"
|
|
168
|
+
alt="${p.imageAlt}"
|
|
169
|
+
loading="lazy"
|
|
170
|
+
style="width:100%;max-width:520px;height:auto;border-radius:var(--radius-lg,16px);object-fit:cover;display:block;"
|
|
171
|
+
/>
|
|
172
|
+
</picture>
|
|
173
|
+
</bd-tab-content-panel-family>
|
|
174
|
+
`)}
|
|
175
|
+
</bd-tabs-component-family>
|
|
176
|
+
`,
|
|
177
|
+
parameters: { docs: { description: { story: 'Imaginea furnizată via slot="image" cu element picture complet.' } } }
|
|
178
|
+
};
|
|
179
|
+
|
|
180
|
+
export const NoTitleNoSubtitle = {
|
|
181
|
+
name : 'No Title / No Subtitle',
|
|
182
|
+
render: () => html`
|
|
183
|
+
<bd-tabs-component-family>
|
|
184
|
+
${renderPanels()}
|
|
185
|
+
</bd-tabs-component-family>
|
|
186
|
+
`,
|
|
187
|
+
parameters: { docs: { description: { story: 'Fără titlu și subtitlu.' } } }
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
export const SingleTab = {
|
|
191
|
+
name : 'Single Tab (edge case)',
|
|
192
|
+
render: () => html`
|
|
193
|
+
<bd-tabs-component-family
|
|
194
|
+
title="Protection for your family"
|
|
195
|
+
highlight-text="family"
|
|
196
|
+
subtitle="Stay protected."
|
|
197
|
+
>
|
|
198
|
+
<bd-tab-content-panel-family
|
|
199
|
+
title="Admin"
|
|
200
|
+
image-src="/assets/tabs-img1.png"
|
|
201
|
+
image-alt="Admin"
|
|
202
|
+
cta-label="Get started"
|
|
203
|
+
cta-href="#"
|
|
204
|
+
>
|
|
205
|
+
<bd-h as="h3" slot="heading" style="color: var(--color-blue-600);">Keep your loved ones protected.</bd-h>
|
|
206
|
+
<div slot="content">
|
|
207
|
+
<bd-p kind="small">Single tab edge case — only one panel available.</bd-p>
|
|
208
|
+
</div>
|
|
209
|
+
</bd-tab-content-panel-family>
|
|
210
|
+
</bd-tabs-component-family>
|
|
211
|
+
`,
|
|
212
|
+
parameters: { docs: { description: { story: 'Edge case cu un singur tab.' } } }
|
|
213
|
+
};
|
|
214
|
+
|
|
215
|
+
export const NoCTA = {
|
|
216
|
+
name : 'No CTA Button',
|
|
217
|
+
render: () => html`
|
|
218
|
+
<bd-tabs-component-family
|
|
219
|
+
title="Customized online protection for each family member"
|
|
220
|
+
highlight-text="family member"
|
|
221
|
+
subtitle="Stay protected at all times."
|
|
222
|
+
>
|
|
223
|
+
${panels.map(p => html`
|
|
224
|
+
<bd-tab-content-panel-family
|
|
225
|
+
title="${p.title}"
|
|
226
|
+
image-src="${p.imageSrc}"
|
|
227
|
+
image-alt="${p.imageAlt}"
|
|
228
|
+
>
|
|
229
|
+
<bd-h as="h3" slot="heading" style="color: var(--color-blue-600);">${p.heading}</bd-h>
|
|
230
|
+
<div slot="content">
|
|
231
|
+
<bd-p kind="small">${p.content}</bd-p>
|
|
232
|
+
</div>
|
|
233
|
+
</bd-tab-content-panel-family>
|
|
234
|
+
`)}
|
|
235
|
+
</bd-tabs-component-family>
|
|
236
|
+
`,
|
|
237
|
+
parameters: { docs: { description: { story: 'Fără buton CTA.' } } }
|
|
238
|
+
};
|
|
239
|
+
|
|
240
|
+
export const WithIcons = {
|
|
241
|
+
name : 'With Tab Icons',
|
|
242
|
+
render: () => html`
|
|
243
|
+
<bd-tabs-component-family
|
|
244
|
+
title="Customized online protection for each family member"
|
|
245
|
+
highlight-text="family member"
|
|
246
|
+
subtitle="Stay protected at all times."
|
|
247
|
+
>
|
|
248
|
+
${panels.map((p, i) => html`
|
|
249
|
+
<bd-tab-content-panel-family
|
|
250
|
+
title="${p.title}"
|
|
251
|
+
icon="/assets/pic${i + 1}.png"
|
|
252
|
+
image-src="${p.imageSrc}"
|
|
253
|
+
image-alt="${p.imageAlt}"
|
|
254
|
+
cta-label="${p.ctaLabel}"
|
|
255
|
+
cta-href="${p.ctaHref}"
|
|
256
|
+
>
|
|
257
|
+
<bd-h as="h3" slot="heading" style="color: var(--color-blue-600);">${p.heading}</bd-h>
|
|
258
|
+
<div slot="content">
|
|
259
|
+
<bd-p kind="small">${p.content}</bd-p>
|
|
260
|
+
</div>
|
|
261
|
+
</bd-tab-content-panel-family>
|
|
262
|
+
`)}
|
|
263
|
+
</bd-tabs-component-family>
|
|
264
|
+
`,
|
|
265
|
+
parameters: { docs: { description: { story: 'Tab-uri cu iconiță lângă label.' } } }
|
|
266
|
+
};
|
|
267
|
+
|
|
268
|
+
export const MobileView = {
|
|
269
|
+
name : 'Mobile View (375px)',
|
|
270
|
+
render: () => html`
|
|
271
|
+
<bd-tabs-component-family
|
|
272
|
+
title="Customized online protection for each family member"
|
|
273
|
+
highlight-text="family member"
|
|
274
|
+
subtitle="Stay protected at all times."
|
|
275
|
+
>
|
|
276
|
+
${renderPanels()}
|
|
277
|
+
</bd-tabs-component-family>
|
|
278
|
+
`,
|
|
279
|
+
parameters: {
|
|
280
|
+
viewport: { defaultViewport: 'mobile1' },
|
|
281
|
+
docs : { description: { story: 'Vedere mobilă la 375px.' } }
|
|
282
|
+
}
|
|
283
|
+
};
|
|
284
|
+
|
|
285
|
+
export const TabletView = {
|
|
286
|
+
name : 'Tablet View (768px)',
|
|
287
|
+
render: () => html`
|
|
288
|
+
<bd-tabs-component-family
|
|
289
|
+
title="Customized online protection for each family member"
|
|
290
|
+
highlight-text="family member"
|
|
291
|
+
subtitle="Stay protected at all times."
|
|
292
|
+
>
|
|
293
|
+
${renderPanels()}
|
|
294
|
+
</bd-tabs-component-family>
|
|
295
|
+
`,
|
|
296
|
+
parameters: {
|
|
297
|
+
viewport: { defaultViewport: 'tablet' },
|
|
298
|
+
docs : { description: { story: 'Vedere tabletă la 768px.' } }
|
|
299
|
+
}
|
|
300
|
+
};
|
|
301
|
+
|
|
302
|
+
export const Playground = {
|
|
303
|
+
name: '🛝 Playground',
|
|
304
|
+
args: {
|
|
305
|
+
title : 'Customized online protection for each family member – Smart, Private & Safe',
|
|
306
|
+
subtitle : 'Your family is unique and so should be your online security.',
|
|
307
|
+
highlightText: 'family member'
|
|
308
|
+
},
|
|
309
|
+
render: (args) => html`
|
|
310
|
+
<bd-tabs-component-family
|
|
311
|
+
title="${args.title}"
|
|
312
|
+
highlight-text="${args.highlightText}"
|
|
313
|
+
subtitle="${args.subtitle}"
|
|
314
|
+
>
|
|
315
|
+
${renderPanels()}
|
|
316
|
+
</bd-tabs-component-family>
|
|
317
|
+
`,
|
|
318
|
+
parameters: { docs: { description: { story: 'Playground interactiv.' } } }
|
|
319
|
+
};
|