@carbon/web-components 2.61.0 → 2.62.0-rc.0

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.
Files changed (241) hide show
  1. package/custom-elements.json +455 -13
  2. package/es/components/action-set/action-set.d.ts +107 -0
  3. package/es/components/action-set/action-set.d.ts.map +1 -0
  4. package/es/components/action-set/action-set.js +269 -0
  5. package/es/components/action-set/action-set.js.map +1 -0
  6. package/es/components/action-set/action-set.scss.js +14 -0
  7. package/es/components/action-set/action-set.scss.js.map +1 -0
  8. package/es/components/action-set/index.d.ts +9 -0
  9. package/es/components/action-set/index.d.ts.map +1 -0
  10. package/es/components/action-set/index.js +8 -0
  11. package/es/components/button/button.d.ts.map +1 -1
  12. package/es/components/button/button.js +7 -2
  13. package/es/components/button/button.js.map +1 -1
  14. package/es/components/data-table/data-table.scss.js +1 -1
  15. package/es/components/date-picker/next/components/date-picker.scss.js +1 -1
  16. package/es/components/file-uploader/file-uploader.scss.js +1 -1
  17. package/es/components/fluid-date-picker/fluid-date-picker.scss.js +1 -1
  18. package/es/components/resizer/defs.d.ts +73 -0
  19. package/es/components/resizer/defs.d.ts.map +1 -0
  20. package/es/components/resizer/defs.js +97 -0
  21. package/es/components/resizer/defs.js.map +1 -0
  22. package/es/components/resizer/index.d.ts +11 -0
  23. package/es/components/resizer/index.d.ts.map +1 -0
  24. package/es/components/resizer/index.js +11 -0
  25. package/es/components/resizer/resizer-grid.d.ts +22 -0
  26. package/es/components/resizer/resizer-grid.d.ts.map +1 -0
  27. package/es/components/resizer/resizer-grid.js +44 -0
  28. package/es/components/resizer/resizer-grid.js.map +1 -0
  29. package/es/components/resizer/resizer-grid.scss.js +14 -0
  30. package/es/components/resizer/resizer-grid.scss.js.map +1 -0
  31. package/es/components/resizer/resizer-handle-pivot.d.ts +31 -0
  32. package/es/components/resizer/resizer-handle-pivot.d.ts.map +1 -0
  33. package/es/components/resizer/resizer-handle-pivot.js +93 -0
  34. package/es/components/resizer/resizer-handle-pivot.js.map +1 -0
  35. package/es/components/resizer/resizer-handle-pivot.scss.js +14 -0
  36. package/es/components/resizer/resizer-handle-pivot.scss.js.map +1 -0
  37. package/es/components/resizer/resizer-handle.d.ts +64 -0
  38. package/es/components/resizer/resizer-handle.d.ts.map +1 -0
  39. package/es/components/resizer/resizer-handle.js +350 -0
  40. package/es/components/resizer/resizer-handle.js.map +1 -0
  41. package/es/components/resizer/resizer-handle.scss.js +14 -0
  42. package/es/components/resizer/resizer-handle.scss.js.map +1 -0
  43. package/es/components/resizer/resizer-panel.d.ts +22 -0
  44. package/es/components/resizer/resizer-panel.d.ts.map +1 -0
  45. package/es/components/resizer/resizer-panel.js +37 -0
  46. package/es/components/resizer/resizer-panel.js.map +1 -0
  47. package/es/components/resizer/resizer-panel.scss.js +14 -0
  48. package/es/components/resizer/resizer-panel.scss.js.map +1 -0
  49. package/es/components/side-panel/_story-assets/index.d.ts +9 -0
  50. package/es/components/side-panel/_story-assets/index.d.ts.map +1 -0
  51. package/es/components/side-panel/_story-assets/index.js +246 -0
  52. package/es/components/side-panel/_story-assets/index.js.map +1 -0
  53. package/es/components/side-panel/defs.d.ts +7 -1
  54. package/es/components/side-panel/defs.d.ts.map +1 -1
  55. package/es/components/side-panel/defs.js +7 -1
  56. package/es/components/side-panel/defs.js.map +1 -1
  57. package/es/components/side-panel/index.d.ts +3 -1
  58. package/es/components/side-panel/index.d.ts.map +1 -1
  59. package/es/components/side-panel/index.js +12 -0
  60. package/es/components/side-panel/index.js.map +1 -0
  61. package/es/components/side-panel/side-panel.d.ts +60 -22
  62. package/es/components/side-panel/side-panel.d.ts.map +1 -1
  63. package/es/components/side-panel/side-panel.js +268 -126
  64. package/es/components/side-panel/side-panel.js.map +1 -1
  65. package/es/components/side-panel/side-panel.scss.js +14 -0
  66. package/es/components/side-panel/side-panel.scss.js.map +1 -0
  67. package/es/components/side-panel/story-styles.scss.js +14 -0
  68. package/es/components/side-panel/story-styles.scss.js.map +1 -0
  69. package/es/components/slider/slider.d.ts +14 -0
  70. package/es/components/slider/slider.d.ts.map +1 -1
  71. package/es/components/slider/slider.js +40 -5
  72. package/es/components/slider/slider.js.map +1 -1
  73. package/es/components/slider/slider.scss.js +1 -1
  74. package/es/components/tabs/tab.d.ts.map +1 -1
  75. package/es/components/tabs/tab.js +4 -1
  76. package/es/components/tabs/tab.js.map +1 -1
  77. package/es/components/tabs/tabs.scss.js +1 -1
  78. package/es/components/tabs/tabs.scss.js.map +1 -1
  79. package/es/components/textarea/textarea.scss.js +1 -1
  80. package/es/components/textarea/textarea.scss.js.map +1 -1
  81. package/es/components/truncated-text/index.d.ts +8 -0
  82. package/es/components/truncated-text/index.d.ts.map +1 -0
  83. package/es/components/truncated-text/index.js +8 -0
  84. package/es/components/truncated-text/truncated-text.d.ts +77 -0
  85. package/es/components/truncated-text/truncated-text.d.ts.map +1 -0
  86. package/es/components/truncated-text/truncated-text.js +216 -0
  87. package/es/components/truncated-text/truncated-text.js.map +1 -0
  88. package/es/components/truncated-text/truncated-text.scss.js +14 -0
  89. package/es/components/truncated-text/truncated-text.scss.js.map +1 -0
  90. package/es/globals/internal/icon-loader-utils.d.ts +2 -2
  91. package/es/globals/internal/icon-loader-utils.d.ts.map +1 -1
  92. package/es/globals/internal/icon-loader-utils.js +1 -1
  93. package/es/globals/internal/icon-loader-utils.js.map +1 -1
  94. package/es/index.d.ts.map +1 -1
  95. package/es-custom/components/action-set/action-set.d.ts +107 -0
  96. package/es-custom/components/action-set/action-set.d.ts.map +1 -0
  97. package/es-custom/components/action-set/action-set.js +269 -0
  98. package/es-custom/components/action-set/action-set.js.map +1 -0
  99. package/es-custom/components/action-set/action-set.scss.js +14 -0
  100. package/es-custom/components/action-set/action-set.scss.js.map +1 -0
  101. package/es-custom/components/action-set/index.d.ts +9 -0
  102. package/es-custom/components/action-set/index.d.ts.map +1 -0
  103. package/es-custom/components/action-set/index.js +8 -0
  104. package/es-custom/components/button/button.d.ts.map +1 -1
  105. package/es-custom/components/button/button.js +7 -2
  106. package/es-custom/components/button/button.js.map +1 -1
  107. package/es-custom/components/data-table/data-table.scss.js +1 -1
  108. package/es-custom/components/date-picker/next/components/date-picker.scss.js +1 -1
  109. package/es-custom/components/file-uploader/file-uploader.scss.js +1 -1
  110. package/es-custom/components/fluid-date-picker/fluid-date-picker.scss.js +1 -1
  111. package/es-custom/components/resizer/defs.d.ts +73 -0
  112. package/es-custom/components/resizer/defs.d.ts.map +1 -0
  113. package/es-custom/components/resizer/defs.js +97 -0
  114. package/es-custom/components/resizer/defs.js.map +1 -0
  115. package/es-custom/components/resizer/index.d.ts +11 -0
  116. package/es-custom/components/resizer/index.d.ts.map +1 -0
  117. package/es-custom/components/resizer/index.js +11 -0
  118. package/es-custom/components/resizer/resizer-grid.d.ts +22 -0
  119. package/es-custom/components/resizer/resizer-grid.d.ts.map +1 -0
  120. package/es-custom/components/resizer/resizer-grid.js +44 -0
  121. package/es-custom/components/resizer/resizer-grid.js.map +1 -0
  122. package/es-custom/components/resizer/resizer-grid.scss.js +14 -0
  123. package/es-custom/components/resizer/resizer-grid.scss.js.map +1 -0
  124. package/es-custom/components/resizer/resizer-handle-pivot.d.ts +31 -0
  125. package/es-custom/components/resizer/resizer-handle-pivot.d.ts.map +1 -0
  126. package/es-custom/components/resizer/resizer-handle-pivot.js +93 -0
  127. package/es-custom/components/resizer/resizer-handle-pivot.js.map +1 -0
  128. package/es-custom/components/resizer/resizer-handle-pivot.scss.js +14 -0
  129. package/es-custom/components/resizer/resizer-handle-pivot.scss.js.map +1 -0
  130. package/es-custom/components/resizer/resizer-handle.d.ts +64 -0
  131. package/es-custom/components/resizer/resizer-handle.d.ts.map +1 -0
  132. package/es-custom/components/resizer/resizer-handle.js +350 -0
  133. package/es-custom/components/resizer/resizer-handle.js.map +1 -0
  134. package/es-custom/components/resizer/resizer-handle.scss.js +14 -0
  135. package/es-custom/components/resizer/resizer-handle.scss.js.map +1 -0
  136. package/es-custom/components/resizer/resizer-panel.d.ts +22 -0
  137. package/es-custom/components/resizer/resizer-panel.d.ts.map +1 -0
  138. package/es-custom/components/resizer/resizer-panel.js +37 -0
  139. package/es-custom/components/resizer/resizer-panel.js.map +1 -0
  140. package/es-custom/components/resizer/resizer-panel.scss.js +14 -0
  141. package/es-custom/components/resizer/resizer-panel.scss.js.map +1 -0
  142. package/es-custom/components/side-panel/_story-assets/index.d.ts +9 -0
  143. package/es-custom/components/side-panel/_story-assets/index.d.ts.map +1 -0
  144. package/es-custom/components/side-panel/_story-assets/index.js +246 -0
  145. package/es-custom/components/side-panel/_story-assets/index.js.map +1 -0
  146. package/es-custom/components/side-panel/defs.d.ts +7 -1
  147. package/es-custom/components/side-panel/defs.d.ts.map +1 -1
  148. package/es-custom/components/side-panel/defs.js +7 -1
  149. package/es-custom/components/side-panel/defs.js.map +1 -1
  150. package/es-custom/components/side-panel/index.d.ts +3 -1
  151. package/es-custom/components/side-panel/index.d.ts.map +1 -1
  152. package/es-custom/components/side-panel/index.js +12 -0
  153. package/es-custom/components/side-panel/index.js.map +1 -0
  154. package/es-custom/components/side-panel/side-panel.d.ts +60 -22
  155. package/es-custom/components/side-panel/side-panel.d.ts.map +1 -1
  156. package/es-custom/components/side-panel/side-panel.js +268 -126
  157. package/es-custom/components/side-panel/side-panel.js.map +1 -1
  158. package/es-custom/components/side-panel/side-panel.scss.js +14 -0
  159. package/es-custom/components/side-panel/side-panel.scss.js.map +1 -0
  160. package/es-custom/components/side-panel/story-styles.scss.js +14 -0
  161. package/es-custom/components/side-panel/story-styles.scss.js.map +1 -0
  162. package/es-custom/components/slider/slider.d.ts +14 -0
  163. package/es-custom/components/slider/slider.d.ts.map +1 -1
  164. package/es-custom/components/slider/slider.js +40 -5
  165. package/es-custom/components/slider/slider.js.map +1 -1
  166. package/es-custom/components/slider/slider.scss.js +1 -1
  167. package/es-custom/components/tabs/tab.d.ts.map +1 -1
  168. package/es-custom/components/tabs/tab.js +4 -1
  169. package/es-custom/components/tabs/tab.js.map +1 -1
  170. package/es-custom/components/tabs/tabs.scss.js +1 -1
  171. package/es-custom/components/tabs/tabs.scss.js.map +1 -1
  172. package/es-custom/components/textarea/textarea.scss.js +1 -1
  173. package/es-custom/components/textarea/textarea.scss.js.map +1 -1
  174. package/es-custom/components/truncated-text/index.d.ts +8 -0
  175. package/es-custom/components/truncated-text/index.d.ts.map +1 -0
  176. package/es-custom/components/truncated-text/index.js +8 -0
  177. package/es-custom/components/truncated-text/truncated-text.d.ts +77 -0
  178. package/es-custom/components/truncated-text/truncated-text.d.ts.map +1 -0
  179. package/es-custom/components/truncated-text/truncated-text.js +216 -0
  180. package/es-custom/components/truncated-text/truncated-text.js.map +1 -0
  181. package/es-custom/components/truncated-text/truncated-text.scss.js +14 -0
  182. package/es-custom/components/truncated-text/truncated-text.scss.js.map +1 -0
  183. package/es-custom/globals/internal/icon-loader-utils.d.ts +2 -2
  184. package/es-custom/globals/internal/icon-loader-utils.d.ts.map +1 -1
  185. package/es-custom/globals/internal/icon-loader-utils.js +1 -1
  186. package/es-custom/globals/internal/icon-loader-utils.js.map +1 -1
  187. package/es-custom/index.d.ts.map +1 -1
  188. package/lib/components/action-set/action-set.d.ts +107 -0
  189. package/lib/components/action-set/action-set.d.ts.map +1 -0
  190. package/lib/components/action-set/index.d.ts +9 -0
  191. package/lib/components/action-set/index.d.ts.map +1 -0
  192. package/lib/components/button/button.d.ts.map +1 -1
  193. package/lib/components/resizer/defs.d.ts +73 -0
  194. package/lib/components/resizer/defs.d.ts.map +1 -0
  195. package/lib/components/resizer/defs.js +112 -0
  196. package/lib/components/resizer/defs.js.map +1 -0
  197. package/lib/components/resizer/index.d.ts +11 -0
  198. package/lib/components/resizer/index.d.ts.map +1 -0
  199. package/lib/components/resizer/resizer-grid.d.ts +22 -0
  200. package/lib/components/resizer/resizer-grid.d.ts.map +1 -0
  201. package/lib/components/resizer/resizer-handle-pivot.d.ts +31 -0
  202. package/lib/components/resizer/resizer-handle-pivot.d.ts.map +1 -0
  203. package/lib/components/resizer/resizer-handle.d.ts +64 -0
  204. package/lib/components/resizer/resizer-handle.d.ts.map +1 -0
  205. package/lib/components/resizer/resizer-panel.d.ts +22 -0
  206. package/lib/components/resizer/resizer-panel.d.ts.map +1 -0
  207. package/lib/components/side-panel/_story-assets/index.d.ts +9 -0
  208. package/lib/components/side-panel/_story-assets/index.d.ts.map +1 -0
  209. package/lib/components/side-panel/defs.d.ts +7 -1
  210. package/lib/components/side-panel/defs.d.ts.map +1 -1
  211. package/lib/components/side-panel/defs.js +7 -1
  212. package/lib/components/side-panel/defs.js.map +1 -1
  213. package/lib/components/side-panel/index.d.ts +3 -1
  214. package/lib/components/side-panel/index.d.ts.map +1 -1
  215. package/lib/components/side-panel/side-panel.d.ts +60 -22
  216. package/lib/components/side-panel/side-panel.d.ts.map +1 -1
  217. package/lib/components/slider/slider.d.ts +14 -0
  218. package/lib/components/slider/slider.d.ts.map +1 -1
  219. package/lib/components/tabs/tab.d.ts.map +1 -1
  220. package/lib/components/truncated-text/index.d.ts +8 -0
  221. package/lib/components/truncated-text/index.d.ts.map +1 -0
  222. package/lib/components/truncated-text/truncated-text.d.ts +77 -0
  223. package/lib/components/truncated-text/truncated-text.d.ts.map +1 -0
  224. package/lib/globals/internal/icon-loader-utils.d.ts +2 -2
  225. package/lib/globals/internal/icon-loader-utils.d.ts.map +1 -1
  226. package/lib/index.d.ts.map +1 -1
  227. package/package.json +7 -7
  228. package/scss/components/action-set/action-set.scss +93 -0
  229. package/scss/components/data-table/_table-core.scss +73 -20
  230. package/scss/components/data-table/_table-selection.scss +31 -14
  231. package/scss/components/resizer/resizer-grid.scss +34 -0
  232. package/scss/components/resizer/resizer-handle-pivot.scss +39 -0
  233. package/scss/components/resizer/resizer-handle.scss +127 -0
  234. package/scss/components/resizer/resizer-panel.scss +10 -0
  235. package/scss/components/side-panel/side-panel.scss +363 -0
  236. package/scss/components/side-panel/story-styles.scss +51 -0
  237. package/scss/components/tabs/tabs.scss +4 -0
  238. package/scss/components/textarea/textarea.scss +6 -0
  239. package/scss/components/truncated-text/truncated-text-story.scss +14 -0
  240. package/scss/components/truncated-text/truncated-text.scss +122 -0
  241. package/telemetry.yml +26 -0
@@ -0,0 +1,246 @@
1
+ /**
2
+ * Copyright IBM Corp. 2026
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+
8
+ import iconLoader from "../../../globals/internal/icon-loader.js";
9
+ import "../../button/defs.js";
10
+ import "../../breadcrumb/index.js";
11
+ import "../../notification/index.js";
12
+ import story_styles_default from "../story-styles.scss.js";
13
+ import { html } from "lit";
14
+ import TrashCan16 from "@carbon/icons/es/trash-can/16";
15
+ import Settings16 from "@carbon/icons/es/settings/16";
16
+ //#region src/components/side-panel/_story-assets/index.ts
17
+ /**
18
+ * Copyright IBM Corp. 2024, 2026
19
+ *
20
+ * This source code is licensed under the Apache-2.0 license found in the
21
+ * LICENSE file in the root directory of this source tree.
22
+ */
23
+ const storyPrefix = "side-panel-stories__";
24
+ const getContent = (index) => {
25
+ switch (index) {
26
+ case 1: return html`
27
+ <style>
28
+ ${story_styles_default}
29
+ </style>
30
+ <h5>Section</h5>
31
+ <cds-custom-text-input
32
+ label="Input A"
33
+ id="side-panel-story-text-input-a"
34
+ class="${storyPrefix}text-input"></cds-custom-text-input>
35
+ <cds-custom-text-input
36
+ label="Input B"
37
+ id="side-panel-story-text-input-b"
38
+ class="${storyPrefix}text-input"></cds-custom-text-input>
39
+ `;
40
+ case 2: return html`
41
+ <style>
42
+ ${story_styles_default}
43
+ </style>
44
+ <h5>Section</h5>
45
+ <div class="${storyPrefix}text-inputs">
46
+ <cds-custom-text-input
47
+ label="Input A"
48
+ id="side-panel-story-text-input-a"></cds-custom-text-input>
49
+ <cds-custom-text-input
50
+ label="Input B"
51
+ id="side-panel-story-text-input-b"></cds-custom-text-input>
52
+ </div>
53
+ <div class="${storyPrefix}text-inputs">
54
+ <cds-custom-text-input
55
+ label="Input C"
56
+ id="side-panel-story-text-input-c"></cds-custom-text-input>
57
+ <cds-custom-text-input
58
+ label="Input D"
59
+ id="side-panel-story-text-input-d"></cds-custom-text-input>
60
+ </div>
61
+ <div class="${storyPrefix}textarea-container">
62
+ <cds-custom-textarea
63
+ label="Notes"
64
+ value="This is a text area"></cds-custom-textarea>
65
+ <cds-custom-textarea
66
+ label="Notes"
67
+ value="This is a text area"></cds-custom-textarea>
68
+ <cds-custom-textarea
69
+ label="Notes"
70
+ value="This is a text area"></cds-custom-textarea>
71
+ </div>
72
+ `;
73
+ default: return null;
74
+ }
75
+ };
76
+ const getSubTitle = (index) => {
77
+ switch (index) {
78
+ case 1: return html`<div slot="subtitle">This is your subtitle slot.</div>`;
79
+ case 2: return html`<div slot="subtitle">
80
+ I am your subtitle slot for <strong>adding detail</strong> that can be
81
+ one or two lines.
82
+ </div>`;
83
+ default: return null;
84
+ }
85
+ };
86
+ const getActionToolbarItems = (index) => {
87
+ switch (index) {
88
+ case 1: return html`
89
+ <cds-custom-button slot="action-toolbar">Copy</cds-custom-button>
90
+ <cds-custom-button
91
+ slot="action-toolbar"
92
+ aria-label="Settings"
93
+ has-icon-only="true"
94
+ kind=${"ghost"}
95
+ size="sm"
96
+ tooltip-text="Settings">
97
+ ${iconLoader(Settings16, { slot: "icon" })}
98
+ </cds-custom-button>
99
+ <cds-custom-button
100
+ slot="action-toolbar"
101
+ aria-label="Delete"
102
+ has-icon-only="true"
103
+ kind=${"ghost"}
104
+ size="sm"
105
+ tooltip-text="Delete">
106
+ ${iconLoader(TrashCan16, { slot: "icon" })}
107
+ </cds-custom-button>
108
+ `;
109
+ default: return null;
110
+ }
111
+ };
112
+ const getActionItems = (index) => {
113
+ switch (index) {
114
+ case 1: return html`<cds-custom-button slot="actions" kind=${"primary"}
115
+ >Primary</cds-custom-button
116
+ >`;
117
+ case 2: return html`<cds-custom-button slot="actions" kind=${"ghost"}
118
+ >Ghost</cds-custom-button
119
+ >`;
120
+ case 3: return html`<cds-custom-button slot="actions" kind=${"danger"}
121
+ >Danger</cds-custom-button
122
+ >`;
123
+ case 4: return html`
124
+ <cds-custom-button slot="actions" kind=${"secondary"}
125
+ >Secondary</cds-custom-button
126
+ >
127
+ <cds-custom-button slot="actions" kind=${"primary"}
128
+ >Primary</cds-custom-button
129
+ >
130
+ `;
131
+ case 5: return html`
132
+ <cds-custom-button slot="actions" kind=${"ghost"}>Ghost</cds-custom-button>
133
+ <cds-custom-button slot="actions" kind=${"primary"}
134
+ >Primary</cds-custom-button
135
+ >
136
+ `;
137
+ case 6: return html`<cds-custom-button slot="actions" kind=${"danger"}
138
+ >Danger</cds-custom-button
139
+ >
140
+ <cds-custom-button slot="actions" kind=${"primary"}
141
+ >Primary</cds-custom-button
142
+ >`;
143
+ case 7: return html`<cds-custom-button slot="actions" kind=${"ghost"}
144
+ >Ghost</cds-custom-button
145
+ >
146
+ <cds-custom-button slot="actions" kind=${"secondary"}
147
+ >Secondary</cds-custom-button
148
+ >
149
+ <cds-custom-button slot="actions" kind=${"primary"}
150
+ >Primary</cds-custom-button
151
+ >`;
152
+ case 8: return html`<cds-custom-button slot="actions" kind=${"danger"}
153
+ >Danger</cds-custom-button
154
+ >
155
+ <cds-custom-button slot="actions" kind=${"secondary"}
156
+ >Secondary</cds-custom-button
157
+ >
158
+ <cds-custom-button slot="actions" kind=${"primary"}
159
+ >Primary</cds-custom-button
160
+ >`;
161
+ case 9: return html`<cds-custom-button slot="actions" kind=${"secondary"}
162
+ >Secondary</cds-custom-button
163
+ >
164
+ <cds-custom-button slot="actions" kind=${"secondary"}
165
+ >Secondary</cds-custom-button
166
+ >
167
+ <cds-custom-button slot="actions" kind=${"primary"}
168
+ >Primary</cds-custom-button
169
+ >`;
170
+ default: return null;
171
+ }
172
+ };
173
+ const getSlug = (index) => {
174
+ switch (index) {
175
+ case 1: return html`<cds-custom-slug size="xs" alignment="bottom-right">
176
+ <div slot="body-text">
177
+ <p class="secondary">AI Explained</p>
178
+ <h1>84%</h1>
179
+ <p class="secondary bold">Confidence score</p>
180
+ <!-- //cspell: disable -->
181
+ <p class="secondary">
182
+ Lorem ipsum dolor sit amet, di os consectetur adipiscing elit, sed
183
+ do eiusmod tempor incididunt ut fsil labore et dolore magna aliqua.
184
+ </p>
185
+ <!-- //cspell: enable -->
186
+ <hr />
187
+ <p class="secondary">Model type</p>
188
+ <p class="bold">Foundation model</p>
189
+ </div>
190
+ </cds-custom-slug>`;
191
+ default: return null;
192
+ }
193
+ };
194
+ const getCustomHeaderComponents = (index) => {
195
+ switch (index) {
196
+ case 1: return html` <style>
197
+ ${story_styles_default}
198
+ </style>
199
+ <div slot="above-title" class="${storyPrefix}custom-header-content">
200
+ <cds-custom-breadcrumb aria-label="">
201
+ <cds-custom-breadcrumb-item>
202
+ <cds-custom-breadcrumb-link href="#">Breadcrumb 1</cds-custom-breadcrumb-link>
203
+ </cds-custom-breadcrumb-item>
204
+ <cds-custom-breadcrumb-item>
205
+ <cds-custom-breadcrumb-link href="#">Breadcrumb 2</cds-custom-breadcrumb-link>
206
+ </cds-custom-breadcrumb-item>
207
+ </cds-custom-breadcrumb>
208
+ </div>`;
209
+ case 2: return html` <style>
210
+ ${story_styles_default}
211
+ </style>
212
+ <div slot="below-title" class="${storyPrefix}custom-header-content">
213
+ <cds-custom-inline-notification
214
+ title="Notification title"
215
+ subtitle="Subtitle text goes here"
216
+ kind="error">
217
+ </cds-custom-inline-notification>
218
+ </div>`;
219
+ case 3: return html` <style>
220
+ ${story_styles_default}
221
+ </style>
222
+ <div slot="above-title" class="${storyPrefix}custom-header-content">
223
+ <cds-custom-breadcrumb aria-label="">
224
+ <cds-custom-breadcrumb-item>
225
+ <cds-custom-breadcrumb-link href="#">Breadcrumb 1</cds-custom-breadcrumb-link>
226
+ </cds-custom-breadcrumb-item>
227
+ <cds-custom-breadcrumb-item>
228
+ <cds-custom-breadcrumb-link href="#">Breadcrumb 2</cds-custom-breadcrumb-link>
229
+ </cds-custom-breadcrumb-item>
230
+ </cds-custom-breadcrumb>
231
+ </div>
232
+
233
+ <div slot="below-title" class="${storyPrefix}custom-header-content">
234
+ <cds-custom-inline-notification
235
+ title="Notification title"
236
+ subtitle="Subtitle text goes here"
237
+ kind="error">
238
+ </cds-custom-inline-notification>
239
+ </div>`;
240
+ default: return null;
241
+ }
242
+ };
243
+ //#endregion
244
+ export { getActionItems, getActionToolbarItems, getContent, getCustomHeaderComponents, getSlug, getSubTitle };
245
+
246
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":["styles"],"sources":["../../../../src/components/side-panel/_story-assets/index.ts"],"sourcesContent":["/**\n * Copyright IBM Corp. 2024, 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\nimport { html } from 'lit';\nimport styles from '../story-styles.scss?lit';\nimport { BUTTON_KIND } from '../../button/defs';\nimport TrashCan16 from '@carbon/icons/es/trash-can/16';\nimport Settings16 from '@carbon/icons/es/settings/16';\nimport { iconLoader } from '../../../globals/internal/icon-loader';\nimport '../../breadcrumb/index';\nimport '../../notification/index';\n\nconst storyPrefix = 'side-panel-stories__';\n\nexport const getContent = (index) => {\n switch (index) {\n case 1:\n return html`\n <style>\n ${styles}\n </style>\n <h5>Section</h5>\n <cds-custom-text-input\n label=\"Input A\"\n id=\"side-panel-story-text-input-a\"\n class=\"${storyPrefix}text-input\"></cds-custom-text-input>\n <cds-custom-text-input\n label=\"Input B\"\n id=\"side-panel-story-text-input-b\"\n class=\"${storyPrefix}text-input\"></cds-custom-text-input>\n `;\n case 2:\n return html`\n <style>\n ${styles}\n </style>\n <h5>Section</h5>\n <div class=\"${storyPrefix}text-inputs\">\n <cds-custom-text-input\n label=\"Input A\"\n id=\"side-panel-story-text-input-a\"></cds-custom-text-input>\n <cds-custom-text-input\n label=\"Input B\"\n id=\"side-panel-story-text-input-b\"></cds-custom-text-input>\n </div>\n <div class=\"${storyPrefix}text-inputs\">\n <cds-custom-text-input\n label=\"Input C\"\n id=\"side-panel-story-text-input-c\"></cds-custom-text-input>\n <cds-custom-text-input\n label=\"Input D\"\n id=\"side-panel-story-text-input-d\"></cds-custom-text-input>\n </div>\n <div class=\"${storyPrefix}textarea-container\">\n <cds-custom-textarea\n label=\"Notes\"\n value=\"This is a text area\"></cds-custom-textarea>\n <cds-custom-textarea\n label=\"Notes\"\n value=\"This is a text area\"></cds-custom-textarea>\n <cds-custom-textarea\n label=\"Notes\"\n value=\"This is a text area\"></cds-custom-textarea>\n </div>\n `;\n\n default:\n return null;\n }\n};\n\nexport const getSubTitle = (index) => {\n switch (index) {\n case 1:\n return html`<div slot=\"subtitle\">This is your subtitle slot.</div>`;\n case 2:\n return html`<div slot=\"subtitle\">\n I am your subtitle slot for <strong>adding detail</strong> that can be\n one or two lines.\n </div>`;\n default:\n return null;\n }\n};\n\nexport const getActionToolbarItems = (index) => {\n switch (index) {\n case 1:\n return html`\n <cds-custom-button slot=\"action-toolbar\">Copy</cds-custom-button>\n <cds-custom-button\n slot=\"action-toolbar\"\n aria-label=\"Settings\"\n has-icon-only=\"true\"\n kind=${BUTTON_KIND.GHOST}\n size=\"sm\"\n tooltip-text=\"Settings\">\n ${iconLoader(Settings16, { slot: 'icon' })}\n </cds-custom-button>\n <cds-custom-button\n slot=\"action-toolbar\"\n aria-label=\"Delete\"\n has-icon-only=\"true\"\n kind=${BUTTON_KIND.GHOST}\n size=\"sm\"\n tooltip-text=\"Delete\">\n ${iconLoader(TrashCan16, { slot: 'icon' })}\n </cds-custom-button>\n `;\n default:\n return null;\n }\n};\n\n// TODO: There are problems switching this\nexport const getActionItems = (index) => {\n switch (index) {\n case 1: // One button\n return html`<cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.PRIMARY}\n >Primary</cds-custom-button\n >`;\n case 2: // One button (ghost)\n return html`<cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.GHOST}\n >Ghost</cds-custom-button\n >`;\n case 3: // One button (danger)\n return html`<cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.DANGER}\n >Danger</cds-custom-button\n >`;\n case 4: // Two buttons\n return html`\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.SECONDARY}\n >Secondary</cds-custom-button\n >\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.PRIMARY}\n >Primary</cds-custom-button\n >\n `;\n case 5: // Two buttons with ghost\n return html`\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.GHOST}>Ghost</cds-custom-button>\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.PRIMARY}\n >Primary</cds-custom-button\n >\n `;\n case 6: // Two buttons with danger\n return html`<cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.DANGER}\n >Danger</cds-custom-button\n >\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.PRIMARY}\n >Primary</cds-custom-button\n >`;\n case 7: // Three buttons with ghost\n return html`<cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.GHOST}\n >Ghost</cds-custom-button\n >\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.SECONDARY}\n >Secondary</cds-custom-button\n >\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.PRIMARY}\n >Primary</cds-custom-button\n >`;\n case 8: // Three buttons with danger\n return html`<cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.DANGER}\n >Danger</cds-custom-button\n >\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.SECONDARY}\n >Secondary</cds-custom-button\n >\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.PRIMARY}\n >Primary</cds-custom-button\n >`;\n case 9: // Three buttons\n return html`<cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.SECONDARY}\n >Secondary</cds-custom-button\n >\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.SECONDARY}\n >Secondary</cds-custom-button\n >\n <cds-custom-button slot=\"actions\" kind=${BUTTON_KIND.PRIMARY}\n >Primary</cds-custom-button\n >`;\n default:\n return null;\n }\n};\n\nexport const getSlug = (index) => {\n switch (index) {\n case 1:\n return html`<cds-custom-slug size=\"xs\" alignment=\"bottom-right\">\n <div slot=\"body-text\">\n <p class=\"secondary\">AI Explained</p>\n <h1>84%</h1>\n <p class=\"secondary bold\">Confidence score</p>\n <!-- //cspell: disable -->\n <p class=\"secondary\">\n Lorem ipsum dolor sit amet, di os consectetur adipiscing elit, sed\n do eiusmod tempor incididunt ut fsil labore et dolore magna aliqua.\n </p>\n <!-- //cspell: enable -->\n <hr />\n <p class=\"secondary\">Model type</p>\n <p class=\"bold\">Foundation model</p>\n </div>\n </cds-custom-slug>`;\n default:\n return null;\n }\n};\n\nexport const getCustomHeaderComponents = (index) => {\n switch (index) {\n case 1:\n return html` <style>\n ${styles}\n </style>\n <div slot=\"above-title\" class=\"${storyPrefix}custom-header-content\">\n <cds-custom-breadcrumb aria-label=\"\">\n <cds-custom-breadcrumb-item>\n <cds-custom-breadcrumb-link href=\"#\">Breadcrumb 1</cds-custom-breadcrumb-link>\n </cds-custom-breadcrumb-item>\n <cds-custom-breadcrumb-item>\n <cds-custom-breadcrumb-link href=\"#\">Breadcrumb 2</cds-custom-breadcrumb-link>\n </cds-custom-breadcrumb-item>\n </cds-custom-breadcrumb>\n </div>`;\n case 2:\n return html` <style>\n ${styles}\n </style>\n <div slot=\"below-title\" class=\"${storyPrefix}custom-header-content\">\n <cds-custom-inline-notification\n title=\"Notification title\"\n subtitle=\"Subtitle text goes here\"\n kind=\"error\">\n </cds-custom-inline-notification>\n </div>`;\n case 3:\n return html` <style>\n ${styles}\n </style>\n <div slot=\"above-title\" class=\"${storyPrefix}custom-header-content\">\n <cds-custom-breadcrumb aria-label=\"\">\n <cds-custom-breadcrumb-item>\n <cds-custom-breadcrumb-link href=\"#\">Breadcrumb 1</cds-custom-breadcrumb-link>\n </cds-custom-breadcrumb-item>\n <cds-custom-breadcrumb-item>\n <cds-custom-breadcrumb-link href=\"#\">Breadcrumb 2</cds-custom-breadcrumb-link>\n </cds-custom-breadcrumb-item>\n </cds-custom-breadcrumb>\n </div>\n\n <div slot=\"below-title\" class=\"${storyPrefix}custom-header-content\">\n <cds-custom-inline-notification\n title=\"Notification title\"\n subtitle=\"Subtitle text goes here\"\n kind=\"error\">\n </cds-custom-inline-notification>\n </div>`;\n default:\n return null;\n }\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAeA,MAAM,cAAc;AAEpB,MAAa,cAAc,UAAU;CACnC,QAAQ,OAAR;EACE,KAAK,GACH,OAAO,IAAI;;YAELA,qBAAO;;;;;;mBAMA,YAAY;;;;mBAIZ,YAAY;;EAE3B,KAAK,GACH,OAAO,IAAI;;YAELA,qBAAO;;;sBAGG,YAAY;;;;;;;;sBAQZ,YAAY;;;;;;;;sBAQZ,YAAY;;;;;;;;;;;;EAa9B,SACE,OAAO;CACX;AACF;AAEA,MAAa,eAAe,UAAU;CACpC,QAAQ,OAAR;EACE,KAAK,GACH,OAAO,IAAI;EACb,KAAK,GACH,OAAO,IAAI;;;;EAIb,SACE,OAAO;CACX;AACF;AAEA,MAAa,yBAAyB,UAAU;CAC9C,QAAQ,OAAR;EACE,KAAK,GACH,OAAO,IAAI;;;;;;yBAMkB;;;YAGvB,WAAW,YAAY,EAAE,MAAM,OAAO,CAAC,EAAE;;;;;;yBAMlB;;;YAGvB,WAAW,YAAY,EAAE,MAAM,OAAO,CAAC,EAAE;;;EAGjD,SACE,OAAO;CACX;AACF;AAGA,MAAa,kBAAkB,UAAU;CACvC,QAAQ,OAAR;EACE,KAAK,GACH,OAAO,IAAI,mCAAA,UAAuD;;;EAGpE,KAAK,GACH,OAAO,IAAI,mCAAA,QAAqD;;;EAGlE,KAAK,GACH,OAAO,IAAI,mCAAA,SAAsD;;;EAGnE,KAAK,GACH,OAAO,IAAI;sDAC+C;;;oDAGF;;;;EAI1D,KAAK,GACH,OAAO,IAAI;kDAC2C;oDACE;;;;EAI1D,KAAK,GACH,OAAO,IAAI,mCAAA,SAAsD;;;oDAGT;;;EAG1D,KAAK,GACH,OAAO,IAAI,mCAAA,QAAqD;;;sDAGN;;;oDAGF;;;EAG1D,KAAK,GACH,OAAO,IAAI,mCAAA,SAAsD;;;sDAGP;;;oDAGF;;;EAG1D,KAAK,GACH,OAAO,IAAI,mCAAA,YAAyD;;;sDAGV;;;oDAGF;;;EAG1D,SACE,OAAO;CACX;AACF;AAEA,MAAa,WAAW,UAAU;CAChC,QAAQ,OAAR;EACE,KAAK,GACH,OAAO,IAAI;;;;;;;;;;;;;;;;EAgBb,SACE,OAAO;CACX;AACF;AAEA,MAAa,6BAA6B,UAAU;CAClD,QAAQ,OAAR;EACE,KAAK,GACH,OAAO,IAAI;YACLA,qBAAO;;yCAEsB,YAAY;;;;;;;;;;EAUjD,KAAK,GACH,OAAO,IAAI;YACLA,qBAAO;;yCAEsB,YAAY;;;;;;;EAOjD,KAAK,GACH,OAAO,IAAI;YACLA,qBAAO;;yCAEsB,YAAY;;;;;;;;;;;yCAWZ,YAAY;;;;;;;EAOjD,SACE,OAAO;CACX;AACF"}
@@ -1,5 +1,7 @@
1
1
  /**
2
- * Copyright IBM Corp. 2023, 2024
2
+ * @license
3
+ *
4
+ * Copyright IBM Corp. 2023, 2026
3
5
  *
4
6
  * This source code is licensed under the Apache-2.0 license found in the
5
7
  * LICENSE file in the root directory of this source tree.
@@ -24,6 +26,10 @@ export declare enum SIDE_PANEL_SIZE {
24
26
  * Large size.
25
27
  */
26
28
  LARGE = "lg",
29
+ /**
30
+ * Extra Large size.
31
+ */
32
+ EXTRA_LARGE = "xl",
27
33
  /**
28
34
  * 2X-Large size.
29
35
  */
@@ -1 +1 @@
1
- {"version":3,"file":"defs.d.ts","sourceRoot":"","sources":["../../../src/components/side-panel/defs.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH;;GAEG;AACH,oBAAY,eAAe;IACzB;;OAEG;IACH,WAAW,OAAO;IAElB;;OAEG;IACH,KAAK,OAAO;IAEZ;;OAEG;IACH,MAAM,OAAO;IAEb;;OAEG;IACH,KAAK,OAAO;IAEZ;;OAEG;IACH,iBAAiB,QAAQ;CAC1B;AAED,oBAAY,oBAAoB;IAC9B,sBAAsB;IACtB,KAAK,UAAU;IAEf,YAAY;IACZ,IAAI,SAAS;CACd"}
1
+ {"version":3,"file":"defs.d.ts","sourceRoot":"","sources":["../../../src/components/side-panel/defs.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH;;GAEG;AACH,oBAAY,eAAe;IACzB;;OAEG;IACH,WAAW,OAAO;IAElB;;OAEG;IACH,KAAK,OAAO;IAEZ;;OAEG;IACH,MAAM,OAAO;IAEb;;OAEG;IACH,KAAK,OAAO;IAEZ;;OAEG;IACH,WAAW,OAAO;IAElB;;OAEG;IACH,iBAAiB,QAAQ;CAC1B;AAED,oBAAY,oBAAoB;IAC9B,sBAAsB;IACtB,KAAK,UAAU;IAEf,YAAY;IACZ,IAAI,SAAS;CACd"}
@@ -7,7 +7,9 @@
7
7
 
8
8
  //#region src/components/side-panel/defs.ts
9
9
  /**
10
- * Copyright IBM Corp. 2023, 2024
10
+ * @license
11
+ *
12
+ * Copyright IBM Corp. 2023, 2026
11
13
  *
12
14
  * This source code is licensed under the Apache-2.0 license found in the
13
15
  * LICENSE file in the root directory of this source tree.
@@ -33,6 +35,10 @@ let SIDE_PANEL_SIZE = /* @__PURE__ */ function(SIDE_PANEL_SIZE) {
33
35
  */
34
36
  SIDE_PANEL_SIZE["LARGE"] = "lg";
35
37
  /**
38
+ * Extra Large size.
39
+ */
40
+ SIDE_PANEL_SIZE["EXTRA_LARGE"] = "xl";
41
+ /**
36
42
  * 2X-Large size.
37
43
  */
38
44
  SIDE_PANEL_SIZE["EXTRA_EXTRA_LARGE"] = "2xl";
@@ -1 +1 @@
1
- {"version":3,"file":"defs.js","names":[],"sources":["../../../src/components/side-panel/defs.ts"],"sourcesContent":["/**\n * Copyright IBM Corp. 2023, 2024\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n/**\n * Modal size.\n */\nexport enum SIDE_PANEL_SIZE {\n /**\n * Extra small size.\n */\n EXTRA_SMALL = 'xs',\n\n /**\n * Small size.\n */\n SMALL = 'sm',\n\n /**\n * Medium size.\n */\n MEDIUM = 'md',\n\n /**\n * Large size.\n */\n LARGE = 'lg',\n\n /**\n * 2X-Large size.\n */\n EXTRA_EXTRA_LARGE = '2xl',\n}\n\nexport enum SIDE_PANEL_PLACEMENT {\n /** right / default */\n RIGHT = 'right',\n\n /** left */\n LEFT = 'left',\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAUA,IAAY,kBAAL,yBAAA,iBAAA;;;;CAIL,gBAAA,iBAAA;;;;CAKA,gBAAA,WAAA;;;;CAKA,gBAAA,YAAA;;;;CAKA,gBAAA,WAAA;;;;CAKA,gBAAA,uBAAA;;AACF,EAAA,CAAA,CAAA;AAEA,IAAY,uBAAL,yBAAA,sBAAA;;CAEL,qBAAA,WAAA;;CAGA,qBAAA,UAAA;;AACF,EAAA,CAAA,CAAA"}
1
+ {"version":3,"file":"defs.js","names":[],"sources":["../../../src/components/side-panel/defs.ts"],"sourcesContent":["/**\n * @license\n *\n * Copyright IBM Corp. 2023, 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n/**\n * Modal size.\n */\nexport enum SIDE_PANEL_SIZE {\n /**\n * Extra small size.\n */\n EXTRA_SMALL = 'xs',\n\n /**\n * Small size.\n */\n SMALL = 'sm',\n\n /**\n * Medium size.\n */\n MEDIUM = 'md',\n\n /**\n * Large size.\n */\n LARGE = 'lg',\n\n /**\n * Extra Large size.\n */\n EXTRA_LARGE = 'xl',\n\n /**\n * 2X-Large size.\n */\n EXTRA_EXTRA_LARGE = '2xl',\n}\n\nexport enum SIDE_PANEL_PLACEMENT {\n /** right / default */\n RIGHT = 'right',\n\n /** left */\n LEFT = 'left',\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAYA,IAAY,kBAAL,yBAAA,iBAAA;;;;CAIL,gBAAA,iBAAA;;;;CAKA,gBAAA,WAAA;;;;CAKA,gBAAA,YAAA;;;;CAKA,gBAAA,WAAA;;;;CAKA,gBAAA,iBAAA;;;;CAKA,gBAAA,uBAAA;;AACF,EAAA,CAAA,CAAA;AAEA,IAAY,uBAAL,yBAAA,sBAAA;;CAEL,qBAAA,WAAA;;CAGA,qBAAA,UAAA;;AACF,EAAA,CAAA,CAAA"}
@@ -1,5 +1,7 @@
1
1
  /**
2
- * Copyright IBM Corp. 2023, 2024
2
+ * @license
3
+ *
4
+ * Copyright IBM Corp. 2023, 2026
3
5
  *
4
6
  * This source code is licensed under the Apache-2.0 license found in the
5
7
  * LICENSE file in the root directory of this source tree.
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/side-panel/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,cAAc,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/side-panel/index.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,cAAc,CAAC"}
@@ -6,3 +6,15 @@
6
6
  */
7
7
 
8
8
  import "./side-panel.js";
9
+ //#region src/components/side-panel/index.ts
10
+ /**
11
+ * @license
12
+ *
13
+ * Copyright IBM Corp. 2023, 2026
14
+ *
15
+ * This source code is licensed under the Apache-2.0 license found in the
16
+ * LICENSE file in the root directory of this source tree.
17
+ */
18
+ //#endregion
19
+
20
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../../src/components/side-panel/index.ts"],"sourcesContent":["/**\n * @license\n *\n * Copyright IBM Corp. 2023, 2026\n *\n * This source code is licensed under the Apache-2.0 license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport './side-panel';\n"],"mappings":""}
@@ -1,4 +1,6 @@
1
1
  /**
2
+ * @license
3
+ *
2
4
  * Copyright IBM Corp. 2023, 2026
3
5
  *
4
6
  * This source code is licensed under the Apache-2.0 license found in the
@@ -6,11 +8,12 @@
6
8
  */
7
9
  import { LitElement } from 'lit';
8
10
  import { SIDE_PANEL_SIZE, SIDE_PANEL_PLACEMENT } from './defs';
11
+ import Handle from '../../globals/internal/handle';
9
12
  import '../button/index';
10
13
  import '../icon-button/index';
11
14
  import '../layer/index';
12
- import Handle from '../../globals/internal/handle';
13
- import '../button/button-set-base';
15
+ import '../action-set/index.js';
16
+ import '../resizer/index.js';
14
17
  export { SIDE_PANEL_SIZE, SIDE_PANEL_PLACEMENT };
15
18
  declare const CDSSidePanel_base: {
16
19
  new (...args: any[]): {
@@ -29,10 +32,6 @@ declare const CDSSidePanel_base: {
29
32
  /**
30
33
  * SidePanel.
31
34
  *
32
- * @deprecated Use Carbon for IBM Products `side-panel` component.
33
- * This component has been deprecated in `@carbon/web-components` and will instead be maintained
34
- * in the Carbon for IBM Products library:
35
- * https://github.com/carbon-design-system/ibm-products/tree/main/packages/ibm-products-web-components
36
35
  * @element cds-custom-side-panel
37
36
  * @csspart dialog The dialog.
38
37
  * @fires cds-custom-side-panel-beingclosed
@@ -50,14 +49,6 @@ declare class CDSSidePanel extends CDSSidePanel_base {
50
49
  * The element that had focus before this side-panel gets open.
51
50
  */
52
51
  private _launcher;
53
- /**
54
- * Node to track focus going outside of side-panel content.
55
- */
56
- private _startSentinelNode;
57
- /**
58
- * Node to track focus going outside of side-panel content.
59
- */
60
- private _endSentinelNode;
61
52
  /**
62
53
  * Node to track side panel.
63
54
  */
@@ -67,7 +58,10 @@ declare class CDSSidePanel extends CDSSidePanel_base {
67
58
  private _title;
68
59
  private _subtitle;
69
60
  private _innerContent;
70
- private _actions;
61
+ /**
62
+ * Reference to the resizer handle element
63
+ */
64
+ private _resizerHandle?;
71
65
  _doAnimateTitle: boolean;
72
66
  _isOpen: boolean;
73
67
  _containerScrollTop: number;
@@ -75,15 +69,27 @@ declare class CDSSidePanel extends CDSSidePanel_base {
75
69
  _hasSlug: boolean;
76
70
  _hasActionToolbar: boolean;
77
71
  _actionsCount: number;
72
+ _actionsMultiple: 'single' | 'double' | 'triple' | '';
78
73
  _slugCloseSize: string;
74
+ _customHeaderElements: Element[];
75
+ _customHeaderHidden: boolean;
76
+ _sidePanelWidth?: number;
77
+ _accumulatedDelta: number;
79
78
  /**
80
- * Handles `blur` event on this element.
79
+ * Get focusable elements.
81
80
  *
82
- * @param event The event.
83
- * @param event.target The event target.
84
- * @param event.relatedTarget The event relatedTarget.
81
+ * Querying all tabbable items.
82
+ *
83
+ * @returns {{first: HTMLElement, last: HTMLElement, all: HTMLElement[]}} Returns an object with various elements.
85
84
  */
86
- private _handleBlur;
85
+ private getFocusable;
86
+ /**
87
+ * Handle the keydown event.
88
+ * Trap the focus inside the side-panel by tracking keydown.key == `Tab`
89
+ *
90
+ * @param {KeyboardEvent} event The keyboard event object.
91
+ */
92
+ protected _handleHostKeydown: (event: KeyboardEvent) => void;
87
93
  private _handleKeydown;
88
94
  private _reducedMotion;
89
95
  /**
@@ -110,9 +116,8 @@ declare class CDSSidePanel extends CDSSidePanel_base {
110
116
  private _checkUpdateIconButtonSizes;
111
117
  private _handleSlugChange;
112
118
  private _handleSubtitleChange;
119
+ private _handleCustomHeaderSlotChange;
113
120
  private _handleActionToolbarChange;
114
- private _checkUpdateActionSizes;
115
- private _maxActions;
116
121
  private _handleActionsChange;
117
122
  private _checkSetDoAnimateTitle;
118
123
  /**
@@ -121,6 +126,26 @@ declare class CDSSidePanel extends CDSSidePanel_base {
121
126
  private _resizeObserver;
122
127
  private _getScrollAnimationDistance;
123
128
  private _scrollObserver;
129
+ /**
130
+ * Handles resize start event from the resizer handle
131
+ */
132
+ private _handleResizeStart;
133
+ /**
134
+ * Handles resize drag event from the resizer handle
135
+ */
136
+ private _handleResizeDrag;
137
+ /**
138
+ * Handles resize end event from the resizer handle
139
+ */
140
+ private _handleResizeEnd;
141
+ /**
142
+ * Handles double-click/double-tap on resizer to reset size
143
+ */
144
+ private _handleResizeReset;
145
+ /**
146
+ * Get the percentage of screen width the panel is covering
147
+ */
148
+ private _getPanelWidthPercent;
124
149
  private _handleCurrentStepUpdate;
125
150
  /**
126
151
  * Determines if the title will animate on scroll
@@ -130,6 +155,10 @@ declare class CDSSidePanel extends CDSSidePanel_base {
130
155
  * Sets the close button icon description
131
156
  */
132
157
  closeIconDescription: string;
158
+ /**
159
+ * Sets the close button tooltip alignment
160
+ */
161
+ closeIconTooltipAlignment: string;
133
162
  /**
134
163
  * Determines whether the side panel should render the condensed version (affects action buttons primarily)
135
164
  */
@@ -170,6 +199,10 @@ declare class CDSSidePanel extends CDSSidePanel_base {
170
199
  * Selector for page content, used to push content to side except
171
200
  */
172
201
  selectorPageContent: string;
202
+ /**
203
+ * Show/hide the "X" close button
204
+ */
205
+ hideCloseButton: boolean;
173
206
  /**
174
207
  * SidePanel size.
175
208
  */
@@ -178,6 +211,10 @@ declare class CDSSidePanel extends CDSSidePanel_base {
178
211
  * Determines if this panel slides in
179
212
  */
180
213
  slideIn: boolean;
214
+ /**
215
+ * Determines if the side panel is resizable
216
+ */
217
+ resizable: boolean;
181
218
  /**
182
219
  * Sets the title text
183
220
  */
@@ -210,6 +247,7 @@ declare class CDSSidePanel extends CDSSidePanel_base {
210
247
  * The name of the custom event fired on clicking the navigate back button
211
248
  */
212
249
  static get eventNavigateBack(): string;
250
+ static styles: any;
213
251
  }
214
252
  export default CDSSidePanel;
215
253
  //# sourceMappingURL=side-panel.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"side-panel.d.ts","sourceRoot":"","sources":["../../../src/components/side-panel/side-panel.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,UAAU,EAAQ,MAAM,KAAK,CAAC;AAWvC,OAAO,EAAE,eAAe,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAAC;AAM/D,OAAO,iBAAiB,CAAC;AACzB,OAAO,sBAAsB,CAAC;AAC9B,OAAO,gBAAgB,CAAC;AACxB,OAAO,MAAM,MAAM,+BAA+B,CAAC;A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