1818<template >
1919 <div
2020 :class =" { disabled: !checked, 'disable-action': disableAction }"
21- class =" re- switch"
21+ class =" switch"
2222 >
23- <label v-if =" $slots.default" :for =" id || name" class =" re- switch-label" >
23+ <label v-if =" $slots.default" :for =" id || name" class =" switch-label" >
2424 <slot />
2525 </label >
26- <div class =" re- switch-container" @click =" toggle($event)" >
27- <div class =" re- switch-thumb" :style =" styles" >
26+ <div class =" switch-container" @click =" toggle($event)" >
27+ <div class =" switch-thumb" :style =" styles" >
2828 <input
2929 :id =" id"
3030 type =" checkbox"
3333 :value =" value"
3434 tabindex =" -1"
3535 />
36- <button :type =" type" class =" re- switch-holder" >
36+ <button :type =" type" class =" switch-holder" >
3737 <svgicon width =" 10" height =" 10" name =" check" color =" white" ></svgicon >
3838 </button >
3939 </div >
@@ -120,41 +120,41 @@ export default {
120120$switch-width : 28px ;
121121$switch-height : 11px ;
122122$switch-thumb-size : 18px ;
123- .re- switch {
123+ .switch {
124124 display : flex ;
125125 align-items : center ;
126126 position : relative ;
127127 & .disabled {
128128 svg {
129129 display : none ;
130130 }
131- .re- switch-thumb {
131+ .switch-thumb {
132132 background-color : #f0f0f0 !important ;
133133 }
134134 }
135135 & .disable-action {
136136 opacity : 0.5 ;
137137 pointer-events : none ;
138138 cursor : default ;
139- .re- switch-thumb {
139+ .switch-thumb {
140140 background-color : var (--color-white ) !important ;
141141 transform : translate3d (-1px , -50% , 0px ) !important ;
142142 }
143143 & :active {
144- .re- switch-thumb {
144+ .switch-thumb {
145145 transform : translate3d (50% , -50% , 0px ) !important ;
146146 }
147147 }
148148 }
149- .re- switch-container {
149+ .switch-container {
150150 width : $switch-width ;
151151 height : $switch-height ;
152152 position : relative ;
153153 border-radius : $switch-height ;
154154 transition : $swift-ease-out ;
155155 background-color : var (--bg-opacity-20 );
156156 cursor : pointer ;
157- .re- switch-thumb {
157+ .switch-thumb {
158158 width : $switch-thumb-size ;
159159 height : $switch-thumb-size ;
160160 position : absolute ;
@@ -168,7 +168,7 @@ $switch-thumb-size: 18px;
168168 position : absolute ;
169169 left : -999em ;
170170 }
171- .re- switch-holder {
171+ .switch-holder {
172172 @include absoluteCenter ;
173173 width : $switch-thumb-size ;
174174 height : $switch-thumb-size ;
@@ -183,9 +183,9 @@ $switch-thumb-size: 18px;
183183 }
184184 }
185185 }
186- .re- switch-label {
186+ .switch-label {
187187 margin-right : 1em ;
188- color : var (--fg-secondary );
188+ color : var (--fg-primary );
189189 }
190190}
191191 </style >
0 commit comments