1
- // @ts -nocheck
2
1
"use client" ;
3
2
4
3
import AppBar from "material-web-components-react/app-bar" ;
@@ -36,6 +35,7 @@ import TextField from "material-web-components-react/text-field";
36
35
37
36
import Stack from "material-web-components-react/stack" ;
38
37
38
+ // @ts -expect-error
39
39
import pkgJson from "material-web-components-react/package.json?module=json" ;
40
40
41
41
import React , { useEffect , useState } from "react" ;
@@ -62,7 +62,7 @@ const DemoSection = ({ title, children }: { title: any; children: any }) => {
62
62
) ;
63
63
} ;
64
64
65
- const NavigationContent = ( { showNavigationModal , setShowNavigationModal } ) => {
65
+ const NavigationContent = ( { setShowNavigationModal } : { setShowNavigationModal : ( value : boolean ) => void } ) => {
66
66
return (
67
67
< >
68
68
< Link href = { "/" } >
@@ -227,6 +227,7 @@ export default function Home() {
227
227
opened = { showNavigationModal }
228
228
pivot = { "start" }
229
229
onNavigationDrawerChanged = { ( value ) => {
230
+ // @ts -expect-error
230
231
setShowNavigationModal ( value ?. detail ?. opened ) ;
231
232
} }
232
233
className = {
@@ -235,7 +236,6 @@ export default function Home() {
235
236
}
236
237
>
237
238
< NavigationContent
238
- showNavigationModal = { showNavigationModal }
239
239
setShowNavigationModal = { setShowNavigationModal }
240
240
/>
241
241
</ NavigationDrawerModal >
@@ -317,8 +317,10 @@ export default function Home() {
317
317
< Column id = "column-a" >
318
318
< DemoSection title = { "Actions" } >
319
319
< ComponentDemo title = { "Common buttons" } >
320
- < Stack direction = "row" spacing = { 2 } >
321
- < Stack >
320
+ { /* @ts -ignore */ }
321
+ < Stack direction = "row" spacing = { 2 } >
322
+ { /* @ts -ignore */ }
323
+ < Stack >
322
324
< Button variant = "elevated" className = "w-full" >
323
325
Elevated
324
326
</ Button >
@@ -335,7 +337,8 @@ export default function Home() {
335
337
Text
336
338
</ Button >
337
339
</ Stack >
338
- < Stack >
340
+ { /* @ts -ignore */ }
341
+ < Stack >
339
342
< Button variant = "elevated" className = "w-full" >
340
343
Icon
341
344
< Icon slot = "icon" > add</ Icon >
@@ -357,7 +360,8 @@ export default function Home() {
357
360
< Icon slot = "icon" > add</ Icon >
358
361
</ Button >
359
362
</ Stack >
360
- < Stack >
363
+ { /* @ts -ignore */ }
364
+ < Stack >
361
365
< Button disabled variant = "elevated" className = "w-full" >
362
366
Elevated
363
367
</ Button >
@@ -378,7 +382,8 @@ export default function Home() {
378
382
</ ComponentDemo >
379
383
380
384
< ComponentDemo title = { "Floating action buttons" } >
381
- < Stack direction = "row" >
385
+ { /* @ts -ignore */ }
386
+ < Stack direction = "row" >
382
387
< FAB size = "small" >
383
388
< Icon slot = "icon" > add</ Icon >
384
389
</ FAB >
@@ -395,7 +400,8 @@ export default function Home() {
395
400
</ ComponentDemo >
396
401
397
402
< ComponentDemo title = { "Icon buttons" } >
398
- < Stack direction = "row" spacing = { 4 } >
403
+ { /* @ts -ignore */ }
404
+ < Stack direction = "row" spacing = { 4 } >
399
405
< IconButton >
400
406
< Icon > Settings</ Icon >
401
407
</ IconButton >
@@ -412,7 +418,8 @@ export default function Home() {
412
418
< Icon > Settings</ Icon >
413
419
</ IconButton >
414
420
</ Stack >
415
- < Stack direction = "row" spacing = { 4 } >
421
+ { /* @ts -ignore */ }
422
+ < Stack direction = "row" spacing = { 4 } >
416
423
< IconButton disabled >
417
424
< Icon > Settings</ Icon >
418
425
</ IconButton >
@@ -462,7 +469,8 @@ export default function Home() {
462
469
463
470
< DemoSection title = "Communication" >
464
471
< ComponentDemo title = { "Badges" } >
465
- < Stack direction = "row" spacing = { 3 } >
472
+ { /* @ts -ignore */ }
473
+ < Stack direction = "row" spacing = { 3 } >
466
474
< IconButton >
467
475
< Icon
468
476
style = { {
@@ -479,15 +487,16 @@ export default function Home() {
479
487
fontVariationSettings : "'FILL' 1" ,
480
488
} }
481
489
>
482
- < Badge value = { 3 } />
490
+ < Badge value = { "3" } />
483
491
mail
484
492
</ Icon >
485
493
</ IconButton >
486
494
</ Stack >
487
495
</ ComponentDemo >
488
496
489
497
< ComponentDemo title = { "Progress indicators" } >
490
- < Stack direction = "row" spacing = { 10 } >
498
+ { /* @ts -ignore */ }
499
+ < Stack direction = "row" spacing = { 10 } >
491
500
< IconButton
492
501
onClick = { ( ) =>
493
502
setIsPlayingProgressIndicators ( ( oldState ) => ! oldState )
@@ -857,7 +866,6 @@ export default function Home() {
857
866
< ComponentDemo title = { "Navigation bar" } >
858
867
< NavigationBar
859
868
className = "w-full flex flex-row items-center"
860
- index = { 0 }
861
869
>
862
870
< NavigationTab className = "px-4" label = "Explore" disabled >
863
871
< Icon
@@ -950,7 +958,7 @@ export default function Home() {
950
958
< AppBar
951
959
variant = "medium"
952
960
className = { "sticky top-0 z-40 !bg-[#fef7fe]" }
953
- onExpansionChange = { ( expanded ) => setIsExpanded ( expanded ) }
961
+ onExpansionChange = { ( expanded : boolean ) => setIsExpanded ( expanded ) }
954
962
style = { {
955
963
// @ts -ignore
956
964
"--md-elevation-level" : 1 ,
0 commit comments