From a7677ef31f13fda2f7a71f5d2b4752dc65a4660f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tu=C4=9F=C3=A7e=20K=C3=BC=C3=A7=C3=BCko=C4=9Flu?= Date: Wed, 29 Jun 2022 17:13:48 +0300 Subject: [PATCH] props fix --- api-generator/components/slider.js | 4 ++-- src/components/slider/Slider.d.ts | 2 +- src/components/slider/Slider.vue | 12 ++++++------ src/views/slider/SliderDoc.vue | 12 ------------ 4 files changed, 9 insertions(+), 21 deletions(-) diff --git a/api-generator/components/slider.js b/api-generator/components/slider.js index 519aa2ad5..f6727378e 100644 --- a/api-generator/components/slider.js +++ b/api-generator/components/slider.js @@ -48,13 +48,13 @@ const SliderProps = [ description: "Index of the element in tabbing order." }, { - name: "ariaLabelledBy", + name: "aria-labelledby", type: "string", default: "null", description: "Establishes relationships between the component and label(s) where its value should be one or more element IDs." }, { - name: "ariaLabel", + name: "aria-label", type: "string", default: "null", description: "Used to define a string that labels the element." diff --git a/src/components/slider/Slider.d.ts b/src/components/slider/Slider.d.ts index 78a7c47c5..99eca9219 100755 --- a/src/components/slider/Slider.d.ts +++ b/src/components/slider/Slider.d.ts @@ -55,7 +55,7 @@ export interface SliderProps { /** * Establishes relationships between the component and label(s) where its value should be one or more element IDs. */ - ariaLabelledBy?: string | undefined; + ariaLabelledby?: string | undefined; /** * Used to define a string that labels the element. */ diff --git a/src/components/slider/Slider.vue b/src/components/slider/Slider.vue index 86b7d19d7..aa76d20c4 100755 --- a/src/components/slider/Slider.vue +++ b/src/components/slider/Slider.vue @@ -2,11 +2,11 @@
+ role="slider" :aria-valuemin="min" :aria-valuenow="modelValue" :aria-valuemax="max" :aria-labelledby="ariaLabelledby" :aria-label="ariaLabel" :aria-orientation="orientation"> + role="slider" :aria-valuemin="min" :aria-valuenow="modelValue ? modelValue[0] : null" :aria-valuemax="max" :aria-labelledby="ariaLabelledby" :aria-label="ariaLabel" :aria-orientation="orientation"> + role="slider" :aria-valuemin="min" :aria-valuenow="modelValue ? modelValue[1] : null" :aria-valuemax="max" :aria-labelledby="ariaLabelledby" :aria-label="ariaLabel" :aria-orientation="orientation">
@@ -44,13 +44,13 @@ export default { }, tabindex: { type: Number, - default: null + default: 0 }, - ariaLabelledBy: { + 'aria-labelledby': { type: String, default: null }, - ariaLabel: { + 'aria-label': { type: String, default: null } diff --git a/src/views/slider/SliderDoc.vue b/src/views/slider/SliderDoc.vue index 8635c7e14..48f5c2cff 100755 --- a/src/views/slider/SliderDoc.vue +++ b/src/views/slider/SliderDoc.vue @@ -120,18 +120,6 @@ export default { number null Index of the element in tabbing order. - - - ariaLabelledBy - string - null - Establishes relationships between the component and label(s) where its value should be one or more element IDs. - - - ariaLabel - string - null - Used to define a string that labels the element.