From a274f3102966e9d00b2d1ecc220274d0ab092ae8 Mon Sep 17 00:00:00 2001 From: Gauthier Roebroeck Date: Fri, 30 Jan 2026 17:42:32 +0800 Subject: [PATCH] filters --- next-ui/src/components/filter/List.stories.ts | 5 ++++- next-ui/src/components/filter/List.vue | 10 +++++++--- next-ui/src/components/filter/TriState.stories.ts | 6 ------ next-ui/src/components/filter/TriState.vue | 13 ++++++++++++- 4 files changed, 23 insertions(+), 11 deletions(-) diff --git a/next-ui/src/components/filter/List.stories.ts b/next-ui/src/components/filter/List.stories.ts index 849cf6de..f894aa6a 100644 --- a/next-ui/src/components/filter/List.stories.ts +++ b/next-ui/src/components/filter/List.stories.ts @@ -22,6 +22,7 @@ const meta = { }, args: { 'onUpdate:modelValue': fn(), + 'onUpdate:mode': fn(), items: [ { title: 'Tag 1', value: '+tag1', valueExclude: '-tag1' }, { title: 'Tag 2', value: '+tag2', valueExclude: '-tag2' }, @@ -41,16 +42,18 @@ export const Default: Story = { export const InitialValue: Story = { args: { modelValue: ['+tag1', '-tag2', 'crap'], + mode: 'allOf', }, } export const Color: Story = { args: { + modelValue: ['+tag1', '-tag2', 'crap'], color: 'red', }, } -export const Objects: Story = { +export const ValueObjects: Story = { args: { items: [ { title: 'Tag 1', value: { include: 'tag1' }, valueExclude: { exclude: 'tag1' } }, diff --git a/next-ui/src/components/filter/List.vue b/next-ui/src/components/filter/List.vue index 13cb69fc..454e4c01 100644 --- a/next-ui/src/components/filter/List.vue +++ b/next-ui/src/components/filter/List.vue @@ -19,8 +19,12 @@