Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
201578c
feat: enable compat
markjaniczak Apr 24, 2025
057e447
feat: enable compat
markjaniczak Apr 24, 2025
dd0047d
chore: add dist artifacts
markjaniczak Apr 24, 2025
5a05389
chore: add dist artifacts
markjaniczak Apr 24, 2025
13e7e27
fix: fix accessibility label
markjaniczak May 2, 2025
2cb0351
chore: build artifacts
markjaniczak May 2, 2025
8eb42b9
fix: daterangepickerfield not resetting
markjaniczak May 12, 2025
c0a34a7
fix: do not prevent event on paste
markjaniczak May 12, 2025
184d3e1
fix: do not prevent keydown if ctrl or meta key is held
markjaniczak May 12, 2025
87d6ec4
fix: tags input
markjaniczak May 19, 2025
d40a951
feat: add open on focus option
markjaniczak May 20, 2025
985517d
fix: revert
markjaniczak May 20, 2025
89dfa61
fix: revert
markjaniczak May 20, 2025
f347278
fix: focus
markjaniczak May 20, 2025
3c58eaa
fix: focus
markjaniczak May 20, 2025
ecfe93c
fix: focus
markjaniczak May 20, 2025
8ddf1d0
feat: add copy paste function to date field input
markjaniczak May 28, 2025
42a65e7
Merge branch 'feat/1897' into v2
markjaniczak May 28, 2025
812dfad
chore: update artifacts
markjaniczak May 28, 2025
aade35b
feat: add to date range field
markjaniczak May 28, 2025
23ed663
Merge branch 'feat/1897' into v2
markjaniczak May 28, 2025
7b9538e
chore: update artifacts
markjaniczak May 28, 2025
c44f5d6
Merge remote-tracking branch 'upstream/v2' into v2
markjaniczak Jul 8, 2025
1d78614
feat: add readonly to number field
markjaniczak Jul 8, 2025
13ff72e
feat: add color swatches
markjaniczak Jul 14, 2025
939adf2
feat: use radix colors
markjaniczak Jul 14, 2025
bd0be40
feat: update docs
markjaniczak Jul 14, 2025
10f9912
feat: docs
markjaniczak Jul 14, 2025
fdd294a
feat: comments
markjaniczak Jul 14, 2025
7495c92
feat: tests
markjaniczak Jul 14, 2025
a547d27
feat: change color picker colors
markjaniczak Jul 14, 2025
b4c081f
feat: docs
markjaniczak Jul 14, 2025
b317675
feat: utils
markjaniczak Jul 14, 2025
4a16bc7
chore: remove console.log
markjaniczak Jul 22, 2025
1920189
chore: remove console log
markjaniczak Aug 6, 2025
d4561b1
Merge remote-tracking branch 'upstream/v2' into v2
markjaniczak Feb 5, 2026
e202618
fix: build errors
markjaniczak Feb 5, 2026
13c4ce1
chore: update build artifacts
markjaniczak Feb 5, 2026
8a9a72f
chore: remove dist
markjaniczak Feb 10, 2026
2e40589
chore: update gitignore
markjaniczak Feb 10, 2026
942f417
Merge v2 into current branch
zernonia Mar 1, 2026
e4f9799
fix: handled coderabbit feedback
zernonia Mar 1, 2026
d7855fc
chore: position folder, add test
zernonia Mar 1, 2026
3501023
revert: compatConfig
zernonia Mar 1, 2026
3e9ab0c
revert: unneeded stuff
zernonia Mar 1, 2026
a465add
Merge remote-tracking branch 'origin/v2' into 501-feature-colorpicker
zernonia Mar 1, 2026
670fbc8
revert: unneeded change
zernonia Mar 1, 2026
aa71c5b
feat: new ColorArea component
zernonia Mar 2, 2026
93e918f
feat: new ColorField component
zernonia Mar 2, 2026
e30b2f7
feat: new ColorSlider component
zernonia Mar 2, 2026
487b826
refactor: swatches component
zernonia Mar 2, 2026
59e183f
feat: demos and shared function
zernonia Mar 2, 2026
016f135
fix: adapt feedback
zernonia Mar 2, 2026
248980b
docs: add color docs
zernonia Mar 2, 2026
cd80cc5
docs: update comments
zernonia Mar 2, 2026
5581550
Merge remote-tracking branch 'origin/v2' into 501-feature-colorpicker
zernonia Mar 2, 2026
6d05003
docs: chore gen
zernonia Mar 2, 2026
5e5a4de
fix: quick test setup, feedback
zernonia Mar 2, 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
1 change: 1 addition & 0 deletions .histoire/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ export default defineConfig({
tree: {
groups: [
{ title: 'Components', include: _file => true },
{ title: 'Compounds', id: 'compounds' },
{ id: 'utilities', title: 'Utilities' },
],
},
Expand Down
19 changes: 19 additions & 0 deletions docs/.vitepress/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,19 @@ export default defineConfig({
{ text: 'Toggle Group', link: '/docs/components/toggle-group' },
],
},
{
text: 'Color',
items: [
{ text: `Color Area ${BadgeHTML('Alpha', true)}`, link: '/docs/components/color-area' },
{ text: `Color Field ${BadgeHTML('Alpha', true)}`, link: '/docs/components/color-field' },
{ text: `Color Slider ${BadgeHTML('Alpha', true)}`, link: '/docs/components/color-slider' },
{ text: `Color Swatch ${BadgeHTML('Alpha', true)}`, link: '/docs/components/color-swatch' },
{
text: `Color Swatch Picker ${BadgeHTML('Alpha', true)}`,
link: '/docs/components/color-swatch-picker',
},
],
},
{
text: 'Dates',
items: [
Expand Down Expand Up @@ -314,6 +327,12 @@ export default defineConfig({
{ text: 'Checkbox Group', link: '/examples/checkbox-group' },
],
},
{
text: 'Color',
items: [
{ text: 'Color Picker', link: '/examples/color-picker' },
],
},
{
text: 'Combobox',
items: [
Expand Down
31 changes: 31 additions & 0 deletions docs/components/demo/ColorArea/tailwind/index.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<script setup lang="ts">
import {
ColorAreaArea,
ColorAreaRoot,
ColorAreaThumb,
} from 'reka-ui'
import { ref } from 'vue'

const color = ref('#ff0000')
</script>

<template>
<div class="flex flex-col gap-4">
<div class="text-sm text-gray-600 dark:text-gray-400">
Current: {{ color }}
</div>

<ColorAreaRoot
v-slot="{ style }"
v-model="color"
class="relative"
>
<ColorAreaArea
class="relative w-[200px] h-[200px] rounded-lg overflow-hidden focus:outline-none focus:ring-2 focus:ring-green-500"
:style="style"
>
<ColorAreaThumb class="block w-4 h-4 rounded-full bg-white border-2 border-gray-400 shadow cursor-pointer" />
</ColorAreaArea>
</ColorAreaRoot>
</div>
</template>
35 changes: 35 additions & 0 deletions docs/components/demo/ColorField/tailwind/index.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<script setup lang="ts">
import {
ColorFieldInput,
ColorFieldRoot,
} from 'reka-ui'
import { ref } from 'vue'

const color = ref('#3b82f6')
</script>

<template>
<div class="flex flex-col gap-3">
<ColorFieldRoot
v-model="color"
class="inline-flex flex-col gap-1"
>
<label class="text-sm font-medium text-gray-900 dark:text-gray-100">
Color
</label>
<div class="flex items-center gap-2">
<div
class="w-8 h-8 rounded border border-gray-200 dark:border-gray-700 shrink-0"
:style="{ background: color }"
/>
<ColorFieldInput
class="px-3 py-2 border border-gray-300 dark:border-gray-600 bg-white dark:bg-gray-800 rounded-md text-sm focus:outline-none focus:ring-2 focus:ring-green-500 focus:border-green-500 disabled:opacity-50 disabled:cursor-not-allowed w-32"
/>
Comment thread
zernonia marked this conversation as resolved.
</div>
</ColorFieldRoot>

<div class="flex items-center gap-2 text-xs text-gray-500">
<span>Value: {{ color }}</span>
</div>
</div>
</template>
37 changes: 37 additions & 0 deletions docs/components/demo/ColorSlider/tailwind/index.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<script setup lang="ts">
import {
ColorSliderRoot,
ColorSliderThumb,
ColorSliderTrack,
} from 'reka-ui'
import { ref } from 'vue'

const color = ref('#10b981')
</script>

<template>
<div class="flex flex-col gap-4">
<ColorSliderRoot
v-model="color"
channel="hue"
class="relative flex items-center select-none touch-none w-[200px] h-5"
>
<ColorSliderTrack
class="relative flex-1 rounded-full h-3"
>
<div class="absolute inset-0 rounded-full" />
</ColorSliderTrack>
<ColorSliderThumb
class="block w-5 h-5 rounded-full bg-white border-2 border-gray-400 shadow-lg cursor-pointer hover:scale-110 transition-transform focus:outline-none focus:ring-2 focus:ring-green-500"
/>
</ColorSliderRoot>

<div class="flex items-center gap-2 text-xs text-gray-500">
<div
class="w-5 h-5 rounded border border-gray-200 shrink-0"
:style="{ background: color }"
/>
<span class="font-mono">{{ color }}</span>
</div>
</div>
</template>
12 changes: 12 additions & 0 deletions docs/components/demo/ColorSwatch/css/index.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<script setup lang="ts">
import { green } from '@radix-ui/colors'
import { ColorSwatch } from 'reka-ui'
import './styles.css'
</script>

<template>
<ColorSwatch
:color="green.green9"
class="swatch"
/>
</template>
11 changes: 11 additions & 0 deletions docs/components/demo/ColorSwatch/css/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
.swatch {
width: 32px;
height: 32px;
border-radius: 4px;
box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.15);
flex-shrink: 0;
}

.dark .swatch {
box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15);
}
11 changes: 11 additions & 0 deletions docs/components/demo/ColorSwatch/tailwind/index.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<script setup lang="ts">
import { green } from '@radix-ui/colors'
import { ColorSwatch } from 'reka-ui'
</script>

<template>
<ColorSwatch
:color="green.green9"
class="size-8 shrink-0 bg-[--reka-color-swatch-color] rounded ring-1 ring-inset ring-black/15 dark:ring-white/15"
/>
</template>
6 changes: 6 additions & 0 deletions docs/components/demo/ColorSwatch/tailwind/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./**/*.vue'],
theme: {},
plugins: [],
}
42 changes: 42 additions & 0 deletions docs/components/demo/ColorSwatchPicker/css/index.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<script setup lang="ts">
import { Icon } from '@iconify/vue'
import {
blue,
green,
orange,
pink,
red,
violet,
yellow,
} from '@radix-ui/colors'
import { ColorSwatchPickerItem, ColorSwatchPickerItemIndicator, ColorSwatchPickerItemSwatch, ColorSwatchPickerRoot } from 'reka-ui'
import './styles.css'

const colors = [
red.red9,
pink.pink9,
violet.violet9,
blue.blue9,
green.green9,
orange.orange9,
yellow.yellow9,
]
</script>

<template>
<ColorSwatchPickerRoot class="root">
<ColorSwatchPickerItem
v-for="color in colors"
:key="color"
:value="color"
class="item"
>
<ColorSwatchPickerItemSwatch
class="swatch"
/>
<ColorSwatchPickerItemIndicator class="indicator">
<Icon icon="radix-icons:check" />
</ColorSwatchPickerItemIndicator>
</ColorSwatchPickerItem>
</ColorSwatchPickerRoot>
</template>
32 changes: 32 additions & 0 deletions docs/components/demo/ColorSwatchPicker/css/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
.root {
display: flex;
gap: 8px;
}

.item {
position: relative;
}

.swatch {
height: 32px;
width: 32px;
border-radius: 4px;
box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.15);
flex-shrink: 0;
cursor: pointer;
}

.dark .swatch {
box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15);
}

.indicator {
position: absolute;
bottom: 4px;
right: 4px;
color: white;
}

.swatch[data-color-contrast='dark'] ~ .indicator {
color: black;
}
41 changes: 41 additions & 0 deletions docs/components/demo/ColorSwatchPicker/tailwind/index.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<script setup lang="ts">
import { Icon } from '@iconify/vue'
import {
blue,
green,
indigo,
orange,
red,
violet,
yellow,
} from '@radix-ui/colors'
import { ColorSwatchPickerItem, ColorSwatchPickerItemIndicator, ColorSwatchPickerItemSwatch, ColorSwatchPickerRoot } from 'reka-ui'

const colors = [
red.red9,
orange.orange9,
yellow.yellow9,
green.green9,
blue.blue9,
indigo.indigo9,
violet.violet9,
]
</script>

<template>
<ColorSwatchPickerRoot class="flex gap-2">
<ColorSwatchPickerItem
v-for="color in colors"
:key="color"
:value="color"
class="relative"
>
<ColorSwatchPickerItemSwatch
class="size-8 rounded ring-1 ring-inset ring-black/15 dark:ring-white/15 bg-[--reka-color-swatch-color] peer"
/>
<ColorSwatchPickerItemIndicator class="text-white peer-data-[color-contrast=dark]:text-black absolute right-1 bottom-1">
<Icon icon="radix-icons:check" />
</ColorSwatchPickerItemIndicator>
</ColorSwatchPickerItem>
</ColorSwatchPickerRoot>
</template>
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./**/*.vue'],
theme: {},
plugins: [],
}
Loading
Loading