@arcgis/portal-components 5.2.0-next.4 → 5.2.0-next.41

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 (207) hide show
  1. package/dist/cdn/2C475EKD.js +2 -0
  2. package/dist/cdn/3J46PXFF.js +3 -0
  3. package/dist/cdn/3MBOA5WF.js +2 -0
  4. package/dist/cdn/{GQFWFZXP.js → 3OBIA66A.js} +1 -1
  5. package/dist/cdn/3Z3ZPFGJ.js +2 -0
  6. package/dist/cdn/5NMFQE4U.js +2 -0
  7. package/dist/cdn/{7WZHZP6U.js → 63THOLAY.js} +9 -3
  8. package/dist/cdn/6AGZRMJC.js +2 -0
  9. package/dist/cdn/6DYBW2C6.js +2 -0
  10. package/dist/cdn/6RK4FBHZ.js +2 -0
  11. package/dist/cdn/6W2IHKCA.js +2 -0
  12. package/dist/cdn/7E5GJIZV.js +2 -0
  13. package/dist/cdn/AL57LV4E.js +2 -0
  14. package/dist/cdn/{LQ3DMZ3K.js → AXM6XCZD.js} +1 -1
  15. package/dist/cdn/AYR65LXN.js +65 -0
  16. package/dist/cdn/BUJPYZSX.js +2 -0
  17. package/dist/cdn/{DKBTJJMW.js → C7ZFXRPS.js} +1 -1
  18. package/dist/cdn/D76KMXZD.js +2 -0
  19. package/dist/cdn/DFTUMKSN.js +3 -0
  20. package/dist/cdn/DZJMNZY6.js +451 -0
  21. package/dist/cdn/EI6BAXCQ.js +2 -0
  22. package/dist/cdn/EVMYGWC6.js +637 -0
  23. package/dist/cdn/FXIP4QXJ.js +2 -0
  24. package/dist/cdn/GE75KDIM.js +2 -0
  25. package/dist/cdn/GJTJLK6T.js +2 -0
  26. package/dist/cdn/GKOXTQHB.js +2 -0
  27. package/dist/cdn/GQMPPCEL.js +2 -0
  28. package/dist/cdn/GXJU3U7U.js +2 -0
  29. package/dist/cdn/HMBSJR37.js +2 -0
  30. package/dist/cdn/HZ5W3DBR.js +2 -0
  31. package/dist/cdn/{V2EOXGK2.js → I234NUZ5.js} +1 -1
  32. package/dist/cdn/I5HSJRM3.js +2 -0
  33. package/dist/cdn/IBP5XPD5.js +2 -0
  34. package/dist/cdn/IC65R4QE.js +2 -0
  35. package/dist/cdn/IHSJ4MKS.js +2 -0
  36. package/dist/cdn/IJ3CLFAU.js +22 -0
  37. package/dist/cdn/IWUJRI4G.js +2 -0
  38. package/dist/cdn/{ZTHTFEYA.js → IXVR3KMC.js} +1 -1
  39. package/dist/cdn/{QNUYUNEY.js → JS45DWQ3.js} +1 -1
  40. package/dist/cdn/{DHHSKOUY.js → JV23HJTE.js} +1 -1
  41. package/dist/cdn/{LAFNDBTQ.js → JYIPREIH.js} +1 -1
  42. package/dist/cdn/JZKBUYPV.js +2 -0
  43. package/dist/cdn/KM5XGRXL.js +2 -0
  44. package/dist/cdn/{3PAHY5KA.js → KNRJ3WXR.js} +1 -1
  45. package/dist/cdn/L4DRNGOL.js +2 -0
  46. package/dist/cdn/{F6V7MLPY.js → L6KBBJEC.js} +1 -1
  47. package/dist/cdn/NJ2WDAJM.js +2 -0
  48. package/dist/cdn/NWIIOJEG.js +2 -0
  49. package/dist/cdn/{53MSUMA3.js → OT4PZJNB.js} +17 -1
  50. package/dist/cdn/POIXW2OA.js +2 -0
  51. package/dist/cdn/QE4CNVDQ.js +34 -0
  52. package/dist/cdn/{AQWTJKUH.js → QKCV7CY2.js} +10 -8
  53. package/dist/cdn/RKNDXSVK.js +2 -0
  54. package/dist/cdn/SLTFLCVR.js +99 -0
  55. package/dist/cdn/SUPKZF5M.js +2 -0
  56. package/dist/cdn/{GT26WGJS.js → SXZRHHXC.js} +1 -1
  57. package/dist/cdn/TJAX7J4T.js +2 -0
  58. package/dist/cdn/{DXCPWJU4.js → TKCE4WYE.js} +1 -1
  59. package/dist/cdn/U3FVMN32.js +2 -0
  60. package/dist/cdn/UZLQALHY.js +2 -0
  61. package/dist/cdn/{RR4BIAPA.js → V4EYW3O6.js} +1 -1
  62. package/dist/cdn/{74XFARCV.js → VW7DSKPH.js} +1 -1
  63. package/dist/cdn/W2SYL7IJ.js +71 -0
  64. package/dist/cdn/{W6PSG4GX.js → W4FGRGLV.js} +10 -5
  65. package/dist/cdn/{SYJSVUUR.js → W4SAWMXS.js} +1 -1
  66. package/dist/cdn/WBZLQZYR.js +134 -0
  67. package/dist/cdn/WGZZB2DJ.js +2 -0
  68. package/dist/cdn/WO23VQK3.js +2 -0
  69. package/dist/cdn/{2UUZHENH.js → WSNLUGEP.js} +1 -1
  70. package/dist/cdn/WSWHK6LB.js +2 -0
  71. package/dist/cdn/{WOZDQW3S.js → WX65MRDH.js} +1 -1
  72. package/dist/cdn/XEK22IDA.js +2 -0
  73. package/dist/cdn/ZPIXIG3Z.js +2 -0
  74. package/dist/cdn/ZVFNCDG5.js +2 -0
  75. package/dist/cdn/assets/portal-browser/t9n/messages.en.json +1 -0
  76. package/dist/cdn/assets/portal-group-badges/t9n/messages.en.json +1 -0
  77. package/dist/cdn/assets/portal-group-card/t9n/messages.en.json +1 -0
  78. package/dist/cdn/assets/portal-item-type/icons/parquetfeaturelayer16.svg +1 -0
  79. package/dist/cdn/assets/portal-item-type/icons/parquetfeaturelayer32.svg +1 -0
  80. package/dist/cdn/assets/portal-item-type/icons/storymapframe16.svg +1 -0
  81. package/dist/cdn/assets/portal-item-type/icons/storymapframe32.svg +1 -0
  82. package/dist/cdn/assets/portal-item-type/t9n/messages.en.json +1 -1
  83. package/dist/cdn/assets/portal-user-popup/t9n/messages.en.json +1 -0
  84. package/dist/cdn/index.js +1 -1
  85. package/dist/cdn/main.css +1 -1
  86. package/dist/chunks/dom.js +36 -0
  87. package/dist/chunks/functionalities.js +5 -4
  88. package/dist/chunks/groups.js +7 -83
  89. package/dist/chunks/item2.js +86 -0
  90. package/dist/chunks/portal.js +48 -8
  91. package/dist/chunks/store.js +18 -0
  92. package/dist/chunks/ui.js +10 -0
  93. package/dist/chunks/user2.js +26 -25
  94. package/dist/components/arcgis-portal-ai-assistant/agents/types.d.ts +11 -2
  95. package/dist/components/arcgis-portal-ai-assistant/customElement.d.ts +4 -2
  96. package/dist/components/arcgis-portal-ai-assistant/customElement.js +797 -488
  97. package/dist/components/arcgis-portal-ai-assistant-interrupt/customElement.js +10 -10
  98. package/dist/components/arcgis-portal-browser/customElement.d.ts +235 -0
  99. package/dist/components/arcgis-portal-browser/customElement.js +201 -0
  100. package/dist/components/arcgis-portal-browser/index.d.ts +1 -0
  101. package/dist/components/arcgis-portal-browser/index.js +6 -0
  102. package/dist/components/arcgis-portal-browser/utils/store.d.ts +31 -0
  103. package/dist/components/arcgis-portal-browser/utils/types.d.ts +18 -0
  104. package/dist/components/arcgis-portal-browser-actions/customElement.d.ts +187 -0
  105. package/dist/components/arcgis-portal-browser-actions/customElement.js +70 -0
  106. package/dist/components/arcgis-portal-browser-actions/index.d.ts +1 -0
  107. package/dist/components/arcgis-portal-browser-actions/index.js +6 -0
  108. package/dist/components/arcgis-portal-browser-actions/types.d.ts +9 -0
  109. package/dist/components/arcgis-portal-browser-filter/customElement.d.ts +226 -0
  110. package/dist/components/arcgis-portal-browser-filter/customElement.js +32 -0
  111. package/dist/components/arcgis-portal-browser-filter/index.d.ts +1 -0
  112. package/dist/components/arcgis-portal-browser-filter/index.js +4 -0
  113. package/dist/components/arcgis-portal-browser-filter-date/customElement.d.ts +233 -0
  114. package/dist/components/arcgis-portal-browser-filter-date/customElement.js +117 -0
  115. package/dist/components/arcgis-portal-browser-filter-date/index.d.ts +1 -0
  116. package/dist/components/arcgis-portal-browser-filter-date/index.js +5 -0
  117. package/dist/components/arcgis-portal-browser-filter-status/customElement.d.ts +193 -0
  118. package/dist/components/arcgis-portal-browser-filter-status/customElement.js +56 -0
  119. package/dist/components/arcgis-portal-browser-filter-status/index.d.ts +1 -0
  120. package/dist/components/arcgis-portal-browser-filter-status/index.js +5 -0
  121. package/dist/components/arcgis-portal-browser-filters/customElement.d.ts +7 -0
  122. package/dist/components/arcgis-portal-browser-filters/customElement.js +29 -0
  123. package/dist/components/arcgis-portal-browser-filters/index.d.ts +1 -0
  124. package/dist/components/arcgis-portal-browser-filters/index.js +2 -0
  125. package/dist/components/arcgis-portal-browser-pagination/customElement.d.ts +194 -0
  126. package/dist/components/arcgis-portal-browser-pagination/customElement.js +51 -0
  127. package/dist/components/arcgis-portal-browser-pagination/index.d.ts +1 -0
  128. package/dist/components/arcgis-portal-browser-pagination/index.js +2 -0
  129. package/dist/components/arcgis-portal-browser-search/customElement.d.ts +195 -0
  130. package/dist/components/arcgis-portal-browser-search/customElement.js +65 -0
  131. package/dist/components/arcgis-portal-browser-search/index.d.ts +1 -0
  132. package/dist/components/arcgis-portal-browser-search/index.js +3 -0
  133. package/dist/components/arcgis-portal-browser-sort/customElement.d.ts +196 -0
  134. package/dist/components/arcgis-portal-browser-sort/customElement.js +93 -0
  135. package/dist/components/arcgis-portal-browser-sort/index.d.ts +1 -0
  136. package/dist/components/arcgis-portal-browser-sort/index.js +9 -0
  137. package/dist/components/arcgis-portal-browser-sort/utils.d.ts +3 -0
  138. package/dist/components/arcgis-portal-browser-top-bar/customElement.d.ts +184 -0
  139. package/dist/components/arcgis-portal-browser-top-bar/customElement.js +51 -0
  140. package/dist/components/arcgis-portal-browser-top-bar/index.d.ts +1 -0
  141. package/dist/components/arcgis-portal-browser-top-bar/index.js +3 -0
  142. package/dist/components/arcgis-portal-browser-view/customElement.d.ts +21 -0
  143. package/dist/components/arcgis-portal-browser-view/customElement.js +30 -0
  144. package/dist/components/arcgis-portal-browser-view/index.d.ts +1 -0
  145. package/dist/components/arcgis-portal-browser-view/index.js +5 -0
  146. package/dist/components/arcgis-portal-group-badges/customElement.d.ts +102 -0
  147. package/dist/components/arcgis-portal-group-badges/customElement.js +50 -0
  148. package/dist/components/arcgis-portal-group-badges/index.d.ts +1 -0
  149. package/dist/components/arcgis-portal-group-badges/index.js +3 -0
  150. package/dist/components/arcgis-portal-group-badges/types.d.ts +3 -0
  151. package/dist/components/arcgis-portal-group-card/customElement.d.ts +167 -0
  152. package/dist/components/arcgis-portal-group-card/customElement.js +183 -0
  153. package/dist/components/arcgis-portal-group-card/index.d.ts +1 -0
  154. package/dist/components/arcgis-portal-group-card/index.js +8 -0
  155. package/dist/components/arcgis-portal-group-thumbnail/customElement.d.ts +32 -0
  156. package/dist/components/arcgis-portal-group-thumbnail/customElement.js +153 -0
  157. package/dist/components/arcgis-portal-group-thumbnail/index.d.ts +1 -0
  158. package/dist/components/arcgis-portal-group-thumbnail/index.js +3 -0
  159. package/dist/components/arcgis-portal-item-type/customElement.d.ts +2 -0
  160. package/dist/components/arcgis-portal-item-type/customElement.js +45 -37
  161. package/dist/components/arcgis-portal-mentionable-text-area/customElement.js +1 -1
  162. package/dist/components/arcgis-portal-replacement-item-redirect/customElement.js +53 -42
  163. package/dist/components/arcgis-portal-user-popup/customElement.d.ts +111 -0
  164. package/dist/components/arcgis-portal-user-popup/customElement.js +224 -0
  165. package/dist/components/arcgis-portal-user-popup/index.d.ts +1 -0
  166. package/dist/components/arcgis-portal-user-popup/index.js +5 -0
  167. package/dist/components/arcgis-portal-voice-input/customElement.d.ts +1 -1
  168. package/dist/docs/api.json +1 -1
  169. package/dist/docs/docs.json +1 -1
  170. package/dist/docs/vscode.html-custom-data.json +1 -1
  171. package/dist/docs/web-types.json +1 -1
  172. package/dist/index.d.ts +122 -2
  173. package/dist/loader.js +19 -4
  174. package/dist/types/group.d.ts +13 -13
  175. package/dist/types/item.d.ts +77 -2
  176. package/dist/types/lumina.d.ts +93 -1
  177. package/dist/types/preact.d.ts +108 -1
  178. package/dist/types/react.d.ts +123 -1
  179. package/dist/types/search.d.ts +27 -0
  180. package/dist/types/stencil.d.ts +93 -1
  181. package/dist/types/tracking.d.ts +10 -0
  182. package/dist/types/user.d.ts +2 -2
  183. package/package.json +11 -11
  184. package/dist/cdn/5DPWJ7DI.js +0 -2
  185. package/dist/cdn/5VSDGPHH.js +0 -2
  186. package/dist/cdn/72N3KAXN.js +0 -2
  187. package/dist/cdn/ANPXRYLV.js +0 -5
  188. package/dist/cdn/B7633S2A.js +0 -422
  189. package/dist/cdn/BEHLBKKM.js +0 -2
  190. package/dist/cdn/CI5ENGVT.js +0 -2
  191. package/dist/cdn/EVDOPN3G.js +0 -54
  192. package/dist/cdn/G47ZZQYL.js +0 -2
  193. package/dist/cdn/GAHILDQF.js +0 -45
  194. package/dist/cdn/GHQ3ZW4U.js +0 -2
  195. package/dist/cdn/GNOZCQ34.js +0 -2
  196. package/dist/cdn/JNRN6DTV.js +0 -2
  197. package/dist/cdn/K3HS2LQ7.js +0 -2
  198. package/dist/cdn/KEKBRUUC.js +0 -2
  199. package/dist/cdn/N6G6Z7BF.js +0 -516
  200. package/dist/cdn/OQDPULPD.js +0 -2
  201. package/dist/cdn/RNLVNDGG.js +0 -2
  202. package/dist/cdn/SM4GWLRA.js +0 -66
  203. package/dist/cdn/TMYTUOSS.js +0 -2
  204. package/dist/cdn/YG5YYL6X.js +0 -2
  205. package/dist/cdn/YIMNOUTF.js +0 -2
  206. package/dist/cdn/YL7PGYWC.js +0 -5
  207. package/dist/cdn/YMPTDKT6.js +0 -2
@@ -0,0 +1,233 @@
1
+ /// <reference path="../../index.d.ts" />
2
+ import type { PublicLitElement as LitElement } from "@arcgis/lumina";
3
+ import type { PortalBrowserFilterDetail, PortalBrowserStore } from "../arcgis-portal-browser/utils/store.js";
4
+ import type { T9nMeta } from "@arcgis/lumina/controllers";
5
+
6
+ export abstract class ArcgisPortalBrowserFilterDate extends LitElement {
7
+ /** @internal */
8
+ protected _messages: {
9
+ browser: {
10
+ refineContent: string;
11
+ filters: string;
12
+ pageRange: string;
13
+ pageRangeAria: string;
14
+ pageRangeWithRecycleBin: string;
15
+ pageRangeAriaWithRecycleBin: string;
16
+ totalSize: string;
17
+ loading: string;
18
+ close: string;
19
+ };
20
+ actions: { more: string; };
21
+ filter: { clear: string; };
22
+ filterDate: {
23
+ today: string;
24
+ yesterday: string;
25
+ last7: string;
26
+ last30: string;
27
+ never: string;
28
+ custom: string;
29
+ title: {
30
+ created: string;
31
+ modified: string;
32
+ joined: string;
33
+ lastLogin: string;
34
+ };
35
+ created: string;
36
+ modified: string;
37
+ joined: string;
38
+ lastLogin: string;
39
+ };
40
+ pagination: {
41
+ next: string;
42
+ prev: string;
43
+ };
44
+ search: {
45
+ label: string;
46
+ search: string;
47
+ clear: string;
48
+ wildcard: string;
49
+ };
50
+ sort: {
51
+ sortDirection: string;
52
+ title: string;
53
+ relevance: string;
54
+ modified: string;
55
+ deleted: string;
56
+ created: string;
57
+ added: string;
58
+ size: string;
59
+ owner: string;
60
+ sizeAsc: string;
61
+ sizeDesc: string;
62
+ numviews: string;
63
+ numAsc: string;
64
+ numDesc: string;
65
+ alphabeticalAsc: string;
66
+ alphabeticalDesc: string;
67
+ recentAsc: string;
68
+ recentDesc: string;
69
+ sort: string;
70
+ sortBy: string;
71
+ sortByColon: string;
72
+ fullname: string;
73
+ username: string;
74
+ name: string;
75
+ membertype: string;
76
+ joined: string;
77
+ lastlogin: string;
78
+ dataset: string;
79
+ mfaenabled: string;
80
+ description: string;
81
+ lastSyncFailureCount: string;
82
+ invitationsPendingCount: string;
83
+ participantGroupLinksCount: string;
84
+ defaultAsc: string;
85
+ defaultDesc: string;
86
+ };
87
+ topBar: { filter: string; };
88
+ filterStatus: {
89
+ clear: string;
90
+ filters: string;
91
+ additional: string;
92
+ clearAllFilters: string;
93
+ };
94
+ } & T9nMeta<{
95
+ browser: {
96
+ refineContent: string;
97
+ filters: string;
98
+ pageRange: string;
99
+ pageRangeAria: string;
100
+ pageRangeWithRecycleBin: string;
101
+ pageRangeAriaWithRecycleBin: string;
102
+ totalSize: string;
103
+ loading: string;
104
+ close: string;
105
+ };
106
+ actions: { more: string; };
107
+ filter: { clear: string; };
108
+ filterDate: {
109
+ today: string;
110
+ yesterday: string;
111
+ last7: string;
112
+ last30: string;
113
+ never: string;
114
+ custom: string;
115
+ title: {
116
+ created: string;
117
+ modified: string;
118
+ joined: string;
119
+ lastLogin: string;
120
+ };
121
+ created: string;
122
+ modified: string;
123
+ joined: string;
124
+ lastLogin: string;
125
+ };
126
+ pagination: {
127
+ next: string;
128
+ prev: string;
129
+ };
130
+ search: {
131
+ label: string;
132
+ search: string;
133
+ clear: string;
134
+ wildcard: string;
135
+ };
136
+ sort: {
137
+ sortDirection: string;
138
+ title: string;
139
+ relevance: string;
140
+ modified: string;
141
+ deleted: string;
142
+ created: string;
143
+ added: string;
144
+ size: string;
145
+ owner: string;
146
+ sizeAsc: string;
147
+ sizeDesc: string;
148
+ numviews: string;
149
+ numAsc: string;
150
+ numDesc: string;
151
+ alphabeticalAsc: string;
152
+ alphabeticalDesc: string;
153
+ recentAsc: string;
154
+ recentDesc: string;
155
+ sort: string;
156
+ sortBy: string;
157
+ sortByColon: string;
158
+ fullname: string;
159
+ username: string;
160
+ name: string;
161
+ membertype: string;
162
+ joined: string;
163
+ lastlogin: string;
164
+ dataset: string;
165
+ mfaenabled: string;
166
+ description: string;
167
+ lastSyncFailureCount: string;
168
+ invitationsPendingCount: string;
169
+ participantGroupLinksCount: string;
170
+ defaultAsc: string;
171
+ defaultDesc: string;
172
+ };
173
+ topBar: { filter: string; };
174
+ filterStatus: {
175
+ clear: string;
176
+ filters: string;
177
+ additional: string;
178
+ clearAllFilters: string;
179
+ };
180
+ }>;
181
+ /** End date for user-defined range. */
182
+ accessor end: Date | number | string | null | undefined;
183
+ /**
184
+ * Set to true to open the filter on first load.
185
+ *
186
+ * @default false
187
+ */
188
+ accessor expanded: boolean;
189
+ /**
190
+ * Set to true to include the never option.
191
+ *
192
+ * @default false
193
+ */
194
+ accessor includeNever: boolean;
195
+ /**
196
+ * Id of the date filter in the browser store.
197
+ *
198
+ * @default "created"
199
+ */
200
+ accessor property: PortalBrowserDateProperty;
201
+ /** Well known date ranges, or custom for user-defined ranges. */
202
+ accessor range: PortalBrowserDateRange;
203
+ /** Property key to use in generated query expressions. */
204
+ accessor serverProperty: string | undefined;
205
+ /** Start date for user-defined range. */
206
+ accessor start: Date | number | string | null | undefined;
207
+ /** Shared browser store used to reset this filter when removed externally. */
208
+ accessor store: PortalBrowserStore | undefined;
209
+ readonly arcgisBrowserFilter: import("@arcgis/lumina").TargetedEvent<this, PortalBrowserDateDetail>;
210
+ readonly "@eventTypes": {
211
+ arcgisBrowserFilter: ArcgisPortalBrowserFilterDate["arcgisBrowserFilter"]["detail"];
212
+ };
213
+ }
214
+
215
+ export type PortalBrowserDateProperty = "created" | "modified";
216
+
217
+ export type PortalBrowserDateRange = (typeof portalBrowserDateRanges)[number] | null;
218
+
219
+ export type PortalBrowserDateDetail = PortalBrowserFilterDetail
220
+ & {
221
+ range: PortalBrowserDateRange;
222
+ start?: Date;
223
+ end?: Date;
224
+ };
225
+
226
+ export const portalBrowserDateRanges: readonly [
227
+ "custom",
228
+ "last30",
229
+ "last7",
230
+ "never",
231
+ "today",
232
+ "yesterday"
233
+ ];
@@ -0,0 +1,117 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
+ import { c as d } from "../../chunks/runtime.js";
3
+ import { watch as u } from "@arcgis/core/core/reactiveUtils.js";
4
+ import { LitElement as m, createEvent as g, nothing as p } from "@arcgis/lumina";
5
+ import { debounce as f } from "@arcgis/toolkit/function";
6
+ import { css as v, html as c } from "lit";
7
+ import { createRef as D, ref as y } from "lit/directives/ref.js";
8
+ import { u as w } from "../../chunks/useT9n.js";
9
+ import "../arcgis-portal-browser-filter/customElement.js";
10
+ const o = 1440 * 60 * 1e3;
11
+ function a(s) {
12
+ const e = typeof s == "string" ? Number.parseInt(s, 10) : typeof s == "number" ? s : (s ?? /* @__PURE__ */ new Date()).valueOf(), t = new Date(e);
13
+ return t.setHours(0, 0, 0, 0), t.valueOf();
14
+ }
15
+ function l(s) {
16
+ return a(s) + o - 1;
17
+ }
18
+ const k = 7 * o, b = v`:host{display:block}.custom-date-picker{margin-top:.5rem;margin-bottom:.5rem;margin-inline-start:1.75rem;width:12.75rem}`, h = ["custom", "last30", "last7", "never", "today", "yesterday"];
19
+ class $ extends m {
20
+ constructor() {
21
+ super(...arguments), this._messages = w({ name: "portal-browser", blocking: !0 }), this._datePicker = D(), this.today = "", this.debouncedRangeChangeHandler = f(() => this.rangeChangeHandler(), 200), this.property = "created", this.range = null, this.expanded = !1, this.includeNever = !1, this.arcgisBrowserFilter = g();
22
+ }
23
+ static {
24
+ this.properties = { property: 1, serverProperty: 1, range: 1, start: 1, end: 1, store: 0, expanded: 5, includeNever: 5 };
25
+ }
26
+ static {
27
+ this.styles = b;
28
+ }
29
+ connectedCallback() {
30
+ super.connectedCallback();
31
+ const e = /* @__PURE__ */ new Date();
32
+ this.today = `${e.getFullYear()}-${e.getMonth() + 1}-${e.getDate()}`, this.attachStoreWatcher(), this.range && (this.range !== "custom" || this.start && this.end) && this.arcgisBrowserFilter.emit(this.getEventDetail());
33
+ }
34
+ willUpdate(e) {
35
+ (e.has("store") || e.has("property")) && this.attachStoreWatcher(), (e.has("range") || e.has("start") || e.has("end")) && this.range === "custom" && this.setDatePickerValue();
36
+ }
37
+ disconnectedCallback() {
38
+ this.removeStoreWatcher?.(), super.disconnectedCallback();
39
+ }
40
+ attachStoreWatcher() {
41
+ if (this.removeStoreWatcher?.(), !this.store)
42
+ return;
43
+ const e = u(() => {
44
+ const t = this.store?.filters?.[this.property];
45
+ return {
46
+ value: t?.value,
47
+ additionalParams: t?.additionalParams
48
+ };
49
+ }, () => {
50
+ const t = this.store?.filters?.[this.property];
51
+ !(t?.value || t?.additionalParams) && this.isActive() && this.resetDatePicker();
52
+ });
53
+ this.removeStoreWatcher = () => e.remove();
54
+ }
55
+ resetDatePicker() {
56
+ this.range = null, this.start = null, this.end = null, this._datePicker.value && (this._datePicker.value.valueAsDate = []);
57
+ }
58
+ getValue() {
59
+ const e = a(), t = l();
60
+ switch (this.range) {
61
+ case "yesterday":
62
+ return [e - o, e - 1];
63
+ case "today":
64
+ return [e, t];
65
+ case "last7":
66
+ return [e - k, t];
67
+ case "last30":
68
+ return [e - o * 30, t];
69
+ case "never":
70
+ return [-1, -1];
71
+ case "custom": {
72
+ const r = a(this.start), i = l(this.end);
73
+ return [r, i];
74
+ }
75
+ default:
76
+ return null;
77
+ }
78
+ }
79
+ getEventDetail() {
80
+ const e = this._messages?.filterDate, t = this.getValue(), r = this.serverProperty ?? (this.property === "modified" ? "modified" : "uploaded"), i = this.range ? e?.[this.range] ?? "" : "", n = e?.[this.property] ?? "";
81
+ return {
82
+ id: this.property,
83
+ value: t ? `(${r}:[${t[0]} TO ${t[1]}])` : "",
84
+ range: this.range,
85
+ start: t ? new Date(t[0]) : void 0,
86
+ end: t ? new Date(t[1]) : void 0,
87
+ label: this.range ? n.replace("${date}", i) : ""
88
+ };
89
+ }
90
+ isActive() {
91
+ return !!(this.range && (this.range !== "custom" || this.start && this.end));
92
+ }
93
+ setDatePickerValue() {
94
+ !this._datePicker.value || this.range !== "custom" || !this.start || !this.end || (this._datePicker.value.valueAsDate = [new Date(a(this.start)), new Date(a(this.end))]);
95
+ }
96
+ rangeChangeHandler() {
97
+ const e = this._datePicker.value?.valueAsDate, [t, r] = Array.isArray(e) ? e : [];
98
+ t && r && (this.start = t, this.end = r, this.arcgisBrowserFilter.emit(this.getEventDetail()));
99
+ }
100
+ renderRange(e) {
101
+ const t = this._messages.filterDate;
102
+ return c`<calcite-tree-item data-range=${e ?? p} .selected=${e === this.range}>${t[e]}</calcite-tree-item>`;
103
+ }
104
+ render() {
105
+ const e = this._messages.filterDate, t = this.includeNever ? h : h.filter((r) => r !== "never");
106
+ return c`<arcgis-portal-browser-filter .heading=${e.title[this.property]} .expanded=${this.expanded} .active=${this.isActive()} .filterId=${this.property} @arcgisBrowserFilterRemove=${() => {
107
+ this.resetDatePicker(), this.arcgisBrowserFilter.emit(this.getEventDetail());
108
+ }}><calcite-tree selection-mode=children scale=m @calciteTreeSelect=${(r) => {
109
+ const n = r.target.selectedItems?.[0]?.dataset.range;
110
+ this.range = this.range === n ? null : n, !(this.range === "custom" && !(this.start && this.end)) && this.arcgisBrowserFilter.emit(this.getEventDetail());
111
+ }}>${t.map((r) => this.renderRange(r))}</calcite-tree>${this.range === "custom" && c`<calcite-input-date-picker class="custom-date-picker" @calciteInputDatePickerChange=${() => this.debouncedRangeChangeHandler()} scale=s .max=${this.today} calendars=1 layout=vertical month-style=abbreviated proximity-selection-disabled range ${y(this._datePicker)}></calcite-input-date-picker>` || ""}</arcgis-portal-browser-filter>`;
112
+ }
113
+ }
114
+ d("arcgis-portal-browser-filter-date", $);
115
+ export {
116
+ $ as ArcgisPortalBrowserFilterDate
117
+ };
@@ -0,0 +1 @@
1
+ export * from "./customElement.js";
@@ -0,0 +1,5 @@
1
+ import "@esri/calcite-components/components/calcite-tree-item";
2
+ import "../arcgis-portal-browser-filter/index.js";
3
+ import "@esri/calcite-components/components/calcite-tree";
4
+ import "@esri/calcite-components/components/calcite-input-date-picker";
5
+ export * from "./customElement.js";
@@ -0,0 +1,193 @@
1
+ /// <reference path="../../index.d.ts" />
2
+ import type { PublicLitElement as LitElement } from "@arcgis/lumina";
3
+ import type { PortalBrowserFilterDetail } from "../arcgis-portal-browser/utils/store.js";
4
+ import type { T9nMeta } from "@arcgis/lumina/controllers";
5
+
6
+ export abstract class ArcgisPortalBrowserFilterStatus extends LitElement {
7
+ /** @internal */
8
+ protected _messages: {
9
+ browser: {
10
+ refineContent: string;
11
+ filters: string;
12
+ pageRange: string;
13
+ pageRangeAria: string;
14
+ pageRangeWithRecycleBin: string;
15
+ pageRangeAriaWithRecycleBin: string;
16
+ totalSize: string;
17
+ loading: string;
18
+ close: string;
19
+ };
20
+ actions: { more: string; };
21
+ filter: { clear: string; };
22
+ filterDate: {
23
+ today: string;
24
+ yesterday: string;
25
+ last7: string;
26
+ last30: string;
27
+ never: string;
28
+ custom: string;
29
+ title: {
30
+ created: string;
31
+ modified: string;
32
+ joined: string;
33
+ lastLogin: string;
34
+ };
35
+ created: string;
36
+ modified: string;
37
+ joined: string;
38
+ lastLogin: string;
39
+ };
40
+ pagination: {
41
+ next: string;
42
+ prev: string;
43
+ };
44
+ search: {
45
+ label: string;
46
+ search: string;
47
+ clear: string;
48
+ wildcard: string;
49
+ };
50
+ sort: {
51
+ sortDirection: string;
52
+ title: string;
53
+ relevance: string;
54
+ modified: string;
55
+ deleted: string;
56
+ created: string;
57
+ added: string;
58
+ size: string;
59
+ owner: string;
60
+ sizeAsc: string;
61
+ sizeDesc: string;
62
+ numviews: string;
63
+ numAsc: string;
64
+ numDesc: string;
65
+ alphabeticalAsc: string;
66
+ alphabeticalDesc: string;
67
+ recentAsc: string;
68
+ recentDesc: string;
69
+ sort: string;
70
+ sortBy: string;
71
+ sortByColon: string;
72
+ fullname: string;
73
+ username: string;
74
+ name: string;
75
+ membertype: string;
76
+ joined: string;
77
+ lastlogin: string;
78
+ dataset: string;
79
+ mfaenabled: string;
80
+ description: string;
81
+ lastSyncFailureCount: string;
82
+ invitationsPendingCount: string;
83
+ participantGroupLinksCount: string;
84
+ defaultAsc: string;
85
+ defaultDesc: string;
86
+ };
87
+ topBar: { filter: string; };
88
+ filterStatus: {
89
+ clear: string;
90
+ filters: string;
91
+ additional: string;
92
+ clearAllFilters: string;
93
+ };
94
+ } & T9nMeta<{
95
+ browser: {
96
+ refineContent: string;
97
+ filters: string;
98
+ pageRange: string;
99
+ pageRangeAria: string;
100
+ pageRangeWithRecycleBin: string;
101
+ pageRangeAriaWithRecycleBin: string;
102
+ totalSize: string;
103
+ loading: string;
104
+ close: string;
105
+ };
106
+ actions: { more: string; };
107
+ filter: { clear: string; };
108
+ filterDate: {
109
+ today: string;
110
+ yesterday: string;
111
+ last7: string;
112
+ last30: string;
113
+ never: string;
114
+ custom: string;
115
+ title: {
116
+ created: string;
117
+ modified: string;
118
+ joined: string;
119
+ lastLogin: string;
120
+ };
121
+ created: string;
122
+ modified: string;
123
+ joined: string;
124
+ lastLogin: string;
125
+ };
126
+ pagination: {
127
+ next: string;
128
+ prev: string;
129
+ };
130
+ search: {
131
+ label: string;
132
+ search: string;
133
+ clear: string;
134
+ wildcard: string;
135
+ };
136
+ sort: {
137
+ sortDirection: string;
138
+ title: string;
139
+ relevance: string;
140
+ modified: string;
141
+ deleted: string;
142
+ created: string;
143
+ added: string;
144
+ size: string;
145
+ owner: string;
146
+ sizeAsc: string;
147
+ sizeDesc: string;
148
+ numviews: string;
149
+ numAsc: string;
150
+ numDesc: string;
151
+ alphabeticalAsc: string;
152
+ alphabeticalDesc: string;
153
+ recentAsc: string;
154
+ recentDesc: string;
155
+ sort: string;
156
+ sortBy: string;
157
+ sortByColon: string;
158
+ fullname: string;
159
+ username: string;
160
+ name: string;
161
+ membertype: string;
162
+ joined: string;
163
+ lastlogin: string;
164
+ dataset: string;
165
+ mfaenabled: string;
166
+ description: string;
167
+ lastSyncFailureCount: string;
168
+ invitationsPendingCount: string;
169
+ participantGroupLinksCount: string;
170
+ defaultAsc: string;
171
+ defaultDesc: string;
172
+ };
173
+ topBar: { filter: string; };
174
+ filterStatus: {
175
+ clear: string;
176
+ filters: string;
177
+ additional: string;
178
+ clearAllFilters: string;
179
+ };
180
+ }>;
181
+ /** Pass the width of the browser from state */
182
+ accessor browserWidth: number | undefined;
183
+ /** Pass the width of the component container */
184
+ accessor componentWidth: number | undefined;
185
+ accessor filters: Record<string, PortalBrowserFilterDetail>;
186
+ accessor hiddenFilterIds: string[];
187
+ readonly arcgisBrowserFilterClear: import("@arcgis/lumina").TargetedEvent<this, null>;
188
+ readonly arcgisBrowserFilterRemove: import("@arcgis/lumina").TargetedEvent<this, string>;
189
+ readonly "@eventTypes": {
190
+ arcgisBrowserFilterClear: ArcgisPortalBrowserFilterStatus["arcgisBrowserFilterClear"]["detail"];
191
+ arcgisBrowserFilterRemove: ArcgisPortalBrowserFilterStatus["arcgisBrowserFilterRemove"]["detail"];
192
+ };
193
+ }
@@ -0,0 +1,56 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
+ import { c as u } from "../../chunks/runtime.js";
3
+ import { keyed as p } from "lit/directives/keyed.js";
4
+ import { LitElement as m, createEvent as d } from "@arcgis/lumina";
5
+ import { css as b, html as e } from "lit";
6
+ import { b as f } from "../../chunks/ui.js";
7
+ import { g } from "../../chunks/dom.js";
8
+ import { u as w } from "../../chunks/useT9n.js";
9
+ const B = b`:host{display:flex;align-items:center}.status-list{display:flex;align-items:center;max-width:100%}.status-chip{max-width:100%;--calcite-color-foreground-2: var(--calcite-color-foreground-1)}.chip-group{max-width:100%;min-width:0}.status-chip__label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.popover-content{max-width:28rem;padding:.75rem}.clear-button{margin-inline-start:.25rem}`;
10
+ class v extends m {
11
+ constructor() {
12
+ super(...arguments), this._messages = w({ name: "portal-browser", blocking: !0 }), this.inBounds = [], this.outOfBounds = [], this.filters = {}, this.hiddenFilterIds = [], this.arcgisBrowserFilterClear = d(), this.arcgisBrowserFilterRemove = d();
13
+ }
14
+ static {
15
+ this.properties = { inBounds: 16, outOfBounds: 16, filters: 0, hiddenFilterIds: 0, componentWidth: 9, browserWidth: 9 };
16
+ }
17
+ static {
18
+ this.styles = B;
19
+ }
20
+ connectedCallback() {
21
+ super.connectedCallback(), this.processValidFilters();
22
+ }
23
+ willUpdate(t) {
24
+ (t.has("filters") || t.has("hiddenFilterIds") || t.has("componentWidth") || t.has("browserWidth")) && this.processValidFilters();
25
+ }
26
+ isFilterValid(t) {
27
+ return this.hiddenFilterIds.includes(t.id) ? !1 : t.id === "collaborations" && "additionalParams" in t ? !!(t.additionalParams && t.label) : !!(t.value && t.label);
28
+ }
29
+ processValidFilters() {
30
+ const t = Object.values(this.filters).filter(this.isFilterValid.bind(this)), s = this.componentWidth ?? 0;
31
+ if ((this.browserWidth ?? window.innerWidth) < f.sm) {
32
+ this.inBounds = t, this.outOfBounds = [];
33
+ return;
34
+ }
35
+ const h = Math.max(s - 460, 0);
36
+ let a = 0;
37
+ const l = [], n = [];
38
+ t.forEach((r) => {
39
+ const c = g({ text: r.label });
40
+ !s || a + c <= h ? (l.push(r), a += c) : n.push(r);
41
+ }), this.inBounds = l, this.outOfBounds = n;
42
+ }
43
+ renderChip(t) {
44
+ return p(t.id, e`<calcite-chip class="status-chip" scale=s .label=${t.label} .value=${t.id} closable appearance=outline @calciteChipClose=${() => {
45
+ this.arcgisBrowserFilterRemove.emit(t.id);
46
+ }}><span class="status-chip__label">${t.label}</span></calcite-chip>`);
47
+ }
48
+ render() {
49
+ const t = this._messages.filterStatus, s = this.outOfBounds.length > 0, o = this.inBounds.length + this.outOfBounds.length;
50
+ return o ? e`<div class="status-list"><calcite-chip-group class="chip-group" .label=${t.filters} scale=s>${this.inBounds.map((i) => this.renderChip(i))}${s && e`<calcite-button id=popover-button round kind=neutral appearance=outline scale=s>+ ${this.outOfBounds.length}</calcite-button>` || ""}</calcite-chip-group>${s && e`<calcite-popover .label=${t.additional} reference-element=popover-button placement=bottom-end><div class="popover-content"><calcite-chip-group .label=${t.additional} scale=s>${this.outOfBounds.map((i) => this.renderChip(i))}</calcite-chip-group></div></calcite-popover>` || ""}${o > 1 && e`<calcite-button class="clear-button" scale=s appearance=transparent kind=brand @click=${() => this.arcgisBrowserFilterClear.emit(null)}>${t.clearAllFilters}</calcite-button>` || ""}</div>` : null;
51
+ }
52
+ }
53
+ u("arcgis-portal-browser-filter-status", v);
54
+ export {
55
+ v as ArcgisPortalBrowserFilterStatus
56
+ };
@@ -0,0 +1 @@
1
+ export * from "./customElement.js";
@@ -0,0 +1,5 @@
1
+ import "@esri/calcite-components/components/calcite-chip";
2
+ import "@esri/calcite-components/components/calcite-chip-group";
3
+ import "@esri/calcite-components/components/calcite-button";
4
+ import "@esri/calcite-components/components/calcite-popover";
5
+ export * from "./customElement.js";
@@ -0,0 +1,7 @@
1
+ /// <reference path="../../index.d.ts" />
2
+ import type { PublicLitElement as LitElement } from "@arcgis/lumina";
3
+ import type { PortalBrowserStore } from "../arcgis-portal-browser/utils/store.js";
4
+
5
+ export abstract class ArcgisPortalBrowserFilters extends LitElement {
6
+ accessor store: PortalBrowserStore | undefined;
7
+ }
@@ -0,0 +1,29 @@
1
+ /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
+ import { c as e } from "../../chunks/runtime.js";
3
+ import { css as o, html as r } from "lit";
4
+ import { LitElement as i, safeClassMap as l } from "@arcgis/lumina";
5
+ import { createRef as a, ref as c } from "lit/directives/ref.js";
6
+ import { b as n } from "../../chunks/ui.js";
7
+ const p = o`:host{display:block}.filters-shell{display:block}.filters-shell__top{padding:0}.filters-shell__top--padded{padding:0 1rem 1rem}`;
8
+ class d extends i {
9
+ constructor() {
10
+ super(...arguments), this._accordionRef = a();
11
+ }
12
+ static {
13
+ this.properties = { store: 0 };
14
+ }
15
+ static {
16
+ this.styles = p;
17
+ }
18
+ updated() {
19
+ this.store && this._accordionRef.value && (this.store.filterElement = this._accordionRef.value);
20
+ }
21
+ render() {
22
+ const t = this.store, s = !!t?.panel || (t?.width ?? 0) < n.sm;
23
+ return r`<div class="filters-shell" .inert=${!!t?.preview}><div class=${l({ "filters-shell__top": !0, "filters-shell__top--padded": s })}><slot name=top></slot></div><slot name=primary></slot><slot name=title></slot><calcite-accordion appearance=transparent icon-type=chevron icon-position=start scale=m ${c(this._accordionRef)}><slot></slot></calcite-accordion><slot name=bottom></slot></div>`;
24
+ }
25
+ }
26
+ e("arcgis-portal-browser-filters", d);
27
+ export {
28
+ d as ArcgisPortalBrowserFilters
29
+ };
@@ -0,0 +1 @@
1
+ export * from "./customElement.js";
@@ -0,0 +1,2 @@
1
+ import "@esri/calcite-components/components/calcite-accordion";
2
+ export * from "./customElement.js";