-
-
Notifications
You must be signed in to change notification settings - Fork 6
Update shadcn theme and fix/standardize styling #2193
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
94cb050
Update to latest shadcn themes
myieye 9747dcc
Fix broken theme values
myieye f0e3843
Improve theme-picker trigger contrast on home page
myieye a0fe555
Adapt ListItem to new theme colors
myieye e060e84
Fix: dark outline button border color
myieye 9e603bb
Update ghost and shell inputs for new shadcn theme
myieye de71839
Use button styling for sort badge-button
myieye aefd69f
Redesign ListItem states
myieye 8c6d1f7
Fix broken outlines in dark mode
myieye 6413d12
Improve writing system contrast
myieye bb2c733
Fix Add sense button outline cropped
myieye 3de1329
Try to fix tests
myieye f0aa75a
Remove test text
myieye 25b100f
Improve primary colour contrast
myieye 1c976eb
Add story for demoing theme colours
myieye 3ccb93c
More elegant demo data fix
myieye File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
80 changes: 80 additions & 0 deletions
80
frontend/viewer/src/stories/editor/fields/ws-colors.stories.svelte
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,80 @@ | ||
| <script module lang="ts"> | ||
| import {defineMeta} from '@storybook/addon-svelte-csf'; | ||
| import {onMount} from 'svelte'; | ||
|
|
||
| const {Story} = defineMeta({}); | ||
|
|
||
| </script> | ||
|
|
||
| <script lang="ts"> | ||
| import {useWritingSystemService, type WritingSystemService} from '$project/data'; | ||
| import {allWsEntry, writingSystems} from '$project/demo/demo-entry-data'; | ||
| import DictionaryEntry from '$lib/components/dictionary/DictionaryEntry.svelte'; | ||
|
|
||
| let wsService = $state<WritingSystemService>(); | ||
| onMount(() => { | ||
| wsService = useWritingSystemService(); | ||
| }); | ||
| </script> | ||
|
|
||
| <Story name="All writing system colors"> | ||
| {#snippet template()} | ||
| <div class="flex flex-col gap-8 p-4"> | ||
|
myieye marked this conversation as resolved.
|
||
| <h2 class="text-lg font-bold">Dictionary Entry — Light & Dark</h2> | ||
| <div class="grid grid-cols-2 gap-4"> | ||
| <div class="light rounded border p-4" data-theme="blue"> | ||
| <h3 class="font-semibold mb-2">Light</h3> | ||
| <DictionaryEntry entry={allWsEntry} /> | ||
| </div> | ||
| <div class="dark rounded border p-4 bg-background text-foreground" data-theme="blue"> | ||
| <h3 class="font-semibold mb-2">Dark</h3> | ||
| <DictionaryEntry entry={allWsEntry} /> | ||
| </div> | ||
| </div> | ||
|
|
||
| <hr class="border-t" /> | ||
|
|
||
| <h2 class="text-lg font-bold">Color Swatches — Light & Dark</h2> | ||
| <div class="grid grid-cols-2 gap-4"> | ||
| <div class="light rounded border p-4" data-theme="blue"> | ||
| <h3 class="font-semibold mb-2">Light</h3> | ||
| <div class="flex flex-col gap-2"> | ||
| <h4 class="text-sm font-medium">Vernacular</h4> | ||
| {#each writingSystems.vernacular as ws (ws.wsId)} | ||
| {@const color = wsService?.wsColor(ws.wsId, 'vernacular')} | ||
| <span class={color}> | ||
| {color} | ||
| </span> | ||
| {/each} | ||
| <h4 class="text-sm font-medium mt-2">Analysis</h4> | ||
| {#each writingSystems.analysis as ws (ws.wsId)} | ||
| {@const color = wsService?.wsColor(ws.wsId, 'analysis')} | ||
| <span class={color}> | ||
| {color} | ||
| </span> | ||
| {/each} | ||
| </div> | ||
| </div> | ||
| <div class="dark rounded border p-4 bg-background text-foreground" data-theme="blue"> | ||
| <h3 class="font-semibold mb-2">Dark</h3> | ||
| <div class="flex flex-col gap-2"> | ||
| <h4 class="text-sm font-medium">Vernacular</h4> | ||
| {#each writingSystems.vernacular as ws (ws.wsId)} | ||
| {@const color = wsService?.wsColor(ws.wsId, 'vernacular')} | ||
| <span class={color}> | ||
| {color} | ||
| </span> | ||
| {/each} | ||
| <h4 class="text-sm font-medium mt-2">Analysis</h4> | ||
| {#each writingSystems.analysis as ws (ws.wsId)} | ||
| {@const color = wsService?.wsColor(ws.wsId, 'analysis')} | ||
| <span class={color}> | ||
| {color} | ||
| </span> | ||
| {/each} | ||
| </div> | ||
| </div> | ||
| </div> | ||
| </div> | ||
| {/snippet} | ||
| </Story> | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.