-
Notifications
You must be signed in to change notification settings - Fork 0
Tailwind 4 #136
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
Tailwind 4 #136
Changes from 10 commits
Commits
Show all changes
26 commits
Select commit
Hold shift + click to select a range
93cdf81
automatic upgrade
dwightjack e7278db
update vite config and re-order class names
dwightjack 272bb27
inline transition classes
dwightjack b7d1de1
cleanup
dwightjack 3329b63
remove unused deps
dwightjack a697665
refactor gaps and alignments
dwightjack 4701e09
remove unused prop
dwightjack 0f6d26a
remove redundant default number
dwightjack 4c2c2da
code refactoring
dwightjack 3502a9b
style updates
dwightjack 580c458
markup updates
dwightjack add255c
tmp pinia plugin
dwightjack 0fa01e7
refactor and use vueuse
dwightjack a1e8655
refactor
dwightjack 7c63a48
fixes
dwightjack faf8cc7
settings dialog
dwightjack b844bec
refactoring
dwightjack c69a7b3
use templateRef
dwightjack 57b6a29
rendering and animation improvements
dwightjack 2bcb44a
announce timer
dwightjack 0d573f0
assign a label
dwightjack 7ad871d
initial setup of tests
dwightjack 0bdc5eb
some more tests
dwightjack b492b34
refactor with fixtures and add more tests
dwightjack 361c434
updated and new tests
dwightjack e7f4d75
Merge pull request #137 from dwightjack/tests
dwightjack 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
Large diffs are not rendered by default.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,21 +1,45 @@ | ||
| @tailwind base; | ||
| @tailwind components; | ||
| @tailwind utilities; | ||
| @import 'tailwindcss'; | ||
|
|
||
| @layer base { | ||
| body { | ||
| @apply text-gray-700 dark:bg-stone-800 dark:text-gray-50; | ||
| @utility input { | ||
|
|
||
| & { | ||
| @apply appearance-none bg-transparent border border-gray-300 dark:border-stone-600 rounded-lg px-2 py-1 text-gray-700 dark:text-gray-200; | ||
| } | ||
| } | ||
|
|
||
| @layer components { | ||
| .input { | ||
| @apply appearance-none bg-transparent border border-gray-300 dark:border-stone-600 rounded-lg pl-2 py-1 text-gray-700 dark:text-gray-200; | ||
| &:is(select) { | ||
| @apply pe-6; | ||
| } | ||
| .text-gray-700[type='number'] { | ||
| -moz-appearance: textfield; | ||
|
|
||
| &[type='number'] { | ||
| appearance: textfield; | ||
| } | ||
| .text-gray-700[type='number']::-webkit-inner-spin-button { | ||
| &[type='number']::-webkit-inner-spin-button { | ||
| -webkit-appearance: none; | ||
| } | ||
| } | ||
|
|
||
|
|
||
| @utility grid-overlap { | ||
| & { | ||
| grid-template: 'full' auto / auto | ||
| } | ||
|
|
||
| & > * { | ||
| grid-area: full; | ||
| } | ||
| } | ||
|
|
||
| @layer theme { | ||
| @property --s { | ||
| syntax: '*'; | ||
| inherits: false; | ||
| } | ||
|
|
||
|
|
||
| } | ||
|
|
||
| @layer base { | ||
| body { | ||
| @apply text-gray-700 dark:bg-stone-800 dark:text-gray-50; | ||
| } | ||
| } |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,21 +1,19 @@ | ||
| <script setup lang="ts"> | ||
| import { bool, oneOf } from 'vue-types'; | ||
| import { oneOf } from 'vue-types'; | ||
| import { iconList } from './BaseIcon.vue'; | ||
| import BaseIcon from './BaseIcon.vue'; | ||
| defineProps({ | ||
| pressed: bool().def(false), | ||
| type: oneOf(['button', 'reset', 'submit', undefined] as const).def('button'), | ||
| icon: oneOf(iconList).isRequired, | ||
| }); | ||
| defineSlots<{ default?: () => unknown }>(); | ||
| </script> | ||
| <template> | ||
| <button | ||
| :type="type" | ||
| class="rounded leading-none p-2 border-2 border-transparent text-blue-500 dark:text-sky-400 transition-colors duration-150 space-x-1" | ||
| :class="{ | ||
| 'bg-blue-200 hover:border-blue-500': pressed, | ||
| 'hover:bg-blue-100 dark:hover:bg-sky-700': !pressed, | ||
| }" | ||
| :aria-pressed="pressed" | ||
| class="inline-flex gap-x-1 rounded-sm border-none p-3 align-middle leading-none text-blue-600 transition-colors duration-150 hover:bg-blue-100 dark:text-sky-400 dark:hover:bg-sky-700" | ||
| > | ||
| <slot /> | ||
| <BaseIcon :name="icon" /> | ||
| <span class="sr-only"><slot /></span> | ||
| </button> | ||
| </template> |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,21 +1,36 @@ | ||
| <script setup lang="ts"> | ||
| import { string, bool, oneOfType } from 'vue-types'; | ||
| import { string, bool, oneOfType, oneOf } from 'vue-types'; | ||
| type TagNames = keyof HTMLElementTagNameMap; | ||
| defineProps({ | ||
| tag: string().def('div'), | ||
| tag: string<TagNames>().def('div' as const), | ||
| centered: bool().def(false), | ||
| verticalAlign: oneOf(['start', 'stretch', 'end', 'center'] as const).def( | ||
| 'start', | ||
| ), | ||
| space: oneOfType([String, Number]).def(4), | ||
| }); | ||
| defineSlots<{ default?: () => unknown }>(); | ||
| </script> | ||
| <template> | ||
| <component | ||
| :is="tag" | ||
| class="flex items-start min-w-0" | ||
| class="gap flex min-w-0" | ||
| :class="{ | ||
| 'justify-center': centered, | ||
| [`gap-${space}`]: space, | ||
| 'items-center': verticalAlign === 'center', | ||
| 'items-stretch': verticalAlign === 'stretch', | ||
| 'items-end': verticalAlign === 'end', | ||
| 'items-start': verticalAlign === 'start', | ||
| }" | ||
| :style="{ | ||
| '--s': space !== 4 ? space : undefined, | ||
| }" | ||
| > | ||
| <slot /> | ||
| </component> | ||
| </template> | ||
| <style scoped> | ||
| .gap { | ||
| column-gap: calc(var(--spacing) * var(--s, 4)); | ||
| } | ||
| </style> | ||
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The CSS variable '--spacing' referenced in the column-gap calculation is undefined. Define this variable or replace it with a proper static value to ensure consistent layout spacing.