Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
122 commits
Select commit Hold shift + click to select a range
0bb77b0
[theme] add new variables
j-mnizhek Jun 30, 2026
86f37f0
[theme] update theme and add comments to a bunch of components styles
j-mnizhek Jul 1, 2026
940a74e
[theme] update groups for some variables
j-mnizhek Jul 2, 2026
7d7e876
[theme] added renamed vars to derprecated
j-mnizhek Jul 2, 2026
c880f63
[theme] added TODO instead of changing styles
j-mnizhek Jul 3, 2026
a902bfa
[theme] added more context for neighborlocation styles
j-mnizhek Jul 3, 2026
7c54fee
Merge branch 'release/v17' into UIK-5351/add-more-variables-to-theme
j-mnizhek Jul 7, 2026
5bfa958
[theme] a bunch of updates after discussing
j-mnizhek Jul 7, 2026
0cfa5b4
[theme] update comment for Hint styles
j-mnizhek Jul 7, 2026
20fb9cc
[theme] name updates
j-mnizhek Jul 7, 2026
208e04a
[theme] add bg to additional Tag
j-mnizhek Jul 7, 2026
f23e679
[feature-highlight] fix missing top prop
j-mnizhek Jul 7, 2026
9d90750
[UIK-5565][dropdown-menu] fixed preventFocusByClick - skip draggable …
ilyabrower Jul 9, 2026
65bdb8f
[chore] Merge branch 'release/v17' into UIK-5351/add-more-variables-t…
j-mnizhek Jul 9, 2026
19e6690
[theme] update some variables names
j-mnizhek Jul 9, 2026
5ea3ceb
[chore] Merge branch 'release/v17' into UIK-5351/add-more-variables-t…
ilyabrower Jul 10, 2026
f83edb5
[theme] removed duplicates in depricates
ilyabrower Jul 13, 2026
e4ed6be
[theme] fix values for Wizard variables
j-mnizhek Jul 13, 2026
e111f7a
[theme] fix switch control bg
j-mnizhek Jul 13, 2026
f4516f6
[switch] update css file
Valeria-Zimnitskaya Jul 14, 2026
59fa951
[chore] Merge branch 'release/v17' into UIK-5351/add-more-variables-t…
ilyabrower Jul 16, 2026
8f52ab0
[UIK-5564][Button] Update button styles + removed hardcoded values + …
j-mnizhek Jul 20, 2026
25cb217
[chore] update snapshot
Valeria-Zimnitskaya Jul 20, 2026
cbcf31a
[theme] change form-control-s to 20px
sheila-semrush Jul 22, 2026
4b6c21e
[chore] fix correct token names for semantic spacing tokens (#3061)
slizhevskyv-semrush Jul 22, 2026
c75443c
[UIK-5580][Inputs] Update styles (#3059)
j-mnizhek Jul 24, 2026
2f5d341
[theme] add timing variables
sheila-semrush Jul 24, 2026
af06715
[theme] add Badge tokens and update DatePicker token values
j-mnizhek Jul 24, 2026
7a73135
[theme] update secondary controls lightness
j-mnizhek Jul 27, 2026
e00d1e7
[theme] update date-picker variables
j-mnizhek Jul 27, 2026
f1c268d
[theme] update vars for content padding
j-mnizhek Jul 28, 2026
8819591
[theme] add more padding variables
j-mnizhek Jul 28, 2026
a13aaab
[theme] add xsmall var for paddings
j-mnizhek Jul 28, 2026
d79b965
[chore] changed timing to easing key in theme
ilyabrower Jul 30, 2026
a1429b3
[chore] changed timing to easings key in theme
ilyabrower Jul 30, 2026
192a004
[theme] add vars for Presets components
j-mnizhek Jul 30, 2026
24945e1
[chore] Merge branch 'release/v18' into UIK-5351/add-more-variables-t…
ilyabrower Jul 30, 2026
c0997e9
[chore] Merge branch 'release/v18' into UIK-5351/add-more-variables-t…
ilyabrower Jul 31, 2026
37fff02
[UIK-5627] rebrand modal (#3079)
sheila-semrush Jul 31, 2026
a632ff6
[UIK-5613] checkbox radio switch rebranding (#3085)
slizhevskyv-semrush Jul 31, 2026
a4b3def
[UIK-5637][card] Update styles (#3080)
j-mnizhek Jul 31, 2026
dbfcd9d
[chore] update snapshots
Valeria-Zimnitskaya Jul 31, 2026
7895f42
[chore] update snapshots
Valeria-Zimnitskaya Jul 31, 2026
95922eb
[theme] update values for dimmed borders
j-mnizhek Jul 31, 2026
cfee282
[UIK-5586] Update Select and DropdownMenu styles (#3065)
sheila-semrush Aug 3, 2026
efd5d78
[theme] add more vars for content padding
j-mnizhek Aug 4, 2026
7c4b3ad
[theme] update value for Dot text
j-mnizhek Aug 4, 2026
231d98f
[theme] add 3 vars for gap and padding
j-mnizhek Aug 4, 2026
fbdea38
[chore] Merge branch 'release/v18' into UIK-5351/add-more-variables-t…
ilyabrower Aug 5, 2026
a595493
[theme] add 2 extra vars for gaps
j-mnizhek Aug 5, 2026
b440fda
[UIK-5619] tooltip and hint redesign (#3081)
ilyabrower Aug 5, 2026
4debd2d
UIK 5649/counter dot rebranding (#3103)
slizhevskyv-semrush Aug 5, 2026
cc7e1eb
[UIK-5551] pills rebranding (#3060)
slizhevskyv-semrush Aug 6, 2026
6dd1583
[UIK-5579][badge] redesign (#3082)
ilyabrower Aug 6, 2026
e96c719
[feature-popover] update styles (#3104)
j-mnizhek Aug 7, 2026
5562a1f
[UIK-5696][notice-bubble] Rebranding (#3109)
j-mnizhek Aug 7, 2026
b5b4e4f
[theme] update vars for ProgressBar
j-mnizhek Aug 7, 2026
358d7bd
[UIK-5609][InputTags] InputTags and Tag rebranding (#3073)
j-mnizhek Aug 10, 2026
d23311e
UIK 5658/pagination rebranding (#3107)
slizhevskyv-semrush Aug 10, 2026
30db205
[theme] make hover for secondary bg darker a little bit
j-mnizhek Aug 10, 2026
102b167
[UIK-5639] BulkTextarea and Textarea rebranding (#3090)
j-mnizhek Aug 10, 2026
2c8f764
[theme] add and update vars for breakpoints and layout
j-mnizhek Aug 11, 2026
344a78b
[UIK-5614][date-picker] changed border-radius in calendar (#3097)
ilyabrower Aug 12, 2026
0733e5d
[docs] update values in breakpoints doc
j-mnizhek Aug 12, 2026
7fd9180
[UIK-5581] filter trigger rebranding (#3066)
ilyabrower Aug 13, 2026
cf98b03
[theme] update values for a couple of variables
j-mnizhek Aug 14, 2026
ae9f537
[chore] Merge branch 'release/v18' into UIK-5351/add-more-variables-t…
ilyabrower Aug 14, 2026
57c393f
[theme] add xsmall gap
j-mnizhek Aug 14, 2026
b4e1267
[theme] remove accidental sync-tokens.ts
j-mnizhek Aug 14, 2026
57bc9be
[pills] update unit snapshots
Valeria-Zimnitskaya Aug 17, 2026
83eda70
[UIK-5737][scroll-area] changed css tokens (#3123)
ilyabrower Aug 17, 2026
2d1aa51
UI k 5700/rewrite component to ns (#3110)
slizhevskyv-semrush Aug 18, 2026
7d12b88
[theme] update values for selected TabLine item
j-mnizhek Aug 18, 2026
9d8d4df
[theme] update accent border in several vars
j-mnizhek Aug 18, 2026
1d4429d
[UIK-5667][skeleton, spin-container, spin] redesign (#3106)
ilyabrower Aug 18, 2026
9166717
[accordion] update styles
j-mnizhek Aug 18, 2026
62704ba
[chore] Merge branch 'UIK-5351/add-more-variables-to-theme'
j-mnizhek Aug 18, 2026
cc0866c
[accordion] update styles and component
j-mnizhek Aug 18, 2026
1118b60
[accordion] update border variable
j-mnizhek Aug 18, 2026
0184d54
[theme] fixed contrast in inverted spin & border tokens
sheila-semrush Aug 19, 2026
f09f28c
UI k 5553/links redesign (#3070)
ilyabrower Aug 20, 2026
b7e76af
[UIK-5804][drag-and-drop] changed bg color (#3140)
ilyabrower Aug 20, 2026
a17700e
[chore] update snapshots
Valeria-Zimnitskaya Aug 20, 2026
154ae02
[chore] update snapshots
Valeria-Zimnitskaya Aug 20, 2026
76facd8
[chore] Merge branch 'release/v18' into UIK-5351/add-more-variables-t…
ilyabrower Aug 24, 2026
8aa0820
[UIK-5686][wizard] rebranding (#3128)
slizhevskyv-semrush Aug 24, 2026
90585ad
[UIK-5652][tab-line, tab-panel] redesign (#3112)
ilyabrower Aug 25, 2026
6a8aae9
[chore] Merge branch 'release/v18' into UIK-5351/add-more-variables-t…
ilyabrower Aug 25, 2026
cc95408
[UIK-5642][breadcrumbs] added gap token (#3149)
ilyabrower Aug 25, 2026
63b870d
[chore] Merge branch 'release/v18' into UIK-5351/add-more-variables-t…
ilyabrower Aug 26, 2026
238fe5b
[chore] fixed linter
ilyabrower Aug 26, 2026
5f658e2
[UIK-5690][fullscreen-modal] changed css tokens (#3124)
ilyabrower Aug 26, 2026
f89d9d4
[theme] add bg-secondary-invert var
j-mnizhek Aug 26, 2026
5647a70
[UIK-5824] add min-width to Pills.Item.Text (#3148)
sheila-semrush Aug 26, 2026
a1ea5cf
[UIK-5848][chore] linter fix (#3158)
ilyabrower Aug 27, 2026
c0cb9e5
[theme] update chart palette values
j-mnizhek Aug 27, 2026
4cb7939
[theme] update semantic vars for chart data
j-mnizhek Aug 27, 2026
8f0f14a
UIK 5794/slider rebranding (#3144)
slizhevskyv-semrush Aug 27, 2026
edacee4
[UIK-5789][color-picker] redesign (#3150)
ilyabrower Aug 28, 2026
73a307f
[UIK-5669][accordion] accordion rebranding/styles refactoring/stories…
slizhevskyv-semrush Aug 31, 2026
6d07292
Merge branch 'UIK-5351/add-more-variables-to-theme' into UIK-5669/acc…
j-mnizhek Sep 1, 2026
49799ba
[progress-bar] redesign (#3143)
ilyabrower Sep 2, 2026
13d5d74
[UIK-5905][link] fixed description of theme property (#3170)
ilyabrower Sep 4, 2026
29c0ddf
[skeleton] fixed area chart svgs (#3164)
sheila-semrush Sep 7, 2026
45b3be5
[color-picker] removed unnecessary opacity (#3162)
ilyabrower Sep 7, 2026
82d85bd
[theme] make text-secondary and text-placeholder lighter
sheila-semrush Sep 7, 2026
2c7b074
[UIK-5788][data-table] changed LinkAction api, fixed ui (#3152)
ilyabrower Sep 9, 2026
4d3ec27
[typography] update styles (#3130)
j-mnizhek Sep 10, 2026
312b4f2
Merge remote-tracking branch 'origin/UIK-5351/add-more-variables-to-t…
slizhevskyv-semrush Sep 10, 2026
fb9ec6e
[accordion] update tests
Valeria-Zimnitskaya Sep 10, 2026
dd10ca0
[UIK-5669][accordion] update styles to have higher priority
slizhevskyv-semrush Sep 10, 2026
a4df1eb
Merge branch 'UIK-5669/accordion-rebranding' of github.com:semrush/in…
slizhevskyv-semrush Sep 10, 2026
f166d75
[accordion] update snapshots
Valeria-Zimnitskaya Sep 14, 2026
6c37f5c
[accordion] test stories and test
Valeria-Zimnitskaya Sep 14, 2026
2a40ace
[chore] megre release v18
Valeria-Zimnitskaya Sep 14, 2026
0b26c4a
[chore] megre release v18
Valeria-Zimnitskaya Sep 14, 2026
32536f1
[UIK-5669][accordion,animation] add reduce motion media rule for Coll…
slizhevskyv-semrush Sep 15, 2026
c200135
[UIK-5669][accordion,animation] add reduce motion media rule for Coll…
slizhevskyv-semrush Sep 15, 2026
1a39d35
[UIK-5669][accordion] update styles
slizhevskyv-semrush Sep 16, 2026
c1cbd42
[UIK-5669][accordion] update styles
slizhevskyv-semrush Sep 16, 2026
eafaf41
[accordion] update test
Valeria-Zimnitskaya Sep 16, 2026
b80238d
[accordion] update test
Valeria-Zimnitskaya Sep 16, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion playground/components/ControlPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function GroupControl({ groupName, controls, groupPropName, onControlChange, isO
<Accordion.Item value={0}>
<Accordion.Item.Toggle className={styles.fullWidthItem}>
<Accordion.Item.ToggleButton>
<Accordion.Item.Chevron mr={2} color='var(--intergalactic-icon-secondary-neutral)' />
<Accordion.Item.Chevron color='var(--intergalactic-icon-secondary-neutral)' />
<Text size={200} fontWeight={500}>
{groupName}
</Text>
Expand Down
29 changes: 22 additions & 7 deletions semcore/accordion/__tests__/__snapshots__/index.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,30 @@ exports[`Accordion > Verify data-ui-name 1`] = `
{
"children": [
{
"children": [],
"uiName": "Item.ToggleButton",
"children": [
{
"children": [
{
"children": [],
"uiName": "Item.ToggleButton",
},
],
"uiName": "Item.Toggle",
},
{
"children": [
{
"children": [],
"uiName": "Box",
},
],
"uiName": "Item.Collapse",
},
],
"uiName": "Accordion.Item",
},
],
"uiName": "Item.Toggle",
},
{
"children": [],
"uiName": "Item.Collapse",
"uiName": "Accordion",
},
],
"uiName": null,
Expand Down
25 changes: 13 additions & 12 deletions semcore/accordion/__tests__/accordion.axe-test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,6 @@ test.describe(`@accordion ${TAG.ACCESSIBILITY}`, () => {
}
});

test('Custom styles', async ({ page }) => {
await loadPage(page, 'stories/components/accordion/docs/examples/custom_styles.tsx', 'en');

const violations = await getAccessibilityViolations({ page });

expect(violations).toEqual([]);
});

test('Heading tag', async ({ page }) => {
await loadPage(page, 'stories/components/accordion/docs/examples/heading_tag.tsx', 'en');

Expand All @@ -36,12 +28,21 @@ test.describe(`@accordion ${TAG.ACCESSIBILITY}`, () => {
expect(violations).toEqual([]);
});

test('Non compact', async ({ page }) => {
await loadPage(page, 'stories/components/accordion/docs/examples/non_compact.tsx', 'en');
test('Primary accordion', async ({ page }) => {
await loadPage(page, 'stories/components/accordion/docs/examples/primary_accordion.tsx', 'en');

const violations = await getAccessibilityViolations({ page });
{
const violations = await getAccessibilityViolations({ page });

expect(violations).toEqual([]);
expect(violations).toEqual([]);
}
{
await page.keyboard.press('Tab');
await page.keyboard.press('Space');
const violations = await getAccessibilityViolations({ page });

expect(violations).toEqual([]);
}
});

test('One section opening', async ({ page }) => {
Expand Down
122 changes: 107 additions & 15 deletions semcore/accordion/__tests__/accordion.browser-test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,21 @@ import { loadPage } from '@semcore/testing-utils/shared/helpers';
import { TAG } from '@semcore/testing-utils/shared/tags';

export const locators = {
accordion: (page: Page) => page.locator(`[data-ui-name="Accordion"]`),
item: (page: Page, index?: number) => {
const base = page.locator(`[data-ui-name="Accordion.Item"]`);
return typeof index === 'number' ? base.nth(index) : base;
},
collapse: (page: Page, index?: number) => {
const base = page.locator(`[data-ui-name="Item.Collapse"]`);
return typeof index === 'number' ? base.nth(index) : base;
},
// The collapse content wrapper carries the generic data-ui-name="Box",
// so it is addressed as the direct child of Item.Collapse.
collapseContainer: (page: Page, index?: number) => {
const base = page.locator(`[data-ui-name="Item.Collapse"] > [data-ui-name="Box"]`);
return typeof index === 'number' ? base.nth(index) : base;
},
chevron: (page: Page, index?: number) => {
const base = page.locator(`svg[data-ui-name="Item.Chevron"]`);
return typeof index === 'number' ? base.nth(index) : base;
Expand All @@ -20,6 +31,10 @@ export const locators = {
const base = page.getByRole('heading');
return typeof index === 'number' ? base.nth(index) : base;
},
toggleButton: (page: Page, index?: number) => {
const base = page.locator(`[data-ui-name="Item.ToggleButton"]`);
return typeof index === 'number' ? base.nth(index) : base;
},
};

/* =====================================================
Expand All @@ -28,8 +43,21 @@ Visual states, hover and focus styles, paddings, margins, and snapshots.
===================================================== */
test.describe(`${TAG.VISUAL}`, () => {
const variables = [
{ use: 'primary' },
{ use: 'secondary' },
{
use: 'primary',
// The chevron stays in the flow: `order` moves it after the label and
// `justify-content: space-between` on the toggle button pins it to the right edge.
chevronOrder: '1',
toggleButtonGap: '8px',
togglePadding: '8px 16px 8px 20px',
},
{
use: 'secondary',
// Here the chevron leads the label, separated only by the toggle button gap.
chevronOrder: '0',
toggleButtonGap: '4px',
togglePadding: '8px 2px',
},
];
variables.forEach((item) => {
test(`Verify use=${item.use}`, {
Expand All @@ -38,7 +66,7 @@ test.describe(`${TAG.VISUAL}`, () => {
'@accordion'],
},
async ({ page }) => {
await loadPage(page, 'stories/components/accordion/docs/examples/basic_usage.tsx', 'en', item);
await loadPage(page, 'stories/components/accordion/docs/examples/basic_usage.tsx', 'en', { use: item.use });

await test.step('Verify active and normal states', async () => {
await expect(page).toHaveScreenshot();
Expand All @@ -50,20 +78,38 @@ test.describe(`${TAG.VISUAL}`, () => {
await expect(page).toHaveScreenshot();
});

await test.step('Verify toggle margins', async () => {
await test.step('Verify chevron placement', async () => {
const count = await locators.chevron(page).count();
for (let i = 0; i < count; i++) {
await expect(locators.chevron(page, i)).toHaveCSS('margin-right', '8px');
await expect(locators.chevron(page, i)).toHaveCSS('order', item.chevronOrder);
// The spacing comes from the toggle button gap, never from a margin on the chevron.
await expect(locators.chevron(page, i)).toHaveCSS('margin-right', '0px');
}
});

await test.step('Verify item padding', async () => {
await test.step('Verify gap between chevron and label', async () => {
const count = await locators.toggleButton(page).count();
for (let i = 0; i < count; i++) {
await expect(locators.toggleButton(page, i)).toHaveCSS('column-gap', item.toggleButtonGap);
}
});

await test.step('Verify toggle padding', async () => {
const count = await locators.toggle(page).count();
for (let i = 0; i < count; i++) {
await expect(locators.toggle(page, i)).toHaveCSS('padding-bottom', '8px');
await expect(locators.toggle(page, i)).toHaveCSS('padding', item.togglePadding);
}
});

await test.step('Verify accordion stacks items in a column with a gap', async () => {
await expect(locators.accordion(page)).toHaveCSS('flex-direction', 'column');
await expect(locators.accordion(page)).toHaveCSS('row-gap', '2px');
});

await test.step('Verify collapse content padding', async () => {
await expect(locators.collapseContainer(page, 0)).toHaveCSS('padding', '12px 20px');
});

await test.step('Verify h3 tab by default', async () => {
const count = await locators.toggle(page).count();

Expand All @@ -85,16 +131,62 @@ test.describe(`${TAG.VISUAL}`, () => {
await expect(page).toHaveScreenshot();
});

test('Verify custom styles for selected toggle ', {
tag: [TAG.PRIORITY_MEDIUM,
test('Verify selected item styles in primary accordion', {
tag: [TAG.PRIORITY_HIGH,
'@accordion'],
}, async ({ page }) => {
await loadPage(page, 'stories/components/accordion/docs/examples/custom_styles.tsx', 'en');
await loadPage(page, 'stories/components/accordion/docs/examples/primary_accordion.tsx', 'en');

await test.step('Verify collapsed item keeps all corners rounded', async () => {
await expect(locators.item(page, 0)).toHaveCSS('border-radius', '8px');
await expect(locators.toggle(page, 0)).toHaveCSS('border-bottom-left-radius', '8px');
await expect(locators.toggle(page, 0)).toHaveCSS('border-bottom-right-radius', '8px');
});

await locators.toggle(page, 0).click();
await page.keyboard.press('Tab');
await page.keyboard.press('Space');
await locators.collapse(page, 1).waitFor({ state: 'visible' });
await expect(page).toHaveScreenshot();
await locators.collapse(page, 0).waitFor({ state: 'visible' });

await test.step('Verify expanded toggle squares its bottom corners', async () => {
await expect(locators.toggle(page, 0)).toHaveCSS('border-bottom-left-radius', '0px');
await expect(locators.toggle(page, 0)).toHaveCSS('border-bottom-right-radius', '0px');
});

await test.step('Verify accent bar is shown on the expanded item', async () => {
// In the primary variant the accent bar is the item's ::before overlay,
// toggled through opacity, so it cannot be read from a regular locator.
// The bar fades in, so poll until the opacity transition settles.
await expect
.poll(async () =>
locators.item(page, 0).evaluate((el) => getComputedStyle(el, '::before').opacity),
)
.toBe('1');

const width = await locators
.item(page, 0)
.evaluate((el) => getComputedStyle(el, '::before').width);

expect(width).toBe('2px');
});

await test.step('Verify expanded state snapshot', async () => {
await expect(page).toHaveScreenshot();
});

await test.step('Verify corners are restored after collapsing', async () => {
await locators.toggle(page, 0).click();
await locators.collapse(page, 0).waitFor({ state: 'hidden' });
await expect(locators.toggle(page, 0)).toHaveCSS('border-bottom-left-radius', '8px');
await expect(locators.toggle(page, 0)).toHaveCSS('border-bottom-right-radius', '8px');
});

await test.step('Verify accent bar is hidden after collapsing', async () => {
// The bar fades out, so poll until the opacity transition settles.
await expect
.poll(async () =>
locators.item(page, 0).evaluate((el) => getComputedStyle(el, '::before').opacity),
)
.toBe('0');
});
});

test('Verify focus on focusable item inside accordion', {
Expand Down Expand Up @@ -330,7 +422,7 @@ test.describe(`${TAG.FUNCTIONAL}`, () => {
TAG.MOUSE,
'@accordion'],
}, async ({ page }) => {
await loadPage(page, 'stories/components/accordion/tests/examples/default-values.tsx', 'en');
await loadPage(page, 'stories/components/accordion/tests/examples/values.tsx', 'en');
await expect(page.locator('[data-test-id="default-value"]')).toBeVisible();
});

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 21 additions & 10 deletions semcore/accordion/src/Accordion.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Collapse as CollapseAnimate, Flex } from '@semcore/base-components';
import { Collapse as CollapseAnimate, Flex, Box } from '@semcore/base-components';
import type { Intergalactic } from '@semcore/core';
import { createComponent, Component, sstyled, Root } from '@semcore/core';
import uniqueIDEnhancement from '@semcore/core/lib/utils/uniqueID';
Expand Down Expand Up @@ -70,8 +70,10 @@ class RootAccordion extends Component<
}

render() {
const { Children } = this.asProps;
return <Children />;
const SAccordion = Root;
const { styles } = this.asProps;

return sstyled(styles)(<SAccordion render={Flex} />);
}
}
export class RootItem extends Component<
Expand Down Expand Up @@ -131,8 +133,10 @@ export class RootItem extends Component<
}

render() {
const { Children } = this.asProps;
return <Children />;
const SAccordionItem = Root;
const { styles } = this.asProps;

return sstyled(styles)(<SAccordionItem render={Box} />);
}
}

Expand Down Expand Up @@ -184,10 +188,11 @@ function ToggleButton(
'ToggleButton'
>,
) {
const SItemToggleButton = Root;
const { styles } = props;

return sstyled(styles)(
<Root render={Flex} alignItems='center' role='button' />,
<SItemToggleButton render={Flex} alignItems='center' role='button' />,
);
}

Expand All @@ -198,17 +203,23 @@ function Collapse(
'Collapse'
>,
) {
const { selected } = props;
const SItemCollapse = Root;
const SItemCollapseContainer = Box;
const { selected, styles, Children } = props;
const visible = selected;

return (
<Root
return sstyled(styles)(
<SItemCollapse
render={CollapseAnimate}
visible={visible}
interactive
inert={!visible ? '' : undefined}
aria-hidden={!visible}
/>
>
<SItemCollapseContainer>
<Children />
</SItemCollapseContainer>
</SItemCollapse>,
);
}

Expand Down
Loading
Loading