@atlassian/clientside-extensions-components 5.0.0 → 5.1.0-5a180d69-mdyn784a

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 (78) hide show
  1. package/dist/cjs/ExtensionPoint.js +1 -1
  2. package/dist/cjs/ExtensionPoint.js.map +1 -1
  3. package/dist/cjs/ExtensionPointInfo.js +25 -19
  4. package/dist/cjs/ExtensionPointInfo.js.map +1 -1
  5. package/dist/cjs/ExtensionsObservable.js +1 -1
  6. package/dist/cjs/ExtensionsObservable.js.map +1 -1
  7. package/dist/cjs/handlers/AsyncPanelHandler.js +1 -1
  8. package/dist/cjs/handlers/AsyncPanelHandler.js.map +1 -1
  9. package/dist/cjs/handlers/ButtonHandler.js +2 -2
  10. package/dist/cjs/handlers/ButtonHandler.js.map +1 -1
  11. package/dist/cjs/handlers/LinkHandler.js +2 -2
  12. package/dist/cjs/handlers/LinkHandler.js.map +1 -1
  13. package/dist/cjs/handlers/ModalHandler.js +5 -5
  14. package/dist/cjs/handlers/ModalHandler.js.map +1 -1
  15. package/dist/cjs/handlers/PanelHandler.js +1 -1
  16. package/dist/cjs/handlers/PanelHandler.js.map +1 -1
  17. package/dist/cjs/handlers/SectionHandler.js +1 -1
  18. package/dist/cjs/handlers/SectionHandler.js.map +1 -1
  19. package/dist/cjs/index.js +10 -10
  20. package/dist/cjs/index.js.map +1 -1
  21. package/dist/cjs/renderElementAsReact.js +4 -3
  22. package/dist/cjs/renderElementAsReact.js.map +1 -1
  23. package/dist/cjs/styled.js +15 -45
  24. package/dist/cjs/styled.js.map +1 -1
  25. package/dist/cjs/types.js +1 -2
  26. package/dist/cjs/types.js.map +1 -1
  27. package/dist/cjs/useExtensions.js +1 -1
  28. package/dist/cjs/useExtensions.js.map +1 -1
  29. package/dist/cjs/useWebPanelRenderer.js.map +1 -1
  30. package/dist/esm/ExtensionPoint.js.map +1 -1
  31. package/dist/esm/ExtensionPointInfo.js +24 -18
  32. package/dist/esm/ExtensionPointInfo.js.map +1 -1
  33. package/dist/esm/ExtensionsObservable.js.map +1 -1
  34. package/dist/esm/handlers/AsyncPanelHandler.js.map +1 -1
  35. package/dist/esm/handlers/ButtonHandler.js.map +1 -1
  36. package/dist/esm/handlers/LinkHandler.js.map +1 -1
  37. package/dist/esm/handlers/ModalHandler.js +5 -5
  38. package/dist/esm/handlers/ModalHandler.js.map +1 -1
  39. package/dist/esm/handlers/PanelHandler.js.map +1 -1
  40. package/dist/esm/renderElementAsReact.js +3 -2
  41. package/dist/esm/renderElementAsReact.js.map +1 -1
  42. package/dist/esm/styled.js +13 -43
  43. package/dist/esm/styled.js.map +1 -1
  44. package/dist/esm/useExtensions.js.map +1 -1
  45. package/dist/esm/useWebPanelRenderer.js.map +1 -1
  46. package/dist/types/ExtensionPointInfo.d.ts +1 -1
  47. package/dist/types/ExtensionPointInfo.d.ts.map +1 -1
  48. package/dist/types/ExtensionsObservable.d.ts.map +1 -1
  49. package/dist/types/debug/types.d.ts +1 -1
  50. package/dist/types/debug/types.d.ts.map +1 -1
  51. package/dist/types/debug/useDebug.d.ts.map +1 -1
  52. package/dist/types/debug/useDiscovery.d.ts.map +1 -1
  53. package/dist/types/debug/useLogging.d.ts.map +1 -1
  54. package/dist/types/debug/useValidation.d.ts.map +1 -1
  55. package/dist/types/handlers/AsyncPanelHandler.d.ts +1 -1
  56. package/dist/types/handlers/AsyncPanelHandler.d.ts.map +1 -1
  57. package/dist/types/handlers/ModalHandler.d.ts +1 -1
  58. package/dist/types/handlers/ModalHandler.d.ts.map +1 -1
  59. package/dist/types/renderElementAsReact.d.ts.map +1 -1
  60. package/dist/types/styled.d.ts +19 -15
  61. package/dist/types/styled.d.ts.map +1 -1
  62. package/dist/types/types.d.ts +4 -4
  63. package/dist/types/types.d.ts.map +1 -1
  64. package/dist/types/useExtensions.d.ts.map +1 -1
  65. package/lib/ExtensionPoint.test.tsx +1 -1
  66. package/lib/ExtensionPointInfo.test.tsx +1 -1
  67. package/lib/ExtensionPointInfo.tsx +48 -30
  68. package/lib/ExtensionsObservable.test.ts +1 -1
  69. package/lib/__snapshots__/ExtensionPointInfo.test.tsx.snap +203 -123
  70. package/lib/debug/useDebug.test.ts +2 -2
  71. package/lib/debug/useDiscovery.test.ts +2 -2
  72. package/lib/debug/useLogging.test.ts +2 -2
  73. package/lib/debug/useValidation.test.ts +2 -2
  74. package/lib/handlers/ModalHandler.tsx +8 -8
  75. package/lib/renderElementAsReact.tsx +7 -2
  76. package/lib/styled.ts +14 -45
  77. package/lib/useExtensions.test.ts +49 -43
  78. package/package.json +16 -15
@@ -1 +1 @@
1
- {"version":3,"file":"ModalHandler.d.ts","sourceRoot":"","sources":["../../../lib/handlers/ModalHandler.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAK1D,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAuB9C,MAAM,WAAW,iBAAiB;IAC9B,MAAM,EAAE,cAAc,CAAC,oBAAoB,CAAC;IAC5C,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,eAAO,MAAM,YAAY,EAAE,iBAAiB,CAAC,iBAAiB,CA0D7D,CAAC;AAEF,MAAM,WAAW,2BAA4B,SAAQ,IAAI,CAAC,cAAc,EAAE,UAAU,CAAC;IACjF,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,MAAM,EAAE,cAAc,CAAC,oBAAoB,CAAC;IAC5C,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,eAAO,MAAM,sBAAsB,EAAE,iBAAiB,CAAC,2BAA2B,CAmDjF,CAAC"}
1
+ {"version":3,"file":"ModalHandler.d.ts","sourceRoot":"","sources":["../../../lib/handlers/ModalHandler.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,KAAK,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAG1D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAsB9C,MAAM,WAAW,iBAAiB;IAC9B,MAAM,EAAE,cAAc,CAAC,oBAAoB,CAAC;IAC5C,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,eAAO,MAAM,YAAY,EAAE,iBAAiB,CAAC,iBAAiB,CA0D7D,CAAC;AAEF,MAAM,WAAW,2BAA4B,SAAQ,IAAI,CAAC,cAAc,EAAE,UAAU,CAAC;IACjF,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,MAAM,EAAE,cAAc,CAAC,oBAAoB,CAAC;IAC5C,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAChC;AAED,eAAO,MAAM,sBAAsB,EAAE,iBAAiB,CAAC,2BAA2B,CAmDjF,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"renderElementAsReact.d.ts","sourceRoot":"","sources":["../../lib/renderElementAsReact.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kCAAkC,CAAC;AAE3E,iBAAS,oBAAoB,CAAC,MAAM,SAAS,KAAK,CAAC,GAAG,CAAC,mBAAmB,EACtE,SAAS,EAAE,kBAAkB,EAC7B,aAAa,EAAE,aAAa,CAAC,MAAM,CAAC,EACpC,eAAe,CAAC,EAAE,OAAO,QAU5B;AAED,eAAe,oBAAoB,CAAC"}
1
+ {"version":3,"file":"renderElementAsReact.d.ts","sourceRoot":"","sources":["../../lib/renderElementAsReact.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,KAAqB,MAAM,OAAO,CAAC;AAC1C,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kCAAkC,CAAC;AAE3E,iBAAS,oBAAoB,CAAC,MAAM,SAAS,KAAK,CAAC,GAAG,CAAC,mBAAmB,EACtE,SAAS,EAAE,kBAAkB,EAC7B,aAAa,EAAE,aAAa,CAAC,MAAM,CAAC,EACpC,eAAe,CAAC,EAAE,OAAO,QAe5B;AAED,eAAe,oBAAoB,CAAC"}
@@ -1,30 +1,34 @@
1
- /// <reference types="react" />
1
+ export declare const GRID_SIZE = 8;
2
2
  export declare const BlinkerContainer: import("@emotion/styled").StyledComponent<{
3
- theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
3
+ theme?: import("@emotion/react").Theme;
4
+ as?: React.ElementType;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
6
6
  export declare const Blinker: import("@emotion/styled").StyledComponent<{
7
- theme?: import("@emotion/react").Theme | undefined;
8
- as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
7
+ theme?: import("@emotion/react").Theme;
8
+ as?: React.ElementType;
9
9
  }, import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {}>;
10
10
  export declare const Table: import("@emotion/styled").StyledComponent<{
11
- theme?: import("@emotion/react").Theme | undefined;
12
- as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
11
+ theme?: import("@emotion/react").Theme;
12
+ as?: React.ElementType;
13
13
  }, import("react").DetailedHTMLProps<import("react").TableHTMLAttributes<HTMLTableElement>, HTMLTableElement>, {}>;
14
14
  export declare const HeadRow: import("@emotion/styled").StyledComponent<{
15
- theme?: import("@emotion/react").Theme | undefined;
16
- as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
15
+ theme?: import("@emotion/react").Theme;
16
+ as?: React.ElementType;
17
17
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLTableRowElement>, HTMLTableRowElement>, {}>;
18
18
  export declare const HeadCell: import("@emotion/styled").StyledComponent<{
19
- theme?: import("@emotion/react").Theme | undefined;
20
- as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
19
+ theme?: import("@emotion/react").Theme;
20
+ as?: React.ElementType;
21
21
  }, import("react").DetailedHTMLProps<import("react").ThHTMLAttributes<HTMLTableHeaderCellElement>, HTMLTableHeaderCellElement>, {}>;
22
22
  export declare const TableRow: import("@emotion/styled").StyledComponent<{
23
- theme?: import("@emotion/react").Theme | undefined;
24
- as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
23
+ theme?: import("@emotion/react").Theme;
24
+ as?: React.ElementType;
25
25
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLTableRowElement>, HTMLTableRowElement>, {}>;
26
26
  export declare const TableCell: import("@emotion/styled").StyledComponent<{
27
- theme?: import("@emotion/react").Theme | undefined;
28
- as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
27
+ theme?: import("@emotion/react").Theme;
28
+ as?: React.ElementType;
29
29
  }, import("react").DetailedHTMLProps<import("react").TdHTMLAttributes<HTMLTableDataCellElement>, HTMLTableDataCellElement>, {}>;
30
+ export declare const HeadingWrapper: import("@emotion/styled").StyledComponent<{
31
+ theme?: import("@emotion/react").Theme;
32
+ as?: React.ElementType;
33
+ }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
30
34
  //# sourceMappingURL=styled.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"styled.d.ts","sourceRoot":"","sources":["../../lib/styled.ts"],"names":[],"mappings":";AAMA,eAAO,MAAM,gBAAgB;;;2GAE5B,CAAC;AAYF,eAAO,MAAM,OAAO;;;qHAsBnB,CAAC;AAmBF,eAAO,MAAM,KAAK;;;kHAGjB,CAAC;AAEF,eAAO,MAAM,OAAO;;;mHAEnB,CAAC;AAEF,eAAO,MAAM,QAAQ;;;mIAmBpB,CAAC;AAIF,eAAO,MAAM,QAAQ;;;mHASpB,CAAC;AAEF,eAAO,MAAM,SAAS;;;+HAWrB,CAAC"}
1
+ {"version":3,"file":"styled.d.ts","sourceRoot":"","sources":["../../lib/styled.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,SAAS,IAAI,CAAC;AAE3B,eAAO,MAAM,gBAAgB;;SAmBzB,MAAI,WAAW;2GAjBlB,CAAC;AAaF,eAAO,MAAM,OAAO;;eAIZ,WAAW;qHAkBlB,CAAC;AAKF,eAAO,MAAM,KAAK;;eAvBV,WAAW;kHA0BlB,CAAC;AAEF,eAAO,MAAM,OAAO;;eA5BZ,WAAW;mHA8BlB,CAAC;AAEF,eAAO,MAAM,QAAQ;;eAhCb,WAAW;mIA0ClB,CAAC;AAEF,eAAO,MAAM,QAAQ;;eA5Cb,WAAW;mHAiDlB,CAAC;AAEF,eAAO,MAAM,SAAS;;eAnDd,WAAW;+HAuDlB,CAAC;AAEF,eAAO,MAAM,cAAc;;eAzDnB,WAAW;yGA2DlB,CAAC"}
@@ -1,13 +1,13 @@
1
1
  import type { ReactNode } from 'react';
2
2
  import type { ExtensionAttributes, ExtensionDescriptor } from '@atlassian/clientside-extensions-registry';
3
3
  import type { Validator } from '@atlassian/clientside-extensions-schema';
4
- export declare type ExtensionState<T extends ExtensionAttributes> = [ExtensionDescriptor<T>[], ExtensionDescriptor<T>[], boolean];
5
- export declare type ExtensionPointCallback<T> = (supportedDescriptors: T[], unsupportedDescriptors: T[], loading: boolean) => ReactNode;
6
- export declare type ExtensionPointState<T extends ExtensionAttributes = ExtensionAttributes> = {
4
+ export type ExtensionState<T extends ExtensionAttributes> = [ExtensionDescriptor<T>[], ExtensionDescriptor<T>[], boolean];
5
+ export type ExtensionPointCallback<T> = (supportedDescriptors: T[], unsupportedDescriptors: T[], loading: boolean) => ReactNode;
6
+ export type ExtensionPointState<T extends ExtensionAttributes = ExtensionAttributes> = {
7
7
  descriptors: ExtensionDescriptor<T>[];
8
8
  loadingState: boolean;
9
9
  };
10
- export declare type ExtensionPointUpdate<T extends ExtensionAttributes = ExtensionAttributes> = {
10
+ export type ExtensionPointUpdate<T extends ExtensionAttributes = ExtensionAttributes> = {
11
11
  state: ExtensionPointState<T>;
12
12
  update: ExtensionDescriptor<T>[];
13
13
  };
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../lib/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,mBAAmB,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAC;AAG1G,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEzE,oBAAY,cAAc,CAAC,CAAC,SAAS,mBAAmB,IAAI,CAAC,mBAAmB,CAAC,CAAC,CAAC,EAAE,EAAE,mBAAmB,CAAC,CAAC,CAAC,EAAE,EAAE,OAAO,CAAC,CAAC;AAC1H,oBAAY,sBAAsB,CAAC,CAAC,IAAI,CAAC,oBAAoB,EAAE,CAAC,EAAE,EAAE,sBAAsB,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,OAAO,KAAK,SAAS,CAAC;AAChI,oBAAY,mBAAmB,CAAC,CAAC,SAAS,mBAAmB,GAAG,mBAAmB,IAAI;IACnF,WAAW,EAAE,mBAAmB,CAAC,CAAC,CAAC,EAAE,CAAC;IACtC,YAAY,EAAE,OAAO,CAAC;CACzB,CAAC;AACF,oBAAY,oBAAoB,CAAC,CAAC,SAAS,mBAAmB,GAAG,mBAAmB,IAAI;IACpF,KAAK,EAAE,mBAAmB,CAAC,CAAC,CAAC,CAAC;IAC9B,MAAM,EAAE,mBAAmB,CAAC,CAAC,CAAC,EAAE,CAAC;CACpC,CAAC;AAEF,MAAM,WAAW,OAAO;IACpB,kBAAkB,EAAE,SAAS,CAAC;IAC9B,gBAAgB,CAAC,EAAE,SAAS,CAAC;CAChC;AAED,wBAAgB,oBAAoB,CAAC,CAAC,EAAE,KAAK,EAAE,IAAI,GAAG,SAAS,GAAG,CAAC,GAAG,KAAK,IAAI,CAAC,CAE/E"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../lib/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,mBAAmB,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAC;AAG1G,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEzE,MAAM,MAAM,cAAc,CAAC,CAAC,SAAS,mBAAmB,IAAI,CAAC,mBAAmB,CAAC,CAAC,CAAC,EAAE,EAAE,mBAAmB,CAAC,CAAC,CAAC,EAAE,EAAE,OAAO,CAAC,CAAC;AAC1H,MAAM,MAAM,sBAAsB,CAAC,CAAC,IAAI,CAAC,oBAAoB,EAAE,CAAC,EAAE,EAAE,sBAAsB,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,OAAO,KAAK,SAAS,CAAC;AAChI,MAAM,MAAM,mBAAmB,CAAC,CAAC,SAAS,mBAAmB,GAAG,mBAAmB,IAAI;IACnF,WAAW,EAAE,mBAAmB,CAAC,CAAC,CAAC,EAAE,CAAC;IACtC,YAAY,EAAE,OAAO,CAAC;CACzB,CAAC;AACF,MAAM,MAAM,oBAAoB,CAAC,CAAC,SAAS,mBAAmB,GAAG,mBAAmB,IAAI;IACpF,KAAK,EAAE,mBAAmB,CAAC,CAAC,CAAC,CAAC;IAC9B,MAAM,EAAE,mBAAmB,CAAC,CAAC,CAAC,EAAE,CAAC;CACpC,CAAC;AAEF,MAAM,WAAW,OAAO;IACpB,kBAAkB,EAAE,SAAS,CAAC;IAC9B,gBAAgB,CAAC,EAAE,SAAS,CAAC;CAChC;AAED,wBAAgB,oBAAoB,CAAC,CAAC,EAAE,KAAK,EAAE,IAAI,GAAG,SAAS,GAAG,CAAC,GAAG,KAAK,IAAI,CAAC,CAE/E"}
@@ -1 +1 @@
1
- {"version":3,"file":"useExtensions.d.ts","sourceRoot":"","sources":["../../lib/useExtensions.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,OAAO,EAAE,MAAM,2CAA2C,CAAC;AAG9F,OAAO,KAAK,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAYvD,eAAO,MAAM,gBAAgB,8HACT,MAAM,8BAEb,OAAO,gCA4BnB,CAAC;AAEF,eAAO,MAAM,aAAa,8HACN,MAAM,8BAEb,OAAO,6MAInB,CAAC;AAEF,eAAO,MAAM,wBAAwB,oHAI3B,MAAM,8BAEH,OAAO,6MAInB,CAAC;AAEF,eAAO,MAAM,yBAAyB,oHAI5B,MAAM,8BAEH,OAAO,YAInB,CAAC"}
1
+ {"version":3,"file":"useExtensions.d.ts","sourceRoot":"","sources":["../../lib/useExtensions.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,OAAO,EAAE,MAAM,2CAA2C,CAAC;AAG9F,OAAO,KAAK,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAYvD,eAAO,MAAM,gBAAgB,GAAI,QAAQ,SAAS,OAAO,CAAC,EAAE,CAAC,GAAG,IAAI,SAAS,WAAW,SAAS,mBAAmB,wCAChG,MAAM,WACb,QAAQ,WACR,OAAO,KACjB,cAAc,CAAC,WAAW,CA2B5B,CAAC;AAEF,eAAO,MAAM,aAAa,GAAI,QAAQ,SAAS,OAAO,CAAC,EAAE,CAAC,GAAG,IAAI,SAAS,WAAW,SAAS,mBAAmB,wCAC7F,MAAM,WACb,QAAQ,WACR,OAAO,6MAInB,CAAC;AAEF,eAAO,MAAM,wBAAwB,GACjC,QAAQ,SAAS,OAAO,CAAC,EAAE,CAAC,GAAG,IAAI,SACnC,WAAW,SAAS,mBAAmB,8BAEjC,MAAM,WACH,QAAQ,WACR,OAAO,6MAInB,CAAC;AAEF,eAAO,MAAM,yBAAyB,GAClC,QAAQ,SAAS,OAAO,CAAC,EAAE,CAAC,GAAG,IAAI,SACnC,WAAW,SAAS,mBAAmB,8BAEjC,MAAM,WACH,QAAQ,WACR,OAAO,YAInB,CAAC"}
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { mocked } from 'ts-jest/utils';
2
+ import { mocked } from 'jest-mock';
3
3
  import { act, render } from '@testing-library/react';
4
4
  import type { ExtensionDescriptor } from '@atlassian/clientside-extensions-registry';
5
5
  import registry from '@atlassian/clientside-extensions-registry';
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { mocked } from 'ts-jest/utils';
2
+ import { mocked } from 'jest-mock';
3
3
  import { render, fireEvent, screen, findByRole as findByRoleInContainer } from '@testing-library/react';
4
4
 
5
5
  import type { SerializedDocument } from '@atlassian/clientside-extensions-schema';
@@ -1,8 +1,9 @@
1
+ import Button from '@atlaskit/button/new';
2
+ import Heading from '@atlaskit/heading';
3
+ import Modal, { ModalFooter, ModalHeader, ModalTitle, ModalTransition } from '@atlaskit/modal-dialog';
1
4
  import type { FunctionComponent } from 'react';
2
5
  import React, { memo, useState } from 'react';
3
- import Button from '@atlaskit/button/standard-button';
4
- import Modal, { ModalTransition, ModalTitle, ModalHeader, ModalFooter } from '@atlaskit/modal-dialog';
5
- import { Link, Element } from 'react-scroll';
6
+ import { Element, Link } from 'react-scroll';
6
7
 
7
8
  import type {
8
9
  SerializedDocument,
@@ -13,9 +14,8 @@ import type {
13
14
  // We only import types here
14
15
  // eslint-disable-next-line node/no-unpublished-import
15
16
  } from '@atlassian/clientside-extensions-schema';
16
- import { gridSize } from '@atlaskit/theme/constants';
17
17
  import useDiscovery from './debug/useDiscovery';
18
- import { Table, TableCell, TableRow, HeadRow, HeadCell, Blinker, BlinkerContainer } from './styled';
18
+ import { Blinker, BlinkerContainer, GRID_SIZE, HeadCell, HeadingWrapper, HeadRow, Table, TableCell, TableRow } from './styled';
19
19
 
20
20
  export type ExtensionPointInfoProps = {
21
21
  name: string;
@@ -66,11 +66,13 @@ const TypeRenderer: FunctionComponent<{ objectType: SerializedObjectType }> = ({
66
66
 
67
67
  const EnumTypeRenderer = ({ enumType }: { enumType: SerializedEnumType }) => (
68
68
  <>
69
- <h3>
70
- {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
71
- {/* @ts-ignore: react-scroll types are not up to date with the latest react version*/}
72
- <Element id={enumType.name}>{enumType.name}</Element>
73
- </h3>
69
+ <HeadingWrapper>
70
+ <Heading size="small" as="h3">
71
+ {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
72
+ {/* @ts-ignore: react-scroll types are not up to date with the latest react version*/}
73
+ <Element id={enumType.name}>{enumType.name}</Element>
74
+ </Heading>
75
+ </HeadingWrapper>
74
76
  {enumType.description ? (
75
77
  <p>{enumType.description}</p>
76
78
  ) : (
@@ -83,11 +85,13 @@ const EnumTypeRenderer = ({ enumType }: { enumType: SerializedEnumType }) => (
83
85
 
84
86
  const UnionTypeRenderer = ({ unionType }: { unionType: SerializedUnionType }) => (
85
87
  <>
86
- <h3>
87
- {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
88
- {/* @ts-ignore: react-scroll types are not up to date with the latest react version*/}
89
- <Element id={unionType.name}>{unionType.name}</Element>
90
- </h3>
88
+ <HeadingWrapper>
89
+ <Heading size="small" as="h3">
90
+ {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
91
+ {/* @ts-ignore: react-scroll types are not up to date with the latest react version*/}
92
+ <Element id={unionType.name}>{unionType.name}</Element>
93
+ </Heading>
94
+ </HeadingWrapper>
91
95
  {unionType.description ? (
92
96
  <p>{unionType.description}</p>
93
97
  ) : (
@@ -106,11 +110,13 @@ const UnionTypeRenderer = ({ unionType }: { unionType: SerializedUnionType }) =>
106
110
 
107
111
  const ScalarRenderer = ({ scalar }: { scalar: SerializedScalar }) => (
108
112
  <>
109
- <h3>
110
- {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
111
- {/* @ts-ignore: react-scroll types are not up to date with the latest react version*/}
112
- <Element id={scalar.name}>{scalar.name}</Element>
113
- </h3>
113
+ <HeadingWrapper>
114
+ <Heading size="small" as="h3">
115
+ {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
116
+ {/* @ts-ignore: react-scroll types are not up to date with the latest react version*/}
117
+ <Element id={scalar.name}>{scalar.name}</Element>
118
+ </Heading>
119
+ </HeadingWrapper>
114
120
  <p>{scalar.description}</p>
115
121
  </>
116
122
  );
@@ -137,7 +143,9 @@ const SchemasRenderer = ({ schemaDocuments: { schema, contextSchema } }: Omit<Ex
137
143
 
138
144
  return (
139
145
  <>
140
- <h2>Attributes</h2>
146
+ <Heading size="medium" as="h2">
147
+ Attributes
148
+ </Heading>
141
149
  {attributesDocument ? (
142
150
  <>
143
151
  <p>List of attributes supported by this extension point.</p>
@@ -147,7 +155,11 @@ const SchemasRenderer = ({ schemaDocuments: { schema, contextSchema } }: Omit<Ex
147
155
  <p>No attributes information provided for this extension point.</p>
148
156
  )}
149
157
 
150
- <h2>Context</h2>
158
+ <HeadingWrapper>
159
+ <Heading size="medium" as="h2">
160
+ Context
161
+ </Heading>
162
+ </HeadingWrapper>
151
163
  {contextDocument ? (
152
164
  <>
153
165
  <p>List of values provided by this extension point as context.</p>
@@ -157,15 +169,21 @@ const SchemasRenderer = ({ schemaDocuments: { schema, contextSchema } }: Omit<Ex
157
169
  <p>No context information provided for this extension point.</p>
158
170
  )}
159
171
 
160
- <h2>Types reference</h2>
172
+ <HeadingWrapper>
173
+ <Heading size="medium" as="h2">
174
+ Types reference
175
+ </Heading>
176
+ </HeadingWrapper>
161
177
  {objectTypeEntries &&
162
178
  objectTypeEntries.map((objectType) => (
163
179
  <React.Fragment key={objectType.name}>
164
- <h3>
165
- {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
166
- {/* @ts-ignore: react-scroll types are not up to date with the latest react version*/}
167
- <Element id={objectType.name}>{objectType.name}</Element>
168
- </h3>
180
+ <HeadingWrapper>
181
+ <Heading size="small" as="h3">
182
+ {/* eslint-disable-next-line @typescript-eslint/ban-ts-comment */}
183
+ {/* @ts-ignore: react-scroll types are not up to date with the latest react version*/}
184
+ <Element id={objectType.name}>{objectType.name}</Element>
185
+ </Heading>
186
+ </HeadingWrapper>
169
187
  <TypeRenderer objectType={objectType} />
170
188
  </React.Fragment>
171
189
  ))}
@@ -184,7 +202,7 @@ const bodyStyles: React.CSSProperties = {
184
202
  overflowY: 'auto',
185
203
  overflowX: 'hidden',
186
204
  // The rest of the styles are copied from the @atlaskit/modal-dialog/dist/esm/modal-body.js
187
- padding: gridSize() * 3,
205
+ padding: GRID_SIZE * 3,
188
206
  flex: '1 1 auto',
189
207
  };
190
208
 
@@ -207,7 +225,7 @@ const ExtensionPointInfo: React.FC<ExtensionPointInfoProps> = ({ name, schemaDoc
207
225
  <ModalTransition>
208
226
  {dialogOpen && (
209
227
  <Modal onClose={closeDialog} width="x-large">
210
- <ModalHeader>
228
+ <ModalHeader hasCloseButton>
211
229
  <ModalTitle>{`Extension point: ${name}`}</ModalTitle>
212
230
  </ModalHeader>
213
231
 
@@ -1,4 +1,4 @@
1
- import { mocked } from 'ts-jest/utils';
1
+ import { mocked } from 'jest-mock';
2
2
  import registry from '@atlassian/clientside-extensions-registry';
3
3
  import * as debug from '@atlassian/clientside-extensions-debug';
4
4
  import type { ExtensionAPI, ExtensionDescriptor } from '@atlassian/clientside-extensions-registry';