@fluentui/react-utilities 9.0.0-rc.4 → 9.0.0-rc.7

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.
@@ -3,14 +3,385 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
+ exports.liProperties = exports.labelProperties = exports.isFluentTrigger = exports.inputProperties = exports.imgProperties = exports.imageProperties = exports.iframeProperties = exports.htmlElementProperties = exports.getTriggerChild = exports.getRTLSafeKey = exports.getPartitionedNativeProps = exports.getNativeProps = exports.getNativeElementProps = exports.formProperties = exports.fieldsetProperties = exports.divProperties = exports.colProperties = exports.colGroupProperties = exports.clamp = exports.buttonProperties = exports.baseElementProperties = exports.baseElementEvents = exports.audioProperties = exports.applyTriggerPropsToChildren = exports.anchorProperties = exports.SSRProvider = exports.SSRContext = exports.useSSRContext = exports.useIsSSR = exports.defaultSSRContextValue = exports.canUseDOM = exports.useUnmount = exports.useTimeout = exports.usePrevious = exports.useOnScrollOutside = exports.useOnClickOutside = exports.useMount = exports.useMergedRefs = exports.useMergedEventCallbacks = exports.useIsomorphicLayoutEffect = exports.useId = exports.useForceUpdate = exports.useFirstMount = exports.useEventCallback = exports.useControllableState = exports.useConst = exports.useBoolean = exports.resetIdsForTests = exports.resolveShorthand = exports.getSlots = void 0;
7
+ exports.videoProperties = exports.trProperties = exports.thProperties = exports.textAreaProperties = exports.tdProperties = exports.tableProperties = exports.shouldPreventDefaultOnKeyDown = exports.selectProperties = exports.optionProperties = exports.omit = exports.olProperties = void 0;
6
8
 
7
- const tslib_1 = /*#__PURE__*/require("tslib");
9
+ var index_1 = /*#__PURE__*/require("./compose/index");
8
10
 
9
- tslib_1.__exportStar(require("./compose/index"), exports);
11
+ Object.defineProperty(exports, "getSlots", {
12
+ enumerable: true,
13
+ get: function () {
14
+ return index_1.getSlots;
15
+ }
16
+ });
17
+ Object.defineProperty(exports, "resolveShorthand", {
18
+ enumerable: true,
19
+ get: function () {
20
+ return index_1.resolveShorthand;
21
+ }
22
+ });
23
+
24
+ var index_2 = /*#__PURE__*/require("./hooks/index");
25
+
26
+ Object.defineProperty(exports, "resetIdsForTests", {
27
+ enumerable: true,
28
+ get: function () {
29
+ return index_2.resetIdsForTests;
30
+ }
31
+ });
32
+ Object.defineProperty(exports, "useBoolean", {
33
+ enumerable: true,
34
+ get: function () {
35
+ return index_2.useBoolean;
36
+ }
37
+ });
38
+ Object.defineProperty(exports, "useConst", {
39
+ enumerable: true,
40
+ get: function () {
41
+ return index_2.useConst;
42
+ }
43
+ });
44
+ Object.defineProperty(exports, "useControllableState", {
45
+ enumerable: true,
46
+ get: function () {
47
+ return index_2.useControllableState;
48
+ }
49
+ });
50
+ Object.defineProperty(exports, "useEventCallback", {
51
+ enumerable: true,
52
+ get: function () {
53
+ return index_2.useEventCallback;
54
+ }
55
+ });
56
+ Object.defineProperty(exports, "useFirstMount", {
57
+ enumerable: true,
58
+ get: function () {
59
+ return index_2.useFirstMount;
60
+ }
61
+ });
62
+ Object.defineProperty(exports, "useForceUpdate", {
63
+ enumerable: true,
64
+ get: function () {
65
+ return index_2.useForceUpdate;
66
+ }
67
+ });
68
+ Object.defineProperty(exports, "useId", {
69
+ enumerable: true,
70
+ get: function () {
71
+ return index_2.useId;
72
+ }
73
+ });
74
+ Object.defineProperty(exports, "useIsomorphicLayoutEffect", {
75
+ enumerable: true,
76
+ get: function () {
77
+ return index_2.useIsomorphicLayoutEffect;
78
+ }
79
+ });
80
+ Object.defineProperty(exports, "useMergedEventCallbacks", {
81
+ enumerable: true,
82
+ get: function () {
83
+ return index_2.useMergedEventCallbacks;
84
+ }
85
+ });
86
+ Object.defineProperty(exports, "useMergedRefs", {
87
+ enumerable: true,
88
+ get: function () {
89
+ return index_2.useMergedRefs;
90
+ }
91
+ });
92
+ Object.defineProperty(exports, "useMount", {
93
+ enumerable: true,
94
+ get: function () {
95
+ return index_2.useMount;
96
+ }
97
+ });
98
+ Object.defineProperty(exports, "useOnClickOutside", {
99
+ enumerable: true,
100
+ get: function () {
101
+ return index_2.useOnClickOutside;
102
+ }
103
+ });
104
+ Object.defineProperty(exports, "useOnScrollOutside", {
105
+ enumerable: true,
106
+ get: function () {
107
+ return index_2.useOnScrollOutside;
108
+ }
109
+ });
110
+ Object.defineProperty(exports, "usePrevious", {
111
+ enumerable: true,
112
+ get: function () {
113
+ return index_2.usePrevious;
114
+ }
115
+ });
116
+ Object.defineProperty(exports, "useTimeout", {
117
+ enumerable: true,
118
+ get: function () {
119
+ return index_2.useTimeout;
120
+ }
121
+ });
122
+ Object.defineProperty(exports, "useUnmount", {
123
+ enumerable: true,
124
+ get: function () {
125
+ return index_2.useUnmount;
126
+ }
127
+ });
128
+
129
+ var index_3 = /*#__PURE__*/require("./ssr/index");
130
+
131
+ Object.defineProperty(exports, "canUseDOM", {
132
+ enumerable: true,
133
+ get: function () {
134
+ return index_3.canUseDOM;
135
+ }
136
+ });
137
+ Object.defineProperty(exports, "defaultSSRContextValue", {
138
+ enumerable: true,
139
+ get: function () {
140
+ return index_3.defaultSSRContextValue;
141
+ }
142
+ });
143
+ Object.defineProperty(exports, "useIsSSR", {
144
+ enumerable: true,
145
+ get: function () {
146
+ return index_3.useIsSSR;
147
+ }
148
+ });
149
+ Object.defineProperty(exports, "useSSRContext", {
150
+ enumerable: true,
151
+ get: function () {
152
+ return index_3.useSSRContext;
153
+ }
154
+ });
155
+ Object.defineProperty(exports, "SSRContext", {
156
+ enumerable: true,
157
+ get: function () {
158
+ return index_3.SSRContext;
159
+ }
160
+ });
161
+ Object.defineProperty(exports, "SSRProvider", {
162
+ enumerable: true,
163
+ get: function () {
164
+ return index_3.SSRProvider;
165
+ }
166
+ });
10
167
 
11
- tslib_1.__exportStar(require("./hooks/index"), exports);
168
+ var index_4 = /*#__PURE__*/require("./utils/index");
12
169
 
13
- tslib_1.__exportStar(require("./ssr/index"), exports);
170
+ Object.defineProperty(exports, "anchorProperties", {
171
+ enumerable: true,
172
+ get: function () {
173
+ return index_4.anchorProperties;
174
+ }
175
+ });
176
+ Object.defineProperty(exports, "applyTriggerPropsToChildren", {
177
+ enumerable: true,
178
+ get: function () {
179
+ return index_4.applyTriggerPropsToChildren;
180
+ }
181
+ });
182
+ Object.defineProperty(exports, "audioProperties", {
183
+ enumerable: true,
184
+ get: function () {
185
+ return index_4.audioProperties;
186
+ }
187
+ });
188
+ Object.defineProperty(exports, "baseElementEvents", {
189
+ enumerable: true,
190
+ get: function () {
191
+ return index_4.baseElementEvents;
192
+ }
193
+ });
194
+ Object.defineProperty(exports, "baseElementProperties", {
195
+ enumerable: true,
196
+ get: function () {
197
+ return index_4.baseElementProperties;
198
+ }
199
+ });
200
+ Object.defineProperty(exports, "buttonProperties", {
201
+ enumerable: true,
202
+ get: function () {
203
+ return index_4.buttonProperties;
204
+ }
205
+ });
206
+ Object.defineProperty(exports, "clamp", {
207
+ enumerable: true,
208
+ get: function () {
209
+ return index_4.clamp;
210
+ }
211
+ });
212
+ Object.defineProperty(exports, "colGroupProperties", {
213
+ enumerable: true,
214
+ get: function () {
215
+ return index_4.colGroupProperties;
216
+ }
217
+ });
218
+ Object.defineProperty(exports, "colProperties", {
219
+ enumerable: true,
220
+ get: function () {
221
+ return index_4.colProperties;
222
+ }
223
+ });
224
+ Object.defineProperty(exports, "divProperties", {
225
+ enumerable: true,
226
+ get: function () {
227
+ return index_4.divProperties;
228
+ }
229
+ });
230
+ Object.defineProperty(exports, "fieldsetProperties", {
231
+ enumerable: true,
232
+ get: function () {
233
+ return index_4.fieldsetProperties;
234
+ }
235
+ });
236
+ Object.defineProperty(exports, "formProperties", {
237
+ enumerable: true,
238
+ get: function () {
239
+ return index_4.formProperties;
240
+ }
241
+ });
242
+ Object.defineProperty(exports, "getNativeElementProps", {
243
+ enumerable: true,
244
+ get: function () {
245
+ return index_4.getNativeElementProps;
246
+ }
247
+ });
248
+ Object.defineProperty(exports, "getNativeProps", {
249
+ enumerable: true,
250
+ get: function () {
251
+ return index_4.getNativeProps;
252
+ }
253
+ });
254
+ Object.defineProperty(exports, "getPartitionedNativeProps", {
255
+ enumerable: true,
256
+ get: function () {
257
+ return index_4.getPartitionedNativeProps;
258
+ }
259
+ });
260
+ Object.defineProperty(exports, "getRTLSafeKey", {
261
+ enumerable: true,
262
+ get: function () {
263
+ return index_4.getRTLSafeKey;
264
+ }
265
+ });
266
+ Object.defineProperty(exports, "getTriggerChild", {
267
+ enumerable: true,
268
+ get: function () {
269
+ return index_4.getTriggerChild;
270
+ }
271
+ });
272
+ Object.defineProperty(exports, "htmlElementProperties", {
273
+ enumerable: true,
274
+ get: function () {
275
+ return index_4.htmlElementProperties;
276
+ }
277
+ });
278
+ Object.defineProperty(exports, "iframeProperties", {
279
+ enumerable: true,
280
+ get: function () {
281
+ return index_4.iframeProperties;
282
+ }
283
+ }); // eslint-disable-next-line deprecation/deprecation
14
284
 
15
- tslib_1.__exportStar(require("./utils/index"), exports);
285
+ Object.defineProperty(exports, "imageProperties", {
286
+ enumerable: true,
287
+ get: function () {
288
+ return index_4.imageProperties;
289
+ }
290
+ });
291
+ Object.defineProperty(exports, "imgProperties", {
292
+ enumerable: true,
293
+ get: function () {
294
+ return index_4.imgProperties;
295
+ }
296
+ });
297
+ Object.defineProperty(exports, "inputProperties", {
298
+ enumerable: true,
299
+ get: function () {
300
+ return index_4.inputProperties;
301
+ }
302
+ });
303
+ Object.defineProperty(exports, "isFluentTrigger", {
304
+ enumerable: true,
305
+ get: function () {
306
+ return index_4.isFluentTrigger;
307
+ }
308
+ });
309
+ Object.defineProperty(exports, "labelProperties", {
310
+ enumerable: true,
311
+ get: function () {
312
+ return index_4.labelProperties;
313
+ }
314
+ });
315
+ Object.defineProperty(exports, "liProperties", {
316
+ enumerable: true,
317
+ get: function () {
318
+ return index_4.liProperties;
319
+ }
320
+ });
321
+ Object.defineProperty(exports, "olProperties", {
322
+ enumerable: true,
323
+ get: function () {
324
+ return index_4.olProperties;
325
+ }
326
+ });
327
+ Object.defineProperty(exports, "omit", {
328
+ enumerable: true,
329
+ get: function () {
330
+ return index_4.omit;
331
+ }
332
+ });
333
+ Object.defineProperty(exports, "optionProperties", {
334
+ enumerable: true,
335
+ get: function () {
336
+ return index_4.optionProperties;
337
+ }
338
+ });
339
+ Object.defineProperty(exports, "selectProperties", {
340
+ enumerable: true,
341
+ get: function () {
342
+ return index_4.selectProperties;
343
+ }
344
+ });
345
+ Object.defineProperty(exports, "shouldPreventDefaultOnKeyDown", {
346
+ enumerable: true,
347
+ get: function () {
348
+ return index_4.shouldPreventDefaultOnKeyDown;
349
+ }
350
+ });
351
+ Object.defineProperty(exports, "tableProperties", {
352
+ enumerable: true,
353
+ get: function () {
354
+ return index_4.tableProperties;
355
+ }
356
+ });
357
+ Object.defineProperty(exports, "tdProperties", {
358
+ enumerable: true,
359
+ get: function () {
360
+ return index_4.tdProperties;
361
+ }
362
+ });
363
+ Object.defineProperty(exports, "textAreaProperties", {
364
+ enumerable: true,
365
+ get: function () {
366
+ return index_4.textAreaProperties;
367
+ }
368
+ });
369
+ Object.defineProperty(exports, "thProperties", {
370
+ enumerable: true,
371
+ get: function () {
372
+ return index_4.thProperties;
373
+ }
374
+ });
375
+ Object.defineProperty(exports, "trProperties", {
376
+ enumerable: true,
377
+ get: function () {
378
+ return index_4.trProperties;
379
+ }
380
+ });
381
+ Object.defineProperty(exports, "videoProperties", {
382
+ enumerable: true,
383
+ get: function () {
384
+ return index_4.videoProperties;
385
+ }
386
+ });
16
387
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["index.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,iBAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,eAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,aAAA,CAAA,EAAA,OAAA;;AACA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,eAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './compose/index';\nexport * from './hooks/index';\nexport * from './ssr/index';\nexport * from './utils/index';\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["index.ts"],"names":[],"mappings":";;;;;;;;AAAA,IAAA,OAAA,gBAAA,OAAA,CAAA,iBAAA,CAAA;;AAAS,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,UAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,QAAA;AAAQ;AAAR,CAAA;AAAU,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,kBAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,gBAAA;AAAgB;AAAhB,CAAA;;AAsBnB,IAAA,OAAA,gBAAA,OAAA,CAAA,eAAA,CAAA;;AACE,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,kBAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,gBAAA;AAAgB;AAAhB,CAAA;AACA,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,YAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,UAAA;AAAU;AAAV,CAAA;AACA,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,UAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,QAAA;AAAQ;AAAR,CAAA;AACA,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,sBAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,oBAAA;AAAoB;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B,CAAA;AACA,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,cAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,YAAA;AAAY;AAAZ,CAAA;AACA,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,cAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,YAAA;AAAY;AAAZ,CAAA;AACA,MAAA,CAAA,cAAA,CAAA,OAAA,EAAA,iBAAA,EAAA;AAAA,EAAA,UAAA,EAAA,IAAA;AAAA,EAAA,GAAA,EAAA,YAAA;AAAA,WAAA,OAAA,CAAA,eAAA;AAAe;AAAf,CAAA","sourcesContent":["export { getSlots, resolveShorthand } from './compose/index';\nexport type {\n AsIntrinsicElement,\n ComponentProps,\n ComponentState,\n ExtractSlotProps,\n ForwardRefComponent,\n IsSingleton,\n PropsWithoutRef,\n ReplaceNullWithUndefined,\n ResolveShorthandFunction,\n ResolveShorthandOptions,\n Slot,\n Slots,\n SlotClassNames,\n SlotPropsRecord,\n SlotRenderFunction,\n SlotShorthandValue,\n UnionToIntersection,\n UnknownSlotProps,\n} from './compose/index';\n\nexport {\n resetIdsForTests,\n useBoolean,\n useConst,\n useControllableState,\n useEventCallback,\n useFirstMount,\n useForceUpdate,\n useId,\n useIsomorphicLayoutEffect,\n useMergedEventCallbacks,\n useMergedRefs,\n useMount,\n useOnClickOutside,\n useOnScrollOutside,\n usePrevious,\n useTimeout,\n useUnmount,\n} from './hooks/index';\nexport type {\n RefObjectFunction,\n UseBooleanCallbacks,\n UseControllableStateOptions,\n UseOnClickOrScrollOutsideOptions,\n} from './hooks/index';\n\nexport { canUseDOM, defaultSSRContextValue, useIsSSR, useSSRContext, SSRContext, SSRProvider } from './ssr/index';\nexport type { SSRContextValue } from './ssr/index';\n\nexport {\n anchorProperties,\n applyTriggerPropsToChildren,\n audioProperties,\n baseElementEvents,\n baseElementProperties,\n buttonProperties,\n clamp,\n colGroupProperties,\n colProperties,\n divProperties,\n fieldsetProperties,\n formProperties,\n getNativeElementProps,\n getNativeProps,\n getPartitionedNativeProps,\n getRTLSafeKey,\n getTriggerChild,\n htmlElementProperties,\n iframeProperties,\n // eslint-disable-next-line deprecation/deprecation\n imageProperties,\n imgProperties,\n inputProperties,\n isFluentTrigger,\n labelProperties,\n liProperties,\n olProperties,\n omit,\n optionProperties,\n selectProperties,\n shouldPreventDefaultOnKeyDown,\n tableProperties,\n tdProperties,\n textAreaProperties,\n thProperties,\n trProperties,\n videoProperties,\n} from './utils/index';\nexport type { FluentTriggerComponent } from './utils/index';\n"],"sourceRoot":"../src/"}
@@ -14,6 +14,10 @@ const keyboard_keys_1 = /*#__PURE__*/require("@fluentui/keyboard-keys");
14
14
 
15
15
 
16
16
  function shouldPreventDefaultOnKeyDown(e) {
17
+ if (e.defaultPrevented) {
18
+ return false;
19
+ }
20
+
17
21
  const key = e.key;
18
22
  const target = e.target;
19
23
  const matchesByKey = key === keyboard_keys_1.Space || key === keyboard_keys_1.Enter;
@@ -1 +1 @@
1
- {"version":3,"sources":["utils/shouldPreventDefaultOnKeyDown.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,eAAA,gBAAA,OAAA,CAAA,yBAAA,CAAA;AAGA;;;;AAIG;;;AACH,SAAgB,6BAAhB,CAA8C,CAA9C,EAAoF;AAClF,QAAM,GAAG,GAAG,CAAC,CAAC,GAAd;AACA,QAAM,MAAM,GAA4B,CAAC,CAAC,MAA1C;AAEA,QAAM,YAAY,GAAG,GAAG,KAAK,eAAA,CAAA,KAAR,IAAiB,GAAG,KAAK,eAAA,CAAA,KAA9C;;AAEA,MAAI,CAAA,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAM,KAAA,CAAN,GAAA,MAAM,CAAE,OAAR,MAAoB,GAAxB,EAA6B;AAC3B,WAAO,GAAG,KAAK,eAAA,CAAA,KAAf;AACD;;AAED,QAAM,YAAY,GAChB,CAAA,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAM,KAAA,CAAN,GAAA,MAAM,CAAE,OAAR,MAAoB,OAApB,IAA+B,CAAA,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAM,KAAA,CAAN,GAAA,MAAM,CAAE,OAAR,MAAoB,UAAnD,IAAiE,CAAA,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAM,KAAA,CAAN,GAAA,MAAM,CAAE,iBAAR,MAA8B,IADjG;AAGA,SAAO,YAAY,IAAI,CAAC,YAAxB;AACD;;AAdD,OAAA,CAAA,6BAAA,GAAA,6BAAA","sourcesContent":["import { Space, Enter } from '@fluentui/keyboard-keys';\nimport * as React from 'react';\n\n/**\n * Checks if the keyboard event should preventDefault() for Enter and Spacebar keys\n *\n * Useful for situations where a keydown needs to be transformed to a click event\n */\nexport function shouldPreventDefaultOnKeyDown(e: KeyboardEvent | React.KeyboardEvent) {\n const key = e.key;\n const target: HTMLElement | undefined = e.target as HTMLElement;\n\n const matchesByKey = key === Space || key === Enter;\n\n if (target?.tagName === 'A') {\n return key === Space;\n }\n\n const ignoredByTag =\n target?.tagName === 'INPUT' || target?.tagName === 'TEXTAREA' || target?.isContentEditable === true;\n\n return matchesByKey && !ignoredByTag;\n}\n"],"sourceRoot":"../src/"}
1
+ {"version":3,"sources":["utils/shouldPreventDefaultOnKeyDown.ts"],"names":[],"mappings":";;;;;;;AAAA,MAAA,eAAA,gBAAA,OAAA,CAAA,yBAAA,CAAA;AAGA;;;;AAIG;;;AACH,SAAgB,6BAAhB,CAA8C,CAA9C,EAAoF;AAClF,MAAI,CAAC,CAAC,gBAAN,EAAwB;AACtB,WAAO,KAAP;AACD;;AAED,QAAM,GAAG,GAAG,CAAC,CAAC,GAAd;AACA,QAAM,MAAM,GAA4B,CAAC,CAAC,MAA1C;AAEA,QAAM,YAAY,GAAG,GAAG,KAAK,eAAA,CAAA,KAAR,IAAiB,GAAG,KAAK,eAAA,CAAA,KAA9C;;AAEA,MAAI,CAAA,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAM,KAAA,CAAN,GAAA,MAAM,CAAE,OAAR,MAAoB,GAAxB,EAA6B;AAC3B,WAAO,GAAG,KAAK,eAAA,CAAA,KAAf;AACD;;AAED,QAAM,YAAY,GAChB,CAAA,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAM,KAAA,CAAN,GAAA,MAAM,CAAE,OAAR,MAAoB,OAApB,IAA+B,CAAA,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAM,KAAA,CAAN,GAAA,MAAM,CAAE,OAAR,MAAoB,UAAnD,IAAiE,CAAA,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAM,KAAA,CAAN,GAAA,MAAM,CAAE,iBAAR,MAA8B,IADjG;AAGA,SAAO,YAAY,IAAI,CAAC,YAAxB;AACD;;AAlBD,OAAA,CAAA,6BAAA,GAAA,6BAAA","sourcesContent":["import { Space, Enter } from '@fluentui/keyboard-keys';\nimport * as React from 'react';\n\n/**\n * Checks if the keyboard event should preventDefault() for Enter and Spacebar keys\n *\n * Useful for situations where a keydown needs to be transformed to a click event\n */\nexport function shouldPreventDefaultOnKeyDown(e: KeyboardEvent | React.KeyboardEvent) {\n if (e.defaultPrevented) {\n return false;\n }\n\n const key = e.key;\n const target: HTMLElement | undefined = e.target as HTMLElement;\n\n const matchesByKey = key === Space || key === Enter;\n\n if (target?.tagName === 'A') {\n return key === Space;\n }\n\n const ignoredByTag =\n target?.tagName === 'INPUT' || target?.tagName === 'TEXTAREA' || target?.isContentEditable === true;\n\n return matchesByKey && !ignoredByTag;\n}\n"],"sourceRoot":"../src/"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluentui/react-utilities",
3
- "version": "9.0.0-rc.4",
3
+ "version": "9.0.0-rc.7",
4
4
  "description": "A set of general React-specific utilities.",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "module": "lib/index.js",
@@ -20,20 +20,16 @@
20
20
  "lint": "just-scripts lint",
21
21
  "test": "jest --passWithNoTests",
22
22
  "docs": "api-extractor run --config=config/api-extractor.local.json --local",
23
- "build:local": "tsc -p ./tsconfig.lib.json --module esnext --emitDeclarationOnly && node ../../scripts/typescript/normalize-import --output ./dist/packages/react-utilities/src && yarn docs",
23
+ "build:local": "tsc -p ./tsconfig.lib.json --module esnext --emitDeclarationOnly && node ../../../scripts/typescript/normalize-import --output ./dist/packages/react-components/react-utilities/src && yarn docs",
24
24
  "start": "yarn storybook",
25
25
  "type-check": "tsc -b tsconfig.json"
26
26
  },
27
27
  "devDependencies": {
28
28
  "@fluentui/eslint-plugin": "*",
29
- "@fluentui/scripts": "^1.0.0",
30
- "@types/react": "16.9.42",
31
- "@types/react-test-renderer": "^16.0.0",
32
- "react": "16.8.6",
33
- "react-test-renderer": "^16.3.0"
29
+ "@fluentui/scripts": "^1.0.0"
34
30
  },
35
31
  "dependencies": {
36
- "@fluentui/keyboard-keys": "9.0.0-rc.3",
32
+ "@fluentui/keyboard-keys": "9.0.0-rc.5",
37
33
  "tslib": "^2.1.0"
38
34
  },
39
35
  "peerDependencies": {
@@ -46,5 +42,12 @@
46
42
  "minor",
47
43
  "patch"
48
44
  ]
45
+ },
46
+ "exports": {
47
+ ".": {
48
+ "types": "./lib/index.d.ts",
49
+ "import": "./lib/index.js",
50
+ "require": "./lib-commonjs/index.js"
51
+ }
49
52
  }
50
53
  }