@momentum-design/components 0.16.1 → 0.16.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -244,797 +244,797 @@
244
244
  },
245
245
  {
246
246
  "kind": "javascript-module",
247
- "path": "components/badge/badge.component.js",
247
+ "path": "components/avatarbutton/avatarbutton.component.js",
248
248
  "declarations": [
249
249
  {
250
250
  "kind": "class",
251
- "description": "The `mdc-badge` component is a versatile UI element used to\ndisplay dot, icons, counters, success, warning and error type badge.\n\nSupported badge types:\n- `dot`: Displays a dot notification badge with a blue color.\n- `icon`: Displays a badge with a specified icon using the `icon-name` attribute.\n- `counter`: Displays a badge with a counter value. If the counter exceeds the `max-counter`,\nit shows `maxCounter+`. The maximum value of the counter is 999 and anything above that will be set to `999+`.\n- `success`: Displays a success badge with a check circle icon and green color.\n- `warning`: Displays a warning badge with a warning icon and yellow color.\n- `error`: Displays a error badge with a error legacy icon and red color.\n\nFor `icon`, `success`, `warning` and `error` types, the `mdc-icon` component is used to render the icon.\n\nFor the `counter` type, the `mdc-text` component is used to render the counter value.",
252
- "name": "Badge",
251
+ "description": "The `mdc-avatarbutton` component is an interactable version of the `mdc-avatar` component.\n\nThis component is made by extending `buttonsimple` class.\nThe button component acts as a wrapper for the avatar component.",
252
+ "name": "AvatarButton",
253
253
  "members": [
254
+ {
255
+ "kind": "field",
256
+ "name": "ariaLabel",
257
+ "type": {
258
+ "text": "string | null"
259
+ },
260
+ "default": "null",
261
+ "description": "Aria-label attribute to be set for accessibility",
262
+ "attribute": "aria-label"
263
+ },
264
+ {
265
+ "kind": "method",
266
+ "name": "setSize",
267
+ "privacy": "private",
268
+ "parameters": [
269
+ {
270
+ "name": "size",
271
+ "type": {
272
+ "text": "AvatarSize"
273
+ }
274
+ }
275
+ ]
276
+ },
277
+ {
278
+ "kind": "field",
279
+ "name": "active",
280
+ "type": {
281
+ "text": "boolean"
282
+ },
283
+ "default": "undefined as unknown",
284
+ "description": "The button's active state indicates whether it is currently toggled on (active) or off (inactive).\nWhen the active state is true, the button is considered to be in an active state, meaning it is toggled on.\nConversely, when the active state is false, the button is in an inactive state, indicating it is toggled off.",
285
+ "attribute": "active",
286
+ "inheritedFrom": {
287
+ "name": "Buttonsimple",
288
+ "module": "components/buttonsimple/buttonsimple.component.js"
289
+ }
290
+ },
291
+ {
292
+ "kind": "field",
293
+ "name": "disabled",
294
+ "type": {
295
+ "text": "boolean"
296
+ },
297
+ "default": "undefined as unknown",
298
+ "description": "Indicates whether the button is disabled.\nWhen the button is disabled for user interaction; it is not focusable or clickable.",
299
+ "attribute": "disabled",
300
+ "inheritedFrom": {
301
+ "name": "Buttonsimple",
302
+ "module": "components/buttonsimple/buttonsimple.component.js"
303
+ }
304
+ },
305
+ {
306
+ "kind": "field",
307
+ "name": "softDisabled",
308
+ "type": {
309
+ "text": "boolean"
310
+ },
311
+ "default": "undefined as unknown",
312
+ "description": "Indicates whether the button is soft disabled.\nWhen set to `true`, the button appears visually disabled but still allows\nfocus, click, and keyboard actions to be passed through.\n\n**Important:** When using soft disabled, consumers must ensure that\nthe button behaves like a disabled button, allowing only focus and\npreventing any interactions (clicks or keyboard actions) from triggering unintended actions.",
313
+ "attribute": "soft-disabled",
314
+ "inheritedFrom": {
315
+ "name": "Buttonsimple",
316
+ "module": "components/buttonsimple/buttonsimple.component.js"
317
+ }
318
+ },
319
+ {
320
+ "kind": "field",
321
+ "name": "role",
322
+ "description": "This property defines the ARIA role for the element. By default, it is set to 'button'.\nConsumers should override this role when:\n- The element is being used in a context where a different role is more appropriate.\n- Custom behaviors are implemented that require a specific ARIA role for accessibility purposes.",
323
+ "default": "'button'",
324
+ "attribute": "role",
325
+ "reflects": true,
326
+ "type": {
327
+ "text": "string"
328
+ },
329
+ "inheritedFrom": {
330
+ "name": "Buttonsimple",
331
+ "module": "components/buttonsimple/buttonsimple.component.js"
332
+ }
333
+ },
254
334
  {
255
335
  "kind": "field",
256
336
  "name": "type",
257
337
  "type": {
258
- "text": "BadgeType | undefined"
338
+ "text": "ButtonType"
259
339
  },
260
- "description": "Type of the badge\nCan be `dot` (notification) , `icon`, `counter`, `success`, `warning` or `error`.",
340
+ "description": "This property defines the type attribute for the button element.\nThe type attribute specifies the behavior of the button when it is clicked.\n- **submit**: The button submits the form data to the server.\n- **reset**: The button resets the form data to its initial state.\n- **button**: The button does nothing when clicked.",
341
+ "default": "button",
261
342
  "attribute": "type",
262
- "reflects": true
343
+ "reflects": true,
344
+ "inheritedFrom": {
345
+ "name": "Buttonsimple",
346
+ "module": "components/buttonsimple/buttonsimple.component.js"
347
+ }
263
348
  },
264
349
  {
265
350
  "kind": "field",
266
- "name": "iconName",
351
+ "name": "src",
267
352
  "type": {
268
- "text": "IconNames | undefined"
353
+ "text": "string | undefined"
269
354
  },
270
- "description": "Name of the icon (= filename).\n\nIf no `icon-name` is provided, no icon will be rendered.",
271
- "attribute": "icon-name"
355
+ "description": "The src is the url which will be used to display the avatar.\nWhen the src is loading, we will display the initials as a placeholder.",
356
+ "attribute": "src",
357
+ "inheritedFrom": {
358
+ "name": "AvatarComponentMixin",
359
+ "module": "utils/mixins/AvatarComponentMixin.js"
360
+ }
272
361
  },
273
362
  {
274
363
  "kind": "field",
275
- "name": "variant",
364
+ "name": "initials",
276
365
  "type": {
277
- "text": "IconVariant"
366
+ "text": "string | undefined"
278
367
  },
279
- "description": "Type of the variant can be `primary` or `secondary`.\nIt defines the background and foreground color of the icon.",
280
- "default": "primary",
281
- "attribute": "variant",
282
- "reflects": true
368
+ "description": "The initials to be displayed for the avatar.",
369
+ "attribute": "initials",
370
+ "inheritedFrom": {
371
+ "name": "AvatarComponentMixin",
372
+ "module": "utils/mixins/AvatarComponentMixin.js"
373
+ }
283
374
  },
284
375
  {
285
376
  "kind": "field",
286
- "name": "counter",
377
+ "name": "presence",
287
378
  "type": {
288
- "text": "number | undefined"
379
+ "text": "PresenceType | undefined"
289
380
  },
290
- "description": "Counter is the number which can be provided in the badge.",
291
- "attribute": "counter"
381
+ "description": "The presence is the status which can be used to display the\nactivity state of a user or a space within an avatar component.\n\nAcceptable values include:\n- `active`\n- `away`\n- `away-calling`\n- `busy`\n- `dnd`\n- `meeting`\n- `on-call`\n- `on-device`\n- `on-mobile`\n- `pause`\n- `pto`\n- `presenting`\n- `quiet`\n- `scheduled`",
382
+ "attribute": "presence",
383
+ "inheritedFrom": {
384
+ "name": "AvatarComponentMixin",
385
+ "module": "utils/mixins/AvatarComponentMixin.js"
386
+ }
292
387
  },
293
388
  {
294
389
  "kind": "field",
295
- "name": "maxCounter",
390
+ "name": "size",
296
391
  "type": {
297
- "text": "number"
392
+ "text": "ButtonSize"
298
393
  },
299
- "description": "The maximum number can be set up to 999, anything above that will be rendered as _999+_.\nThe max counter can be `9`, `99` or `999`.",
300
- "default": "99",
301
- "attribute": "max-counter",
302
- "reflects": true
394
+ "description": "Acceptable values include (size in px unit):\n- 24\n- 32\n- 48\n- 64\n- 72\n- 88\n- 124",
395
+ "default": "32",
396
+ "attribute": "size",
397
+ "reflects": true,
398
+ "inheritedFrom": {
399
+ "name": "Buttonsimple",
400
+ "module": "components/buttonsimple/buttonsimple.component.js"
401
+ }
303
402
  },
304
403
  {
305
404
  "kind": "field",
306
- "name": "overlay",
405
+ "name": "iconName",
406
+ "type": {
407
+ "text": "IconNames | undefined"
408
+ },
409
+ "description": "Name of the icon to be displayed inside the Avatar.\nMust be a valid icon name.",
410
+ "attribute": "icon-name",
411
+ "inheritedFrom": {
412
+ "name": "AvatarComponentMixin",
413
+ "module": "utils/mixins/AvatarComponentMixin.js"
414
+ }
415
+ },
416
+ {
417
+ "kind": "field",
418
+ "name": "counter",
419
+ "type": {
420
+ "text": "number | undefined"
421
+ },
422
+ "description": "The counter is the number which can be displayed on the avatar.\nThe maximum number is 99 and if the given number is greater than 99,\nthen the avatar will be displayed as `99+`.\nIf the given number is a negative number,\nthen the avatar will be displayed as `0`.",
423
+ "attribute": "counter",
424
+ "inheritedFrom": {
425
+ "name": "AvatarComponentMixin",
426
+ "module": "utils/mixins/AvatarComponentMixin.js"
427
+ }
428
+ },
429
+ {
430
+ "kind": "field",
431
+ "name": "isTyping",
307
432
  "type": {
308
433
  "text": "boolean"
309
434
  },
310
435
  "default": "false",
311
- "description": "Overlay is to add a thin outline to the badge.\nThis will help distinguish between the badge and the button,\nwhere the badge will be layered on top of a button.",
312
- "attribute": "overlay"
436
+ "description": "Represents the typing indicator when the user is typing.",
437
+ "attribute": "is-typing",
438
+ "inheritedFrom": {
439
+ "name": "AvatarComponentMixin",
440
+ "module": "utils/mixins/AvatarComponentMixin.js"
441
+ }
313
442
  },
314
443
  {
315
444
  "kind": "field",
316
- "name": "ariaLabel",
445
+ "name": "tabIndex",
317
446
  "type": {
318
- "text": "string | null"
447
+ "text": "number"
319
448
  },
320
- "default": "null",
321
- "description": "Aria-label attribute to be set for accessibility",
322
- "attribute": "aria-label"
449
+ "default": "0",
450
+ "description": "The tabindex of the button.",
451
+ "attribute": "tabIndex",
452
+ "reflects": true,
453
+ "inheritedFrom": {
454
+ "name": "Buttonsimple",
455
+ "module": "components/buttonsimple/buttonsimple.component.js"
456
+ }
323
457
  },
324
458
  {
325
459
  "kind": "method",
326
- "name": "getCounterText",
460
+ "name": "executeAction",
461
+ "privacy": "private",
462
+ "inheritedFrom": {
463
+ "name": "Buttonsimple",
464
+ "module": "components/buttonsimple/buttonsimple.component.js"
465
+ }
466
+ },
467
+ {
468
+ "kind": "method",
469
+ "name": "setAriaPressed",
327
470
  "privacy": "private",
328
- "return": {
329
- "type": {
330
- "text": ""
331
- }
332
- },
333
471
  "parameters": [
334
472
  {
335
- "name": "maxCounter",
473
+ "name": "element",
336
474
  "type": {
337
- "text": "number"
475
+ "text": "HTMLElement"
338
476
  },
339
- "description": "the maximum limit which can be displayed on the badge"
477
+ "description": "The target element."
340
478
  },
341
479
  {
342
- "name": "counter",
343
- "optional": true,
480
+ "name": "active",
344
481
  "type": {
345
- "text": "number"
482
+ "text": "boolean"
346
483
  },
347
- "description": "the number to be displayed on the badge"
484
+ "description": "The active state."
348
485
  }
349
486
  ],
350
- "description": "If `type` is set to `counter` and if `counter` is greater than `maxCounter`,\nthen it will return a string the maxCounter value as string.\nOtherwise, it will return a string representation of `counter`.\nIf `counter` is not a number, it will return an empty string."
487
+ "description": "Sets the aria-pressed attribute based on the active state.",
488
+ "inheritedFrom": {
489
+ "name": "Buttonsimple",
490
+ "module": "components/buttonsimple/buttonsimple.component.js"
491
+ }
351
492
  },
352
493
  {
353
494
  "kind": "method",
354
- "name": "getBadgeIcon",
495
+ "name": "setSoftDisabled",
355
496
  "privacy": "private",
356
- "return": {
357
- "type": {
358
- "text": ""
359
- }
360
- },
361
497
  "parameters": [
362
498
  {
363
- "name": "iconName",
499
+ "name": "element",
364
500
  "type": {
365
- "text": "string"
501
+ "text": "HTMLElement"
366
502
  },
367
- "description": "the name of the icon from the icon set"
503
+ "description": "The button element."
368
504
  },
369
505
  {
370
- "name": "backgroundClassPostfix",
506
+ "name": "softDisabled",
371
507
  "type": {
372
- "text": "string"
508
+ "text": "boolean"
373
509
  },
374
- "description": "postfix for the class to style the badge icon."
510
+ "description": "The soft-disabled state."
375
511
  }
376
512
  ],
377
- "description": "Method to generate the badge icon."
513
+ "description": "Sets the soft-disabled attribute for the button.\nWhen soft-disabled, the button looks to be disabled but remains focusable and clickable.\nAlso sets/removes aria-disabled attribute.",
514
+ "inheritedFrom": {
515
+ "name": "Buttonsimple",
516
+ "module": "components/buttonsimple/buttonsimple.component.js"
517
+ }
378
518
  },
379
519
  {
380
520
  "kind": "method",
381
- "name": "getBadgeDot",
521
+ "name": "setDisabled",
382
522
  "privacy": "private",
383
- "return": {
384
- "type": {
385
- "text": ""
523
+ "parameters": [
524
+ {
525
+ "name": "element",
526
+ "type": {
527
+ "text": "HTMLElement"
528
+ },
529
+ "description": "The button element."
530
+ },
531
+ {
532
+ "name": "disabled",
533
+ "type": {
534
+ "text": "boolean"
535
+ },
536
+ "description": "The disabled state."
386
537
  }
387
- },
388
- "description": "Method to generate the badge dot template."
538
+ ],
539
+ "description": "Sets the disabled attribute for the button.\nWhen disabled, the button is not focusable or clickable, and tabindex is set to -1.\nThe previous tabindex is stored and restored when enabled.\nAlso sets/removes aria-disabled attribute.",
540
+ "inheritedFrom": {
541
+ "name": "Buttonsimple",
542
+ "module": "components/buttonsimple/buttonsimple.component.js"
543
+ }
389
544
  },
390
545
  {
391
546
  "kind": "method",
392
- "name": "getBadgeCounterText",
547
+ "name": "triggerClickEvent",
393
548
  "privacy": "private",
394
- "return": {
395
- "type": {
396
- "text": ""
397
- }
398
- },
399
- "description": "Method to generate the badge text and counter template."
549
+ "inheritedFrom": {
550
+ "name": "Buttonsimple",
551
+ "module": "components/buttonsimple/buttonsimple.component.js"
552
+ }
400
553
  },
401
554
  {
402
555
  "kind": "method",
403
- "name": "setRoleByAriaLabel",
556
+ "name": "handleKeyDown",
404
557
  "privacy": "private",
405
- "return": {
406
- "type": {
407
- "text": "void"
558
+ "parameters": [
559
+ {
560
+ "name": "event",
561
+ "type": {
562
+ "text": "KeyboardEvent"
563
+ },
564
+ "description": "The keyboard event."
408
565
  }
409
- },
410
- "description": "Method to set the role based on the aria-label provided.\nIf the aria-label is provided, the role of the element will be 'img'.\nOtherwise, the role will be null."
566
+ ],
567
+ "description": "Handles the keydown event on the button.\nIf the key is 'Enter' or 'Space', the button is pressed.\nIf the key is 'Enter', the button is pressed. The native HTML button works in the same way.",
568
+ "inheritedFrom": {
569
+ "name": "Buttonsimple",
570
+ "module": "components/buttonsimple/buttonsimple.component.js"
571
+ }
411
572
  },
412
573
  {
413
574
  "kind": "method",
414
- "name": "getBadgeContentBasedOnType",
575
+ "name": "handleKeyUp",
415
576
  "privacy": "private",
416
- "return": {
417
- "type": {
418
- "text": ""
577
+ "parameters": [
578
+ {
579
+ "name": "event",
580
+ "type": {
581
+ "text": "KeyboardEvent"
582
+ },
583
+ "description": "The keyboard event."
419
584
  }
420
- },
421
- "description": "Generates the badge content based on the badge type.\nUtilizes various helper methods to create the appropriate badge template based on the\ncurrent badge type. Supports 'dot', 'icon', 'counter', 'success', 'warning', and 'error'\ntypes, returning the corresponding template result for each type."
585
+ ],
586
+ "description": "Handles the keyup event on the button.\nIf the key is 'Enter' or 'Space', the button is clicked.\nIf the key is 'Space', the button is pressed. The native HTML button works in the same way.",
587
+ "inheritedFrom": {
588
+ "name": "Buttonsimple",
589
+ "module": "components/buttonsimple/buttonsimple.component.js"
590
+ }
422
591
  }
423
592
  ],
424
593
  "attributes": [
425
594
  {
426
- "name": "type",
595
+ "name": "aria-label",
427
596
  "type": {
428
- "text": "BadgeType | undefined"
597
+ "text": "string | null"
429
598
  },
430
- "description": "Type of the badge\nCan be `dot` (notification) , `icon`, `counter`, `success`, `warning` or `error`.",
431
- "fieldName": "type"
599
+ "default": "null",
600
+ "description": "Aria-label attribute to be set for accessibility",
601
+ "fieldName": "ariaLabel"
432
602
  },
433
603
  {
434
- "name": "icon-name",
604
+ "name": "src",
435
605
  "type": {
436
- "text": "IconNames | undefined"
606
+ "text": "string | undefined"
437
607
  },
438
- "description": "Name of the icon (= filename).\n\nIf no `icon-name` is provided, no icon will be rendered.",
439
- "fieldName": "iconName"
608
+ "description": "The src is the url which will be used to display the avatar.\nWhen the src is loading, we will display the initials as a placeholder.",
609
+ "fieldName": "src",
610
+ "inheritedFrom": {
611
+ "name": "AvatarComponentMixin",
612
+ "module": "src/utils/mixins/AvatarComponentMixin.ts"
613
+ }
440
614
  },
441
615
  {
442
- "name": "variant",
616
+ "name": "initials",
443
617
  "type": {
444
- "text": "IconVariant"
618
+ "text": "string | undefined"
445
619
  },
446
- "description": "Type of the variant can be `primary` or `secondary`.\nIt defines the background and foreground color of the icon.",
447
- "default": "primary",
448
- "fieldName": "variant"
620
+ "description": "The initials to be displayed for the avatar.",
621
+ "fieldName": "initials",
622
+ "inheritedFrom": {
623
+ "name": "AvatarComponentMixin",
624
+ "module": "src/utils/mixins/AvatarComponentMixin.ts"
625
+ }
449
626
  },
450
627
  {
451
- "name": "counter",
628
+ "name": "presence",
452
629
  "type": {
453
- "text": "number | undefined"
630
+ "text": "PresenceType | undefined"
454
631
  },
455
- "description": "Counter is the number which can be provided in the badge.",
456
- "fieldName": "counter"
632
+ "description": "The presence is the status which can be used to display the\nactivity state of a user or a space within an avatar component.\n\nAcceptable values include:\n- `active`\n- `away`\n- `away-calling`\n- `busy`\n- `dnd`\n- `meeting`\n- `on-call`\n- `on-device`\n- `on-mobile`\n- `pause`\n- `pto`\n- `presenting`\n- `quiet`\n- `scheduled`",
633
+ "fieldName": "presence",
634
+ "inheritedFrom": {
635
+ "name": "AvatarComponentMixin",
636
+ "module": "src/utils/mixins/AvatarComponentMixin.ts"
637
+ }
457
638
  },
458
639
  {
459
- "name": "max-counter",
640
+ "name": "size",
460
641
  "type": {
461
- "text": "number"
642
+ "text": "ButtonSize"
462
643
  },
463
- "description": "The maximum number can be set up to 999, anything above that will be rendered as _999+_.\nThe max counter can be `9`, `99` or `999`.",
464
- "default": "99",
465
- "fieldName": "maxCounter"
644
+ "description": "Acceptable values include (size in px unit):\n- 24\n- 32\n- 48\n- 64\n- 72\n- 88\n- 124",
645
+ "default": "32",
646
+ "fieldName": "size",
647
+ "inheritedFrom": {
648
+ "name": "Buttonsimple",
649
+ "module": "src/components/buttonsimple/buttonsimple.component.ts"
650
+ }
466
651
  },
467
652
  {
468
- "name": "overlay",
653
+ "name": "icon-name",
469
654
  "type": {
470
- "text": "boolean"
655
+ "text": "IconNames | undefined"
471
656
  },
472
- "default": "false",
473
- "description": "Overlay is to add a thin outline to the badge.\nThis will help distinguish between the badge and the button,\nwhere the badge will be layered on top of a button.",
474
- "fieldName": "overlay"
657
+ "description": "Name of the icon to be displayed inside the Avatar.\nMust be a valid icon name.",
658
+ "fieldName": "iconName",
659
+ "inheritedFrom": {
660
+ "name": "AvatarComponentMixin",
661
+ "module": "src/utils/mixins/AvatarComponentMixin.ts"
662
+ }
475
663
  },
476
664
  {
477
- "name": "aria-label",
665
+ "name": "counter",
478
666
  "type": {
479
- "text": "string | null"
667
+ "text": "number | undefined"
480
668
  },
481
- "default": "null",
482
- "description": "Aria-label attribute to be set for accessibility",
483
- "fieldName": "ariaLabel"
484
- }
485
- ],
486
- "superclass": {
487
- "name": "Component",
488
- "module": "/src/models"
489
- },
490
- "tagName": "mdc-badge",
491
- "jsDoc": "/**\n * The `mdc-badge` component is a versatile UI element used to\n * display dot, icons, counters, success, warning and error type badge.\n *\n * Supported badge types:\n * - `dot`: Displays a dot notification badge with a blue color.\n * - `icon`: Displays a badge with a specified icon using the `icon-name` attribute.\n * - `counter`: Displays a badge with a counter value. If the counter exceeds the `max-counter`,\n * it shows `maxCounter+`. The maximum value of the counter is 999 and anything above that will be set to `999+`.\n * - `success`: Displays a success badge with a check circle icon and green color.\n * - `warning`: Displays a warning badge with a warning icon and yellow color.\n * - `error`: Displays a error badge with a error legacy icon and red color.\n *\n * For `icon`, `success`, `warning` and `error` types, the `mdc-icon` component is used to render the icon.\n *\n * For the `counter` type, the `mdc-text` component is used to render the counter value.\n *\n * @dependency mdc-icon\n * @dependency mdc-text\n *\n * @tagname mdc-badge\n */",
492
- "customElement": true
493
- }
494
- ],
495
- "exports": [
496
- {
497
- "kind": "js",
498
- "name": "default",
499
- "declaration": {
500
- "name": "Badge",
501
- "module": "components/badge/badge.component.js"
502
- }
503
- }
504
- ]
505
- },
506
- {
507
- "kind": "javascript-module",
508
- "path": "components/avatarbutton/avatarbutton.component.js",
509
- "declarations": [
510
- {
511
- "kind": "class",
512
- "description": "The `mdc-avatarbutton` component is an interactable version of the `mdc-avatar` component.\n\nThis component is made by extending `buttonsimple` class.\nThe button component acts as a wrapper for the avatar component.",
513
- "name": "AvatarButton",
514
- "members": [
669
+ "description": "The counter is the number which can be displayed on the avatar.\nThe maximum number is 99 and if the given number is greater than 99,\nthen the avatar will be displayed as `99+`.\nIf the given number is a negative number,\nthen the avatar will be displayed as `0`.",
670
+ "fieldName": "counter",
671
+ "inheritedFrom": {
672
+ "name": "AvatarComponentMixin",
673
+ "module": "src/utils/mixins/AvatarComponentMixin.ts"
674
+ }
675
+ },
515
676
  {
516
- "kind": "field",
517
- "name": "ariaLabel",
677
+ "name": "is-typing",
518
678
  "type": {
519
- "text": "string | null"
679
+ "text": "boolean"
520
680
  },
521
- "default": "null",
522
- "description": "Aria-label attribute to be set for accessibility",
523
- "attribute": "aria-label"
524
- },
525
- {
526
- "kind": "method",
527
- "name": "setSize",
528
- "privacy": "private",
529
- "parameters": [
530
- {
531
- "name": "size",
532
- "type": {
533
- "text": "AvatarSize"
534
- }
535
- }
536
- ]
681
+ "default": "false",
682
+ "description": "Represents the typing indicator when the user is typing.",
683
+ "fieldName": "isTyping",
684
+ "inheritedFrom": {
685
+ "name": "AvatarComponentMixin",
686
+ "module": "src/utils/mixins/AvatarComponentMixin.ts"
687
+ }
537
688
  },
538
689
  {
539
- "kind": "field",
540
690
  "name": "active",
541
691
  "type": {
542
692
  "text": "boolean"
543
693
  },
544
- "default": "undefined as unknown",
694
+ "default": "false",
545
695
  "description": "The button's active state indicates whether it is currently toggled on (active) or off (inactive).\nWhen the active state is true, the button is considered to be in an active state, meaning it is toggled on.\nConversely, when the active state is false, the button is in an inactive state, indicating it is toggled off.",
546
- "attribute": "active",
696
+ "fieldName": "active",
547
697
  "inheritedFrom": {
548
698
  "name": "Buttonsimple",
549
- "module": "components/buttonsimple/buttonsimple.component.js"
699
+ "module": "src/components/buttonsimple/buttonsimple.component.ts"
550
700
  }
551
701
  },
552
702
  {
553
- "kind": "field",
554
703
  "name": "disabled",
555
704
  "type": {
556
705
  "text": "boolean"
557
706
  },
558
- "default": "undefined as unknown",
707
+ "default": "false",
559
708
  "description": "Indicates whether the button is disabled.\nWhen the button is disabled for user interaction; it is not focusable or clickable.",
560
- "attribute": "disabled",
709
+ "fieldName": "disabled",
561
710
  "inheritedFrom": {
562
711
  "name": "Buttonsimple",
563
- "module": "components/buttonsimple/buttonsimple.component.js"
712
+ "module": "src/components/buttonsimple/buttonsimple.component.ts"
564
713
  }
565
714
  },
566
715
  {
567
- "kind": "field",
568
- "name": "softDisabled",
716
+ "name": "soft-disabled",
569
717
  "type": {
570
718
  "text": "boolean"
571
719
  },
572
- "default": "undefined as unknown",
720
+ "default": "false",
573
721
  "description": "Indicates whether the button is soft disabled.\nWhen set to `true`, the button appears visually disabled but still allows\nfocus, click, and keyboard actions to be passed through.\n\n**Important:** When using soft disabled, consumers must ensure that\nthe button behaves like a disabled button, allowing only focus and\npreventing any interactions (clicks or keyboard actions) from triggering unintended actions.",
574
- "attribute": "soft-disabled",
722
+ "fieldName": "softDisabled",
575
723
  "inheritedFrom": {
576
724
  "name": "Buttonsimple",
577
- "module": "components/buttonsimple/buttonsimple.component.js"
725
+ "module": "src/components/buttonsimple/buttonsimple.component.ts"
578
726
  }
579
727
  },
580
728
  {
581
- "kind": "field",
582
- "name": "role",
583
- "description": "This property defines the ARIA role for the element. By default, it is set to 'button'.\nConsumers should override this role when:\n- The element is being used in a context where a different role is more appropriate.\n- Custom behaviors are implemented that require a specific ARIA role for accessibility purposes.",
584
- "default": "'button'",
585
- "attribute": "role",
586
- "reflects": true,
729
+ "name": "tabIndex",
587
730
  "type": {
588
- "text": "string"
731
+ "text": "number"
589
732
  },
733
+ "default": "0",
734
+ "description": "The tabindex of the button.",
735
+ "fieldName": "tabIndex",
590
736
  "inheritedFrom": {
591
737
  "name": "Buttonsimple",
592
- "module": "components/buttonsimple/buttonsimple.component.js"
738
+ "module": "src/components/buttonsimple/buttonsimple.component.ts"
593
739
  }
594
740
  },
595
741
  {
596
- "kind": "field",
597
- "name": "type",
598
- "type": {
599
- "text": "ButtonType"
600
- },
601
- "description": "This property defines the type attribute for the button element.\nThe type attribute specifies the behavior of the button when it is clicked.\n- **submit**: The button submits the form data to the server.\n- **reset**: The button resets the form data to its initial state.\n- **button**: The button does nothing when clicked.",
742
+ "name": "role",
743
+ "description": "This property defines the ARIA role for the element. By default, it is set to 'button'.\nConsumers should override this role when:\n- The element is being used in a context where a different role is more appropriate.\n- Custom behaviors are implemented that require a specific ARIA role for accessibility purposes.",
602
744
  "default": "button",
603
- "attribute": "type",
604
- "reflects": true,
745
+ "fieldName": "role",
605
746
  "inheritedFrom": {
606
747
  "name": "Buttonsimple",
607
- "module": "components/buttonsimple/buttonsimple.component.js"
748
+ "module": "src/components/buttonsimple/buttonsimple.component.ts"
608
749
  }
609
750
  },
610
751
  {
611
- "kind": "field",
612
- "name": "src",
752
+ "name": "type",
613
753
  "type": {
614
- "text": "string | undefined"
754
+ "text": "ButtonType"
615
755
  },
616
- "description": "The src is the url which will be used to display the avatar.\nWhen the src is loading, we will display the initials as a placeholder.",
617
- "attribute": "src",
756
+ "description": "This property defines the type attribute for the button element.\nThe type attribute specifies the behavior of the button when it is clicked.\n- **submit**: The button submits the form data to the server.\n- **reset**: The button resets the form data to its initial state.\n- **button**: The button does nothing when clicked.",
757
+ "default": "button",
758
+ "fieldName": "type",
618
759
  "inheritedFrom": {
619
- "name": "AvatarComponentMixin",
620
- "module": "utils/mixins/AvatarComponentMixin.js"
760
+ "name": "Buttonsimple",
761
+ "module": "src/components/buttonsimple/buttonsimple.component.ts"
621
762
  }
622
- },
763
+ }
764
+ ],
765
+ "mixins": [
766
+ {
767
+ "name": "AvatarComponentMixin",
768
+ "module": "/src/utils/mixins/AvatarComponentMixin"
769
+ }
770
+ ],
771
+ "superclass": {
772
+ "name": "Buttonsimple",
773
+ "module": "/src/components/buttonsimple"
774
+ },
775
+ "tagName": "mdc-avatarbutton",
776
+ "jsDoc": "/**\n * The `mdc-avatarbutton` component is an interactable version of the `mdc-avatar` component.\n *\n * This component is made by extending `buttonsimple` class.\n * The button component acts as a wrapper for the avatar component.\n *\n * @dependency mdc-avatar\n *\n * @tagname mdc-avatarbutton\n */",
777
+ "customElement": true
778
+ }
779
+ ],
780
+ "exports": [
781
+ {
782
+ "kind": "js",
783
+ "name": "default",
784
+ "declaration": {
785
+ "name": "AvatarButton",
786
+ "module": "components/avatarbutton/avatarbutton.component.js"
787
+ }
788
+ }
789
+ ]
790
+ },
791
+ {
792
+ "kind": "javascript-module",
793
+ "path": "components/badge/badge.component.js",
794
+ "declarations": [
795
+ {
796
+ "kind": "class",
797
+ "description": "The `mdc-badge` component is a versatile UI element used to\ndisplay dot, icons, counters, success, warning and error type badge.\n\nSupported badge types:\n- `dot`: Displays a dot notification badge with a blue color.\n- `icon`: Displays a badge with a specified icon using the `icon-name` attribute.\n- `counter`: Displays a badge with a counter value. If the counter exceeds the `max-counter`,\nit shows `maxCounter+`. The maximum value of the counter is 999 and anything above that will be set to `999+`.\n- `success`: Displays a success badge with a check circle icon and green color.\n- `warning`: Displays a warning badge with a warning icon and yellow color.\n- `error`: Displays a error badge with a error legacy icon and red color.\n\nFor `icon`, `success`, `warning` and `error` types, the `mdc-icon` component is used to render the icon.\n\nFor the `counter` type, the `mdc-text` component is used to render the counter value.",
798
+ "name": "Badge",
799
+ "members": [
623
800
  {
624
801
  "kind": "field",
625
- "name": "initials",
802
+ "name": "type",
626
803
  "type": {
627
- "text": "string | undefined"
804
+ "text": "BadgeType | undefined"
628
805
  },
629
- "description": "The initials to be displayed for the avatar.",
630
- "attribute": "initials",
631
- "inheritedFrom": {
632
- "name": "AvatarComponentMixin",
633
- "module": "utils/mixins/AvatarComponentMixin.js"
634
- }
806
+ "description": "Type of the badge\nCan be `dot` (notification) , `icon`, `counter`, `success`, `warning` or `error`.",
807
+ "attribute": "type",
808
+ "reflects": true
635
809
  },
636
810
  {
637
811
  "kind": "field",
638
- "name": "presence",
812
+ "name": "iconName",
639
813
  "type": {
640
- "text": "PresenceType | undefined"
814
+ "text": "IconNames | undefined"
641
815
  },
642
- "description": "The presence is the status which can be used to display the\nactivity state of a user or a space within an avatar component.\n\nAcceptable values include:\n- `active`\n- `away`\n- `away-calling`\n- `busy`\n- `dnd`\n- `meeting`\n- `on-call`\n- `on-device`\n- `on-mobile`\n- `pause`\n- `pto`\n- `presenting`\n- `quiet`\n- `scheduled`",
643
- "attribute": "presence",
644
- "inheritedFrom": {
645
- "name": "AvatarComponentMixin",
646
- "module": "utils/mixins/AvatarComponentMixin.js"
647
- }
816
+ "description": "Name of the icon (= filename).\n\nIf no `icon-name` is provided, no icon will be rendered.",
817
+ "attribute": "icon-name"
648
818
  },
649
819
  {
650
820
  "kind": "field",
651
- "name": "size",
821
+ "name": "variant",
652
822
  "type": {
653
- "text": "ButtonSize"
823
+ "text": "IconVariant"
654
824
  },
655
- "description": "Acceptable values include (size in px unit):\n- 24\n- 32\n- 48\n- 64\n- 72\n- 88\n- 124",
656
- "default": "32",
657
- "attribute": "size",
658
- "reflects": true,
659
- "inheritedFrom": {
660
- "name": "Buttonsimple",
661
- "module": "components/buttonsimple/buttonsimple.component.js"
662
- }
825
+ "description": "Type of the variant can be `primary` or `secondary`.\nIt defines the background and foreground color of the icon.",
826
+ "default": "primary",
827
+ "attribute": "variant",
828
+ "reflects": true
663
829
  },
664
830
  {
665
831
  "kind": "field",
666
- "name": "iconName",
832
+ "name": "counter",
667
833
  "type": {
668
- "text": "IconNames | undefined"
834
+ "text": "number | undefined"
669
835
  },
670
- "description": "Name of the icon to be displayed inside the Avatar.\nMust be a valid icon name.",
671
- "attribute": "icon-name",
672
- "inheritedFrom": {
673
- "name": "AvatarComponentMixin",
674
- "module": "utils/mixins/AvatarComponentMixin.js"
675
- }
836
+ "description": "Counter is the number which can be provided in the badge.",
837
+ "attribute": "counter"
676
838
  },
677
839
  {
678
840
  "kind": "field",
679
- "name": "counter",
841
+ "name": "maxCounter",
680
842
  "type": {
681
- "text": "number | undefined"
843
+ "text": "number"
682
844
  },
683
- "description": "The counter is the number which can be displayed on the avatar.\nThe maximum number is 99 and if the given number is greater than 99,\nthen the avatar will be displayed as `99+`.\nIf the given number is a negative number,\nthen the avatar will be displayed as `0`.",
684
- "attribute": "counter",
685
- "inheritedFrom": {
686
- "name": "AvatarComponentMixin",
687
- "module": "utils/mixins/AvatarComponentMixin.js"
688
- }
845
+ "description": "The maximum number can be set up to 999, anything above that will be rendered as _999+_.\nThe max counter can be `9`, `99` or `999`.",
846
+ "default": "99",
847
+ "attribute": "max-counter",
848
+ "reflects": true
689
849
  },
690
850
  {
691
851
  "kind": "field",
692
- "name": "isTyping",
852
+ "name": "overlay",
693
853
  "type": {
694
854
  "text": "boolean"
695
855
  },
696
856
  "default": "false",
697
- "description": "Represents the typing indicator when the user is typing.",
698
- "attribute": "is-typing",
699
- "inheritedFrom": {
700
- "name": "AvatarComponentMixin",
701
- "module": "utils/mixins/AvatarComponentMixin.js"
702
- }
857
+ "description": "Overlay is to add a thin outline to the badge.\nThis will help distinguish between the badge and the button,\nwhere the badge will be layered on top of a button.",
858
+ "attribute": "overlay"
703
859
  },
704
860
  {
705
861
  "kind": "field",
706
- "name": "tabIndex",
862
+ "name": "ariaLabel",
707
863
  "type": {
708
- "text": "number"
864
+ "text": "string | null"
709
865
  },
710
- "default": "0",
711
- "description": "The tabindex of the button.",
712
- "attribute": "tabIndex",
713
- "reflects": true,
714
- "inheritedFrom": {
715
- "name": "Buttonsimple",
716
- "module": "components/buttonsimple/buttonsimple.component.js"
717
- }
718
- },
719
- {
720
- "kind": "method",
721
- "name": "executeAction",
722
- "privacy": "private",
723
- "inheritedFrom": {
724
- "name": "Buttonsimple",
725
- "module": "components/buttonsimple/buttonsimple.component.js"
726
- }
727
- },
728
- {
729
- "kind": "method",
730
- "name": "setAriaPressed",
731
- "privacy": "private",
732
- "parameters": [
733
- {
734
- "name": "element",
735
- "type": {
736
- "text": "HTMLElement"
737
- },
738
- "description": "The target element."
739
- },
740
- {
741
- "name": "active",
742
- "type": {
743
- "text": "boolean"
744
- },
745
- "description": "The active state."
746
- }
747
- ],
748
- "description": "Sets the aria-pressed attribute based on the active state.",
749
- "inheritedFrom": {
750
- "name": "Buttonsimple",
751
- "module": "components/buttonsimple/buttonsimple.component.js"
752
- }
866
+ "default": "null",
867
+ "description": "Aria-label attribute to be set for accessibility",
868
+ "attribute": "aria-label"
753
869
  },
754
870
  {
755
871
  "kind": "method",
756
- "name": "setSoftDisabled",
872
+ "name": "getCounterText",
757
873
  "privacy": "private",
758
- "parameters": [
759
- {
760
- "name": "element",
761
- "type": {
762
- "text": "HTMLElement"
763
- },
764
- "description": "The button element."
765
- },
766
- {
767
- "name": "softDisabled",
768
- "type": {
769
- "text": "boolean"
770
- },
771
- "description": "The soft-disabled state."
874
+ "return": {
875
+ "type": {
876
+ "text": ""
772
877
  }
773
- ],
774
- "description": "Sets the soft-disabled attribute for the button.\nWhen soft-disabled, the button looks to be disabled but remains focusable and clickable.\nAlso sets/removes aria-disabled attribute.",
775
- "inheritedFrom": {
776
- "name": "Buttonsimple",
777
- "module": "components/buttonsimple/buttonsimple.component.js"
778
- }
779
- },
780
- {
781
- "kind": "method",
782
- "name": "setDisabled",
783
- "privacy": "private",
878
+ },
784
879
  "parameters": [
785
880
  {
786
- "name": "element",
881
+ "name": "maxCounter",
787
882
  "type": {
788
- "text": "HTMLElement"
883
+ "text": "number"
789
884
  },
790
- "description": "The button element."
885
+ "description": "the maximum limit which can be displayed on the badge"
791
886
  },
792
887
  {
793
- "name": "disabled",
794
- "type": {
795
- "text": "boolean"
796
- },
797
- "description": "The disabled state."
798
- }
799
- ],
800
- "description": "Sets the disabled attribute for the button.\nWhen disabled, the button is not focusable or clickable, and tabindex is set to -1.\nThe previous tabindex is stored and restored when enabled.\nAlso sets/removes aria-disabled attribute.",
801
- "inheritedFrom": {
802
- "name": "Buttonsimple",
803
- "module": "components/buttonsimple/buttonsimple.component.js"
804
- }
805
- },
806
- {
807
- "kind": "method",
808
- "name": "triggerClickEvent",
809
- "privacy": "private",
810
- "inheritedFrom": {
811
- "name": "Buttonsimple",
812
- "module": "components/buttonsimple/buttonsimple.component.js"
813
- }
814
- },
815
- {
816
- "kind": "method",
817
- "name": "handleKeyDown",
818
- "privacy": "private",
819
- "parameters": [
820
- {
821
- "name": "event",
888
+ "name": "counter",
889
+ "optional": true,
822
890
  "type": {
823
- "text": "KeyboardEvent"
891
+ "text": "number"
824
892
  },
825
- "description": "The keyboard event."
893
+ "description": "the number to be displayed on the badge"
826
894
  }
827
895
  ],
828
- "description": "Handles the keydown event on the button.\nIf the key is 'Enter' or 'Space', the button is pressed.\nIf the key is 'Enter', the button is pressed. The native HTML button works in the same way.",
829
- "inheritedFrom": {
830
- "name": "Buttonsimple",
831
- "module": "components/buttonsimple/buttonsimple.component.js"
832
- }
896
+ "description": "If `type` is set to `counter` and if `counter` is greater than `maxCounter`,\nthen it will return a string the maxCounter value as string.\nOtherwise, it will return a string representation of `counter`.\nIf `counter` is not a number, it will return an empty string."
833
897
  },
834
898
  {
835
899
  "kind": "method",
836
- "name": "handleKeyUp",
900
+ "name": "getBadgeIcon",
837
901
  "privacy": "private",
902
+ "return": {
903
+ "type": {
904
+ "text": ""
905
+ }
906
+ },
838
907
  "parameters": [
839
908
  {
840
- "name": "event",
909
+ "name": "iconName",
841
910
  "type": {
842
- "text": "KeyboardEvent"
911
+ "text": "string"
843
912
  },
844
- "description": "The keyboard event."
913
+ "description": "the name of the icon from the icon set"
914
+ },
915
+ {
916
+ "name": "backgroundClassPostfix",
917
+ "type": {
918
+ "text": "string"
919
+ },
920
+ "description": "postfix for the class to style the badge icon."
845
921
  }
846
922
  ],
847
- "description": "Handles the keyup event on the button.\nIf the key is 'Enter' or 'Space', the button is clicked.\nIf the key is 'Space', the button is pressed. The native HTML button works in the same way.",
848
- "inheritedFrom": {
849
- "name": "Buttonsimple",
850
- "module": "components/buttonsimple/buttonsimple.component.js"
851
- }
852
- }
853
- ],
854
- "attributes": [
923
+ "description": "Method to generate the badge icon."
924
+ },
855
925
  {
856
- "name": "aria-label",
857
- "type": {
858
- "text": "string | null"
926
+ "kind": "method",
927
+ "name": "getBadgeDot",
928
+ "privacy": "private",
929
+ "return": {
930
+ "type": {
931
+ "text": ""
932
+ }
859
933
  },
860
- "default": "null",
861
- "description": "Aria-label attribute to be set for accessibility",
862
- "fieldName": "ariaLabel"
934
+ "description": "Method to generate the badge dot template."
863
935
  },
864
936
  {
865
- "name": "src",
866
- "type": {
867
- "text": "string | undefined"
937
+ "kind": "method",
938
+ "name": "getBadgeCounterText",
939
+ "privacy": "private",
940
+ "return": {
941
+ "type": {
942
+ "text": ""
943
+ }
868
944
  },
869
- "description": "The src is the url which will be used to display the avatar.\nWhen the src is loading, we will display the initials as a placeholder.",
870
- "fieldName": "src",
871
- "inheritedFrom": {
872
- "name": "AvatarComponentMixin",
873
- "module": "src/utils/mixins/AvatarComponentMixin.ts"
874
- }
945
+ "description": "Method to generate the badge text and counter template."
875
946
  },
876
947
  {
877
- "name": "initials",
878
- "type": {
879
- "text": "string | undefined"
948
+ "kind": "method",
949
+ "name": "setRoleByAriaLabel",
950
+ "privacy": "private",
951
+ "return": {
952
+ "type": {
953
+ "text": "void"
954
+ }
880
955
  },
881
- "description": "The initials to be displayed for the avatar.",
882
- "fieldName": "initials",
883
- "inheritedFrom": {
884
- "name": "AvatarComponentMixin",
885
- "module": "src/utils/mixins/AvatarComponentMixin.ts"
886
- }
956
+ "description": "Method to set the role based on the aria-label provided.\nIf the aria-label is provided, the role of the element will be 'img'.\nOtherwise, the role will be null."
887
957
  },
888
958
  {
889
- "name": "presence",
890
- "type": {
891
- "text": "PresenceType | undefined"
959
+ "kind": "method",
960
+ "name": "getBadgeContentBasedOnType",
961
+ "privacy": "private",
962
+ "return": {
963
+ "type": {
964
+ "text": ""
965
+ }
892
966
  },
893
- "description": "The presence is the status which can be used to display the\nactivity state of a user or a space within an avatar component.\n\nAcceptable values include:\n- `active`\n- `away`\n- `away-calling`\n- `busy`\n- `dnd`\n- `meeting`\n- `on-call`\n- `on-device`\n- `on-mobile`\n- `pause`\n- `pto`\n- `presenting`\n- `quiet`\n- `scheduled`",
894
- "fieldName": "presence",
895
- "inheritedFrom": {
896
- "name": "AvatarComponentMixin",
897
- "module": "src/utils/mixins/AvatarComponentMixin.ts"
898
- }
899
- },
967
+ "description": "Generates the badge content based on the badge type.\nUtilizes various helper methods to create the appropriate badge template based on the\ncurrent badge type. Supports 'dot', 'icon', 'counter', 'success', 'warning', and 'error'\ntypes, returning the corresponding template result for each type."
968
+ }
969
+ ],
970
+ "attributes": [
900
971
  {
901
- "name": "size",
972
+ "name": "type",
902
973
  "type": {
903
- "text": "ButtonSize"
974
+ "text": "BadgeType | undefined"
904
975
  },
905
- "description": "Acceptable values include (size in px unit):\n- 24\n- 32\n- 48\n- 64\n- 72\n- 88\n- 124",
906
- "default": "32",
907
- "fieldName": "size",
908
- "inheritedFrom": {
909
- "name": "Buttonsimple",
910
- "module": "src/components/buttonsimple/buttonsimple.component.ts"
911
- }
976
+ "description": "Type of the badge\nCan be `dot` (notification) , `icon`, `counter`, `success`, `warning` or `error`.",
977
+ "fieldName": "type"
912
978
  },
913
979
  {
914
980
  "name": "icon-name",
915
981
  "type": {
916
982
  "text": "IconNames | undefined"
917
983
  },
918
- "description": "Name of the icon to be displayed inside the Avatar.\nMust be a valid icon name.",
919
- "fieldName": "iconName",
920
- "inheritedFrom": {
921
- "name": "AvatarComponentMixin",
922
- "module": "src/utils/mixins/AvatarComponentMixin.ts"
923
- }
924
- },
925
- {
926
- "name": "counter",
927
- "type": {
928
- "text": "number | undefined"
929
- },
930
- "description": "The counter is the number which can be displayed on the avatar.\nThe maximum number is 99 and if the given number is greater than 99,\nthen the avatar will be displayed as `99+`.\nIf the given number is a negative number,\nthen the avatar will be displayed as `0`.",
931
- "fieldName": "counter",
932
- "inheritedFrom": {
933
- "name": "AvatarComponentMixin",
934
- "module": "src/utils/mixins/AvatarComponentMixin.ts"
935
- }
984
+ "description": "Name of the icon (= filename).\n\nIf no `icon-name` is provided, no icon will be rendered.",
985
+ "fieldName": "iconName"
936
986
  },
937
987
  {
938
- "name": "is-typing",
988
+ "name": "variant",
939
989
  "type": {
940
- "text": "boolean"
990
+ "text": "IconVariant"
941
991
  },
942
- "default": "false",
943
- "description": "Represents the typing indicator when the user is typing.",
944
- "fieldName": "isTyping",
945
- "inheritedFrom": {
946
- "name": "AvatarComponentMixin",
947
- "module": "src/utils/mixins/AvatarComponentMixin.ts"
948
- }
992
+ "description": "Type of the variant can be `primary` or `secondary`.\nIt defines the background and foreground color of the icon.",
993
+ "default": "primary",
994
+ "fieldName": "variant"
949
995
  },
950
996
  {
951
- "name": "active",
997
+ "name": "counter",
952
998
  "type": {
953
- "text": "boolean"
999
+ "text": "number | undefined"
954
1000
  },
955
- "default": "false",
956
- "description": "The button's active state indicates whether it is currently toggled on (active) or off (inactive).\nWhen the active state is true, the button is considered to be in an active state, meaning it is toggled on.\nConversely, when the active state is false, the button is in an inactive state, indicating it is toggled off.",
957
- "fieldName": "active",
958
- "inheritedFrom": {
959
- "name": "Buttonsimple",
960
- "module": "src/components/buttonsimple/buttonsimple.component.ts"
961
- }
1001
+ "description": "Counter is the number which can be provided in the badge.",
1002
+ "fieldName": "counter"
962
1003
  },
963
1004
  {
964
- "name": "disabled",
1005
+ "name": "max-counter",
965
1006
  "type": {
966
- "text": "boolean"
1007
+ "text": "number"
967
1008
  },
968
- "default": "false",
969
- "description": "Indicates whether the button is disabled.\nWhen the button is disabled for user interaction; it is not focusable or clickable.",
970
- "fieldName": "disabled",
971
- "inheritedFrom": {
972
- "name": "Buttonsimple",
973
- "module": "src/components/buttonsimple/buttonsimple.component.ts"
974
- }
1009
+ "description": "The maximum number can be set up to 999, anything above that will be rendered as _999+_.\nThe max counter can be `9`, `99` or `999`.",
1010
+ "default": "99",
1011
+ "fieldName": "maxCounter"
975
1012
  },
976
1013
  {
977
- "name": "soft-disabled",
1014
+ "name": "overlay",
978
1015
  "type": {
979
1016
  "text": "boolean"
980
1017
  },
981
1018
  "default": "false",
982
- "description": "Indicates whether the button is soft disabled.\nWhen set to `true`, the button appears visually disabled but still allows\nfocus, click, and keyboard actions to be passed through.\n\n**Important:** When using soft disabled, consumers must ensure that\nthe button behaves like a disabled button, allowing only focus and\npreventing any interactions (clicks or keyboard actions) from triggering unintended actions.",
983
- "fieldName": "softDisabled",
984
- "inheritedFrom": {
985
- "name": "Buttonsimple",
986
- "module": "src/components/buttonsimple/buttonsimple.component.ts"
987
- }
988
- },
989
- {
990
- "name": "tabIndex",
991
- "type": {
992
- "text": "number"
993
- },
994
- "default": "0",
995
- "description": "The tabindex of the button.",
996
- "fieldName": "tabIndex",
997
- "inheritedFrom": {
998
- "name": "Buttonsimple",
999
- "module": "src/components/buttonsimple/buttonsimple.component.ts"
1000
- }
1001
- },
1002
- {
1003
- "name": "role",
1004
- "description": "This property defines the ARIA role for the element. By default, it is set to 'button'.\nConsumers should override this role when:\n- The element is being used in a context where a different role is more appropriate.\n- Custom behaviors are implemented that require a specific ARIA role for accessibility purposes.",
1005
- "default": "button",
1006
- "fieldName": "role",
1007
- "inheritedFrom": {
1008
- "name": "Buttonsimple",
1009
- "module": "src/components/buttonsimple/buttonsimple.component.ts"
1010
- }
1019
+ "description": "Overlay is to add a thin outline to the badge.\nThis will help distinguish between the badge and the button,\nwhere the badge will be layered on top of a button.",
1020
+ "fieldName": "overlay"
1011
1021
  },
1012
1022
  {
1013
- "name": "type",
1023
+ "name": "aria-label",
1014
1024
  "type": {
1015
- "text": "ButtonType"
1025
+ "text": "string | null"
1016
1026
  },
1017
- "description": "This property defines the type attribute for the button element.\nThe type attribute specifies the behavior of the button when it is clicked.\n- **submit**: The button submits the form data to the server.\n- **reset**: The button resets the form data to its initial state.\n- **button**: The button does nothing when clicked.",
1018
- "default": "button",
1019
- "fieldName": "type",
1020
- "inheritedFrom": {
1021
- "name": "Buttonsimple",
1022
- "module": "src/components/buttonsimple/buttonsimple.component.ts"
1023
- }
1024
- }
1025
- ],
1026
- "mixins": [
1027
- {
1028
- "name": "AvatarComponentMixin",
1029
- "module": "/src/utils/mixins/AvatarComponentMixin"
1027
+ "default": "null",
1028
+ "description": "Aria-label attribute to be set for accessibility",
1029
+ "fieldName": "ariaLabel"
1030
1030
  }
1031
1031
  ],
1032
1032
  "superclass": {
1033
- "name": "Buttonsimple",
1034
- "module": "/src/components/buttonsimple"
1033
+ "name": "Component",
1034
+ "module": "/src/models"
1035
1035
  },
1036
- "tagName": "mdc-avatarbutton",
1037
- "jsDoc": "/**\n * The `mdc-avatarbutton` component is an interactable version of the `mdc-avatar` component.\n *\n * This component is made by extending `buttonsimple` class.\n * The button component acts as a wrapper for the avatar component.\n *\n * @dependency mdc-avatar\n *\n * @tagname mdc-avatarbutton\n */",
1036
+ "tagName": "mdc-badge",
1037
+ "jsDoc": "/**\n * The `mdc-badge` component is a versatile UI element used to\n * display dot, icons, counters, success, warning and error type badge.\n *\n * Supported badge types:\n * - `dot`: Displays a dot notification badge with a blue color.\n * - `icon`: Displays a badge with a specified icon using the `icon-name` attribute.\n * - `counter`: Displays a badge with a counter value. If the counter exceeds the `max-counter`,\n * it shows `maxCounter+`. The maximum value of the counter is 999 and anything above that will be set to `999+`.\n * - `success`: Displays a success badge with a check circle icon and green color.\n * - `warning`: Displays a warning badge with a warning icon and yellow color.\n * - `error`: Displays a error badge with a error legacy icon and red color.\n *\n * For `icon`, `success`, `warning` and `error` types, the `mdc-icon` component is used to render the icon.\n *\n * For the `counter` type, the `mdc-text` component is used to render the counter value.\n *\n * @dependency mdc-icon\n * @dependency mdc-text\n *\n * @tagname mdc-badge\n */",
1038
1038
  "customElement": true
1039
1039
  }
1040
1040
  ],
@@ -1043,8 +1043,8 @@
1043
1043
  "kind": "js",
1044
1044
  "name": "default",
1045
1045
  "declaration": {
1046
- "name": "AvatarButton",
1047
- "module": "components/avatarbutton/avatarbutton.component.js"
1046
+ "name": "Badge",
1047
+ "module": "components/badge/badge.component.js"
1048
1048
  }
1049
1049
  }
1050
1050
  ]
@@ -2604,6 +2604,28 @@
2604
2604
  "privacy": "private",
2605
2605
  "description": "Get the icon name based on the presence type",
2606
2606
  "readonly": true
2607
+ },
2608
+ {
2609
+ "kind": "method",
2610
+ "name": "handleOnLoad",
2611
+ "privacy": "private",
2612
+ "return": {
2613
+ "type": {
2614
+ "text": "void"
2615
+ }
2616
+ },
2617
+ "description": "Handles the successful load of an icon.\nSets the `currentIconType` property to match the `type` property."
2618
+ },
2619
+ {
2620
+ "kind": "method",
2621
+ "name": "handleOnError",
2622
+ "privacy": "private",
2623
+ "return": {
2624
+ "type": {
2625
+ "text": "void"
2626
+ }
2627
+ },
2628
+ "description": "Handles an error that occurs when loading an icon."
2607
2629
  }
2608
2630
  ],
2609
2631
  "attributes": [