@sbb-esta/lyne-elements-dev 4.6.0-dev.1772527171 → 4.7.0-dev.1772543736

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -86779,27 +86779,23 @@
86779
86779
  },
86780
86780
  {
86781
86781
  "kind": "javascript-module",
86782
- "path": "menu/menu-button/menu-button.component.js",
86782
+ "path": "menu/menu/menu.component.js",
86783
86783
  "declarations": [
86784
86784
  {
86785
86785
  "kind": "class",
86786
- "description": "It displays a button element that can be used in the `sbb-menu` component.",
86787
- "name": "SbbMenuButtonElement",
86786
+ "description": "It displays a contextual menu with one or more action element.",
86787
+ "name": "SbbMenuElement",
86788
86788
  "cssProperties": [
86789
86789
  {
86790
- "description": "Can be used to modify horizontal padding.",
86791
- "name": "--sbb-menu-action-outer-horizontal-padding",
86792
- "default": "var(--sbb-spacing-fixed-3x)"
86790
+ "description": "To specify a custom stack order, the `z-index` can be overridden by defining this CSS variable. The default `z-index` of the component is set to `var(--sbb-overlay-default-z-index)` with a value of `1000`.",
86791
+ "name": "--sbb-menu-z-index",
86792
+ "default": "var(--sbb-overlay-default-z-index)"
86793
86793
  }
86794
86794
  ],
86795
86795
  "slots": [
86796
86796
  {
86797
- "description": "Use the unnamed slot to add content to the `sbb-menu-button`.",
86797
+ "description": "Use the unnamed slot to add `sbb-menu-button`/`sbb-menu-link` or other elements to the menu.",
86798
86798
  "name": ""
86799
- },
86800
- {
86801
- "description": "Use this slot to provide an icon. If `icon-name` is set, a `sbb-icon` will be used.",
86802
- "name": "icon"
86803
86799
  }
86804
86800
  ],
86805
86801
  "members": [
@@ -86807,255 +86803,268 @@
86807
86803
  "kind": "field",
86808
86804
  "name": "role",
86809
86805
  "type": {
86810
- "text": "ElementInternals['role']"
86806
+ "text": "string"
86811
86807
  },
86812
86808
  "privacy": "public",
86813
86809
  "static": true,
86814
86810
  "readonly": true,
86815
- "default": "'menuitem'",
86816
- "inheritedFrom": {
86817
- "name": "SbbButtonLikeBaseElement",
86818
- "module": "core/base-elements/button-base-element.js"
86819
- }
86811
+ "default": "'menu'"
86820
86812
  },
86821
86813
  {
86822
86814
  "kind": "field",
86823
- "name": "disabledInteractive",
86815
+ "name": "trigger",
86824
86816
  "type": {
86825
- "text": "boolean"
86817
+ "text": "HTMLElement | null"
86826
86818
  },
86827
86819
  "privacy": "public",
86828
- "default": "false",
86829
- "description": "Whether the button should be aria-disabled but stay interactive.",
86830
- "attribute": "disabled-interactive",
86831
- "reflects": true,
86832
- "inheritedFrom": {
86833
- "name": "SbbDisabledInteractiveMixin",
86834
- "module": "core/mixins/disabled-mixin.js"
86835
- }
86820
+ "default": "null",
86821
+ "description": "The element that will trigger the menu overlay.\n\nFor attribute usage, provide an id reference.",
86822
+ "attribute": "trigger"
86836
86823
  },
86837
86824
  {
86838
86825
  "kind": "field",
86839
- "name": "disabled",
86840
- "privacy": "public",
86841
- "description": "Whether the component is disabled.",
86842
- "default": "false",
86826
+ "name": "_menu",
86843
86827
  "type": {
86844
- "text": "boolean"
86828
+ "text": "HTMLDivElement"
86845
86829
  },
86846
- "attribute": "disabled",
86847
- "reflects": true,
86848
- "inheritedFrom": {
86849
- "name": "SbbDisabledMixin",
86850
- "module": "core/mixins/disabled-mixin.js"
86851
- }
86830
+ "privacy": "private"
86852
86831
  },
86853
86832
  {
86854
86833
  "kind": "field",
86855
- "name": "#disabled",
86834
+ "name": "_triggerElement",
86835
+ "type": {
86836
+ "text": "HTMLElement | null"
86837
+ },
86856
86838
  "privacy": "private",
86839
+ "default": "null"
86840
+ },
86841
+ {
86842
+ "kind": "field",
86843
+ "name": "_triggerAbortController",
86844
+ "type": {
86845
+ "text": "AbortController"
86846
+ },
86847
+ "privacy": "private"
86848
+ },
86849
+ {
86850
+ "kind": "field",
86851
+ "name": "_isPointerDownEventOnMenu",
86857
86852
  "type": {
86858
86853
  "text": "boolean"
86859
86854
  },
86860
- "default": "false",
86861
- "inheritedFrom": {
86862
- "name": "SbbDisabledMixin",
86863
- "module": "core/mixins/disabled-mixin.js"
86864
- }
86855
+ "privacy": "private",
86856
+ "default": "false"
86857
+ },
86858
+ {
86859
+ "kind": "field",
86860
+ "name": "_windowEventsController",
86861
+ "type": {
86862
+ "text": "AbortController"
86863
+ },
86864
+ "privacy": "private"
86865
+ },
86866
+ {
86867
+ "kind": "field",
86868
+ "name": "_escapableOverlayController",
86869
+ "privacy": "private",
86870
+ "default": "new SbbEscapableOverlayController(this)"
86871
+ },
86872
+ {
86873
+ "kind": "field",
86874
+ "name": "_focusTrapController",
86875
+ "privacy": "private",
86876
+ "default": "new SbbFocusTrapController(this)"
86877
+ },
86878
+ {
86879
+ "kind": "field",
86880
+ "name": "_scrollHandler",
86881
+ "privacy": "private",
86882
+ "default": "new SbbScrollHandler()"
86883
+ },
86884
+ {
86885
+ "kind": "field",
86886
+ "name": "_inertController",
86887
+ "privacy": "private",
86888
+ "default": "new SbbInertController(this)"
86889
+ },
86890
+ {
86891
+ "kind": "field",
86892
+ "name": "_mobileBreakpoint",
86893
+ "privacy": "private",
86894
+ "default": "SbbMediaQueryBreakpointSmallAndBelow"
86895
+ },
86896
+ {
86897
+ "kind": "field",
86898
+ "name": "_mediaMatcher",
86899
+ "privacy": "private",
86900
+ "default": "new SbbMediaMatcherController(this, { [this._mobileBreakpoint]: (matches) => { if (matches && (this.state === 'opening' || this.state === 'opened')) { this._scrollHandler.disableScroll(); } else { this._scrollHandler.enableScroll(); } }, })"
86901
+ },
86902
+ {
86903
+ "kind": "field",
86904
+ "name": "_darkModeController",
86905
+ "privacy": "private",
86906
+ "default": "new SbbDarkModeController(this, () => this._syncNegative())"
86907
+ },
86908
+ {
86909
+ "kind": "field",
86910
+ "name": "_language",
86911
+ "privacy": "private",
86912
+ "default": "new SbbLanguageController(this)"
86913
+ },
86914
+ {
86915
+ "kind": "field",
86916
+ "name": "_nestedMenu",
86917
+ "type": {
86918
+ "text": "SbbMenuElement | null"
86919
+ },
86920
+ "privacy": "private",
86921
+ "default": "null"
86865
86922
  },
86866
86923
  {
86867
86924
  "kind": "method",
86868
- "name": "isDisabledExternally",
86869
- "privacy": "protected",
86925
+ "name": "escapeStrategy",
86926
+ "privacy": "public",
86870
86927
  "return": {
86871
86928
  "type": {
86872
- "text": "boolean"
86929
+ "text": "void"
86873
86930
  }
86874
86931
  },
86875
- "description": "Will be used as 'or' check to the current disabled state.\nCan e.g. be used to read disabled state of a group.",
86932
+ "description": "The method which is called on escape key press. Defaults to calling close()",
86876
86933
  "inheritedFrom": {
86877
- "name": "SbbDisabledMixin",
86878
- "module": "core/mixins/disabled-mixin.js"
86934
+ "name": "SbbOpenCloseBaseElement",
86935
+ "module": "core/base-elements/open-close-base-element.js"
86879
86936
  }
86880
86937
  },
86881
86938
  {
86882
- "kind": "field",
86883
- "name": "styles",
86884
- "type": {
86885
- "text": "CSSResultGroup"
86886
- },
86939
+ "kind": "method",
86940
+ "name": "open",
86887
86941
  "privacy": "public",
86888
- "static": true,
86889
- "default": "[boxSizingStyles, style]",
86942
+ "return": {
86943
+ "type": {
86944
+ "text": "void"
86945
+ }
86946
+ },
86947
+ "description": "Opens the menu on trigger click.",
86890
86948
  "inheritedFrom": {
86891
- "name": "SbbMenuActionCommonElementMixin",
86892
- "module": "menu/common/menu-action-common.js"
86949
+ "name": "SbbOpenCloseBaseElement",
86950
+ "module": "core/base-elements/open-close-base-element.js"
86893
86951
  }
86894
86952
  },
86895
86953
  {
86896
86954
  "kind": "method",
86897
- "name": "renderTemplate",
86898
- "privacy": "protected",
86955
+ "name": "close",
86956
+ "privacy": "public",
86899
86957
  "return": {
86900
86958
  "type": {
86901
- "text": "TemplateResult"
86959
+ "text": "void"
86902
86960
  }
86903
86961
  },
86904
- "description": "Override this method to render the component template.",
86962
+ "description": "Closes the menu and all its nested menus.",
86905
86963
  "inheritedFrom": {
86906
- "name": "SbbActionBaseElement",
86907
- "module": "core/base-elements/action-base-element.js"
86964
+ "name": "SbbOpenCloseBaseElement",
86965
+ "module": "core/base-elements/open-close-base-element.js"
86908
86966
  }
86909
86967
  },
86910
86968
  {
86911
- "kind": "field",
86912
- "name": "iconName",
86913
- "type": {
86914
- "text": "string"
86915
- },
86969
+ "kind": "method",
86970
+ "name": "closeAll",
86916
86971
  "privacy": "public",
86917
- "default": "''",
86918
- "description": "The icon name we want to use, choose from the small icon variants\nfrom the ui-icons category from here\nhttps://icons.app.sbb.ch.",
86919
- "attribute": "icon-name",
86920
- "inheritedFrom": {
86921
- "name": "SbbIconNameMixin",
86922
- "module": "icon/icon-name-mixin.js"
86923
- }
86972
+ "return": {
86973
+ "type": {
86974
+ "text": "void"
86975
+ }
86976
+ },
86977
+ "description": "Closes the menu and all related menus (nested and parent menus)."
86924
86978
  },
86925
86979
  {
86926
86980
  "kind": "method",
86927
- "name": "renderIconSlot",
86928
- "privacy": "protected",
86981
+ "name": "_close",
86982
+ "privacy": "private",
86929
86983
  "return": {
86930
86984
  "type": {
86931
- "text": "TemplateResult"
86985
+ "text": "void"
86932
86986
  }
86933
86987
  },
86934
86988
  "parameters": [
86935
86989
  {
86936
- "name": "classname",
86937
- "optional": true,
86938
- "type": {
86939
- "text": "string"
86940
- }
86990
+ "name": "closeAll",
86991
+ "default": "false",
86992
+ "description": "If true, it ensures animations are correct by toggling some states when closing all related menus at once.",
86993
+ "optional": true
86941
86994
  }
86942
- ],
86943
- "inheritedFrom": {
86944
- "name": "SbbIconNameMixin",
86945
- "module": "icon/icon-name-mixin.js"
86946
- }
86995
+ ]
86947
86996
  },
86948
86997
  {
86949
86998
  "kind": "method",
86950
- "name": "renderIconName",
86951
- "privacy": "protected",
86999
+ "name": "_isZeroAnimationDuration",
87000
+ "privacy": "private",
86952
87001
  "return": {
86953
87002
  "type": {
86954
- "text": "string"
87003
+ "text": "boolean"
86955
87004
  }
86956
- },
86957
- "inheritedFrom": {
86958
- "name": "SbbIconNameMixin",
86959
- "module": "icon/icon-name-mixin.js"
86960
87005
  }
86961
87006
  },
86962
87007
  {
86963
87008
  "kind": "method",
86964
- "name": "_renderIconName",
87009
+ "name": "_handleOpening",
86965
87010
  "privacy": "private",
86966
87011
  "return": {
86967
87012
  "type": {
86968
- "text": "string"
87013
+ "text": "void"
86969
87014
  }
86970
- },
86971
- "inheritedFrom": {
86972
- "name": "SbbIconNameMixin",
86973
- "module": "icon/icon-name-mixin.js"
86974
87015
  }
86975
87016
  },
86976
87017
  {
86977
- "kind": "field",
86978
- "name": "_elementsOnWhichEnterPressTriggersSubmit",
86979
- "type": {
86980
- "text": "array"
86981
- },
87018
+ "kind": "method",
87019
+ "name": "_handleClosing",
86982
87020
  "privacy": "private",
86983
- "readonly": true,
86984
- "default": "[ 'input', 'sbb-date-input', 'sbb-time-input', ]",
86985
- "inheritedFrom": {
86986
- "name": "SbbButtonBaseElement",
86987
- "module": "core/base-elements/button-base-element.js"
86988
- }
86989
- },
86990
- {
86991
- "kind": "field",
86992
- "name": "value",
86993
- "type": {
86994
- "text": "string"
86995
- },
86996
- "privacy": "public",
86997
- "inheritedFrom": {
86998
- "name": "SbbButtonBaseElement",
86999
- "module": "core/base-elements/button-base-element.js"
87000
- },
87001
- "default": "''",
87002
- "description": "Value of the form element.",
87003
- "attribute": "value"
87004
- },
87005
- {
87006
- "kind": "field",
87007
- "name": "type",
87008
- "privacy": "public",
87009
- "description": "The type attribute to use for the button.",
87010
- "default": "'button'",
87011
- "type": {
87012
- "text": "SbbButtonType"
87013
- },
87014
- "attribute": "type",
87015
- "inheritedFrom": {
87016
- "name": "SbbButtonBaseElement",
87017
- "module": "core/base-elements/button-base-element.js"
87021
+ "return": {
87022
+ "type": {
87023
+ "text": "void"
87024
+ }
87018
87025
  }
87019
87026
  },
87020
87027
  {
87021
- "kind": "field",
87022
- "name": "form",
87023
- "type": {
87024
- "text": "HTMLFormElement | null"
87025
- },
87026
- "privacy": "public",
87027
- "description": "The `<form>` element to associate the button with.",
87028
- "inheritedFrom": {
87029
- "name": "SbbButtonBaseElement",
87030
- "module": "core/base-elements/button-base-element.js"
87028
+ "kind": "method",
87029
+ "name": "_handleKeyDown",
87030
+ "privacy": "private",
87031
+ "return": {
87032
+ "type": {
87033
+ "text": "void"
87034
+ }
87031
87035
  },
87032
- "attribute": "form"
87036
+ "parameters": [
87037
+ {
87038
+ "name": "evt",
87039
+ "type": {
87040
+ "text": "KeyboardEvent"
87041
+ }
87042
+ }
87043
+ ]
87033
87044
  },
87034
87045
  {
87035
- "kind": "field",
87036
- "name": "_formId",
87037
- "type": {
87038
- "text": "string"
87039
- },
87046
+ "kind": "method",
87047
+ "name": "_configureTrigger",
87040
87048
  "privacy": "private",
87041
- "default": "''",
87042
- "inheritedFrom": {
87043
- "name": "SbbButtonBaseElement",
87044
- "module": "core/base-elements/button-base-element.js"
87049
+ "return": {
87050
+ "type": {
87051
+ "text": "void"
87052
+ }
87045
87053
  }
87046
87054
  },
87047
87055
  {
87048
- "kind": "field",
87049
- "name": "_handleButtonClick",
87056
+ "kind": "method",
87057
+ "name": "_attachWindowEvents",
87050
87058
  "privacy": "private",
87051
- "inheritedFrom": {
87052
- "name": "SbbButtonBaseElement",
87053
- "module": "core/base-elements/button-base-element.js"
87059
+ "return": {
87060
+ "type": {
87061
+ "text": "void"
87062
+ }
87054
87063
  }
87055
87064
  },
87056
87065
  {
87057
87066
  "kind": "method",
87058
- "name": "_requestSubmit",
87067
+ "name": "_interactiveElementClick",
87059
87068
  "privacy": "private",
87060
87069
  "return": {
87061
87070
  "type": {
@@ -87064,154 +87073,79 @@
87064
87073
  },
87065
87074
  "parameters": [
87066
87075
  {
87067
- "name": "form",
87076
+ "name": "event",
87068
87077
  "type": {
87069
- "text": "HTMLFormElement"
87078
+ "text": "Event"
87070
87079
  }
87071
87080
  }
87072
- ],
87073
- "inheritedFrom": {
87074
- "name": "SbbButtonBaseElement",
87075
- "module": "core/base-elements/button-base-element.js"
87076
- }
87077
- },
87078
- {
87079
- "kind": "field",
87080
- "name": "_formKeyDown",
87081
- "privacy": "private",
87082
- "inheritedFrom": {
87083
- "name": "SbbButtonBaseElement",
87084
- "module": "core/base-elements/button-base-element.js"
87085
- }
87086
- },
87087
- {
87088
- "kind": "field",
87089
- "name": "formAssociated",
87090
- "type": {
87091
- "text": "boolean"
87092
- },
87093
- "privacy": "public",
87094
- "static": true,
87095
- "default": "true",
87096
- "inheritedFrom": {
87097
- "name": "SbbFormAssociatedMixin",
87098
- "module": "core/mixins/form-associated-mixin.js"
87099
- }
87100
- },
87101
- {
87102
- "kind": "field",
87103
- "name": "name",
87104
- "privacy": "public",
87105
- "description": "Name of the form element. Will be read from name attribute.",
87106
- "type": {
87107
- "text": "string"
87108
- },
87109
- "attribute": "name",
87110
- "inheritedFrom": {
87111
- "name": "SbbFormAssociatedMixin",
87112
- "module": "core/mixins/form-associated-mixin.js"
87113
- }
87081
+ ]
87114
87082
  },
87115
87083
  {
87116
87084
  "kind": "field",
87117
- "name": "validity",
87118
- "type": {
87119
- "text": "ValidityState"
87120
- },
87121
- "privacy": "public",
87122
- "description": "Returns the ValidityState object for this element.",
87123
- "readonly": true,
87124
- "inheritedFrom": {
87125
- "name": "SbbFormAssociatedMixin",
87126
- "module": "core/mixins/form-associated-mixin.js"
87127
- }
87085
+ "name": "_pointerDownListener",
87086
+ "privacy": "private"
87128
87087
  },
87129
87088
  {
87130
87089
  "kind": "field",
87131
- "name": "validationMessage",
87132
- "type": {
87133
- "text": "string"
87134
- },
87135
- "privacy": "public",
87136
- "description": "Returns the current error message, if available, which corresponds\nto the current validation state.\nPlease note that only one message is returned at a time (e.g. if\nmultiple validity states are invalid, only the chronologically first one\nis returned until it is fixed, at which point the next message might be\nreturned, if it is still applicable). Also, a custom validity message\n(see below) has precedence over native validation messages.",
87137
- "readonly": true,
87138
- "inheritedFrom": {
87139
- "name": "SbbFormAssociatedMixin",
87140
- "module": "core/mixins/form-associated-mixin.js"
87141
- }
87090
+ "name": "_closeOnBackdropClick",
87091
+ "privacy": "private"
87142
87092
  },
87143
87093
  {
87144
- "kind": "field",
87145
- "name": "willValidate",
87146
- "type": {
87147
- "text": "boolean"
87094
+ "kind": "method",
87095
+ "name": "_nestedMenus",
87096
+ "privacy": "private",
87097
+ "return": {
87098
+ "type": {
87099
+ "text": "SbbMenuElement[]"
87100
+ }
87148
87101
  },
87149
- "privacy": "public",
87150
- "description": "Returns true if this element will be validated\nwhen the form is submitted; false otherwise.",
87151
- "readonly": true,
87152
- "inheritedFrom": {
87153
- "name": "SbbFormAssociatedMixin",
87154
- "module": "core/mixins/form-associated-mixin.js"
87155
- }
87102
+ "description": "Converts the linked list into an array of SbbMenuElement."
87156
87103
  },
87157
87104
  {
87158
- "kind": "field",
87159
- "name": "_validityStates",
87105
+ "kind": "method",
87106
+ "name": "_parentMenu",
87160
87107
  "privacy": "private",
87161
- "default": "new Map< keyof ValidityStateFlags, { flagValue: unknown; message: string } >()",
87162
- "inheritedFrom": {
87163
- "name": "SbbFormAssociatedMixin",
87164
- "module": "core/mixins/form-associated-mixin.js"
87108
+ "return": {
87109
+ "type": {
87110
+ "text": "SbbMenuElement | null"
87111
+ }
87165
87112
  }
87166
87113
  },
87167
87114
  {
87168
- "kind": "field",
87169
- "name": "formDisabled",
87170
- "type": {
87171
- "text": "boolean"
87115
+ "kind": "method",
87116
+ "name": "_mainMenu",
87117
+ "privacy": "private",
87118
+ "return": {
87119
+ "type": {
87120
+ "text": "SbbMenuElement"
87121
+ }
87172
87122
  },
87173
- "privacy": "protected",
87174
- "default": "false",
87175
- "description": "Whenever a surrounding form or fieldset is changing its disabled state.",
87176
- "inheritedFrom": {
87177
- "name": "SbbFormAssociatedMixin",
87178
- "module": "core/mixins/form-associated-mixin.js"
87179
- }
87123
+ "description": "The outermost menu."
87180
87124
  },
87181
87125
  {
87182
87126
  "kind": "method",
87183
- "name": "checkValidity",
87184
- "privacy": "public",
87127
+ "name": "_isNested",
87128
+ "privacy": "private",
87185
87129
  "return": {
87186
87130
  "type": {
87187
87131
  "text": "boolean"
87188
87132
  }
87189
- },
87190
- "description": "Returns true if this element has no validity problems; false otherwise.\nFires an invalid event at the element in the latter case.",
87191
- "inheritedFrom": {
87192
- "name": "SbbFormAssociatedMixin",
87193
- "module": "core/mixins/form-associated-mixin.js"
87194
87133
  }
87195
87134
  },
87196
87135
  {
87197
87136
  "kind": "method",
87198
- "name": "reportValidity",
87199
- "privacy": "public",
87137
+ "name": "_updateNestedInert",
87138
+ "privacy": "private",
87200
87139
  "return": {
87201
87140
  "type": {
87202
- "text": "boolean"
87141
+ "text": "void"
87203
87142
  }
87204
- },
87205
- "description": "Returns true if this element has no validity problems; otherwise,\nreturns false, fires an invalid event at the element,\nand (if the event isn't canceled) reports the problem to the user.",
87206
- "inheritedFrom": {
87207
- "name": "SbbFormAssociatedMixin",
87208
- "module": "core/mixins/form-associated-mixin.js"
87209
87143
  }
87210
87144
  },
87211
87145
  {
87212
87146
  "kind": "method",
87213
- "name": "setCustomValidity",
87214
- "privacy": "public",
87147
+ "name": "_handleMouseOver",
87148
+ "privacy": "private",
87215
87149
  "return": {
87216
87150
  "type": {
87217
87151
  "text": "void"
@@ -87219,64 +87153,64 @@
87219
87153
  },
87220
87154
  "parameters": [
87221
87155
  {
87222
- "name": "message",
87156
+ "name": "event",
87223
87157
  "type": {
87224
- "text": "string"
87158
+ "text": "MouseEvent"
87225
87159
  }
87226
87160
  }
87227
- ],
87228
- "description": "Sets the custom validity message for this element. Use the empty string\nto indicate that the element does not have a custom validity error.",
87229
- "inheritedFrom": {
87230
- "name": "SbbFormAssociatedMixin",
87231
- "module": "core/mixins/form-associated-mixin.js"
87232
- }
87161
+ ]
87233
87162
  },
87234
87163
  {
87235
87164
  "kind": "method",
87236
- "name": "_hasDisabledAncestor",
87165
+ "name": "_onMenuAnimationEnd",
87237
87166
  "privacy": "private",
87238
87167
  "return": {
87239
87168
  "type": {
87240
- "text": "boolean"
87169
+ "text": "void"
87241
87170
  }
87242
87171
  },
87243
- "inheritedFrom": {
87244
- "name": "SbbFormAssociatedMixin",
87245
- "module": "core/mixins/form-associated-mixin.js"
87172
+ "parameters": [
87173
+ {
87174
+ "name": "event",
87175
+ "type": {
87176
+ "text": "AnimationEvent"
87177
+ }
87178
+ }
87179
+ ]
87180
+ },
87181
+ {
87182
+ "kind": "method",
87183
+ "name": "_setMenuPosition",
87184
+ "privacy": "private",
87185
+ "return": {
87186
+ "type": {
87187
+ "text": "void"
87188
+ }
87246
87189
  }
87247
87190
  },
87248
87191
  {
87249
87192
  "kind": "method",
87250
- "name": "updateFormValue",
87251
- "privacy": "protected",
87193
+ "name": "_syncNegative",
87194
+ "privacy": "private",
87252
87195
  "return": {
87253
87196
  "type": {
87254
87197
  "text": "void"
87255
87198
  }
87256
- },
87257
- "description": "Should be called when form value is changed.\nAdapts and sets the formValue in the supported format (string | FormData | File | null)\nhttps://developer.mozilla.org/en-US/docs/Web/API/ElementInternals/setFormValue",
87258
- "inheritedFrom": {
87259
- "name": "SbbFormAssociatedMixin",
87260
- "module": "core/mixins/form-associated-mixin.js"
87261
87199
  }
87262
87200
  },
87263
87201
  {
87264
87202
  "kind": "method",
87265
- "name": "formState",
87266
- "privacy": "protected",
87203
+ "name": "_isMobile",
87204
+ "privacy": "private",
87267
87205
  "return": {
87268
87206
  "type": {
87269
- "text": "FormRestoreState"
87207
+ "text": "boolean"
87270
87208
  }
87271
- },
87272
- "inheritedFrom": {
87273
- "name": "SbbFormAssociatedMixin",
87274
- "module": "core/mixins/form-associated-mixin.js"
87275
87209
  }
87276
87210
  },
87277
87211
  {
87278
87212
  "kind": "method",
87279
- "name": "setValidityFlag",
87213
+ "name": "toggleState",
87280
87214
  "privacy": "protected",
87281
87215
  "return": {
87282
87216
  "type": {
@@ -87285,117 +87219,256 @@
87285
87219
  },
87286
87220
  "parameters": [
87287
87221
  {
87288
- "name": "flag",
87289
- "type": {
87290
- "text": "T"
87291
- }
87292
- },
87293
- {
87294
- "name": "message",
87222
+ "name": "value",
87295
87223
  "type": {
87296
87224
  "text": "string"
87297
87225
  }
87298
87226
  },
87299
87227
  {
87300
- "name": "flagValue",
87228
+ "name": "force",
87301
87229
  "optional": true,
87302
87230
  "type": {
87303
- "text": "ValidityStateFlags[T]"
87231
+ "text": "boolean"
87304
87232
  }
87305
87233
  }
87306
87234
  ],
87307
- "description": "Marks this element as suffering from the constraint indicated by the\nflag argument and associates the given message to it.\nNote that only one message is displayed at a time and custom messages by\nconsumers are always displayed before internal messages and internal\nmessages are displayed in the order they were added.\nTo set/define custom validity state flags, you need to extend the\nValidityState prototype (and the CustomValidityState interface).",
87308
87235
  "inheritedFrom": {
87309
- "name": "SbbFormAssociatedMixin",
87310
- "module": "core/mixins/form-associated-mixin.js"
87236
+ "name": "SbbOpenCloseBaseElement",
87237
+ "module": "core/base-elements/open-close-base-element.js"
87238
+ }
87239
+ },
87240
+ {
87241
+ "kind": "field",
87242
+ "name": "events",
87243
+ "privacy": "public",
87244
+ "static": true,
87245
+ "readonly": true,
87246
+ "default": "{ beforeopen: 'beforeopen', open: 'open', beforeclose: 'beforeclose', close: 'close', }",
87247
+ "type": {
87248
+ "text": "{\n beforeopen: 'beforeopen',\n open: 'open',\n beforeclose: 'beforeclose',\n close: 'close',\n }"
87249
+ },
87250
+ "inheritedFrom": {
87251
+ "name": "SbbOpenCloseBaseElement",
87252
+ "module": "core/base-elements/open-close-base-element.js"
87253
+ }
87254
+ },
87255
+ {
87256
+ "kind": "field",
87257
+ "name": "state",
87258
+ "privacy": "protected",
87259
+ "description": "The state of the component.",
87260
+ "type": {
87261
+ "text": "SbbOpenedClosedState"
87262
+ },
87263
+ "default": "'closed'",
87264
+ "inheritedFrom": {
87265
+ "name": "SbbOpenCloseBaseElement",
87266
+ "module": "core/base-elements/open-close-base-element.js"
87267
+ }
87268
+ },
87269
+ {
87270
+ "kind": "field",
87271
+ "name": "_state",
87272
+ "type": {
87273
+ "text": "SbbOpenedClosedState"
87274
+ },
87275
+ "privacy": "private",
87276
+ "inheritedFrom": {
87277
+ "name": "SbbOpenCloseBaseElement",
87278
+ "module": "core/base-elements/open-close-base-element.js"
87279
+ }
87280
+ },
87281
+ {
87282
+ "kind": "field",
87283
+ "name": "isOpen",
87284
+ "type": {
87285
+ "text": "boolean"
87286
+ },
87287
+ "privacy": "public",
87288
+ "description": "Whether the element is open.",
87289
+ "readonly": true,
87290
+ "inheritedFrom": {
87291
+ "name": "SbbOpenCloseBaseElement",
87292
+ "module": "core/base-elements/open-close-base-element.js"
87311
87293
  }
87312
87294
  },
87313
87295
  {
87314
87296
  "kind": "method",
87315
- "name": "removeValidityFlag",
87297
+ "name": "dispatchBeforeOpenEvent",
87316
87298
  "privacy": "protected",
87317
87299
  "return": {
87318
87300
  "type": {
87319
- "text": "void"
87301
+ "text": "boolean"
87320
87302
  }
87321
87303
  },
87322
- "parameters": [
87323
- {
87324
- "name": "flag",
87325
- "type": {
87326
- "text": "T"
87327
- }
87328
- }
87329
- ],
87330
- "description": "Removes the validity state flag entry and updates validity state.",
87331
87304
  "inheritedFrom": {
87332
- "name": "SbbFormAssociatedMixin",
87333
- "module": "core/mixins/form-associated-mixin.js"
87305
+ "name": "SbbOpenCloseBaseElement",
87306
+ "module": "core/base-elements/open-close-base-element.js"
87334
87307
  }
87335
87308
  },
87336
87309
  {
87337
87310
  "kind": "method",
87338
- "name": "validate",
87311
+ "name": "dispatchOpenEvent",
87339
87312
  "privacy": "protected",
87340
87313
  "return": {
87341
87314
  "type": {
87342
- "text": "void"
87315
+ "text": "boolean"
87343
87316
  }
87344
87317
  },
87345
- "description": "To be called whenever the current element needs to be validated.",
87346
87318
  "inheritedFrom": {
87347
- "name": "SbbFormAssociatedMixin",
87348
- "module": "core/mixins/form-associated-mixin.js"
87319
+ "name": "SbbOpenCloseBaseElement",
87320
+ "module": "core/base-elements/open-close-base-element.js"
87349
87321
  }
87350
87322
  },
87351
87323
  {
87352
87324
  "kind": "method",
87353
- "name": "shouldValidate",
87325
+ "name": "dispatchBeforeCloseEvent",
87354
87326
  "privacy": "protected",
87355
87327
  "return": {
87356
87328
  "type": {
87357
87329
  "text": "boolean"
87358
87330
  }
87359
87331
  },
87360
- "parameters": [
87361
- {
87362
- "name": "name",
87363
- "type": {
87364
- "text": "PropertyKey | undefined"
87365
- }
87366
- }
87367
- ],
87368
- "description": "Whether validation should be run on a property change with the given name.",
87369
87332
  "inheritedFrom": {
87370
- "name": "SbbFormAssociatedMixin",
87371
- "module": "core/mixins/form-associated-mixin.js"
87333
+ "name": "SbbOpenCloseBaseElement",
87334
+ "module": "core/base-elements/open-close-base-element.js"
87372
87335
  }
87373
87336
  },
87374
87337
  {
87375
87338
  "kind": "method",
87376
- "name": "_setInternalValidity",
87377
- "privacy": "private",
87339
+ "name": "dispatchCloseEvent",
87340
+ "privacy": "protected",
87378
87341
  "return": {
87379
87342
  "type": {
87380
- "text": "void"
87343
+ "text": "boolean"
87381
87344
  }
87382
87345
  },
87383
87346
  "inheritedFrom": {
87384
- "name": "SbbFormAssociatedMixin",
87385
- "module": "core/mixins/form-associated-mixin.js"
87347
+ "name": "SbbOpenCloseBaseElement",
87348
+ "module": "core/base-elements/open-close-base-element.js"
87349
+ }
87350
+ }
87351
+ ],
87352
+ "attributes": [
87353
+ {
87354
+ "name": "trigger",
87355
+ "type": {
87356
+ "text": "HTMLElement | null"
87357
+ },
87358
+ "default": "null",
87359
+ "description": "The element that will trigger the menu overlay.\n\nFor attribute usage, provide an id reference.",
87360
+ "fieldName": "trigger"
87361
+ }
87362
+ ],
87363
+ "superclass": {
87364
+ "name": "SbbOpenCloseBaseElement",
87365
+ "module": "core/base-elements.js"
87366
+ },
87367
+ "tagName": "sbb-menu",
87368
+ "customElement": true,
87369
+ "events": [
87370
+ {
87371
+ "name": "beforeopen",
87372
+ "type": {
87373
+ "text": "Event"
87374
+ },
87375
+ "description": "Emits whenever the component starts the opening transition. Can be canceled.",
87376
+ "inheritedFrom": {
87377
+ "name": "SbbOpenCloseBaseElement",
87378
+ "module": "core/base-elements/open-close-base-element.js"
87386
87379
  }
87387
87380
  },
87381
+ {
87382
+ "name": "open",
87383
+ "type": {
87384
+ "text": "Event"
87385
+ },
87386
+ "description": "Emits whenever the component is opened.",
87387
+ "inheritedFrom": {
87388
+ "name": "SbbOpenCloseBaseElement",
87389
+ "module": "core/base-elements/open-close-base-element.js"
87390
+ }
87391
+ },
87392
+ {
87393
+ "name": "beforeclose",
87394
+ "type": {
87395
+ "text": "Event"
87396
+ },
87397
+ "description": "Emits whenever the component begins the closing transition. Can be canceled.",
87398
+ "inheritedFrom": {
87399
+ "name": "SbbOpenCloseBaseElement",
87400
+ "module": "core/base-elements/open-close-base-element.js"
87401
+ }
87402
+ },
87403
+ {
87404
+ "name": "close",
87405
+ "type": {
87406
+ "text": "Event"
87407
+ },
87408
+ "description": "Emits whenever the component is closed.",
87409
+ "inheritedFrom": {
87410
+ "name": "SbbOpenCloseBaseElement",
87411
+ "module": "core/base-elements/open-close-base-element.js"
87412
+ }
87413
+ }
87414
+ ]
87415
+ }
87416
+ ],
87417
+ "exports": [
87418
+ {
87419
+ "kind": "js",
87420
+ "name": "SbbMenuElement",
87421
+ "declaration": {
87422
+ "name": "SbbMenuElement",
87423
+ "module": "menu/menu/menu.component.js"
87424
+ }
87425
+ },
87426
+ {
87427
+ "kind": "custom-element-definition",
87428
+ "name": "sbb-menu",
87429
+ "declaration": {
87430
+ "name": "SbbMenuElement",
87431
+ "module": "menu/menu/menu.component.js"
87432
+ }
87433
+ }
87434
+ ]
87435
+ },
87436
+ {
87437
+ "kind": "javascript-module",
87438
+ "path": "menu/menu-button/menu-button.component.js",
87439
+ "declarations": [
87440
+ {
87441
+ "kind": "class",
87442
+ "description": "It displays a button element that can be used in the `sbb-menu` component.",
87443
+ "name": "SbbMenuButtonElement",
87444
+ "cssProperties": [
87445
+ {
87446
+ "description": "Can be used to modify horizontal padding.",
87447
+ "name": "--sbb-menu-action-outer-horizontal-padding",
87448
+ "default": "var(--sbb-spacing-fixed-3x)"
87449
+ }
87450
+ ],
87451
+ "slots": [
87452
+ {
87453
+ "description": "Use the unnamed slot to add content to the `sbb-menu-button`.",
87454
+ "name": ""
87455
+ },
87456
+ {
87457
+ "description": "Use this slot to provide an icon. If `icon-name` is set, a `sbb-icon` will be used.",
87458
+ "name": "icon"
87459
+ }
87460
+ ],
87461
+ "members": [
87388
87462
  {
87389
87463
  "kind": "field",
87390
- "name": "_preventScrollOnSpaceKeydown",
87391
- "privacy": "private",
87392
- "description": "Prevents scrolling from pressing Space, when the event target is an action element.\nAlso sets active state.",
87393
- "parameters": [
87394
- {
87395
- "description": "The origin event.",
87396
- "name": "event"
87397
- }
87398
- ],
87464
+ "name": "role",
87465
+ "type": {
87466
+ "text": "ElementInternals['role']"
87467
+ },
87468
+ "privacy": "public",
87469
+ "static": true,
87470
+ "readonly": true,
87471
+ "default": "'menuitem'",
87399
87472
  "inheritedFrom": {
87400
87473
  "name": "SbbButtonLikeBaseElement",
87401
87474
  "module": "core/base-elements/button-base-element.js"
@@ -87403,75 +87476,88 @@
87403
87476
  },
87404
87477
  {
87405
87478
  "kind": "field",
87406
- "name": "_removeActiveMarker",
87407
- "privacy": "private",
87479
+ "name": "disabledInteractive",
87480
+ "type": {
87481
+ "text": "boolean"
87482
+ },
87483
+ "privacy": "public",
87484
+ "default": "false",
87485
+ "description": "Whether the button should be aria-disabled but stay interactive.",
87486
+ "attribute": "disabled-interactive",
87487
+ "reflects": true,
87408
87488
  "inheritedFrom": {
87409
- "name": "SbbButtonLikeBaseElement",
87410
- "module": "core/base-elements/button-base-element.js"
87489
+ "name": "SbbDisabledInteractiveMixin",
87490
+ "module": "core/mixins/disabled-mixin.js"
87411
87491
  }
87412
87492
  },
87413
87493
  {
87414
87494
  "kind": "field",
87415
- "name": "_dispatchClickEventOnSpaceKeyup",
87416
- "privacy": "private",
87417
- "description": "Dispatches a 'click' PointerEvent if the original keyboard event is a 'Space' press.\nAs verified with the native button, when 'Space' is pressed, a 'click' event is dispatched\nafter the 'keyup' event.",
87418
- "parameters": [
87419
- {
87420
- "description": "The origin event.",
87421
- "name": "event"
87422
- }
87423
- ],
87495
+ "name": "disabled",
87496
+ "privacy": "public",
87497
+ "description": "Whether the component is disabled.",
87498
+ "default": "false",
87499
+ "type": {
87500
+ "text": "boolean"
87501
+ },
87502
+ "attribute": "disabled",
87503
+ "reflects": true,
87424
87504
  "inheritedFrom": {
87425
- "name": "SbbButtonLikeBaseElement",
87426
- "module": "core/base-elements/button-base-element.js"
87505
+ "name": "SbbDisabledMixin",
87506
+ "module": "core/mixins/disabled-mixin.js"
87427
87507
  }
87428
87508
  },
87429
87509
  {
87430
87510
  "kind": "field",
87431
- "name": "_dispatchClickEvent",
87511
+ "name": "#disabled",
87432
87512
  "privacy": "private",
87513
+ "type": {
87514
+ "text": "boolean"
87515
+ },
87516
+ "default": "false",
87433
87517
  "inheritedFrom": {
87434
- "name": "SbbButtonLikeBaseElement",
87435
- "module": "core/base-elements/button-base-element.js"
87518
+ "name": "SbbDisabledMixin",
87519
+ "module": "core/mixins/disabled-mixin.js"
87436
87520
  }
87437
87521
  },
87438
87522
  {
87439
87523
  "kind": "method",
87440
- "name": "toggleState",
87524
+ "name": "isDisabledExternally",
87441
87525
  "privacy": "protected",
87442
87526
  "return": {
87443
87527
  "type": {
87444
- "text": "void"
87528
+ "text": "boolean"
87445
87529
  }
87446
87530
  },
87447
- "parameters": [
87448
- {
87449
- "name": "value",
87450
- "type": {
87451
- "text": "string"
87452
- }
87453
- },
87454
- {
87455
- "name": "force",
87456
- "optional": true,
87457
- "type": {
87458
- "text": "boolean"
87459
- }
87460
- }
87461
- ],
87531
+ "description": "Will be used as 'or' check to the current disabled state.\nCan e.g. be used to read disabled state of a group.",
87462
87532
  "inheritedFrom": {
87463
- "name": "SbbActionBaseElement",
87464
- "module": "core/base-elements/action-base-element.js"
87533
+ "name": "SbbDisabledMixin",
87534
+ "module": "core/mixins/disabled-mixin.js"
87465
87535
  }
87466
87536
  },
87467
87537
  {
87468
87538
  "kind": "field",
87469
- "name": "maybeDisabled",
87539
+ "name": "styles",
87470
87540
  "type": {
87471
- "text": "boolean | undefined"
87541
+ "text": "CSSResultGroup"
87472
87542
  },
87543
+ "privacy": "public",
87544
+ "static": true,
87545
+ "default": "[boxSizingStyles, style]",
87546
+ "inheritedFrom": {
87547
+ "name": "SbbMenuActionCommonElementMixin",
87548
+ "module": "menu/common/menu-action-common.js"
87549
+ }
87550
+ },
87551
+ {
87552
+ "kind": "method",
87553
+ "name": "renderTemplate",
87473
87554
  "privacy": "protected",
87474
- "readonly": true,
87555
+ "return": {
87556
+ "type": {
87557
+ "text": "TemplateResult"
87558
+ }
87559
+ },
87560
+ "description": "Override this method to render the component template.",
87475
87561
  "inheritedFrom": {
87476
87562
  "name": "SbbActionBaseElement",
87477
87563
  "module": "core/base-elements/action-base-element.js"
@@ -87479,411 +87565,375 @@
87479
87565
  },
87480
87566
  {
87481
87567
  "kind": "field",
87482
- "name": "maybeDisabledInteractive",
87568
+ "name": "iconName",
87483
87569
  "type": {
87484
- "text": "boolean | undefined"
87570
+ "text": "string"
87485
87571
  },
87486
- "privacy": "protected",
87487
- "readonly": true,
87572
+ "privacy": "public",
87573
+ "default": "''",
87574
+ "description": "The icon name we want to use, choose from the small icon variants\nfrom the ui-icons category from here\nhttps://icons.app.sbb.ch.",
87575
+ "attribute": "icon-name",
87488
87576
  "inheritedFrom": {
87489
- "name": "SbbActionBaseElement",
87490
- "module": "core/base-elements/action-base-element.js"
87577
+ "name": "SbbIconNameMixin",
87578
+ "module": "icon/icon-name-mixin.js"
87491
87579
  }
87492
87580
  },
87493
87581
  {
87494
87582
  "kind": "method",
87495
- "name": "setupBaseEventHandlers",
87583
+ "name": "renderIconSlot",
87496
87584
  "privacy": "protected",
87497
87585
  "return": {
87498
87586
  "type": {
87499
- "text": "void"
87587
+ "text": "TemplateResult"
87500
87588
  }
87501
87589
  },
87590
+ "parameters": [
87591
+ {
87592
+ "name": "classname",
87593
+ "optional": true,
87594
+ "type": {
87595
+ "text": "string"
87596
+ }
87597
+ }
87598
+ ],
87502
87599
  "inheritedFrom": {
87503
- "name": "SbbActionBaseElement",
87504
- "module": "core/base-elements/action-base-element.js"
87600
+ "name": "SbbIconNameMixin",
87601
+ "module": "icon/icon-name-mixin.js"
87505
87602
  }
87506
- }
87507
- ],
87508
- "mixins": [
87509
- {
87510
- "name": "SbbDisabledTabIndexActionMixin",
87511
- "module": "core/mixins.js"
87512
87603
  },
87513
87604
  {
87514
- "name": "SbbMenuActionCommonElementMixin",
87515
- "module": "menu/common.js"
87516
- }
87517
- ],
87518
- "superclass": {
87519
- "name": "SbbButtonBaseElement",
87520
- "module": "core/base-elements.js"
87521
- },
87522
- "tagName": "sbb-menu-button",
87523
- "customElement": true,
87524
- "attributes": [
87525
- {
87526
- "name": "disabled-interactive",
87527
- "type": {
87528
- "text": "boolean"
87605
+ "kind": "method",
87606
+ "name": "renderIconName",
87607
+ "privacy": "protected",
87608
+ "return": {
87609
+ "type": {
87610
+ "text": "string"
87611
+ }
87529
87612
  },
87530
- "default": "false",
87531
- "description": "Whether the button should be aria-disabled but stay interactive.",
87532
- "fieldName": "disabledInteractive",
87533
87613
  "inheritedFrom": {
87534
- "name": "SbbDisabledInteractiveMixin",
87535
- "module": "core/mixins/disabled-mixin.js"
87614
+ "name": "SbbIconNameMixin",
87615
+ "module": "icon/icon-name-mixin.js"
87536
87616
  }
87537
87617
  },
87538
87618
  {
87539
- "name": "disabled",
87540
- "description": "Whether the component is disabled.",
87541
- "default": "false",
87542
- "type": {
87543
- "text": "boolean"
87619
+ "kind": "method",
87620
+ "name": "_renderIconName",
87621
+ "privacy": "private",
87622
+ "return": {
87623
+ "type": {
87624
+ "text": "string"
87625
+ }
87544
87626
  },
87545
- "fieldName": "disabled",
87546
87627
  "inheritedFrom": {
87547
- "name": "SbbDisabledMixin",
87548
- "module": "core/mixins/disabled-mixin.js"
87628
+ "name": "SbbIconNameMixin",
87629
+ "module": "icon/icon-name-mixin.js"
87549
87630
  }
87550
87631
  },
87551
87632
  {
87552
- "name": "icon-name",
87633
+ "kind": "field",
87634
+ "name": "_elementsOnWhichEnterPressTriggersSubmit",
87553
87635
  "type": {
87554
- "text": "string"
87636
+ "text": "array"
87555
87637
  },
87556
- "default": "''",
87557
- "description": "The icon name we want to use, choose from the small icon variants\nfrom the ui-icons category from here\nhttps://icons.app.sbb.ch.",
87558
- "fieldName": "iconName",
87638
+ "privacy": "private",
87639
+ "readonly": true,
87640
+ "default": "[ 'input', 'sbb-date-input', 'sbb-time-input', ]",
87559
87641
  "inheritedFrom": {
87560
- "name": "SbbIconNameMixin",
87561
- "module": "icon/icon-name-mixin.js"
87642
+ "name": "SbbButtonBaseElement",
87643
+ "module": "core/base-elements/button-base-element.js"
87562
87644
  }
87563
87645
  },
87564
87646
  {
87647
+ "kind": "field",
87565
87648
  "name": "value",
87566
87649
  "type": {
87567
87650
  "text": "string"
87568
87651
  },
87569
- "default": "''",
87570
- "description": "Value of the form element.",
87571
- "fieldName": "value",
87652
+ "privacy": "public",
87572
87653
  "inheritedFrom": {
87573
87654
  "name": "SbbButtonBaseElement",
87574
87655
  "module": "core/base-elements/button-base-element.js"
87575
- }
87656
+ },
87657
+ "default": "''",
87658
+ "description": "Value of the form element.",
87659
+ "attribute": "value"
87576
87660
  },
87577
87661
  {
87662
+ "kind": "field",
87578
87663
  "name": "type",
87664
+ "privacy": "public",
87579
87665
  "description": "The type attribute to use for the button.",
87580
87666
  "default": "'button'",
87581
87667
  "type": {
87582
87668
  "text": "SbbButtonType"
87583
87669
  },
87584
- "fieldName": "type",
87670
+ "attribute": "type",
87585
87671
  "inheritedFrom": {
87586
87672
  "name": "SbbButtonBaseElement",
87587
87673
  "module": "core/base-elements/button-base-element.js"
87588
87674
  }
87589
87675
  },
87590
87676
  {
87677
+ "kind": "field",
87591
87678
  "name": "form",
87592
- "description": "The `<form>` element to associate the button with.",
87593
87679
  "type": {
87594
87680
  "text": "HTMLFormElement | null"
87595
87681
  },
87596
- "fieldName": "form",
87682
+ "privacy": "public",
87683
+ "description": "The `<form>` element to associate the button with.",
87597
87684
  "inheritedFrom": {
87598
87685
  "name": "SbbButtonBaseElement",
87599
87686
  "module": "core/base-elements/button-base-element.js"
87600
- }
87687
+ },
87688
+ "attribute": "form"
87601
87689
  },
87602
87690
  {
87603
- "name": "name",
87604
- "description": "Name of the form element. Will be read from name attribute.",
87691
+ "kind": "field",
87692
+ "name": "_formId",
87605
87693
  "type": {
87606
87694
  "text": "string"
87607
87695
  },
87608
- "fieldName": "name",
87696
+ "privacy": "private",
87697
+ "default": "''",
87609
87698
  "inheritedFrom": {
87610
- "name": "SbbFormAssociatedMixin",
87611
- "module": "core/mixins/form-associated-mixin.js"
87699
+ "name": "SbbButtonBaseElement",
87700
+ "module": "core/base-elements/button-base-element.js"
87612
87701
  }
87613
- }
87614
- ]
87615
- }
87616
- ],
87617
- "exports": [
87618
- {
87619
- "kind": "js",
87620
- "name": "SbbMenuButtonElement",
87621
- "declaration": {
87622
- "name": "SbbMenuButtonElement",
87623
- "module": "menu/menu-button/menu-button.component.js"
87624
- }
87625
- },
87626
- {
87627
- "kind": "custom-element-definition",
87628
- "name": "sbb-menu-button",
87629
- "declaration": {
87630
- "name": "SbbMenuButtonElement",
87631
- "module": "menu/menu-button/menu-button.component.js"
87632
- }
87633
- }
87634
- ]
87635
- },
87636
- {
87637
- "kind": "javascript-module",
87638
- "path": "menu/menu/menu.component.js",
87639
- "declarations": [
87640
- {
87641
- "kind": "class",
87642
- "description": "It displays a contextual menu with one or more action element.",
87643
- "name": "SbbMenuElement",
87644
- "cssProperties": [
87645
- {
87646
- "description": "To specify a custom stack order, the `z-index` can be overridden by defining this CSS variable. The default `z-index` of the component is set to `var(--sbb-overlay-default-z-index)` with a value of `1000`.",
87647
- "name": "--sbb-menu-z-index",
87648
- "default": "var(--sbb-overlay-default-z-index)"
87649
- }
87650
- ],
87651
- "slots": [
87652
- {
87653
- "description": "Use the unnamed slot to add `sbb-menu-button`/`sbb-menu-link` or other elements to the menu.",
87654
- "name": ""
87655
- }
87656
- ],
87657
- "members": [
87658
- {
87659
- "kind": "field",
87660
- "name": "role",
87661
- "type": {
87662
- "text": "string"
87663
- },
87664
- "privacy": "public",
87665
- "static": true,
87666
- "readonly": true,
87667
- "default": "'menu'"
87668
87702
  },
87669
87703
  {
87670
87704
  "kind": "field",
87671
- "name": "trigger",
87672
- "type": {
87673
- "text": "HTMLElement | null"
87674
- },
87675
- "privacy": "public",
87676
- "default": "null",
87677
- "description": "The element that will trigger the menu overlay.\n\nFor attribute usage, provide an id reference.",
87678
- "attribute": "trigger"
87705
+ "name": "_handleButtonClick",
87706
+ "privacy": "private",
87707
+ "inheritedFrom": {
87708
+ "name": "SbbButtonBaseElement",
87709
+ "module": "core/base-elements/button-base-element.js"
87710
+ }
87679
87711
  },
87680
87712
  {
87681
- "kind": "field",
87682
- "name": "_menu",
87683
- "type": {
87684
- "text": "HTMLDivElement"
87713
+ "kind": "method",
87714
+ "name": "_requestSubmit",
87715
+ "privacy": "private",
87716
+ "return": {
87717
+ "type": {
87718
+ "text": "void"
87719
+ }
87685
87720
  },
87686
- "privacy": "private"
87721
+ "parameters": [
87722
+ {
87723
+ "name": "form",
87724
+ "type": {
87725
+ "text": "HTMLFormElement"
87726
+ }
87727
+ }
87728
+ ],
87729
+ "inheritedFrom": {
87730
+ "name": "SbbButtonBaseElement",
87731
+ "module": "core/base-elements/button-base-element.js"
87732
+ }
87687
87733
  },
87688
87734
  {
87689
87735
  "kind": "field",
87690
- "name": "_triggerElement",
87691
- "type": {
87692
- "text": "HTMLElement | null"
87693
- },
87736
+ "name": "_formKeyDown",
87694
87737
  "privacy": "private",
87695
- "default": "null"
87738
+ "inheritedFrom": {
87739
+ "name": "SbbButtonBaseElement",
87740
+ "module": "core/base-elements/button-base-element.js"
87741
+ }
87696
87742
  },
87697
87743
  {
87698
87744
  "kind": "field",
87699
- "name": "_triggerAbortController",
87745
+ "name": "formAssociated",
87700
87746
  "type": {
87701
- "text": "AbortController"
87747
+ "text": "boolean"
87702
87748
  },
87703
- "privacy": "private"
87749
+ "privacy": "public",
87750
+ "static": true,
87751
+ "default": "true",
87752
+ "inheritedFrom": {
87753
+ "name": "SbbFormAssociatedMixin",
87754
+ "module": "core/mixins/form-associated-mixin.js"
87755
+ }
87704
87756
  },
87705
87757
  {
87706
87758
  "kind": "field",
87707
- "name": "_isPointerDownEventOnMenu",
87759
+ "name": "name",
87760
+ "privacy": "public",
87761
+ "description": "Name of the form element. Will be read from name attribute.",
87708
87762
  "type": {
87709
- "text": "boolean"
87763
+ "text": "string"
87710
87764
  },
87711
- "privacy": "private",
87712
- "default": "false"
87765
+ "attribute": "name",
87766
+ "inheritedFrom": {
87767
+ "name": "SbbFormAssociatedMixin",
87768
+ "module": "core/mixins/form-associated-mixin.js"
87769
+ }
87713
87770
  },
87714
87771
  {
87715
87772
  "kind": "field",
87716
- "name": "_windowEventsController",
87773
+ "name": "validity",
87717
87774
  "type": {
87718
- "text": "AbortController"
87775
+ "text": "ValidityState"
87719
87776
  },
87720
- "privacy": "private"
87721
- },
87722
- {
87723
- "kind": "field",
87724
- "name": "_escapableOverlayController",
87725
- "privacy": "private",
87726
- "default": "new SbbEscapableOverlayController(this)"
87727
- },
87728
- {
87729
- "kind": "field",
87730
- "name": "_focusTrapController",
87731
- "privacy": "private",
87732
- "default": "new SbbFocusTrapController(this)"
87733
- },
87734
- {
87735
- "kind": "field",
87736
- "name": "_scrollHandler",
87737
- "privacy": "private",
87738
- "default": "new SbbScrollHandler()"
87739
- },
87740
- {
87741
- "kind": "field",
87742
- "name": "_inertController",
87743
- "privacy": "private",
87744
- "default": "new SbbInertController(this)"
87745
- },
87746
- {
87747
- "kind": "field",
87748
- "name": "_mobileBreakpoint",
87749
- "privacy": "private",
87750
- "default": "SbbMediaQueryBreakpointSmallAndBelow"
87777
+ "privacy": "public",
87778
+ "description": "Returns the ValidityState object for this element.",
87779
+ "readonly": true,
87780
+ "inheritedFrom": {
87781
+ "name": "SbbFormAssociatedMixin",
87782
+ "module": "core/mixins/form-associated-mixin.js"
87783
+ }
87751
87784
  },
87752
87785
  {
87753
87786
  "kind": "field",
87754
- "name": "_mediaMatcher",
87755
- "privacy": "private",
87756
- "default": "new SbbMediaMatcherController(this, { [this._mobileBreakpoint]: (matches) => { if (matches && (this.state === 'opening' || this.state === 'opened')) { this._scrollHandler.disableScroll(); } else { this._scrollHandler.enableScroll(); } }, })"
87787
+ "name": "validationMessage",
87788
+ "type": {
87789
+ "text": "string"
87790
+ },
87791
+ "privacy": "public",
87792
+ "description": "Returns the current error message, if available, which corresponds\nto the current validation state.\nPlease note that only one message is returned at a time (e.g. if\nmultiple validity states are invalid, only the chronologically first one\nis returned until it is fixed, at which point the next message might be\nreturned, if it is still applicable). Also, a custom validity message\n(see below) has precedence over native validation messages.",
87793
+ "readonly": true,
87794
+ "inheritedFrom": {
87795
+ "name": "SbbFormAssociatedMixin",
87796
+ "module": "core/mixins/form-associated-mixin.js"
87797
+ }
87757
87798
  },
87758
87799
  {
87759
87800
  "kind": "field",
87760
- "name": "_darkModeController",
87761
- "privacy": "private",
87762
- "default": "new SbbDarkModeController(this, () => this._syncNegative())"
87801
+ "name": "willValidate",
87802
+ "type": {
87803
+ "text": "boolean"
87804
+ },
87805
+ "privacy": "public",
87806
+ "description": "Returns true if this element will be validated\nwhen the form is submitted; false otherwise.",
87807
+ "readonly": true,
87808
+ "inheritedFrom": {
87809
+ "name": "SbbFormAssociatedMixin",
87810
+ "module": "core/mixins/form-associated-mixin.js"
87811
+ }
87763
87812
  },
87764
87813
  {
87765
87814
  "kind": "field",
87766
- "name": "_language",
87815
+ "name": "_validityStates",
87767
87816
  "privacy": "private",
87768
- "default": "new SbbLanguageController(this)"
87817
+ "default": "new Map< keyof ValidityStateFlags, { flagValue: unknown; message: string } >()",
87818
+ "inheritedFrom": {
87819
+ "name": "SbbFormAssociatedMixin",
87820
+ "module": "core/mixins/form-associated-mixin.js"
87821
+ }
87769
87822
  },
87770
87823
  {
87771
87824
  "kind": "field",
87772
- "name": "_nestedMenu",
87825
+ "name": "formDisabled",
87773
87826
  "type": {
87774
- "text": "SbbMenuElement | null"
87775
- },
87776
- "privacy": "private",
87777
- "default": "null"
87778
- },
87779
- {
87780
- "kind": "method",
87781
- "name": "escapeStrategy",
87782
- "privacy": "public",
87783
- "return": {
87784
- "type": {
87785
- "text": "void"
87786
- }
87827
+ "text": "boolean"
87787
87828
  },
87788
- "description": "The method which is called on escape key press. Defaults to calling close()",
87829
+ "privacy": "protected",
87830
+ "default": "false",
87831
+ "description": "Whenever a surrounding form or fieldset is changing its disabled state.",
87789
87832
  "inheritedFrom": {
87790
- "name": "SbbOpenCloseBaseElement",
87791
- "module": "core/base-elements/open-close-base-element.js"
87833
+ "name": "SbbFormAssociatedMixin",
87834
+ "module": "core/mixins/form-associated-mixin.js"
87792
87835
  }
87793
87836
  },
87794
87837
  {
87795
87838
  "kind": "method",
87796
- "name": "open",
87839
+ "name": "checkValidity",
87797
87840
  "privacy": "public",
87798
87841
  "return": {
87799
87842
  "type": {
87800
- "text": "void"
87843
+ "text": "boolean"
87801
87844
  }
87802
87845
  },
87803
- "description": "Opens the menu on trigger click.",
87846
+ "description": "Returns true if this element has no validity problems; false otherwise.\nFires an invalid event at the element in the latter case.",
87804
87847
  "inheritedFrom": {
87805
- "name": "SbbOpenCloseBaseElement",
87806
- "module": "core/base-elements/open-close-base-element.js"
87848
+ "name": "SbbFormAssociatedMixin",
87849
+ "module": "core/mixins/form-associated-mixin.js"
87807
87850
  }
87808
87851
  },
87809
87852
  {
87810
87853
  "kind": "method",
87811
- "name": "close",
87854
+ "name": "reportValidity",
87812
87855
  "privacy": "public",
87813
87856
  "return": {
87814
87857
  "type": {
87815
- "text": "void"
87858
+ "text": "boolean"
87816
87859
  }
87817
87860
  },
87818
- "description": "Closes the menu and all its nested menus.",
87861
+ "description": "Returns true if this element has no validity problems; otherwise,\nreturns false, fires an invalid event at the element,\nand (if the event isn't canceled) reports the problem to the user.",
87819
87862
  "inheritedFrom": {
87820
- "name": "SbbOpenCloseBaseElement",
87821
- "module": "core/base-elements/open-close-base-element.js"
87863
+ "name": "SbbFormAssociatedMixin",
87864
+ "module": "core/mixins/form-associated-mixin.js"
87822
87865
  }
87823
87866
  },
87824
87867
  {
87825
87868
  "kind": "method",
87826
- "name": "closeAll",
87869
+ "name": "setCustomValidity",
87827
87870
  "privacy": "public",
87828
87871
  "return": {
87829
87872
  "type": {
87830
87873
  "text": "void"
87831
87874
  }
87832
87875
  },
87833
- "description": "Closes the menu and all related menus (nested and parent menus)."
87834
- },
87835
- {
87836
- "kind": "method",
87837
- "name": "_close",
87838
- "privacy": "private",
87839
- "return": {
87840
- "type": {
87841
- "text": "void"
87842
- }
87843
- },
87844
87876
  "parameters": [
87845
87877
  {
87846
- "name": "closeAll",
87847
- "default": "false",
87848
- "description": "If true, it ensures animations are correct by toggling some states when closing all related menus at once.",
87849
- "optional": true
87878
+ "name": "message",
87879
+ "type": {
87880
+ "text": "string"
87881
+ }
87850
87882
  }
87851
- ]
87883
+ ],
87884
+ "description": "Sets the custom validity message for this element. Use the empty string\nto indicate that the element does not have a custom validity error.",
87885
+ "inheritedFrom": {
87886
+ "name": "SbbFormAssociatedMixin",
87887
+ "module": "core/mixins/form-associated-mixin.js"
87888
+ }
87852
87889
  },
87853
87890
  {
87854
87891
  "kind": "method",
87855
- "name": "_isZeroAnimationDuration",
87892
+ "name": "_hasDisabledAncestor",
87856
87893
  "privacy": "private",
87857
87894
  "return": {
87858
87895
  "type": {
87859
87896
  "text": "boolean"
87860
87897
  }
87898
+ },
87899
+ "inheritedFrom": {
87900
+ "name": "SbbFormAssociatedMixin",
87901
+ "module": "core/mixins/form-associated-mixin.js"
87861
87902
  }
87862
87903
  },
87863
87904
  {
87864
87905
  "kind": "method",
87865
- "name": "_handleOpening",
87866
- "privacy": "private",
87906
+ "name": "updateFormValue",
87907
+ "privacy": "protected",
87867
87908
  "return": {
87868
87909
  "type": {
87869
87910
  "text": "void"
87870
87911
  }
87912
+ },
87913
+ "description": "Should be called when form value is changed.\nAdapts and sets the formValue in the supported format (string | FormData | File | null)\nhttps://developer.mozilla.org/en-US/docs/Web/API/ElementInternals/setFormValue",
87914
+ "inheritedFrom": {
87915
+ "name": "SbbFormAssociatedMixin",
87916
+ "module": "core/mixins/form-associated-mixin.js"
87871
87917
  }
87872
87918
  },
87873
87919
  {
87874
87920
  "kind": "method",
87875
- "name": "_handleClosing",
87876
- "privacy": "private",
87921
+ "name": "formState",
87922
+ "privacy": "protected",
87877
87923
  "return": {
87878
87924
  "type": {
87879
- "text": "void"
87925
+ "text": "FormRestoreState"
87880
87926
  }
87927
+ },
87928
+ "inheritedFrom": {
87929
+ "name": "SbbFormAssociatedMixin",
87930
+ "module": "core/mixins/form-associated-mixin.js"
87881
87931
  }
87882
87932
  },
87883
87933
  {
87884
87934
  "kind": "method",
87885
- "name": "_handleKeyDown",
87886
- "privacy": "private",
87935
+ "name": "setValidityFlag",
87936
+ "privacy": "protected",
87887
87937
  "return": {
87888
87938
  "type": {
87889
87939
  "text": "void"
@@ -87891,37 +87941,35 @@
87891
87941
  },
87892
87942
  "parameters": [
87893
87943
  {
87894
- "name": "evt",
87944
+ "name": "flag",
87895
87945
  "type": {
87896
- "text": "KeyboardEvent"
87946
+ "text": "T"
87947
+ }
87948
+ },
87949
+ {
87950
+ "name": "message",
87951
+ "type": {
87952
+ "text": "string"
87953
+ }
87954
+ },
87955
+ {
87956
+ "name": "flagValue",
87957
+ "optional": true,
87958
+ "type": {
87959
+ "text": "ValidityStateFlags[T]"
87897
87960
  }
87898
87961
  }
87899
- ]
87900
- },
87901
- {
87902
- "kind": "method",
87903
- "name": "_configureTrigger",
87904
- "privacy": "private",
87905
- "return": {
87906
- "type": {
87907
- "text": "void"
87908
- }
87909
- }
87910
- },
87911
- {
87912
- "kind": "method",
87913
- "name": "_attachWindowEvents",
87914
- "privacy": "private",
87915
- "return": {
87916
- "type": {
87917
- "text": "void"
87918
- }
87962
+ ],
87963
+ "description": "Marks this element as suffering from the constraint indicated by the\nflag argument and associates the given message to it.\nNote that only one message is displayed at a time and custom messages by\nconsumers are always displayed before internal messages and internal\nmessages are displayed in the order they were added.\nTo set/define custom validity state flags, you need to extend the\nValidityState prototype (and the CustomValidityState interface).",
87964
+ "inheritedFrom": {
87965
+ "name": "SbbFormAssociatedMixin",
87966
+ "module": "core/mixins/form-associated-mixin.js"
87919
87967
  }
87920
87968
  },
87921
87969
  {
87922
87970
  "kind": "method",
87923
- "name": "_interactiveElementClick",
87924
- "privacy": "private",
87971
+ "name": "removeValidityFlag",
87972
+ "privacy": "protected",
87925
87973
  "return": {
87926
87974
  "type": {
87927
87975
  "text": "void"
@@ -87929,139 +87977,118 @@
87929
87977
  },
87930
87978
  "parameters": [
87931
87979
  {
87932
- "name": "event",
87980
+ "name": "flag",
87933
87981
  "type": {
87934
- "text": "Event"
87982
+ "text": "T"
87935
87983
  }
87936
87984
  }
87937
- ]
87938
- },
87939
- {
87940
- "kind": "field",
87941
- "name": "_pointerDownListener",
87942
- "privacy": "private"
87943
- },
87944
- {
87945
- "kind": "field",
87946
- "name": "_closeOnBackdropClick",
87947
- "privacy": "private"
87948
- },
87949
- {
87950
- "kind": "method",
87951
- "name": "_nestedMenus",
87952
- "privacy": "private",
87953
- "return": {
87954
- "type": {
87955
- "text": "SbbMenuElement[]"
87956
- }
87957
- },
87958
- "description": "Converts the linked list into an array of SbbMenuElement."
87959
- },
87960
- {
87961
- "kind": "method",
87962
- "name": "_parentMenu",
87963
- "privacy": "private",
87964
- "return": {
87965
- "type": {
87966
- "text": "SbbMenuElement | null"
87967
- }
87968
- }
87969
- },
87970
- {
87971
- "kind": "method",
87972
- "name": "_mainMenu",
87973
- "privacy": "private",
87974
- "return": {
87975
- "type": {
87976
- "text": "SbbMenuElement"
87977
- }
87978
- },
87979
- "description": "The outermost menu."
87980
- },
87981
- {
87982
- "kind": "method",
87983
- "name": "_isNested",
87984
- "privacy": "private",
87985
- "return": {
87986
- "type": {
87987
- "text": "boolean"
87988
- }
87985
+ ],
87986
+ "description": "Removes the validity state flag entry and updates validity state.",
87987
+ "inheritedFrom": {
87988
+ "name": "SbbFormAssociatedMixin",
87989
+ "module": "core/mixins/form-associated-mixin.js"
87989
87990
  }
87990
87991
  },
87991
87992
  {
87992
87993
  "kind": "method",
87993
- "name": "_updateNestedInert",
87994
- "privacy": "private",
87994
+ "name": "validate",
87995
+ "privacy": "protected",
87995
87996
  "return": {
87996
87997
  "type": {
87997
87998
  "text": "void"
87998
87999
  }
88000
+ },
88001
+ "description": "To be called whenever the current element needs to be validated.",
88002
+ "inheritedFrom": {
88003
+ "name": "SbbFormAssociatedMixin",
88004
+ "module": "core/mixins/form-associated-mixin.js"
87999
88005
  }
88000
88006
  },
88001
88007
  {
88002
88008
  "kind": "method",
88003
- "name": "_handleMouseOver",
88004
- "privacy": "private",
88009
+ "name": "shouldValidate",
88010
+ "privacy": "protected",
88005
88011
  "return": {
88006
88012
  "type": {
88007
- "text": "void"
88013
+ "text": "boolean"
88008
88014
  }
88009
88015
  },
88010
88016
  "parameters": [
88011
88017
  {
88012
- "name": "event",
88018
+ "name": "name",
88013
88019
  "type": {
88014
- "text": "MouseEvent"
88020
+ "text": "PropertyKey | undefined"
88015
88021
  }
88016
88022
  }
88017
- ]
88023
+ ],
88024
+ "description": "Whether validation should be run on a property change with the given name.",
88025
+ "inheritedFrom": {
88026
+ "name": "SbbFormAssociatedMixin",
88027
+ "module": "core/mixins/form-associated-mixin.js"
88028
+ }
88018
88029
  },
88019
88030
  {
88020
88031
  "kind": "method",
88021
- "name": "_onMenuAnimationEnd",
88032
+ "name": "_setInternalValidity",
88022
88033
  "privacy": "private",
88023
88034
  "return": {
88024
88035
  "type": {
88025
88036
  "text": "void"
88026
88037
  }
88027
88038
  },
88039
+ "inheritedFrom": {
88040
+ "name": "SbbFormAssociatedMixin",
88041
+ "module": "core/mixins/form-associated-mixin.js"
88042
+ }
88043
+ },
88044
+ {
88045
+ "kind": "field",
88046
+ "name": "_preventScrollOnSpaceKeydown",
88047
+ "privacy": "private",
88048
+ "description": "Prevents scrolling from pressing Space, when the event target is an action element.\nAlso sets active state.",
88028
88049
  "parameters": [
88029
- {
88030
- "name": "event",
88031
- "type": {
88032
- "text": "AnimationEvent"
88033
- }
88050
+ {
88051
+ "description": "The origin event.",
88052
+ "name": "event"
88034
88053
  }
88035
- ]
88054
+ ],
88055
+ "inheritedFrom": {
88056
+ "name": "SbbButtonLikeBaseElement",
88057
+ "module": "core/base-elements/button-base-element.js"
88058
+ }
88036
88059
  },
88037
88060
  {
88038
- "kind": "method",
88039
- "name": "_setMenuPosition",
88061
+ "kind": "field",
88062
+ "name": "_removeActiveMarker",
88040
88063
  "privacy": "private",
88041
- "return": {
88042
- "type": {
88043
- "text": "void"
88044
- }
88064
+ "inheritedFrom": {
88065
+ "name": "SbbButtonLikeBaseElement",
88066
+ "module": "core/base-elements/button-base-element.js"
88045
88067
  }
88046
88068
  },
88047
88069
  {
88048
- "kind": "method",
88049
- "name": "_syncNegative",
88070
+ "kind": "field",
88071
+ "name": "_dispatchClickEventOnSpaceKeyup",
88050
88072
  "privacy": "private",
88051
- "return": {
88052
- "type": {
88053
- "text": "void"
88073
+ "description": "Dispatches a 'click' PointerEvent if the original keyboard event is a 'Space' press.\nAs verified with the native button, when 'Space' is pressed, a 'click' event is dispatched\nafter the 'keyup' event.",
88074
+ "parameters": [
88075
+ {
88076
+ "description": "The origin event.",
88077
+ "name": "event"
88054
88078
  }
88079
+ ],
88080
+ "inheritedFrom": {
88081
+ "name": "SbbButtonLikeBaseElement",
88082
+ "module": "core/base-elements/button-base-element.js"
88055
88083
  }
88056
88084
  },
88057
88085
  {
88058
- "kind": "method",
88059
- "name": "_isMobile",
88086
+ "kind": "field",
88087
+ "name": "_dispatchClickEvent",
88060
88088
  "privacy": "private",
88061
- "return": {
88062
- "type": {
88063
- "text": "boolean"
88064
- }
88089
+ "inheritedFrom": {
88090
+ "name": "SbbButtonLikeBaseElement",
88091
+ "module": "core/base-elements/button-base-element.js"
88065
88092
  }
88066
88093
  },
88067
88094
  {
@@ -88089,182 +88116,155 @@
88089
88116
  }
88090
88117
  ],
88091
88118
  "inheritedFrom": {
88092
- "name": "SbbOpenCloseBaseElement",
88093
- "module": "core/base-elements/open-close-base-element.js"
88119
+ "name": "SbbActionBaseElement",
88120
+ "module": "core/base-elements/action-base-element.js"
88094
88121
  }
88095
88122
  },
88096
88123
  {
88097
88124
  "kind": "field",
88098
- "name": "events",
88099
- "privacy": "public",
88100
- "static": true,
88101
- "readonly": true,
88102
- "default": "{ beforeopen: 'beforeopen', open: 'open', beforeclose: 'beforeclose', close: 'close', }",
88125
+ "name": "maybeDisabled",
88103
88126
  "type": {
88104
- "text": "{\n beforeopen: 'beforeopen',\n open: 'open',\n beforeclose: 'beforeclose',\n close: 'close',\n }"
88127
+ "text": "boolean | undefined"
88105
88128
  },
88106
- "inheritedFrom": {
88107
- "name": "SbbOpenCloseBaseElement",
88108
- "module": "core/base-elements/open-close-base-element.js"
88109
- }
88110
- },
88111
- {
88112
- "kind": "field",
88113
- "name": "state",
88114
88129
  "privacy": "protected",
88115
- "description": "The state of the component.",
88116
- "type": {
88117
- "text": "SbbOpenedClosedState"
88118
- },
88119
- "default": "'closed'",
88120
- "inheritedFrom": {
88121
- "name": "SbbOpenCloseBaseElement",
88122
- "module": "core/base-elements/open-close-base-element.js"
88123
- }
88124
- },
88125
- {
88126
- "kind": "field",
88127
- "name": "_state",
88128
- "type": {
88129
- "text": "SbbOpenedClosedState"
88130
- },
88131
- "privacy": "private",
88130
+ "readonly": true,
88132
88131
  "inheritedFrom": {
88133
- "name": "SbbOpenCloseBaseElement",
88134
- "module": "core/base-elements/open-close-base-element.js"
88132
+ "name": "SbbActionBaseElement",
88133
+ "module": "core/base-elements/action-base-element.js"
88135
88134
  }
88136
88135
  },
88137
88136
  {
88138
88137
  "kind": "field",
88139
- "name": "isOpen",
88138
+ "name": "maybeDisabledInteractive",
88140
88139
  "type": {
88141
- "text": "boolean"
88140
+ "text": "boolean | undefined"
88142
88141
  },
88143
- "privacy": "public",
88144
- "description": "Whether the element is open.",
88142
+ "privacy": "protected",
88145
88143
  "readonly": true,
88146
88144
  "inheritedFrom": {
88147
- "name": "SbbOpenCloseBaseElement",
88148
- "module": "core/base-elements/open-close-base-element.js"
88145
+ "name": "SbbActionBaseElement",
88146
+ "module": "core/base-elements/action-base-element.js"
88149
88147
  }
88150
88148
  },
88151
88149
  {
88152
88150
  "kind": "method",
88153
- "name": "dispatchBeforeOpenEvent",
88151
+ "name": "setupBaseEventHandlers",
88154
88152
  "privacy": "protected",
88155
88153
  "return": {
88156
88154
  "type": {
88157
- "text": "boolean"
88155
+ "text": "void"
88158
88156
  }
88159
88157
  },
88160
88158
  "inheritedFrom": {
88161
- "name": "SbbOpenCloseBaseElement",
88162
- "module": "core/base-elements/open-close-base-element.js"
88159
+ "name": "SbbActionBaseElement",
88160
+ "module": "core/base-elements/action-base-element.js"
88163
88161
  }
88162
+ }
88163
+ ],
88164
+ "mixins": [
88165
+ {
88166
+ "name": "SbbDisabledTabIndexActionMixin",
88167
+ "module": "core/mixins.js"
88164
88168
  },
88165
88169
  {
88166
- "kind": "method",
88167
- "name": "dispatchOpenEvent",
88168
- "privacy": "protected",
88169
- "return": {
88170
- "type": {
88171
- "text": "boolean"
88172
- }
88170
+ "name": "SbbMenuActionCommonElementMixin",
88171
+ "module": "menu/common.js"
88172
+ }
88173
+ ],
88174
+ "superclass": {
88175
+ "name": "SbbButtonBaseElement",
88176
+ "module": "core/base-elements.js"
88177
+ },
88178
+ "tagName": "sbb-menu-button",
88179
+ "customElement": true,
88180
+ "attributes": [
88181
+ {
88182
+ "name": "disabled-interactive",
88183
+ "type": {
88184
+ "text": "boolean"
88173
88185
  },
88186
+ "default": "false",
88187
+ "description": "Whether the button should be aria-disabled but stay interactive.",
88188
+ "fieldName": "disabledInteractive",
88174
88189
  "inheritedFrom": {
88175
- "name": "SbbOpenCloseBaseElement",
88176
- "module": "core/base-elements/open-close-base-element.js"
88190
+ "name": "SbbDisabledInteractiveMixin",
88191
+ "module": "core/mixins/disabled-mixin.js"
88177
88192
  }
88178
88193
  },
88179
88194
  {
88180
- "kind": "method",
88181
- "name": "dispatchBeforeCloseEvent",
88182
- "privacy": "protected",
88183
- "return": {
88184
- "type": {
88185
- "text": "boolean"
88186
- }
88195
+ "name": "disabled",
88196
+ "description": "Whether the component is disabled.",
88197
+ "default": "false",
88198
+ "type": {
88199
+ "text": "boolean"
88187
88200
  },
88201
+ "fieldName": "disabled",
88188
88202
  "inheritedFrom": {
88189
- "name": "SbbOpenCloseBaseElement",
88190
- "module": "core/base-elements/open-close-base-element.js"
88203
+ "name": "SbbDisabledMixin",
88204
+ "module": "core/mixins/disabled-mixin.js"
88191
88205
  }
88192
88206
  },
88193
88207
  {
88194
- "kind": "method",
88195
- "name": "dispatchCloseEvent",
88196
- "privacy": "protected",
88197
- "return": {
88198
- "type": {
88199
- "text": "boolean"
88200
- }
88208
+ "name": "icon-name",
88209
+ "type": {
88210
+ "text": "string"
88201
88211
  },
88212
+ "default": "''",
88213
+ "description": "The icon name we want to use, choose from the small icon variants\nfrom the ui-icons category from here\nhttps://icons.app.sbb.ch.",
88214
+ "fieldName": "iconName",
88202
88215
  "inheritedFrom": {
88203
- "name": "SbbOpenCloseBaseElement",
88204
- "module": "core/base-elements/open-close-base-element.js"
88216
+ "name": "SbbIconNameMixin",
88217
+ "module": "icon/icon-name-mixin.js"
88205
88218
  }
88206
- }
88207
- ],
88208
- "attributes": [
88209
- {
88210
- "name": "trigger",
88211
- "type": {
88212
- "text": "HTMLElement | null"
88213
- },
88214
- "default": "null",
88215
- "description": "The element that will trigger the menu overlay.\n\nFor attribute usage, provide an id reference.",
88216
- "fieldName": "trigger"
88217
- }
88218
- ],
88219
- "superclass": {
88220
- "name": "SbbOpenCloseBaseElement",
88221
- "module": "core/base-elements.js"
88222
- },
88223
- "tagName": "sbb-menu",
88224
- "customElement": true,
88225
- "events": [
88219
+ },
88226
88220
  {
88227
- "name": "beforeopen",
88221
+ "name": "value",
88228
88222
  "type": {
88229
- "text": "Event"
88223
+ "text": "string"
88230
88224
  },
88231
- "description": "Emits whenever the component starts the opening transition. Can be canceled.",
88225
+ "default": "''",
88226
+ "description": "Value of the form element.",
88227
+ "fieldName": "value",
88232
88228
  "inheritedFrom": {
88233
- "name": "SbbOpenCloseBaseElement",
88234
- "module": "core/base-elements/open-close-base-element.js"
88229
+ "name": "SbbButtonBaseElement",
88230
+ "module": "core/base-elements/button-base-element.js"
88235
88231
  }
88236
88232
  },
88237
88233
  {
88238
- "name": "open",
88234
+ "name": "type",
88235
+ "description": "The type attribute to use for the button.",
88236
+ "default": "'button'",
88239
88237
  "type": {
88240
- "text": "Event"
88238
+ "text": "SbbButtonType"
88241
88239
  },
88242
- "description": "Emits whenever the component is opened.",
88240
+ "fieldName": "type",
88243
88241
  "inheritedFrom": {
88244
- "name": "SbbOpenCloseBaseElement",
88245
- "module": "core/base-elements/open-close-base-element.js"
88242
+ "name": "SbbButtonBaseElement",
88243
+ "module": "core/base-elements/button-base-element.js"
88246
88244
  }
88247
88245
  },
88248
88246
  {
88249
- "name": "beforeclose",
88247
+ "name": "form",
88248
+ "description": "The `<form>` element to associate the button with.",
88250
88249
  "type": {
88251
- "text": "Event"
88250
+ "text": "HTMLFormElement | null"
88252
88251
  },
88253
- "description": "Emits whenever the component begins the closing transition. Can be canceled.",
88252
+ "fieldName": "form",
88254
88253
  "inheritedFrom": {
88255
- "name": "SbbOpenCloseBaseElement",
88256
- "module": "core/base-elements/open-close-base-element.js"
88254
+ "name": "SbbButtonBaseElement",
88255
+ "module": "core/base-elements/button-base-element.js"
88257
88256
  }
88258
88257
  },
88259
88258
  {
88260
- "name": "close",
88259
+ "name": "name",
88260
+ "description": "Name of the form element. Will be read from name attribute.",
88261
88261
  "type": {
88262
- "text": "Event"
88262
+ "text": "string"
88263
88263
  },
88264
- "description": "Emits whenever the component is closed.",
88264
+ "fieldName": "name",
88265
88265
  "inheritedFrom": {
88266
- "name": "SbbOpenCloseBaseElement",
88267
- "module": "core/base-elements/open-close-base-element.js"
88266
+ "name": "SbbFormAssociatedMixin",
88267
+ "module": "core/mixins/form-associated-mixin.js"
88268
88268
  }
88269
88269
  }
88270
88270
  ]
@@ -88273,18 +88273,18 @@
88273
88273
  "exports": [
88274
88274
  {
88275
88275
  "kind": "js",
88276
- "name": "SbbMenuElement",
88276
+ "name": "SbbMenuButtonElement",
88277
88277
  "declaration": {
88278
- "name": "SbbMenuElement",
88279
- "module": "menu/menu/menu.component.js"
88278
+ "name": "SbbMenuButtonElement",
88279
+ "module": "menu/menu-button/menu-button.component.js"
88280
88280
  }
88281
88281
  },
88282
88282
  {
88283
88283
  "kind": "custom-element-definition",
88284
- "name": "sbb-menu",
88284
+ "name": "sbb-menu-button",
88285
88285
  "declaration": {
88286
- "name": "SbbMenuElement",
88287
- "module": "menu/menu/menu.component.js"
88286
+ "name": "SbbMenuButtonElement",
88287
+ "module": "menu/menu-button/menu-button.component.js"
88288
88288
  }
88289
88289
  }
88290
88290
  ]