@equinor/amplify-component-lib 13.2.5-beta.0 → 13.2.5

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 (106) hide show
  1. package/dist/atoms/hooks/useLocalStorage.d.ts +2 -2
  2. package/dist/atoms/hooks/useLocalStorage.js +1 -1
  3. package/dist/atoms/hooks/useSelect.d.ts +3 -3
  4. package/dist/atoms/index.d.ts +1 -1
  5. package/dist/atoms/index.js +1 -1
  6. package/dist/atoms/style/index.d.ts +1 -1
  7. package/dist/atoms/style/index.js +1 -1
  8. package/dist/atoms/utils/auth_environment.d.ts +0 -1
  9. package/dist/atoms/utils/auth_environment.js +1 -1
  10. package/dist/deprecated/ExpandingIconButton/ExpandingIconButton.d.ts +1 -1
  11. package/dist/deprecated/IconToggleButton.d.ts +1 -1
  12. package/dist/deprecated/OldStepper/OldStepLine.js +1 -1
  13. package/dist/deprecated/OldStepper/OldStepper.d.ts +1 -1
  14. package/dist/index.d.ts +1 -1
  15. package/dist/molecules/AnimatedCheckmark/AnimatedCheckmark.d.ts +1 -1
  16. package/dist/molecules/ApplicationIcon/ApplicationIcon.d.ts +1 -1
  17. package/dist/molecules/Badge/Badge.d.ts +1 -1
  18. package/dist/molecules/Button/Button.js +1 -1
  19. package/dist/molecules/Button/IconButton/IconButton.js +1 -1
  20. package/dist/molecules/Chip/Chip.d.ts +3 -3
  21. package/dist/molecules/Chip/Chip.styles.js +1 -1
  22. package/dist/molecules/Confetti/Confetti.types.d.ts +1 -1
  23. package/dist/molecules/Confetti/utils/seasonalColors.js +1 -1
  24. package/dist/molecules/DateRangePicker/DateRangePicker.d.ts +3 -3
  25. package/dist/molecules/EquinorLogo/EquinorLogo.d.ts +2 -2
  26. package/dist/molecules/FileProgress/CompactFileProgress.js +1 -1
  27. package/dist/molecules/FileProgress/FileProgress.types.d.ts +1 -1
  28. package/dist/molecules/IconCell/IconCell.d.ts +1 -1
  29. package/dist/molecules/IconCell/IconCell.styles.js +3 -3
  30. package/dist/molecules/IconCell/IconCell.utils.js +1 -1
  31. package/dist/molecules/OptionDrawer/OptionDrawer.d.ts +1 -1
  32. package/dist/molecules/ProfileAvatar/ProfileAvatar.d.ts +2 -2
  33. package/dist/molecules/ProfileAvatar/ProfileAvatar.js +1 -1
  34. package/dist/molecules/RichTextEditor/custom-extensions/AmplifyKit.js +1 -1
  35. package/dist/molecules/RichTextEditor/index.d.ts +6 -6
  36. package/dist/molecules/RichTextEditor/index.js +1 -1
  37. package/dist/molecules/Select/ComboBox/ComboBox.d.ts +2 -2
  38. package/dist/molecules/Select/PersistentComboBox/PersistentComboBox.d.ts +2 -2
  39. package/dist/molecules/Select/Select.styles.d.ts +5 -5
  40. package/dist/molecules/Select/Select.styles.js +1 -1
  41. package/dist/molecules/Select/Select.types.d.ts +1 -1
  42. package/dist/molecules/Select/SelectMenuItem.utils.js +1 -1
  43. package/dist/molecules/Select/SingleSelect/SingleSelect.d.ts +2 -2
  44. package/dist/molecules/SelectionControls/Radio/Radio.d.ts +2 -2
  45. package/dist/molecules/SelectionControls/Switch/Switch.d.ts +2 -2
  46. package/dist/molecules/Stepper/Step/Step.js +1 -1
  47. package/dist/molecules/Stepper/StepLine.js +1 -1
  48. package/dist/molecules/Stepper/Stepper.js +1 -1
  49. package/dist/molecules/Waves/Waves.d.ts +1 -1
  50. package/dist/molecules/index.d.ts +1 -1
  51. package/dist/molecules/index.js +1 -1
  52. package/dist/organisms/Faq/Faq.d.ts +1 -1
  53. package/dist/organisms/Faq/Faq.utils.js +1 -1
  54. package/dist/organisms/FieldSelector/ChangingField.js +1 -1
  55. package/dist/organisms/Filter/AutoCompleteText.js +1 -1
  56. package/dist/organisms/Filter/Filter.d.ts +2 -2
  57. package/dist/organisms/Filter/Filter.types.d.ts +1 -1
  58. package/dist/organisms/Filter/QuickFilter.d.ts +2 -2
  59. package/dist/organisms/Filter/SortMenu.d.ts +2 -2
  60. package/dist/organisms/ReleaseNote/ReleaseNote.d.ts +3 -3
  61. package/dist/organisms/SideBar/MenuItem/CollapsableMenuItem.js +4 -1
  62. package/dist/organisms/SideBar/MenuItem/MenuItem.d.ts +1 -1
  63. package/dist/organisms/SideBar/SideBar.d.ts +2 -2
  64. package/dist/organisms/SideBar/index.d.ts +1 -1
  65. package/dist/organisms/Status/Action.d.ts +2 -2
  66. package/dist/organisms/Status/Description.d.ts +2 -2
  67. package/dist/organisms/Status/MissingAccesses.d.ts +2 -2
  68. package/dist/organisms/Status/Title.d.ts +2 -2
  69. package/dist/organisms/Status/collections/BadRequest.d.ts +2 -2
  70. package/dist/organisms/Status/collections/GenericError.d.ts +2 -2
  71. package/dist/organisms/Status/collections/MissingPermissions.d.ts +2 -2
  72. package/dist/organisms/Status/collections/PageNotFound.d.ts +2 -2
  73. package/dist/organisms/Status/collections/ServerError.d.ts +2 -2
  74. package/dist/organisms/Status/index.d.ts +1 -1
  75. package/dist/organisms/Template/Template.d.ts +3 -3
  76. package/dist/organisms/ToggleGroup/ToggleGroupOption.js +1 -1
  77. package/dist/organisms/TopBar/Account/Account.d.ts +1 -1
  78. package/dist/organisms/TopBar/Account/AccountButton.js +1 -1
  79. package/dist/organisms/TopBar/Actions.d.ts +2 -2
  80. package/dist/organisms/TopBar/FieldMenu/FieldMenu.d.ts +3 -3
  81. package/dist/organisms/TopBar/Guidelines/Guidelines.d.ts +1 -1
  82. package/dist/organisms/TopBar/Notifications/NotificationProvider.d.ts +2 -2
  83. package/dist/organisms/TopBar/Notifications/NotificationsTemplate/Notifications.types.d.ts +1 -1
  84. package/dist/organisms/TopBar/Resources/Feedback/Feedback.utils.js +1 -1
  85. package/dist/organisms/TopBar/Resources/Feedback/FeedbackForm/LockedInputTooltip.js +2 -2
  86. package/dist/organisms/TopBar/Resources/Feedback/FeedbackForm/Severity.js +1 -1
  87. package/dist/organisms/TopBar/Resources/Feedback/FeedbackForm/UploadFile/ImageFile.js +1 -1
  88. package/dist/organisms/TopBar/Resources/Feedback/FeedbackForm/UploadFile/UploadFile.js +1 -1
  89. package/dist/organisms/TopBar/Resources/Feedback/ResponsePage/ResponsePage.js +1 -1
  90. package/dist/organisms/TopBar/Resources/Feedback/ResponsePage/ResponseStatus.js +1 -1
  91. package/dist/organisms/TopBar/Resources/Feedback/ResponsePage/Success.js +1 -1
  92. package/dist/organisms/TopBar/Resources/Resources.d.ts +1 -1
  93. package/dist/organisms/TopBar/Tutorials/TutorialItem.js +1 -1
  94. package/dist/organisms/TopBar/index.d.ts +1 -1
  95. package/dist/organisms/index.d.ts +1 -1
  96. package/dist/organisms/index.js +1 -1
  97. package/dist/providers/AuthProvider/AuthProvider.d.ts +3 -15
  98. package/dist/providers/AuthProvider/AuthProvider.js +1 -1
  99. package/dist/providers/AuthProvider/AuthProviderInner.js +1 -1
  100. package/dist/providers/LoadingProvider.js +1 -1
  101. package/dist/providers/SnackbarProvider/SnackbarProvider.d.ts +1 -1
  102. package/dist/providers/StepperProvider.d.ts +1 -1
  103. package/dist/providers/StepperProvider.js +1 -1
  104. package/dist/providers/TableOfContentsProvider.d.ts +1 -1
  105. package/dist/providers/TutorialHighlightingProvider/TutorialHighlightingProviderInner.js +1 -1
  106. package/package.json +1 -1
@@ -52,4 +52,4 @@ import { Radio as Radio$1, RadioProps as RadioProps$1 } from "./SelectionControl
52
52
  import { Switch as Switch$1, SwitchProps as SwitchProps$1 } from "./SelectionControls/Switch/Switch.js";
53
53
  import { Waves } from "./Waves/Waves.js";
54
54
  import { Accordion, AccordionHeaderActionsProps, AccordionHeaderProps, AccordionHeaderTitleProps, AccordionItemProps, AccordionPanelProps, AccordionProps, BreadcrumbProps, Breadcrumbs, BreadcrumbsProps, CircularProgress as CircularProgress$1, CircularProgressProps, Dialog as EDSDialog, DialogProps as EDSDialogProps, Divider as Divider$1, DividerProps, DotProgress as DotProgress$1, DotProgressProps, Icon as Icon$1, IconProps as IconProps$1, LinearProgress as LinearProgress$1, LinearProgressProps, Menu as Menu$1, MenuProps, SearchProps as SearchProps$1, Typography as Typography$1, TypographyProps } from "@equinor/eds-core-react";
55
- export { Accordion, type AccordionHeaderActionsProps, type AccordionHeaderProps, type AccordionHeaderTitleProps, type AccordionItemProps, type AccordionPanelProps, type AccordionProps, AmplifyBar, AmplifyKit, AnimatedCheckmark, ApplicationIcon, type ApplicationIconProps, Badge, type BadgeProps, Banner, type BannerProps, type BaseChipProps, type BreadcrumbProps, Breadcrumbs, type BreadcrumbsProps, Button$1 as Button, type ButtonProps, Checkbox$1 as Checkbox, type CheckboxProps$1 as CheckboxProps, Chip$1 as Chip, CircularProgress$1 as CircularProgress, type CircularProgressProps, ComboBox, ComboBoxChip, type ComboBoxProps, Confetti, type ConfettiBoomProps, type ConfettiProps, type ConfettiShowerProps, DEFAULT_FEATURES, DatePicker$1 as DatePicker, type DatePickerProps$1 as DatePickerProps, DateRangePicker$1 as DateRangePicker, type DateRangePickerProps$1 as DateRangePickerProps, Dialog$1 as Dialog, type DialogAction, type DialogProps$1 as DialogProps, Divider$1 as Divider, type DividerProps, DotProgress$1 as DotProgress, type DotProgressProps, EDSDialog, type EDSDialogProps, EditorMenu, EditorPanel, EditorText, EquinorLogo, type EquinorLogoProps, FeedBackIcon, type FeedBackIconProps, FileProgress, type FileProgressProps, type FileProgressPropsExtension, FileUploadArea, type FileUploadAreaProps, FullPageSpinner, type FullPageSpinnerProps, Icon$1 as Icon, IconButton, type IconButtonProps, IconCell, type IconCellColor, type IconCellColorObject, IconCellColors, type IconCellProps, type IconCellState, IconCellStates, type IconCellVariant, IconCellVariants, type IconProps$1 as IconProps, ImageExtensionFnProps, InfoElement, type InfoElementProps, InformationalNotice, type InformationalNoticeProps, LinearProgress$1 as LinearProgress, type LinearProgressProps, ListItem, type ListItemProps, Menu$1 as Menu, type MenuProps, OptionDrawer, type OptionDrawerProps, type OptionDrawerSelectItem, OptionalTooltip, type OptionalTooltipProps, PersistentComboBox, type PersistentComboBoxProps, ProfileAvatar, type ProfileAvatarProps, Radio$1 as Radio, type RadioProps$1 as RadioProps, RichText, RichTextDisplay, type RichTextDisplayProps, RichTextEditor, RichTextEditorFeatures, type RichTextEditorProps, Search$1 as Search, type SearchProps$1 as SearchProps, type SelectOption, type SelectOptionRequired, SingleSelect, type SingleSelectProps, SkeletonBase, type SkeletonBaseProps, SkeletonGradient, type SkeletonGradientProps, Stepper, type StepperProps, Switch$1 as Switch, type SwitchProps$1 as SwitchProps, type Tab, TableHeader, type TableHeaderProps, TableMenuBar, Tabs, type TabsProps, Tag, type TagProps, TextField$1 as TextField, type TextFieldProps$1 as TextFieldProps, TextTable, Toast, type ToastProps, Typography$1 as Typography, type TypographyProps, Waves, skeletonBaseloading };
55
+ export { Accordion, type AccordionHeaderActionsProps, type AccordionHeaderProps, type AccordionHeaderTitleProps, type AccordionItemProps, type AccordionPanelProps, type AccordionProps, type BreadcrumbProps, Breadcrumbs, type BreadcrumbsProps, CircularProgress$1 as CircularProgress, type CircularProgressProps, Divider$1 as Divider, type DividerProps, DotProgress$1 as DotProgress, type DotProgressProps, EDSDialog, type EDSDialogProps, Icon$1 as Icon, type IconProps$1 as IconProps, LinearProgress$1 as LinearProgress, type LinearProgressProps, Menu$1 as Menu, type MenuProps, type SearchProps$1 as SearchProps, Typography$1 as Typography, type TypographyProps };
@@ -1 +1 @@
1
- import{FullPageSpinner as e}from"./FullPageSpinner/FullPageSpinner.js";import{DEFAULT_FEATURES as t,RichTextEditorFeatures as n}from"./RichTextEditor/RichTextEditor.types.js";import{AmplifyKit as r}from"./RichTextEditor/custom-extensions/AmplifyKit.js";import{AnimatedCheckmark as i}from"./AnimatedCheckmark/AnimatedCheckmark.js";import{ApplicationIcon as a}from"./ApplicationIcon/ApplicationIcon.js";import{Badge as o}from"./Badge/Badge.js";import{Banner as s}from"./Banner/Banner.js";import{Button as c}from"./Button/Button.js";import{IconButton as l}from"./Button/IconButton/IconButton.js";import{Chip as u}from"./Chip/Chip.js";import{Confetti as d}from"./Confetti/Confetti.js";import{SkeletonBase as f,skeletonBaseloading as p}from"./Skeleton/SkeletonBase/SkeletonBase.js";import{DatePicker as m}from"./DatePicker/DatePicker.js";import{DateRangePicker as h}from"./DateRangePicker/DateRangePicker.js";import{OptionalTooltip as g}from"./OptionalTooltip/OptionalTooltip.js";import{Dialog as _}from"./Dialog/Dialog.js";import{EquinorLogo as v}from"./EquinorLogo/EquinorLogo.js";import{FileProgress as y}from"./FileProgress/FileProgress.js";import{FileUploadArea as b}from"./FileUploadArea/FileUploadArea.js";import{IconCellColors as x,IconCellStates as S,IconCellVariants as C}from"./IconCell/IconCell.types.js";import{IconCell as w}from"./IconCell/IconCell.js";import{InfoElement as T}from"./InfoElement/InfoElement.js";import{InformationalNotice as E}from"./InformationalNotice/InformationalNotice.js";import{ProfileAvatar as D}from"./ProfileAvatar/ProfileAvatar.js";import{RichTextDisplay as O}from"./RichTextDisplay/RichTextDisplay.js";import{TableMenuBar as k,TextTable as A}from"./RichTextEditor/MenuBar/Table/TableBar.js";import{TextField as j}from"./TextField/TextField.js";import{AmplifyBar as M,EditorMenu as N,EditorText as P}from"./RichTextEditor/MenuBar/MenuBar.js";import{RichTextEditor as F}from"./RichTextEditor/RichTextEditor.js";import{RichText as I}from"./RichTextEditor/index.js";import{Tabs as L}from"./Tabs/Tabs.js";import{Search as R}from"./Search/Search.js";import{SkeletonGradient as z}from"./Skeleton/SkeletonGradient/SkeletonGradient.js";import{Stepper as B}from"./Stepper/Stepper.js";import{OptionDrawer as V}from"./OptionDrawer/OptionDrawer.js";import{ComboBoxChip as H}from"./Select/Select.styles.js";import{ComboBox as U}from"./Select/ComboBox/ComboBox.js";import{PersistentComboBox as W}from"./Select/PersistentComboBox/PersistentComboBox.js";import{SingleSelect as G}from"./Select/SingleSelect/SingleSelect.js";import{Tag as K}from"./Tag/Tag.js";import{TableHeader as q}from"./TableHeader/TableHeader.js";import{FeedBackIcon as J}from"./FeedBackIcon/FeedBackIcon.js";import{ListItem as Y}from"./ListItem/ListItem.js";import{Checkbox as X}from"./SelectionControls/Checkbox/Checkbox.js";import{Radio as Z}from"./SelectionControls/Radio/Radio.js";import{Switch as Q}from"./SelectionControls/Switch/Switch.js";import{Waves as $}from"./Waves/Waves.js";import{Toast as ee}from"./Toast/Toast.js";import{Accordion as te,Breadcrumbs as ne,CircularProgress as re,Dialog as ie,Divider as ae,DotProgress as oe,Icon as se,LinearProgress as ce,Menu as le,Typography as ue}from"@equinor/eds-core-react";export{te as Accordion,M as AmplifyBar,r as AmplifyKit,i as AnimatedCheckmark,a as ApplicationIcon,o as Badge,s as Banner,ne as Breadcrumbs,c as Button,X as Checkbox,u as Chip,re as CircularProgress,U as ComboBox,H as ComboBoxChip,d as Confetti,t as DEFAULT_FEATURES,m as DatePicker,h as DateRangePicker,_ as Dialog,ae as Divider,oe as DotProgress,ie as EDSDialog,N as EditorMenu,P as EditorText,v as EquinorLogo,J as FeedBackIcon,y as FileProgress,b as FileUploadArea,e as FullPageSpinner,se as Icon,l as IconButton,w as IconCell,x as IconCellColors,S as IconCellStates,C as IconCellVariants,T as InfoElement,E as InformationalNotice,ce as LinearProgress,Y as ListItem,le as Menu,V as OptionDrawer,g as OptionalTooltip,W as PersistentComboBox,D as ProfileAvatar,Z as Radio,I as RichText,O as RichTextDisplay,F as RichTextEditor,n as RichTextEditorFeatures,R as Search,G as SingleSelect,f as SkeletonBase,z as SkeletonGradient,B as Stepper,Q as Switch,q as TableHeader,k as TableMenuBar,L as Tabs,K as Tag,j as TextField,A as TextTable,ee as Toast,ue as Typography,$ as Waves,p as skeletonBaseloading};
1
+ import"./FullPageSpinner/FullPageSpinner.js";import"./RichTextEditor/RichTextEditor.types.js";import"./RichTextEditor/custom-extensions/AmplifyKit.js";import"./AnimatedCheckmark/AnimatedCheckmark.js";import"./ApplicationIcon/ApplicationIcon.js";import"./Badge/Badge.js";import"./Banner/Banner.js";import"./Button/Button.js";import"./Button/IconButton/IconButton.js";import"./Chip/Chip.js";import"./Confetti/Confetti.js";import"./Skeleton/SkeletonBase/SkeletonBase.js";import"./DatePicker/DatePicker.js";import"./DateRangePicker/DateRangePicker.js";import"./OptionalTooltip/OptionalTooltip.js";import"./Dialog/Dialog.js";import"./EquinorLogo/EquinorLogo.js";import"./FileProgress/FileProgress.js";import"./FileUploadArea/FileUploadArea.js";import"./IconCell/IconCell.types.js";import"./IconCell/IconCell.js";import"./InfoElement/InfoElement.js";import"./InformationalNotice/InformationalNotice.js";import"./ProfileAvatar/ProfileAvatar.js";import"./RichTextDisplay/RichTextDisplay.js";import"./RichTextEditor/MenuBar/Table/TableBar.js";import"./TextField/TextField.js";import"./RichTextEditor/MenuBar/MenuBar.js";import"./RichTextEditor/RichTextEditor.js";import"./RichTextEditor/index.js";import"./Tabs/Tabs.js";import"./Search/Search.js";import"./Skeleton/SkeletonGradient/SkeletonGradient.js";import"./Stepper/Stepper.js";import"./OptionDrawer/OptionDrawer.js";import"./Select/Select.styles.js";import"./Select/ComboBox/ComboBox.js";import"./Select/PersistentComboBox/PersistentComboBox.js";import"./Select/SingleSelect/SingleSelect.js";import"./Tag/Tag.js";import"./TableHeader/TableHeader.js";import"./FeedBackIcon/FeedBackIcon.js";import"./ListItem/ListItem.js";import"./SelectionControls/Checkbox/Checkbox.js";import"./SelectionControls/Radio/Radio.js";import"./SelectionControls/Switch/Switch.js";import"./Waves/Waves.js";import"./Toast/Toast.js";import{Accordion as e,Breadcrumbs as t,CircularProgress as n,Dialog as r,Divider as i,DotProgress as a,Icon as o,LinearProgress as s,Menu as c,Typography as l}from"@equinor/eds-core-react";export{e as Accordion,t as Breadcrumbs,n as CircularProgress,i as Divider,a as DotProgress,r as EDSDialog,o as Icon,s as LinearProgress,c as Menu,l as Typography};
@@ -7,4 +7,4 @@ interface FaqProps {
7
7
  }
8
8
  declare const Faq: FC<FaqProps>;
9
9
  //#endregion
10
- export { Faq, FaqProps };
10
+ export { Faq };
@@ -1 +1 @@
1
- const e=e=>{let t=(e.faqs?.length??0)>0,n=e.subCategories?.some(e=>(e.faqs?.length??0)>0);return t||!!n};function t(e,t){let n=t.toLowerCase();return!e.answer||!e.question?!1:n===``?!0:e.answer.toLowerCase().includes(n)||e.question.toLowerCase().includes(n)}function n(t){return e(t)}function r(e,n){let r=(e.faqs??[]).filter(e=>!n||t(e,n)),i=(e.subCategories??[]).map(e=>{let r=(e.faqs??[]).filter(e=>!n||t(e,n));return r.length>0?{...e,faqs:r}:null}).filter(Boolean);return{...e,faqs:r,subCategories:i}}export{e as categoryHasFaqs,t as faqInSearch,n as filterCategory,r as mapCategoryToSearch};
1
+ const e=e=>{let t=(e.faqs?.length??0)>0,n=e.subCategories?.some(e=>(e.faqs?.length??0)>0);return t||!!n};function t(e,t){let n=t.toLowerCase();return!e.answer||!e.question?!1:n===``?!0:e.answer.toLowerCase().includes(n)||e.question.toLowerCase().includes(n)}function n(t){return e(t)}function r(e,n){let r=(e.faqs??[]).filter(e=>!n||t(e,n)),i=(e.subCategories??[]).map(e=>{let r=(e.faqs??[]).filter(e=>!n||t(e,n));return r.length>0?{...e,faqs:r}:null}).filter(Boolean);return{...e,faqs:r,subCategories:i}}export{e as categoryHasFaqs,n as filterCategory,r as mapCategoryToSearch};
@@ -21,4 +21,4 @@ import{colors as e}from"../../atoms/style/colors.js";import{spacings as t}from".
21
21
  span {
22
22
  text-transform: capitalize;
23
23
  }
24
- `,m=({fieldName:e,onChangedField:t,finishedText:a})=>{let{finished:s,progress:m}=r({onDone:t});return l(d,{children:s?u(c,{children:[u(p,{variant:`h3`,children:[`Changed to `,l(`span`,{children:n(e)})]}),l(i,{}),l(o,{variant:`h6`,children:a})]}):u(c,{children:[u(o,{variant:`h3`,children:[`Changing field.`,`.`.repeat(m/35)]}),l(f,{variant:`determinate`,value:m})]})})};export{m as ChangingField,f as LinearProgress};
24
+ `,m=({fieldName:e,onChangedField:t,finishedText:a})=>{let{finished:s,progress:m}=r({onDone:t});return l(d,{children:s?u(c,{children:[u(p,{variant:`h3`,children:[`Changed to `,l(`span`,{children:n(e)})]}),l(i,{}),l(o,{variant:`h6`,children:a})]}):u(c,{children:[u(o,{variant:`h3`,children:[`Changing field.`,`.`.repeat(m/35)]}),l(f,{variant:`determinate`,value:m})]})})};export{m as ChangingField};
@@ -8,4 +8,4 @@ import{colors as e}from"../../atoms/style/colors.js";import{findStartAndEndIndex
8
8
  > span {
9
9
  color: transparent;
10
10
  }
11
- `;function c({search:e,autoCompleteOptions:r}){let i=n({autoCompleteOptions:r,searchValue:e});if(i.length===0)return null;let c=i[0],[l,u]=t({searchValue:e,label:c.label});return l===0?o(s,{children:[a(`span`,{children:e.slice(0,e.length)}),c.label.slice(u+1)]}):null}export{c as AutoCompleteText,s as StyledTypography};
11
+ `;function c({search:e,autoCompleteOptions:r}){let i=n({autoCompleteOptions:r,searchValue:e});if(i.length===0)return null;let c=i[0],[l,u]=t({searchValue:e,label:c.label});return l===0?o(s,{children:[a(`span`,{children:e.slice(0,e.length)}),c.label.slice(u+1)]}):null}export{c as AutoCompleteText};
@@ -1,5 +1,5 @@
1
1
  import { FilterProps } from "./Filter.types.js";
2
- import * as react187 from "react";
2
+ import * as react183 from "react";
3
3
 
4
4
  //#region src/organisms/Filter/Filter.d.ts
5
5
 
@@ -32,6 +32,6 @@ declare function Filter<T extends string>({
32
32
  id,
33
33
  openOnFocus,
34
34
  ...rest
35
- }: FilterProps<T>): react187.JSX.Element;
35
+ }: FilterProps<T>): react183.JSX.Element;
36
36
  //#endregion
37
37
  export { Filter };
@@ -26,4 +26,4 @@ interface FilterWithAutoCompleteOptions<T extends string> extends CommonFilterPr
26
26
  }
27
27
  type FilterProps<T extends string> = CommonFilterProps<T> | FilterWithAutoCompleteOptions<T>;
28
28
  //#endregion
29
- export { FilterProps, FilterWithAutoCompleteOptions };
29
+ export { FilterProps };
@@ -1,6 +1,6 @@
1
1
  import { SelectOptionRequired } from "../../molecules/Select/Select.types.js";
2
2
  import { FilterProps } from "./Filter.types.js";
3
- import * as react188 from "react";
3
+ import * as react184 from "react";
4
4
 
5
5
  //#region src/organisms/Filter/QuickFilter.d.ts
6
6
  interface QuickFilterProps<T extends string> {
@@ -14,6 +14,6 @@ declare function QuickFilter<T extends string>({
14
14
  items,
15
15
  onQuickFilter,
16
16
  label
17
- }: QuickFilterProps<T>): react188.JSX.Element;
17
+ }: QuickFilterProps<T>): react184.JSX.Element;
18
18
  //#endregion
19
19
  export { QuickFilter };
@@ -1,4 +1,4 @@
1
- import * as react186 from "react";
1
+ import * as react182 from "react";
2
2
 
3
3
  //#region src/organisms/Filter/SortMenu.d.ts
4
4
  interface SortMenuProps<S> {
@@ -13,6 +13,6 @@ declare function SortMenu<S>({
13
13
  value,
14
14
  onChange,
15
15
  items
16
- }: SortMenuProps<S>): react186.JSX.Element;
16
+ }: SortMenuProps<S>): react182.JSX.Element;
17
17
  //#endregion
18
18
  export { SortMenu };
@@ -1,4 +1,4 @@
1
- import * as react12 from "react";
1
+ import * as react7 from "react";
2
2
  import { ReactNode } from "react";
3
3
  import { ReleaseNote } from "@equinor/subsurface-app-management";
4
4
 
@@ -7,9 +7,9 @@ type ReleaseNoteProps = {
7
7
  actionMenu?: ReactNode;
8
8
  expanded?: boolean;
9
9
  } & ReleaseNote;
10
- declare const ReleaseNote$1: react12.ForwardRefExoticComponent<{
10
+ declare const ReleaseNote$1: react7.ForwardRefExoticComponent<{
11
11
  actionMenu?: ReactNode;
12
12
  expanded?: boolean;
13
- } & ReleaseNote & react12.RefAttributes<HTMLDivElement>>;
13
+ } & ReleaseNote & react7.RefAttributes<HTMLDivElement>>;
14
14
  //#endregion
15
15
  export { ReleaseNote$1 as ReleaseNote, ReleaseNoteProps };
@@ -45,4 +45,7 @@ import{colors as e}from"../../../atoms/style/colors.js";import{spacings as t}fro
45
45
  > p:first-child {
46
46
  grid-column: 2;
47
47
  }
48
- `,D=({icon:t,name:s,items:h,...g})=>{let{pathname:D}=C(),O=w(),k=r(D),{isOpen:A}=n(),j=r(A),M=h.some(e=>!!O({...e})),N=d(null),[P,F]=f(!1),I=()=>F(e=>!e);l(()=>{(j&&!A&&P||k!==D&&P&&!A)&&F(!1)},[P,A,D,j,k]);let L=u(()=>v(i,{title:s,placement:`right`,children:v(c,{children:y(T,{ref:N,$open:A,$active:M,$expanded:P,onClick:I,...g,children:[v(a,{"data-testid":`icon-container`,children:v(p,{data:t,size:24,color:e.interactive.primary__resting.rgba})}),A&&y(_,{children:[v(o,{$active:!1,$disabled:!1,variant:`button`,group:`navigation`,children:s}),v(p,{data:P?x:b,size:24,color:e.interactive.primary__resting.rgba})]})]})})}),[P,t,M,A,s,g]);return P&&A?y(_,{children:[L,h.map((e,t)=>v(E,{$disabled:e.disabled||!1,...e,children:v(o,{$active:M,$disabled:e.disabled||!1,variant:`button`,group:`navigation`,children:e.name})},t))]}):P?y(_,{children:[L,v(m,{open:!0,anchorEl:N.current,placement:`right-start`,onClose:I,children:h.map(e=>v(m.Item,{as:S,active:!!O({...e}),style:{width:`256px`},...e,children:e.name},`${e.to}-${e.name}`))})]}):L};export{D as CollapsableMenuItem};
48
+ `,D=h(m)`
49
+ max-height: 80vh;
50
+ overflow-y: auto;
51
+ `,O=({icon:t,name:s,items:h,...g})=>{let{pathname:O}=C(),k=w(),A=r(O),{isOpen:j}=n(),M=r(j),N=h.some(e=>!!k({...e})),P=d(null),[F,I]=f(!1),L=()=>I(e=>!e);l(()=>{(M&&!j&&F||A!==O&&F&&!j)&&I(!1)},[F,j,O,M,A]);let R=u(()=>v(i,{title:s,placement:`right`,children:v(c,{children:y(T,{ref:P,$open:j,$active:N,$expanded:F,onClick:L,...g,children:[v(a,{"data-testid":`icon-container`,children:v(p,{data:t,size:24,color:e.interactive.primary__resting.rgba})}),j&&y(_,{children:[v(o,{$active:!1,$disabled:!1,variant:`button`,group:`navigation`,children:s}),v(p,{data:F?x:b,size:24,color:e.interactive.primary__resting.rgba})]})]})})}),[F,t,N,j,s,g]);return F&&j?y(_,{children:[R,h.map((e,t)=>v(E,{$disabled:e.disabled||!1,...e,children:v(o,{$active:N,$disabled:e.disabled||!1,variant:`button`,group:`navigation`,children:e.name})},t))]}):F?y(_,{children:[R,v(D,{open:!0,anchorEl:P.current,placement:`right-start`,onClose:L,children:h.map(e=>v(m.Item,{as:S,active:!!k({...e}),style:{width:`256px`},...e,children:e.name},`${e.to}-${e.name}`))})]}):R};export{O as CollapsableMenuItem};
@@ -7,4 +7,4 @@ type MenuItemProps = {
7
7
  } & SideBarMenuItem;
8
8
  declare const MenuItem: FC<MenuItemProps>;
9
9
  //#endregion
10
- export { MenuItem, MenuItemProps };
10
+ export { MenuItem };
@@ -1,4 +1,4 @@
1
- import * as react189 from "react";
1
+ import * as react185 from "react";
2
2
  import { HTMLAttributes, ReactNode } from "react";
3
3
 
4
4
  //#region src/organisms/SideBar/SideBar.d.ts
@@ -16,6 +16,6 @@ interface SideBarWithCreate extends SideBarProps {
16
16
  createDisabled?: boolean;
17
17
  createActive?: boolean;
18
18
  }
19
- declare const SideBar: react189.ForwardRefExoticComponent<(SideBarWithCreate | BaseSideBar) & react189.RefAttributes<HTMLDivElement>>;
19
+ declare const SideBar: react185.ForwardRefExoticComponent<(SideBarWithCreate | BaseSideBar) & react185.RefAttributes<HTMLDivElement>>;
20
20
  //#endregion
21
21
  export { SideBar };
@@ -12,4 +12,4 @@ type SidebarType = typeof SideBar$1 & {
12
12
  type ItemType = SideBarMenuItem;
13
13
  declare const SideBar: SidebarType;
14
14
  //#endregion
15
- export { type ItemType, SideBar, type SidebarType };
15
+ export { type ItemType, SideBar };
@@ -1,10 +1,10 @@
1
- import * as react196 from "react";
1
+ import * as react198 from "react";
2
2
 
3
3
  //#region src/organisms/Status/Action.d.ts
4
4
  interface ActionProps {
5
5
  onClick: () => void;
6
6
  buttonText?: string;
7
7
  }
8
- declare const Action: react196.ForwardRefExoticComponent<ActionProps & react196.RefAttributes<HTMLButtonElement>>;
8
+ declare const Action: react198.ForwardRefExoticComponent<ActionProps & react198.RefAttributes<HTMLButtonElement>>;
9
9
  //#endregion
10
10
  export { Action };
@@ -1,9 +1,9 @@
1
- import * as react202 from "react";
1
+ import * as react200 from "react";
2
2
 
3
3
  //#region src/organisms/Status/Description.d.ts
4
4
  interface DescriptionProps {
5
5
  text?: string;
6
6
  }
7
- declare const Description: react202.ForwardRefExoticComponent<DescriptionProps & react202.RefAttributes<HTMLHeadingElement>>;
7
+ declare const Description: react200.ForwardRefExoticComponent<DescriptionProps & react200.RefAttributes<HTMLHeadingElement>>;
8
8
  //#endregion
9
9
  export { Description };
@@ -1,4 +1,4 @@
1
- import * as react200 from "react";
1
+ import * as react202 from "react";
2
2
 
3
3
  //#region src/organisms/Status/MissingAccesses.d.ts
4
4
  interface AccessType {
@@ -9,6 +9,6 @@ interface MissingAccessesProps {
9
9
  accesses?: AccessType[];
10
10
  text?: string;
11
11
  }
12
- declare const MissingAccesses: react200.ForwardRefExoticComponent<MissingAccessesProps & react200.RefAttributes<HTMLDivElement>>;
12
+ declare const MissingAccesses: react202.ForwardRefExoticComponent<MissingAccessesProps & react202.RefAttributes<HTMLDivElement>>;
13
13
  //#endregion
14
14
  export { MissingAccesses };
@@ -1,9 +1,9 @@
1
- import * as react198 from "react";
1
+ import * as react196 from "react";
2
2
 
3
3
  //#region src/organisms/Status/Title.d.ts
4
4
  interface TitleProps {
5
5
  title?: string;
6
6
  }
7
- declare const Title: react198.ForwardRefExoticComponent<TitleProps & react198.RefAttributes<HTMLHeadingElement>>;
7
+ declare const Title: react196.ForwardRefExoticComponent<TitleProps & react196.RefAttributes<HTMLHeadingElement>>;
8
8
  //#endregion
9
9
  export { Title };
@@ -1,4 +1,4 @@
1
- import * as react195 from "react";
1
+ import * as react194 from "react";
2
2
 
3
3
  //#region src/organisms/Status/collections/BadRequest.d.ts
4
4
  interface BadRequestProps {
@@ -12,6 +12,6 @@ declare const BadRequest: ({
12
12
  redirectFallbackUrl,
13
13
  onBackClick,
14
14
  hideBackButton
15
- }: BadRequestProps) => react195.JSX.Element;
15
+ }: BadRequestProps) => react194.JSX.Element;
16
16
  //#endregion
17
17
  export { BadRequest };
@@ -1,4 +1,4 @@
1
- import * as react191 from "react";
1
+ import * as react195 from "react";
2
2
 
3
3
  //#region src/organisms/Status/collections/GenericError.d.ts
4
4
  interface GenericErrorProps {
@@ -14,6 +14,6 @@ declare const GenericError: ({
14
14
  redirectFallbackUrl,
15
15
  onBackClick,
16
16
  hideBackButton
17
- }: GenericErrorProps) => react191.JSX.Element;
17
+ }: GenericErrorProps) => react195.JSX.Element;
18
18
  //#endregion
19
19
  export { GenericError };
@@ -1,4 +1,4 @@
1
- import * as react192 from "react";
1
+ import * as react191 from "react";
2
2
 
3
3
  //#region src/organisms/Status/collections/MissingPermissions.d.ts
4
4
  interface MissingPermissionsProps {
@@ -14,6 +14,6 @@ declare const MissingPermissions: ({
14
14
  redirectFallbackUrl,
15
15
  onBackClick,
16
16
  hideBackButton
17
- }: MissingPermissionsProps) => react192.JSX.Element;
17
+ }: MissingPermissionsProps) => react191.JSX.Element;
18
18
  //#endregion
19
19
  export { MissingPermissions };
@@ -1,4 +1,4 @@
1
- import * as react193 from "react";
1
+ import * as react192 from "react";
2
2
 
3
3
  //#region src/organisms/Status/collections/PageNotFound.d.ts
4
4
  interface PageNotFoundProps {
@@ -12,6 +12,6 @@ declare const PageNotFound: ({
12
12
  redirectFallbackUrl,
13
13
  onBackClick,
14
14
  hideBackButton
15
- }: PageNotFoundProps) => react193.JSX.Element;
15
+ }: PageNotFoundProps) => react192.JSX.Element;
16
16
  //#endregion
17
17
  export { PageNotFound };
@@ -1,4 +1,4 @@
1
- import * as react194 from "react";
1
+ import * as react193 from "react";
2
2
 
3
3
  //#region src/organisms/Status/collections/ServerError.d.ts
4
4
  interface ServerErrorProps {
@@ -12,6 +12,6 @@ declare const ServerError: ({
12
12
  redirectFallbackUrl,
13
13
  onBackClick,
14
14
  hideBackButton
15
- }: ServerErrorProps) => react194.JSX.Element;
15
+ }: ServerErrorProps) => react193.JSX.Element;
16
16
  //#endregion
17
17
  export { ServerError };
@@ -13,4 +13,4 @@ type StatusType = typeof Status$1 & {
13
13
  };
14
14
  declare const Status: StatusType;
15
15
  //#endregion
16
- export { Status, type StatusType };
16
+ export { Status };
@@ -1,4 +1,4 @@
1
- import * as react7 from "react";
1
+ import * as react9 from "react";
2
2
  import * as styled_components0 from "styled-components";
3
3
  import { IStyledComponent } from "styled-components";
4
4
  import * as styled_components_dist_types0 from "styled-components/dist/types";
@@ -7,8 +7,8 @@ import * as styled_components_dist_types0 from "styled-components/dist/types";
7
7
  interface ContentProps {
8
8
  $open: boolean;
9
9
  }
10
- declare const Content: styled_components_dist_types0.IStyledComponentBase<"web", styled_components0.FastOmit<styled_components0.FastOmit<react7.DetailedHTMLProps<react7.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "$open"> & ContentProps, never> & Partial<Pick<styled_components0.FastOmit<react7.DetailedHTMLProps<react7.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "$open"> & ContentProps, never>>> & string;
11
- declare const GlobalStyles: react7.NamedExoticComponent<styled_components0.ExecutionProps & object>;
10
+ declare const Content: styled_components_dist_types0.IStyledComponentBase<"web", styled_components0.FastOmit<styled_components0.FastOmit<react9.DetailedHTMLProps<react9.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "$open"> & ContentProps, never> & Partial<Pick<styled_components0.FastOmit<react9.DetailedHTMLProps<react9.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "$open"> & ContentProps, never>>> & string;
11
+ declare const GlobalStyles: react9.NamedExoticComponent<styled_components0.ExecutionProps & object>;
12
12
  type TemplateType = IStyledComponent<'web', any> & {
13
13
  Container: IStyledComponent<'web', any>;
14
14
  Content: typeof Content;
@@ -55,4 +55,4 @@ import{colors as e}from"../../atoms/style/colors.js";import{spacings as t}from".
55
55
  fill: ${e.interactive.disabled__text.rgba};
56
56
  }
57
57
  }
58
- `,d=i(({checked:e,onToggle:t,icon:n,disabled:i,...s},d)=>{let f=`tooltip`in s?{...s,tooltip:void 0,toolTipPlacement:void 0}:{...s};return l(u,{ref:d,"aria-checked":e,onClick:()=>{t(!e)},disabled:i,...f,children:[n?`tooltip`in s&&s.tooltip?c(r,{title:s.tooltip,placement:s.tooltipPlacement,children:c(a,{data:n,size:24})}):c(a,{data:n,size:24}):null,`label`in s?c(o,{as:`span`,variant:`button`,group:`navigation`,children:s.label}):null]})});d.displayName=`ToggleGroupOption`;export{d as ToggleGroupOption};
58
+ `,d=i(({checked:e,onToggle:t,icon:n,disabled:i,...s},d)=>l(u,{ref:d,"aria-checked":e,onClick:()=>{t(!e)},disabled:i,...`tooltip`in s?{...s,tooltip:void 0,toolTipPlacement:void 0}:{...s},children:[n?`tooltip`in s&&s.tooltip?c(r,{title:s.tooltip,placement:s.tooltipPlacement,children:c(a,{data:n,size:24})}):c(a,{data:n,size:24}):null,`label`in s?c(o,{as:`span`,variant:`button`,group:`navigation`,children:s.label}):null]}));d.displayName=`ToggleGroupOption`;export{d as ToggleGroupOption};
@@ -11,4 +11,4 @@ interface AccountProps {
11
11
  }
12
12
  declare const Account: FC<AccountProps>;
13
13
  //#endregion
14
- export { Account, AccountProps };
14
+ export { Account };
@@ -6,4 +6,4 @@ import{spacings as e}from"../../../atoms/style/spacings.js";import{useAuth as t}
6
6
  background: ${({$variant:e})=>s(e).chipBackground};
7
7
  outline: none;
8
8
  padding: 0;
9
- `,h=l(({onClick:e,environmentToggle:n},s)=>{let{account:l,photo:u}=t(),{data:h}=i(),g=n.length>0,_=n.map(e=>o(e.value)),v=h?.roles?.sort()??[];return f(p,{children:[v.at(0)&&d(m,{$variant:`impersonate`,children:v[0]}),v.length>1&&d(m,{$variant:`impersonate`,children:`+${v.length-1}`}),g&&_.at(0)&&d(m,{$variant:`environment`,children:_[0]}),_.length>1&&d(m,{$variant:`environment`,children:`+${_.length-1}`}),d(a,{ref:s,onClick:e,children:g&&h?d(c,{size:36,variant:`combined`}):g?d(c,{size:36,name:n.map(e=>e.value).join(`, `),variant:`environment`}):h?d(c,{size:36,variant:`impersonate`}):d(r,{size:36,name:l?.name,url:u})})]})});h.displayName=`AccountButton`;export{h as AccountButton,m as StatusChip};
9
+ `,h=l(({onClick:e,environmentToggle:n},s)=>{let{account:l,photo:u}=t(),{data:h}=i(),g=n.length>0,_=n.map(e=>o(e.value)),v=h?.roles?.sort()??[];return f(p,{children:[v.at(0)&&d(m,{$variant:`impersonate`,children:v[0]}),v.length>1&&d(m,{$variant:`impersonate`,children:`+${v.length-1}`}),g&&_.at(0)&&d(m,{$variant:`environment`,children:_[0]}),_.length>1&&d(m,{$variant:`environment`,children:`+${_.length-1}`}),d(a,{ref:s,onClick:e,children:g&&h?d(c,{size:36,variant:`combined`}):g?d(c,{size:36,name:n.map(e=>e.value).join(`, `),variant:`environment`}):h?d(c,{size:36,variant:`impersonate`}):d(r,{size:36,name:l?.name,url:u})})]})});h.displayName=`AccountButton`;export{h as AccountButton};
@@ -1,7 +1,7 @@
1
- import * as react184 from "react";
1
+ import * as react189 from "react";
2
2
  import { HTMLAttributes } from "react";
3
3
 
4
4
  //#region src/organisms/TopBar/Actions.d.ts
5
- declare const Actions: react184.ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & react184.RefAttributes<HTMLDivElement>>;
5
+ declare const Actions: react189.ForwardRefExoticComponent<HTMLAttributes<HTMLDivElement> & react189.RefAttributes<HTMLDivElement>>;
6
6
  //#endregion
7
7
  export { Actions };
@@ -1,5 +1,5 @@
1
1
  import { Field } from "../../../atoms/types/Field.js";
2
- import * as react182 from "react";
2
+ import * as react187 from "react";
3
3
 
4
4
  //#region src/organisms/TopBar/FieldMenu/FieldMenu.d.ts
5
5
  interface FieldMenuProps {
@@ -8,6 +8,6 @@ interface FieldMenuProps {
8
8
  itemNameSingular?: string;
9
9
  showAccessITLink?: boolean;
10
10
  }
11
- declare const FieldMenu: react182.ForwardRefExoticComponent<FieldMenuProps & react182.RefAttributes<HTMLDivElement>>;
11
+ declare const FieldMenu: react187.ForwardRefExoticComponent<FieldMenuProps & react187.RefAttributes<HTMLDivElement>>;
12
12
  //#endregion
13
- export { FieldMenu, FieldMenuProps };
13
+ export { FieldMenu };
@@ -11,4 +11,4 @@ interface GuidelineProps {
11
11
  }
12
12
  declare const Guidelines: FC<GuidelineProps>;
13
13
  //#endregion
14
- export { GuidelineProps, GuidelineSections, Guidelines };
14
+ export { GuidelineSections, Guidelines };
@@ -1,4 +1,4 @@
1
- import * as react231 from "react";
1
+ import * as react235 from "react";
2
2
  import { Dispatch, FC, ReactNode, SetStateAction } from "react";
3
3
 
4
4
  //#region src/organisms/TopBar/Notifications/NotificationProvider.d.ts
@@ -6,7 +6,7 @@ interface NotificationContext {
6
6
  setIsOpen: Dispatch<SetStateAction<boolean>>;
7
7
  isOpen: boolean;
8
8
  }
9
- declare const NotificationContext: react231.Context<NotificationContext | undefined>;
9
+ declare const NotificationContext: react235.Context<NotificationContext | undefined>;
10
10
  declare const useNotification: () => NotificationContext;
11
11
  //#endregion
12
12
  export { useNotification };
@@ -83,4 +83,4 @@ type ExperienceReadyToPublishTypes = {
83
83
  notificationType: NotificationsTypes.EXPERIENCE_READY_TO_PUBLISH;
84
84
  } & NotificationDto;
85
85
  //#endregion
86
- export { DefaultNotificationTypes, Due3WeeksTypes, ExperienceReadyToPublishTypes, MergeBranchOrcaTypes, NotificationDto, NotificationExperienceDto, NotificationsTypes, ReadyToReportNotificationTypes, RequestChangeOrcaTypes, RequestReviewOrcaTypes, ReviewQANotificationsTypes, SignalRMessage, TagDto, userNotification };
86
+ export { DefaultNotificationTypes, Due3WeeksTypes, ExperienceReadyToPublishTypes, MergeBranchOrcaTypes, ReadyToReportNotificationTypes, RequestChangeOrcaTypes, RequestReviewOrcaTypes, ReviewQANotificationsTypes };
@@ -5,4 +5,4 @@ import"../../../../atoms/enums/Environment.js";import{environment as e}from"../.
5
5
  ${e.description} \n \n User agent string: ${navigator.userAgent}`},p=(e,t)=>{let n=t?`selfservice?id=ticket&table=incident&sys_id=`:`now/nav/ui/classic/params/target/incident.do%3Fsys_id%3D`;return`https://equinor${s(import.meta.env.VITE_ENVIRONMENT_NAME)===`production`?``:`test`}.service-now.com/${n}${e}`},m=()=>{if(navigator.userAgent.includes(`Edg`))return`Edge`;if(navigator.userAgent.includes(`Chrome`))return`Chrome`;if(navigator.userAgent.includes(`Safari`))return`Safari`;if(navigator.userAgent.includes(`Firefox`))return`Firefox`},h=e=>{let t=e;e===`Edge`&&(t=`Edg`);let n=RegExp(`${t}/(\\d+(?:\\.\\d+)+)`);return navigator.userAgent.match(n)?.[1]},g=()=>{let e=m();return e?`${e} (${h(e)})`:`Not found`},_=(e,r,i,s,l)=>{let u=i===a.BUG?`:bug: Bug report`:`:bulb: Suggestion`,f=[],m=[];m.push({type:`mrkdwn`,text:`*Title* \n ${e.title}`}),f.push({type:`mrkdwn`,text:` ${t(new Date,{format:`DD. month YYYY`})}`}),e.url&&f.push({type:`mrkdwn`,text:`*<${e.url}|Error URL>*`}),e.urgency&&m.push({type:`mrkdwn`,text:`*Severity* \n ${c(e)} ${d(e.urgency)}`});let h=[{type:`header`,text:{type:`plain_text`,text:u,emoji:!0}},{type:`section`,fields:f},{type:`section`,fields:m},{type:`section`,fields:[{type:`mrkdwn`,text:`*Application*
6
6
  `+o(import.meta.env.VITE_NAME)},{type:`mrkdwn`,text:`*User* \n ${s}`}]},{type:`section`,fields:[{type:`mrkdwn`,text:`*Browser*
7
7
  `+g()},{type:`mrkdwn`,text:`*Field* \n ${n(r??`Not found`)}`}]},{type:`section`,text:{type:`mrkdwn`,text:`*Description*
8
- `+e.description}}];return l&&h.push({type:`section`,text:{type:`mrkdwn`,text:`*<${p(l)}|:link: Click to open the ticket in Service Now>*`}}),h.push({type:`divider`}),JSON.stringify(h)};export{f as createServiceNowDescription,p as createServiceNowUrl,_ as createSlackMessage,g as getBrowserInfo,u as getServiceNowUrgencyNumber,c as getSeverityEmoji,d as getUrgencyDisplayText,l as readUploadedFileAsText};
8
+ `+e.description}}];return l&&h.push({type:`section`,text:{type:`mrkdwn`,text:`*<${p(l)}|:link: Click to open the ticket in Service Now>*`}}),h.push({type:`divider`}),JSON.stringify(h)};export{f as createServiceNowDescription,p as createServiceNowUrl,_ as createSlackMessage,g as getBrowserInfo,u as getServiceNowUrgencyNumber,d as getUrgencyDisplayText,l as readUploadedFileAsText};
@@ -2,6 +2,6 @@ import{OptionalTooltip as e}from"../../../../../molecules/OptionalTooltip/Option
2
2
  white-space: break-spaces;
3
3
  text-align: center;
4
4
  width: 400px;
5
- `,o=t(({show:e,children:t},r)=>{let o=n(()=>e?`The report was successfully submitted to ServiceNow.
5
+ `,o=t(({show:e,children:t},r)=>i(a,{title:n(()=>e?`The report was successfully submitted to ServiceNow.
6
6
  This field is locked so you can retry sending it to the development team.
7
- To reset the form, use the button in the bottom left corner.`:``,[e]);return i(a,{title:o,children:i(`div`,{ref:r,children:t})})});o.displayName=`LockedInputTooltip`;export{o as LockedInputTooltip};
7
+ To reset the form, use the button in the bottom left corner.`:``,[e]),children:i(`div`,{ref:r,children:t})}));o.displayName=`LockedInputTooltip`;export{o as LockedInputTooltip};
@@ -1,3 +1,3 @@
1
1
  import{SingleSelect as e}from"../../../../../molecules/Select/SingleSelect/SingleSelect.js";import{SORTED_BUG_SEVERITY_OPTIONS as t}from"../Feedback.const.js";import{getUrgencyDisplayText as n}from"../Feedback.utils.js";import{useFeedbackContext as r}from"../hooks/useFeedbackContext.js";import{LockedInputTooltip as i}from"./LockedInputTooltip.js";import a from"styled-components";import{jsx as o}from"react/jsx-runtime";const s=a.div`
2
2
  grid-column: 1/2;
3
- `,c=t.map(e=>({value:e,label:n(e)})),l=()=>{let{serviceNowSuccess:t,feedbackContent:a,updateFeedback:l}=r(),u=a.urgency?{value:a.urgency,label:n(a.urgency)}:void 0;return o(s,{children:o(i,{show:t,children:o(e,{items:c,label:`Severity`,meta:`optional`,clearable:!0,disabled:t,value:u,placeholder:`Select error impact`,onSelect:e=>{l(`urgency`,e?.value)}})})})};export{l as Severity};
3
+ `,c=t.map(e=>({value:e,label:n(e)})),l=()=>{let{serviceNowSuccess:t,feedbackContent:a,updateFeedback:l}=r();return o(s,{children:o(i,{show:t,children:o(e,{items:c,label:`Severity`,meta:`optional`,clearable:!0,disabled:t,value:a.urgency?{value:a.urgency,label:n(a.urgency)}:void 0,placeholder:`Select error impact`,onSelect:e=>{l(`urgency`,e?.value)}})})})};export{l as Severity};
@@ -4,4 +4,4 @@ import{tokens as e}from"../../../../../../node_modules/@equinor/eds-tokens/dist/
4
4
  width: 82px;
5
5
  height: 82px;
6
6
  position: relative;
7
- `,_=e=>{let[u,_]=c(``),{error:v,onDelete:y}=e,b=s(()=>{if(!v)return;let t=e.errors[0].code,n=e.errors[0].message;return t===`file-too-large`?n=n.replace(/(\d+ bytes)/,`1MB`):t===`file-invalid-type`&&(n=n.replace(/(\w+\/\w+,)/g,``).replaceAll(`,`,`, `)),`${e.errors[0].code} \n${n}`},[v,e]),x=s(()=>e.file.name,[v,e]),S=s(()=>v?e.errors.find(e=>e.code.includes(`invalid`))?`Invalid file type`:e.errors.find(e=>e.code.includes(`large`))?`Invalid file size`:`Error`:``,[v,e]);return o(()=>{v||(async e=>{let n=await t(e);_(n)})(e.file)},[v,e]),f(g,{children:[d(r,{title:`${x}${v?`: `+b:``}`,children:v?f(a,{children:[d(l,{data:m,color:h.interactive.warning__text.rgba}),d(`div`,{children:S})]}):d(i,{children:d(`img`,{src:u,alt:`Uploaded file: ${x}`})})}),d(n,{"data-testid":`attachment-delete-button`,onClick:y,children:d(l,{color:h.text.static_icons__tertiary.rgba,data:p,size:24})})]})};export{_ as ImageFile};
7
+ `,_=e=>{let[u,_]=c(``),{error:v,onDelete:y}=e,b=s(()=>{if(!v)return;let t=e.errors[0].code,n=e.errors[0].message;return t===`file-too-large`?n=n.replace(/(\d+ bytes)/,`1MB`):t===`file-invalid-type`&&(n=n.replace(/(\w+\/\w+,)/g,``).replaceAll(`,`,`, `)),`${e.errors[0].code} \n${n}`},[v,e]),x=s(()=>e.file.name,[v,e]),S=s(()=>v?e.errors.find(e=>e.code.includes(`invalid`))?`Invalid file type`:e.errors.find(e=>e.code.includes(`large`))?`Invalid file size`:`Error`:``,[v,e]);return o(()=>{v||(async e=>{_(await t(e))})(e.file)},[v,e]),f(g,{children:[d(r,{title:`${x}${v?`: `+b:``}`,children:v?f(a,{children:[d(l,{data:m,color:h.interactive.warning__text.rgba}),d(`div`,{children:S})]}):d(i,{children:d(`img`,{src:u,alt:`Uploaded file: ${x}`})})}),d(n,{"data-testid":`attachment-delete-button`,onClick:y,children:d(l,{color:h.text.static_icons__tertiary.rgba,data:p,size:24})})]})};export{_ as ImageFile};
@@ -2,4 +2,4 @@ import{FileUploadArea as e}from"../../../../../../molecules/FileUploadArea/FileU
2
2
  grid-column: 1/3;
3
3
  display: flex;
4
4
  flex-direction: column;
5
- `;function d(e,t){if(e.length===0||e.length===1)return e;for(let n=0;n<e.length;n++)for(let r=n+1;r<e.length;r++)t(e[n],e[r])&&e.splice(n,1);return e}const f=()=>{let{feedbackAttachments:s,setFeedbackAttachments:f}=n(),[p,m]=o([]),h=(e,t)=>{if(e.length>=1){let t=e.filter(e=>!e.name.startsWith(`.`));new FileReader().readAsDataURL(e[0]);let n=[];s&&n.push(...s);let r=d([...t,...n],(e,t)=>e.name===t.name&&e.size===t.size);f(r)}m(t)},g=e=>{let t=s?.filter(t=>t.name!==e.name&&t.size!==e.size)??[];f(t)},_=e=>{m(p?.filter(t=>t.file.name===e.file.name&&t.file.size!==e.file.size)??[])};return l(u,{children:[c(i,{group:`input`,variant:`label`,children:`Attachments (.jpg, .jpeg, .png) (max 1 MB)`}),l(r,{children:[c(e,{maxSize:t,onDrop:h,accept:{"image/jpeg":[`.jpeg`,`.jpg`],"image/png":[`.png`]},size:`small`}),s?.map(e=>c(a,{onDelete:()=>g(e),file:e},e.name+e.size)),p.map(e=>c(a,{...e,onDelete:()=>_(e),error:!0},e.file.name+e.file.size))]})]})};export{u as Container,f as UploadFile};
5
+ `;function d(e,t){if(e.length===0||e.length===1)return e;for(let n=0;n<e.length;n++)for(let r=n+1;r<e.length;r++)t(e[n],e[r])&&e.splice(n,1);return e}const f=()=>{let{feedbackAttachments:s,setFeedbackAttachments:f}=n(),[p,m]=o([]),h=(e,t)=>{if(e.length>=1){let t=e.filter(e=>!e.name.startsWith(`.`));new FileReader().readAsDataURL(e[0]);let n=[];s&&n.push(...s),f(d([...t,...n],(e,t)=>e.name===t.name&&e.size===t.size))}m(t)},g=e=>{f(s?.filter(t=>t.name!==e.name&&t.size!==e.size)??[])},_=e=>{m(p?.filter(t=>t.file.name===e.file.name&&t.file.size!==e.file.size)??[])};return l(u,{children:[c(i,{group:`input`,variant:`label`,children:`Attachments (.jpg, .jpeg, .png) (max 1 MB)`}),l(r,{children:[c(e,{maxSize:t,onDrop:h,accept:{"image/jpeg":[`.jpeg`,`.jpg`],"image/png":[`.png`]},size:`small`}),s?.map(e=>c(a,{onDelete:()=>g(e),file:e},e.name+e.size)),p.map(e=>c(a,{...e,onDelete:()=>_(e),error:!0},e.file.name+e.file.size))]})]})};export{f as UploadFile};
@@ -1,4 +1,4 @@
1
- import{spacings as e}from"../../../../../atoms/style/spacings.js";import{useFeedbackContext as t}from"../hooks/useFeedbackContext.js";import{ContentWrapper as n}from"../Feedback.styles.js";import{AnimateChangeInHeight as r}from"./AnimateChangeInHeight.js";import{ResponseStatus as i}from"./ResponseStatus.js";import{Success as a}from"./Success.js";import{useEffect as o,useState as s}from"react";import{Button as c}from"@equinor/eds-core-react";import l from"styled-components";import{jsx as u,jsxs as d}from"react/jsx-runtime";import{motion as f}from"motion/react";const p=l(f.div)`
1
+ import{spacings as e}from"../../../../../atoms/style/spacings.js";import{useFeedbackContext as t}from"../hooks/useFeedbackContext.js";import{ContentWrapper as n}from"../Feedback.styles.js";import{AnimateChangeInHeight as r}from"./AnimateChangeInHeight.js";import i from"./ResponseStatus.js";import{Success as a}from"./Success.js";import{useEffect as o,useState as s}from"react";import{Button as c}from"@equinor/eds-core-react";import l from"styled-components";import{jsx as u,jsxs as d}from"react/jsx-runtime";import{motion as f}from"motion/react";const p=l(f.div)`
2
2
  display: flex;
3
3
  gap: ${e.large};
4
4
  height: auto;
@@ -1 +1 @@
1
- import{useFeedbackContext as e}from"../hooks/useFeedbackContext.js";import{RequestStatus as t}from"./RequestStatus.js";import{Fragment as n,jsx as r,jsxs as i}from"react/jsx-runtime";import{WorkItemType as a}from"@equinor/subsurface-app-management";const o=()=>{let{serviceNowRequestResponse:o,workItemRequestResponse:s,selectedType:c}=e();return i(n,{children:[c===a.BUG&&r(t,{title:`Service Now`,requestStatus:o}),r(t,{title:`Development team`,requestStatus:s})]})};export{o as ResponseStatus,o as default};
1
+ import{useFeedbackContext as e}from"../hooks/useFeedbackContext.js";import{RequestStatus as t}from"./RequestStatus.js";import{Fragment as n,jsx as r,jsxs as i}from"react/jsx-runtime";import{WorkItemType as a}from"@equinor/subsurface-app-management";const o=()=>{let{serviceNowRequestResponse:o,workItemRequestResponse:s,selectedType:c}=e();return i(n,{children:[c===a.BUG&&r(t,{title:`Service Now`,requestStatus:o}),r(t,{title:`Development team`,requestStatus:s})]})};export{o as default};
@@ -6,4 +6,4 @@ import{tokens as e}from"../../../../../node_modules/@equinor/eds-tokens/dist/esm
6
6
  padding-left: ${t.large};
7
7
  font-weight: 400;
8
8
  font-size: 16px;
9
- `,d=()=>{let{selectedType:e,serviceNowUrl:t}=n();return o(l,{children:[a(r,{variant:`h3`,children:`Thank you, we have received your ${e===s.BUG?`report!`:`suggestion!`}`}),e===s.BUG&&t.length>0&&a(u,{href:t,children:`See ticket in ServiceNow`})]})};export{u as ServiceNowLink,d as Success};
9
+ `,d=()=>{let{selectedType:e,serviceNowUrl:t}=n();return o(l,{children:[a(r,{variant:`h3`,children:`Thank you, we have received your ${e===s.BUG?`report!`:`suggestion!`}`}),e===s.BUG&&t.length>0&&a(u,{href:t,children:`See ticket in ServiceNow`})]})};export{d as Success};
@@ -10,4 +10,4 @@ interface ResourcesProps {
10
10
  }
11
11
  declare const Resources: FC<ResourcesProps>;
12
12
  //#endregion
13
- export { Resources, ResourcesProps };
13
+ export { Resources };
@@ -18,4 +18,4 @@ import{animation as e}from"../../../atoms/style/animation.js";import{colors as t
18
18
  &:hover {
19
19
  background: ${t.interactive.primary__hover_alt.rgba};
20
20
  }
21
- `,f=({onTutorialStart:e,onClose:n,id:a,name:f})=>{let{startTutorial:p,seenTutorialIDs:m}=u(),h=m.includes(a);return s(d,{onClick:()=>{p(a),e?.(a),n()},children:[h&&s(`header`,{children:[o(r,{data:c,size:16,color:t.interactive.primary__resting.rgba}),o(i,{varinat:`caption`,children:`COMPLETED`})]}),o(i,{variant:`h4`,children:f}),o(r,{data:l,color:t.interactive.primary__resting.rgba})]})};export{f as TutorialItem};
21
+ `,f=({onTutorialStart:e,onClose:n,id:a,name:f})=>{let{startTutorial:p,seenTutorialIDs:m}=u();return s(d,{onClick:()=>{p(a),e?.(a),n()},children:[m.includes(a)&&s(`header`,{children:[o(r,{data:c,size:16,color:t.interactive.primary__resting.rgba}),o(i,{varinat:`caption`,children:`COMPLETED`})]}),o(i,{variant:`h4`,children:f}),o(r,{data:l,color:t.interactive.primary__resting.rgba})]})};export{f as TutorialItem};
@@ -24,4 +24,4 @@ type TopBarType = typeof TopBar$1 & {
24
24
  };
25
25
  declare const TopBar: TopBarType;
26
26
  //#endregion
27
- export { TopBar, type TopBarType };
27
+ export { TopBar };
@@ -24,4 +24,4 @@ import { Faq } from "./Faq/Faq.js";
24
24
  import { ReleaseNotesPage } from "./ReleaseNotesPage/ReleaseNotesPage.js";
25
25
  import { Card as Card$1, CardProps } from "@equinor/eds-core-react";
26
26
  import { EdsDataGridProps as DataGridProps } from "@equinor/eds-data-grid-react";
27
- export { ApiResponseError, BadRequest, Card$1 as Card, type CardProps, type ContentProps, DataGrid, type DataGridProps, Faq, FieldSelector, type FieldSelectorProps, Filter, FilterType, GenericError, type GuidelineSections, type ItemType, MissingAccessToApp, MissingPermissions, PageNotFound, PageTitle, ReleaseNote, type ReleaseNoteProps, ReleaseNotesPage, ServerError, type SettingsSection, SideBar, SideSheet, type SideSheetProps, Status, TableOfContents, type TableOfContentsProps, Template, type TemplateType, ToggleGroup, TopBar$1 as TopBar };
27
+ export { Card$1 as Card, type CardProps, type DataGridProps };
@@ -1 +1 @@
1
- import{Status as e}from"./Status/index.js";import{MissingAccessToApp as t}from"./Status/collections/MissingAccessToApp.js";import{DataGrid as n}from"./DataGrid/DataGrid.js";import{Template as r}from"./Template/Template.js";import{FieldSelector as i}from"./FieldSelector/FieldSelector.js";import{Filter as a}from"./Filter/index.js";import{SideBar as o}from"./SideBar/index.js";import{ReleaseNote as s}from"./ReleaseNote/ReleaseNote.js";import{TopBar as c}from"./TopBar/index.js";import{BadRequest as l}from"./Status/collections/BadRequest.js";import{GenericError as u}from"./Status/collections/GenericError.js";import{MissingPermissions as d}from"./Status/collections/MissingPermissions.js";import{PageNotFound as f}from"./Status/collections/PageNotFound.js";import{ServerError as p}from"./Status/collections/ServerError.js";import{ApiResponseError as m}from"./Status/collections/ApiResponseError.js";import{SideSheet as h}from"./SideSheet/SideSheet.js";import{TableOfContents as g}from"./TableOfContents/TableOfContents.js";import{PageTitle as _}from"./PageTitle/PageTitle.js";import{ToggleGroup as v}from"./ToggleGroup/index.js";import{Faq as y}from"./Faq/Faq.js";import{ReleaseNotesPage as b}from"./ReleaseNotesPage/ReleaseNotesPage.js";import{Card as x}from"@equinor/eds-core-react";export{m as ApiResponseError,l as BadRequest,x as Card,n as DataGrid,y as Faq,i as FieldSelector,a as Filter,u as GenericError,t as MissingAccessToApp,d as MissingPermissions,f as PageNotFound,_ as PageTitle,s as ReleaseNote,b as ReleaseNotesPage,p as ServerError,o as SideBar,h as SideSheet,e as Status,g as TableOfContents,r as Template,v as ToggleGroup,c as TopBar};
1
+ import"./Status/index.js";import"./Status/collections/MissingAccessToApp.js";import"./DataGrid/DataGrid.js";import"./Template/Template.js";import"./FieldSelector/FieldSelector.js";import"./Filter/index.js";import"./SideBar/index.js";import"./ReleaseNote/ReleaseNote.js";import"./TopBar/index.js";import"./Status/collections/BadRequest.js";import"./Status/collections/GenericError.js";import"./Status/collections/MissingPermissions.js";import"./Status/collections/PageNotFound.js";import"./Status/collections/ServerError.js";import"./Status/collections/ApiResponseError.js";import"./SideSheet/SideSheet.js";import"./TableOfContents/TableOfContents.js";import"./PageTitle/PageTitle.js";import"./ToggleGroup/index.js";import"./Faq/Faq.js";import"./ReleaseNotesPage/ReleaseNotesPage.js";import{Card as e}from"@equinor/eds-core-react";export{e as Card};
@@ -1,26 +1,14 @@
1
1
  import { FC, ReactElement, ReactNode } from "react";
2
- import { AccountInfo, AuthenticationResult } from "@azure/msal-browser";
2
+ import { AccountInfo } from "@azure/msal-browser";
3
3
 
4
4
  //#region src/providers/AuthProvider/AuthProvider.d.ts
5
- type AuthState = 'loading' | 'authorized' | 'unauthorized' | 'interactionRequired';
5
+ type AuthState = 'loading' | 'authorized' | 'unauthorized';
6
6
  interface AuthContextType {
7
7
  account: AccountInfo | undefined;
8
8
  photo: string | undefined;
9
9
  roles: string[] | undefined;
10
10
  logout: () => void;
11
11
  authState: AuthState;
12
- /**
13
- * Trigger an interactive popup login. Useful when silent auth cannot
14
- * complete (e.g. embedded in an iframe where third-party cookies are
15
- * blocked). On success the context transitions to `authorized` in place,
16
- * with roles populated, without requiring a page reload.
17
- */
18
- login: () => Promise<void>;
19
- /**
20
- * Acquire a token interactively (popup) for the given scopes, falling back
21
- * to the configured API scope when none are provided.
22
- */
23
- acquireToken: (scopes?: string[]) => Promise<AuthenticationResult | null>;
24
12
  }
25
13
  declare const useAuth: () => AuthContextType;
26
14
  interface AuthProviderProps {
@@ -39,4 +27,4 @@ interface AuthProviderProps {
39
27
  */
40
28
  declare const AuthProvider: FC<AuthProviderProps>;
41
29
  //#endregion
42
- export { AuthContextType, AuthProvider, AuthState, useAuth };
30
+ export { AuthProvider, useAuth };
@@ -1 +1 @@
1
- import{auth as e,environment as t}from"../../atoms/utils/auth_environment.js";import{AuthProviderInner as n}from"./AuthProviderInner.js";import{createContext as r,useContext as i,useMemo as a,useState as o}from"react";import{MsalProvider as s}from"@azure/msal-react";import{jsx as c}from"react/jsx-runtime";import{jwtDecode as l}from"jwt-decode";const{msalApp:u,GRAPH_REQUESTS_LOGIN:d,GRAPH_REQUESTS_BACKEND:f}=e,{getIsMock:p,getMockUserPhoto:m,getMockRoles:h,getApiScope:g}=t,_=r(void 0),v=()=>{let e=i(_);if(e===void 0)throw Error(`useAuth must be used within a AuthContext provider`);return e},y={homeAccountId:`mock-home-account-id`,environment:`mock`,tenantId:`mock-tenant-id`,username:`MOCK@equinor.com`,localAccountId:`mock-local-account-id`,name:`Mock mocksnes`,idToken:`fake`,idTokenClaims:{id:`claim`},nativeAccountId:`accountid`,authorityType:`authority`,tenantProfiles:new Map},b=({children:e,loadingComponent:t,unauthorizedComponent:r,withoutLoader:i=!1,withoutBackend:v=!1})=>{let[b,x]=o(void 0),[S,C]=o(),[w,T]=o(`loading`),[E,D]=o(),O=a(()=>p(import.meta.env.VITE_IS_MOCK),[]),k=a(()=>m(import.meta.env.VITE_MOCK_USER_PHOTO),[]),A=a(()=>h(import.meta.env.VITE_MOCK_ROLES),[]),j=a(()=>g(import.meta.env.VITE_API_SCOPE),[]),M=a(()=>[...d.scopes,j],[j]);return O?(w===`loading`&&setTimeout(()=>{T(`authorized`)},1e3),c(_.Provider,{value:{roles:A,account:y,photo:k,logout:()=>console.log(`Logged out the user!`),authState:w,login:()=>(T(`authorized`),Promise.resolve()),acquireToken:()=>Promise.resolve(null)},children:e})):c(_.Provider,{value:{roles:S,account:b,photo:E,logout:()=>u.logoutRedirect(),authState:w,login:async()=>{let e=await u.loginPopup({scopes:M});e.account&&(u.setActiveAccount(e.account),x(e.account));try{let e=l((await u.acquireTokenSilent(f(j))).accessToken);e.roles&&e.roles.length>0?(C(e.roles),T(`authorized`)):(C(void 0),T(`unauthorized`))}catch(e){throw console.error(`[AuthProvider] Could not acquire roles after interactive login`,e),e}},acquireToken:async e=>{try{return await u.acquireTokenPopup({scopes:e??[j]})}catch(e){return console.error(`[AuthProvider] acquireTokenPopup failed`,e),null}}},children:c(s,{instance:u,children:c(n,{loadingComponent:t,unauthorizedComponent:r,account:b,setAccount:x,setRoles:C,setPhoto:D,authState:w,setAuthState:T,withoutLoader:i,withoutBackend:v,children:e})})})};export{b as AuthProvider,y as MOCK_USER,v as useAuth};
1
+ import{auth as e,environment as t}from"../../atoms/utils/auth_environment.js";import{AuthProviderInner as n}from"./AuthProviderInner.js";import{createContext as r,useContext as i,useMemo as a,useState as o}from"react";import{MsalProvider as s}from"@azure/msal-react";import{jsx as c}from"react/jsx-runtime";const{msalApp:l}=e,{getIsMock:u,getMockUserPhoto:d,getMockRoles:f}=t,p=r(void 0),m=()=>{let e=i(p);if(e===void 0)throw Error(`useAuth must be used within a AuthContext provider`);return e},h={homeAccountId:`mock-home-account-id`,environment:`mock`,tenantId:`mock-tenant-id`,username:`MOCK@equinor.com`,localAccountId:`mock-local-account-id`,name:`Mock mocksnes`,idToken:`fake`,idTokenClaims:{id:`claim`},nativeAccountId:`accountid`,authorityType:`authority`,tenantProfiles:new Map},g=({children:e,loadingComponent:t,unauthorizedComponent:r,withoutLoader:i=!1,withoutBackend:m=!1})=>{let[g,_]=o(void 0),[v,y]=o(),[b,x]=o(`loading`),[S,C]=o(),w=a(()=>u(import.meta.env.VITE_IS_MOCK),[]),T=a(()=>d(import.meta.env.VITE_MOCK_USER_PHOTO),[]),E=a(()=>f(import.meta.env.VITE_MOCK_ROLES),[]);return w?(b===`loading`&&setTimeout(()=>{x(`authorized`)},1e3),c(p.Provider,{value:{roles:E,account:h,photo:T,logout:()=>console.log(`Logged out the user!`),authState:b},children:e})):c(p.Provider,{value:{roles:v,account:g,photo:S,logout:()=>l.logoutRedirect(),authState:b},children:c(s,{instance:l,children:c(n,{loadingComponent:t,unauthorizedComponent:r,account:g,setAccount:_,setRoles:y,setPhoto:C,authState:b,setAuthState:x,withoutLoader:i,withoutBackend:m,children:e})})})};export{g as AuthProvider,m as useAuth};