@atlaskit/dropdown-menu 11.8.0 → 11.8.1

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @atlaskit/dropdown-menu
2
2
 
3
+ ## 11.8.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`41fae2c6f68`](https://bitbucket.org/atlassian/atlassian-frontend/commits/41fae2c6f68) - Upgrade Typescript from `4.5.5` to `4.9.5`
8
+
3
9
  ## 11.8.0
4
10
 
5
11
  ### Minor Changes
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/dropdown-menu",
3
- "version": "11.8.0",
3
+ "version": "11.8.1",
4
4
  "sideEffects": false
5
5
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/dropdown-menu",
3
- "version": "11.8.0",
3
+ "version": "11.8.1",
4
4
  "sideEffects": false
5
5
  }
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/dropdown-menu",
3
- "version": "11.8.0",
3
+ "version": "11.8.1",
4
4
  "sideEffects": false
5
5
  }
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
- declare type OptionsInGroup = {
2
+ type OptionsInGroup = {
3
3
  [key: string]: boolean | undefined;
4
4
  };
5
- declare type SelectionStoreContextProps = {
5
+ type SelectionStoreContextProps = {
6
6
  setItemState: (group: string, id: string, value: boolean | undefined) => void;
7
7
  getItemState: (group: string, id: string) => boolean | undefined;
8
8
  setGroupState: (group: string, value: OptionsInGroup) => void;
@@ -15,7 +15,7 @@ declare type SelectionStoreContextProps = {
15
15
  *
16
16
  */
17
17
  export declare const SelectionStoreContext: React.Context<SelectionStoreContextProps>;
18
- declare type SelectionStoreProps = {
18
+ type SelectionStoreProps = {
19
19
  children: React.ReactNode;
20
20
  };
21
21
  /**
@@ -1,10 +1,10 @@
1
- declare type CheckboxStateArgs = {
1
+ type CheckboxStateArgs = {
2
2
  id: string;
3
3
  isSelected: boolean | undefined;
4
4
  defaultSelected: boolean | undefined;
5
5
  };
6
- declare type SetStateCallback = (value: boolean | undefined) => boolean;
7
- declare type CheckboxStateValue = [boolean, (newValue: SetStateCallback) => void];
6
+ type SetStateCallback = (value: boolean | undefined) => boolean;
7
+ type CheckboxStateValue = [boolean, (newValue: SetStateCallback) => void];
8
8
  /**
9
9
  * Custom hook to handle checkbox state for dropdown menu.
10
10
  * It works in tandem with the selection store context when the
@@ -1,9 +1,9 @@
1
- declare type RadioStateArgs = {
1
+ type RadioStateArgs = {
2
2
  id: string;
3
3
  isSelected: boolean | undefined;
4
4
  defaultSelected: boolean | undefined;
5
5
  };
6
- declare type SetStateCallback = (value: boolean | undefined) => boolean;
7
- declare type RadioStateValue = [boolean, (newValue: SetStateCallback) => void];
6
+ type SetStateCallback = (value: boolean | undefined) => boolean;
7
+ type RadioStateValue = [boolean, (newValue: SetStateCallback) => void];
8
8
  declare function useRadioState({ id, isSelected, defaultSelected, }: RadioStateArgs): RadioStateValue;
9
9
  export default useRadioState;
@@ -1,20 +1,20 @@
1
1
  import { KeyboardEvent, MouseEvent, ReactElement, ReactNode, Ref } from 'react';
2
2
  import type { CustomItemProps, MenuGroupProps, SectionProps } from '@atlaskit/menu/types';
3
3
  import type { ContentProps, TriggerProps } from '@atlaskit/popup/types';
4
- export declare type FocusableElement = HTMLAnchorElement | HTMLButtonElement;
5
- export declare type Action = 'next' | 'prev' | 'first' | 'last';
6
- export declare type Placement = 'auto-start' | 'auto' | 'auto-end' | 'top-start' | 'top' | 'top-end' | 'right-start' | 'right' | 'right-end' | 'bottom-end' | 'bottom' | 'bottom-start' | 'left-end' | 'left' | 'left-start';
7
- export declare type ItemId = string;
8
- export declare type GroupId = string;
9
- export declare type CachedItem = {
4
+ export type FocusableElement = HTMLAnchorElement | HTMLButtonElement;
5
+ export type Action = 'next' | 'prev' | 'first' | 'last';
6
+ export type Placement = 'auto-start' | 'auto' | 'auto-end' | 'top-start' | 'top' | 'top-end' | 'right-start' | 'right' | 'right-end' | 'bottom-end' | 'bottom' | 'bottom-start' | 'left-end' | 'left' | 'left-start';
7
+ export type ItemId = string;
8
+ export type GroupId = string;
9
+ export type CachedItem = {
10
10
  id: ItemId;
11
11
  groupId: GroupId;
12
12
  };
13
- export declare type FocusItem = {
13
+ export type FocusItem = {
14
14
  itemId: ItemId;
15
15
  itemNode: HTMLElement;
16
16
  };
17
- export declare type Behaviors = 'checkbox' | 'radio' | 'menuitemcheckbox' | 'menuitemradio';
17
+ export type Behaviors = 'checkbox' | 'radio' | 'menuitemcheckbox' | 'menuitemradio';
18
18
  export interface CustomTriggerProps<TriggerElement extends HTMLElement = HTMLElement> extends Omit<TriggerProps, 'ref'> {
19
19
  /**
20
20
  * Ref that should be applied to the trigger. This is used to calculate the menu position.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/dropdown-menu",
3
- "version": "11.8.0",
3
+ "version": "11.8.1",
4
4
  "description": "A dropdown menu displays a list of actions or options to a user.",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -12,6 +12,14 @@
12
12
  "module": "dist/esm/index.js",
13
13
  "module:es2019": "dist/es2019/index.js",
14
14
  "types": "dist/types/index.d.ts",
15
+ "typesVersions": {
16
+ ">=4.5 <4.9": {
17
+ "*": [
18
+ "dist/types-ts4.5/*",
19
+ "dist/types-ts4.5/index.d.ts"
20
+ ]
21
+ }
22
+ },
15
23
  "sideEffects": false,
16
24
  "atlaskit:src": "src/index.tsx",
17
25
  "atlassian": {
@@ -31,7 +39,7 @@
31
39
  "@atlaskit/popup": "^1.6.0",
32
40
  "@atlaskit/spinner": "^15.5.0",
33
41
  "@atlaskit/theme": "^12.5.0",
34
- "@atlaskit/tokens": "^1.3.0",
42
+ "@atlaskit/tokens": "^1.4.0",
35
43
  "@atlaskit/visually-hidden": "^1.2.0",
36
44
  "@babel/runtime": "^7.0.0",
37
45
  "@emotion/react": "^11.7.1",
@@ -46,7 +54,7 @@
46
54
  "@atlaskit/docs": "*",
47
55
  "@atlaskit/ds-explorations": "^2.1.0",
48
56
  "@atlaskit/heading": "^1.3.0",
49
- "@atlaskit/lozenge": "11.4.0",
57
+ "@atlaskit/lozenge": "11.4.1",
50
58
  "@atlaskit/modal-dialog": "^12.5.0",
51
59
  "@atlaskit/primitives": "^0.9.0",
52
60
  "@atlaskit/section-message": "^6.4.0",
@@ -63,7 +71,7 @@
63
71
  "react-dom": "^16.8.0",
64
72
  "storybook-addon-performance": "^0.16.0",
65
73
  "tiny-invariant": "^1.2.0",
66
- "typescript": "4.5.5"
74
+ "typescript": "~4.9.5"
67
75
  },
68
76
  "keywords": [
69
77
  "atlaskit",
@@ -6,9 +6,9 @@
6
6
  "sideEffects": false,
7
7
  "types": "../dist/types/types.d.ts",
8
8
  "typesVersions": {
9
- ">=4.0 <4.5": {
9
+ ">=4.5 <4.9": {
10
10
  "*": [
11
- "../dist/types-ts4.0/types.d.ts"
11
+ "../dist/types-ts4.5/types.d.ts"
12
12
  ]
13
13
  }
14
14
  }