File tree Expand file tree Collapse file tree 1 file changed +16
-9
lines changed Expand file tree Collapse file tree 1 file changed +16
-9
lines changed Original file line number Diff line number Diff line change @@ -122,20 +122,27 @@ const motions = {
122122 } ,
123123}
124124
125- // disable all documentation motions
126- Object . entries ( motions ) . forEach ( ( [ _ , val ] ) => {
127- Object . keys ( val ) . forEach ( ( k ) => {
128- // nested motion config
125+ /**
126+ * This is to disable animations, the animations are a bit much and need tweaking
127+ * we should also provide a way for users to disable them when enabled.
128+ */
129+ for ( const val of Object . values ( motions ) ) {
130+ // set each variant to an empty object
131+ for ( const k of Object . keys ( val ) ) {
132+ // h1,common are nested reset their variants to an empty object
129133 if ( [ 'h1' , 'common' ] . includes ( k ) ) {
130- Object . keys ( val ) . forEach ( ( kNested ) => {
131- val [ k ] [ kNested ] = { }
132- } )
134+ // @ts -expect-error not specific
135+ for ( const nestedK of Object . keys ( val [ k ] ) ) {
136+ // @ts -expect-error not specific
137+ val [ k ] [ nestedK ] = { }
138+ }
133139 }
134140 else {
141+ // @ts -expect-error not specific
135142 val [ k ] = { }
136143 }
137- } )
138- } )
144+ }
145+ }
139146
140147export default defineAppConfig ( {
141148 ui : {
You can’t perform that action at this time.
0 commit comments