mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 02:11:05 +00:00
fix: avoid using reserved $
for Svelte 5 compat
Co-Authored-By: Eric Fulton <5297269+Sahasrara@users.noreply.github.com>
This commit is contained in:
parent
96aef1705c
commit
a0d5028540
2 changed files with 4 additions and 4 deletions
|
@ -23,8 +23,8 @@
|
||||||
|
|
||||||
ctx.add({ id, text, selected });
|
ctx.add({ id, text, selected });
|
||||||
|
|
||||||
const unsubscribe = ctx.currentId.subscribe(($) => {
|
const unsubscribe = ctx.currentId.subscribe((currentId) => {
|
||||||
selected = $ === id;
|
selected = currentId === id;
|
||||||
});
|
});
|
||||||
|
|
||||||
afterUpdate(() => {
|
afterUpdate(() => {
|
||||||
|
|
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
const dispatch = createEventDispatcher();
|
const dispatch = createEventDispatcher();
|
||||||
const steps = writable([]);
|
const steps = writable([]);
|
||||||
const stepsById = derived(steps, ($) =>
|
const stepsById = derived(steps, (steps) =>
|
||||||
$.reduce((a, c) => ({ ...a, [c.id]: c }), {})
|
steps.reduce((a, c) => ({ ...a, [c.id]: c }), {})
|
||||||
);
|
);
|
||||||
const preventChangeOnClickStore = writable(preventChangeOnClick);
|
const preventChangeOnClickStore = writable(preventChangeOnClick);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue