Skip to content

Commit 63047f6

Browse files
Melissa Thompsonaramos-adobe
Melissa Thompson
authored andcommitted
feat(switch): s2 migration (#2651)
* feat(switch): s2 migration * chore: remove themes * fix: animation * fix: whcm light mode unchecked handle shows * docs(storybook): align chromatic setup with new standard * fix: checked corners for non-retina display * fix: whcm handle selected color * fix: namespace mods, use semantic tokens instead of global * fix: handle state colors
1 parent 71187d1 commit 63047f6

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

components/switch/stories/switch.stories.js

+25
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,31 @@ WithForcedColors.parameters = {
6262
forcedColors: "active",
6363
modes: disableDefaultModes
6464
},
65+
decorators: [
66+
(Story, context) => html`
67+
<style>
68+
.spectrum-Detail { display: inline-block; }
69+
.spectrum-Typography > div {
70+
border: 1px solid var(--spectrum-gray-200);
71+
border-radius: 4px;
72+
padding: 0 1em 1em;
73+
/* Why seafoam? Because it separates it from the component styles. */
74+
--mod-detail-font-color: var(--spectrum-seafoam-900);
75+
}
76+
</style>
77+
<div
78+
style=${styleMap({
79+
display: "flex",
80+
flexDirection: "column",
81+
alignItems: "flex-start",
82+
gap: "1rem",
83+
"--mod-detail-margin-end": ".3rem",
84+
})}
85+
>
86+
${Story(context)}
87+
</div>
88+
`,
89+
],
6590
};
6691

6792
// ********* DOCS ONLY ********* //

0 commit comments

Comments
 (0)