@box/unified-share-modal 3.4.29 → 3.4.30

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.
@@ -1 +1 @@
1
- import{useUnifiedShareModalContext}from"../esm/lib/contexts/unified-share-modal-context.js";import{formatDateFromTimestampToDateString}from"../esm/lib/utils/date.js";import{callOnKeyboardEvent}from"../esm/lib/utils/event.js";import{getNotificationArgs}from"../esm/lib/utils/notification.js";import messages from"../esm/lib/components/unified-share-form-modal/shared-link-section/messages.js";import{useUnifiedShareFormContext}from"../esm/lib/contexts/unified-share-form-context.js";import{useSharingAction}from"../esm/lib/hooks/use-sharing-action.js";import{t as SharedLinkAccess}from"./shared-link-access.js";import{t as SharedLinkFooter}from"./shared-link-footer.js";import{t as SharedLinkPermission}from"./shared-link-permission.js";import{useCallback,useEffect,useRef}from"react";import{useIntl}from"react-intl";import{Button,Focusable,Link,Status,Switch,Text,Tooltip,useNotification}from"@box/blueprint-web";import{jsx,jsxs}from"react/jsx-runtime";import{ClockBadge}from"@box/blueprint-web-assets/icons/Line";import{CopyInput}from"@box/copy-input";import{Mail}from"@box/blueprint-web-assets/icons/Medium";import{SurfaceStatusSurfaceRed}from"@box/blueprint-web-assets/tokens/tokens";import '../styles/shared-link-section.css';var shared_link_section_module_default={container:`_container_w9erl_1`,toggle:`_toggle_w9erl_7`,settings:`_settings_w9erl_13`,copy:`_copy_w9erl_22`,access:`_access_w9erl_30`};function SharedLinkSection(){let{formatMessage}=useIntl(),{addNotification}=useNotification(),copyInputRef=useRef(null),{isInteracted,isSharedLinkAutoCopied,isSharedLinkAutoCreated,setForm}=useUnifiedShareFormContext(),{config,eventService,isFetching,isSubmitting,item,setView,sharedLink,sharingService}=useUnifiedShareModalContext(),{permissions={}}=item,{onSharedLinkCopy,onSharedLinkSettingsClick}=eventService,{createSharedLink}=sharingService,{notifications,sharedLinkAutoCopy,sharedLinkAutoCreate}=config,hasSharedLink=!!sharedLink.url,isAutoCopyEnabled=sharedLinkAutoCopy&&!isSharedLinkAutoCopied.current&&!isInteracted,isAutoCreateEnabled=sharedLinkAutoCreate&&!isSharedLinkAutoCreated.current&&!isInteracted,{onAction:onCreate}=useSharingAction(useCallback(async()=>{let response=await createSharedLink();return isAutoCopyEnabled?{messages:[]}:response},[isAutoCopyEnabled,createSharedLink]),`create-shared-link`);useEffect(()=>{(async()=>{isFetching||isSubmitting||((isAutoCopyEnabled||isAutoCreateEnabled)&&!hasSharedLink&&!isSharedLinkAutoCreated.current&&(isSharedLinkAutoCreated.current=!0,await onCreate()),isAutoCopyEnabled&&hasSharedLink&&copyInputRef.current&&copyInputRef.current.click())})()},[hasSharedLink,isAutoCopyEnabled,isAutoCreateEnabled,isFetching,isSharedLinkAutoCopied,isSharedLinkAutoCreated,isSubmitting,onCreate]);let handleCopySuccess=useCallback(result=>{if(onSharedLinkCopy&&onSharedLinkCopy(result),!isAutoCopyEnabled)return;isSharedLinkAutoCopied.current=!0;let message;message=typeof result==`string`?isSharedLinkAutoCreated.current?formatMessage(messages.autoCreateCopySuccessNoticeText):formatMessage(messages.autoCopySuccessNoticeText):isSharedLinkAutoCreated.current?formatMessage(messages.autoCreateCopyErrorNoticeText):null,message&&notifications.includes(`auto-copy-shared-link`)&&addNotification({...getNotificationArgs(formatMessage,`success`),styledText:message})},[addNotification,formatMessage,isAutoCopyEnabled,isSharedLinkAutoCopied,isSharedLinkAutoCreated,notifications,onSharedLinkCopy]),handleSharedLinkToggleChange=async checked=>{if(checked){await onCreate();return}setView(`remove-shared-link`)},handleSharedLinkSettingsClick=()=>{if(onSharedLinkSettingsClick){onSharedLinkSettingsClick();return}setView(`shared-link-settings`)},sharedLinkToggleTooltip,isSharedLinkToggleDisabled=!1;return!hasSharedLink&&!isSubmitting&&(sharedLinkToggleTooltip=formatMessage(messages.sharedLinkToggleTooltip)),!hasSharedLink&&!permissions.canShare&&(sharedLinkToggleTooltip=formatMessage(messages.createLinkDisabledTooltip),isSharedLinkToggleDisabled=!0),hasSharedLink&&!permissions.canSetShareAccess&&(sharedLinkToggleTooltip=formatMessage(messages.removeLinkDisabledTooltip),isSharedLinkToggleDisabled=!0),jsxs(`div`,{className:shared_link_section_module_default.container,children:[jsx(Text,{as:`label`,variant:`bodyDefaultBold`,children:formatMessage(messages.shareLinkLabel)}),jsxs(`div`,{className:shared_link_section_module_default.toggle,children:[jsx(Tooltip,{align:`start`,content:sharedLinkToggleTooltip,"data-testid":`usm-SharedLinkToggle-tooltip`,open:sharedLinkToggleTooltip?void 0:!1,children:jsx(Focusable,{focusable:isSharedLinkToggleDisabled,children:jsx(Switch.Item,{autoFocus:!permissions.canInviteCollaborator,checked:hasSharedLink,"data-target-id":`Toggle-CreateSharedLink`,disabled:isSharedLinkToggleDisabled||isSubmitting,label:formatMessage(messages.sharedLinkToggleLabel),onCheckedChange:handleSharedLinkToggleChange,value:`shared-link`})})}),hasSharedLink&&!!sharedLink.expiresAt&&jsx(Tooltip,{content:formatMessage(messages.expirationIconTooltip,{expirationDate:formatDateFromTimestampToDateString(sharedLink.expiresAt)}),"data-testid":`usm-SharedLinkExpiration-tooltip`,children:jsx(Status,{color:SurfaceStatusSurfaceRed,hideText:!0,icon:ClockBadge,text:formatMessage(messages.expirationIconLabel)})}),hasSharedLink&&config.sharedLinkSettings&&jsx(Link,{"aria-disabled":isSubmitting,"aria-haspopup":`dialog`,className:shared_link_section_module_default.settings,"data-target-id":`PlainButton-SharedLinkSettings`,onClick:handleSharedLinkSettingsClick,onKeyDown:callOnKeyboardEvent(handleSharedLinkSettingsClick,{canPreventDefault:!0}),role:`button`,tabIndex:isSubmitting?-1:0,variant:`standalone`,children:formatMessage(messages.sharedLinkSettingsLabel)})]}),hasSharedLink&&jsxs(`div`,{className:shared_link_section_module_default.copy,children:[jsx(CopyInput,{ref:copyInputRef,autoFocus:sharedLinkAutoCreate&&isSharedLinkAutoCreated.current&&!isInteracted,"data-target-id":`Button-CopySharedLink`,disabled:isSubmitting,hideLabel:!0,label:formatMessage(messages.sharedLinkUrlLabel),onCopy:handleCopySuccess,value:sharedLink.url}),config.sharedLinkEmail&&jsx(Tooltip,{align:`end`,content:formatMessage(messages.sharedLinkEmailLabel),children:jsx(Button,{"aria-label":formatMessage(messages.sharedLinkEmailLabel),"data-target-id":`Button-SendSharedLink`,disabled:isSubmitting,endIcon:Mail,onClick:()=>setForm(`email`),size:`large`,variant:`secondary`})})]}),hasSharedLink&&(config.sharedLinkAccess||config.sharedLinkPermission)&&jsxs(`div`,{className:shared_link_section_module_default.access,children:[config.sharedLinkAccess&&jsx(SharedLinkAccess,{}),config.sharedLinkPermission&&jsx(SharedLinkPermission,{})]}),hasSharedLink&&jsx(SharedLinkFooter,{onSharedLinkSettingsClick:handleSharedLinkSettingsClick})]})}export{SharedLinkSection as t};
1
+ import{useUnifiedShareModalContext}from"../esm/lib/contexts/unified-share-modal-context.js";import{formatDateFromTimestampToDateString}from"../esm/lib/utils/date.js";import{callOnKeyboardEvent}from"../esm/lib/utils/event.js";import{getNotificationArgs}from"../esm/lib/utils/notification.js";import messages from"../esm/lib/components/unified-share-form-modal/shared-link-section/messages.js";import{useUnifiedShareFormContext}from"../esm/lib/contexts/unified-share-form-context.js";import{useSharingAction}from"../esm/lib/hooks/use-sharing-action.js";import{t as SharedLinkAccess}from"./shared-link-access.js";import{t as SharedLinkFooter}from"./shared-link-footer.js";import{t as SharedLinkPermission}from"./shared-link-permission.js";import{useCallback,useEffect,useRef}from"react";import{useIntl}from"react-intl";import{Button,Focusable,Link,Status,Switch,Text,Tooltip,useNotification}from"@box/blueprint-web";import{jsx,jsxs}from"react/jsx-runtime";import{ClockBadge}from"@box/blueprint-web-assets/icons/Line";import{CopyInput}from"@box/copy-input";import{Mail}from"@box/blueprint-web-assets/icons/Medium";import{SurfaceStatusSurfaceRed}from"@box/blueprint-web-assets/tokens/tokens";import '../styles/shared-link-section.css';var shared_link_section_module_default={container:`_container_w9erl_1`,toggle:`_toggle_w9erl_7`,settings:`_settings_w9erl_13`,copy:`_copy_w9erl_22`,access:`_access_w9erl_30`};function SharedLinkSection(){let{formatMessage}=useIntl(),{addNotification}=useNotification(),copyInputRef=useRef(null),{isInteracted,isSharedLinkAutoCopied,isSharedLinkAutoCreated,setForm}=useUnifiedShareFormContext(),{config,eventService,isFetching,isSubmitting,item,setView,sharedLink,sharingService}=useUnifiedShareModalContext(),{permissions={}}=item,{onSharedLinkCopy,onSharedLinkSettingsClick}=eventService,{createSharedLink}=sharingService,{notifications,sharedLinkAutoCopy,sharedLinkAutoCreate}=config,hasSharedLink=!!sharedLink.url,isAutoCopyEnabled=sharedLinkAutoCopy&&!isSharedLinkAutoCopied.current&&!isInteracted,isAutoCreateEnabled=sharedLinkAutoCreate&&!isSharedLinkAutoCreated.current&&!isInteracted,{onAction:onCreate}=useSharingAction(useCallback(async()=>{let response=await createSharedLink();return isAutoCopyEnabled?{messages:[]}:response},[isAutoCopyEnabled,createSharedLink]),`create-shared-link`);useEffect(()=>{(async()=>{isFetching||isSubmitting||((isAutoCopyEnabled||isAutoCreateEnabled)&&!hasSharedLink&&!isSharedLinkAutoCreated.current&&(isSharedLinkAutoCreated.current=!0,await onCreate()),isAutoCopyEnabled&&hasSharedLink&&copyInputRef.current&&copyInputRef.current.click())})()},[hasSharedLink,isAutoCopyEnabled,isAutoCreateEnabled,isFetching,isSharedLinkAutoCopied,isSharedLinkAutoCreated,isSubmitting,onCreate]);let handleCopySuccess=useCallback(result=>{if(onSharedLinkCopy&&onSharedLinkCopy(result),!isAutoCopyEnabled)return;isSharedLinkAutoCopied.current=!0;let{otpMode,otpAllowlistItemCount:allowlistCount}=sharedLink.settings??{},isEmptyAllowlist=otpMode===`allowlist`&&!allowlistCount,notification=null;typeof result==`string`?notification=isEmptyAllowlist?{message:formatMessage(messages.copyWithEmptyAllowlistNotice),variant:`warning`}:{message:formatMessage(isSharedLinkAutoCreated.current?messages.autoCreateCopySuccessNoticeText:messages.autoCopySuccessNoticeText),variant:`success`}:isSharedLinkAutoCreated.current&&(notification={message:formatMessage(messages.autoCreateCopyErrorNoticeText),variant:`success`}),notification&&notifications.includes(`auto-copy-shared-link`)&&addNotification({...getNotificationArgs(formatMessage,notification.variant),styledText:notification.message})},[addNotification,formatMessage,isAutoCopyEnabled,isSharedLinkAutoCopied,isSharedLinkAutoCreated,notifications,onSharedLinkCopy,sharedLink.settings]),handleSharedLinkToggleChange=async checked=>{if(checked){await onCreate();return}setView(`remove-shared-link`)},handleSharedLinkSettingsClick=()=>{if(onSharedLinkSettingsClick){onSharedLinkSettingsClick();return}setView(`shared-link-settings`)},sharedLinkToggleTooltip,isSharedLinkToggleDisabled=!1;return!hasSharedLink&&!isSubmitting&&(sharedLinkToggleTooltip=formatMessage(messages.sharedLinkToggleTooltip)),!hasSharedLink&&!permissions.canShare&&(sharedLinkToggleTooltip=formatMessage(messages.createLinkDisabledTooltip),isSharedLinkToggleDisabled=!0),hasSharedLink&&!permissions.canSetShareAccess&&(sharedLinkToggleTooltip=formatMessage(messages.removeLinkDisabledTooltip),isSharedLinkToggleDisabled=!0),jsxs(`div`,{className:shared_link_section_module_default.container,children:[jsx(Text,{as:`label`,variant:`bodyDefaultBold`,children:formatMessage(messages.shareLinkLabel)}),jsxs(`div`,{className:shared_link_section_module_default.toggle,children:[jsx(Tooltip,{align:`start`,content:sharedLinkToggleTooltip,"data-testid":`usm-SharedLinkToggle-tooltip`,open:sharedLinkToggleTooltip?void 0:!1,children:jsx(Focusable,{focusable:isSharedLinkToggleDisabled,children:jsx(Switch.Item,{autoFocus:!permissions.canInviteCollaborator,checked:hasSharedLink,"data-target-id":`Toggle-CreateSharedLink`,disabled:isSharedLinkToggleDisabled||isSubmitting,label:formatMessage(messages.sharedLinkToggleLabel),onCheckedChange:handleSharedLinkToggleChange,value:`shared-link`})})}),hasSharedLink&&!!sharedLink.expiresAt&&jsx(Tooltip,{content:formatMessage(messages.expirationIconTooltip,{expirationDate:formatDateFromTimestampToDateString(sharedLink.expiresAt)}),"data-testid":`usm-SharedLinkExpiration-tooltip`,children:jsx(Status,{color:SurfaceStatusSurfaceRed,hideText:!0,icon:ClockBadge,text:formatMessage(messages.expirationIconLabel)})}),hasSharedLink&&config.sharedLinkSettings&&jsx(Link,{"aria-disabled":isSubmitting,"aria-haspopup":`dialog`,className:shared_link_section_module_default.settings,"data-target-id":`PlainButton-SharedLinkSettings`,onClick:handleSharedLinkSettingsClick,onKeyDown:callOnKeyboardEvent(handleSharedLinkSettingsClick,{canPreventDefault:!0}),role:`button`,tabIndex:isSubmitting?-1:0,variant:`standalone`,children:formatMessage(messages.sharedLinkSettingsLabel)})]}),hasSharedLink&&jsxs(`div`,{className:shared_link_section_module_default.copy,children:[jsx(CopyInput,{ref:copyInputRef,autoFocus:sharedLinkAutoCreate&&isSharedLinkAutoCreated.current&&!isInteracted,"data-target-id":`Button-CopySharedLink`,disabled:isSubmitting,hideLabel:!0,label:formatMessage(messages.sharedLinkUrlLabel),onCopy:handleCopySuccess,value:sharedLink.url}),config.sharedLinkEmail&&jsx(Tooltip,{align:`end`,content:formatMessage(messages.sharedLinkEmailLabel),children:jsx(Button,{"aria-label":formatMessage(messages.sharedLinkEmailLabel),"data-target-id":`Button-SendSharedLink`,disabled:isSubmitting,endIcon:Mail,onClick:()=>setForm(`email`),size:`large`,variant:`secondary`})})]}),hasSharedLink&&(config.sharedLinkAccess||config.sharedLinkPermission)&&jsxs(`div`,{className:shared_link_section_module_default.access,children:[config.sharedLinkAccess&&jsx(SharedLinkAccess,{}),config.sharedLinkPermission&&jsx(SharedLinkPermission,{})]}),hasSharedLink&&jsx(SharedLinkFooter,{onSharedLinkSettingsClick:handleSharedLinkSettingsClick})]})}export{SharedLinkSection as t};
@@ -1 +1 @@
1
- import{defineMessages}from"react-intl";var messages=defineMessages({closeButton:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.closeButton`,defaultMessage:`Close`},shareLinkLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.shareLinkLabel`,defaultMessage:`Share Link`},sharedLinkToggleLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkToggleLabel`,defaultMessage:`Shared link`},sharedLinkToggleTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkToggleTooltip`,defaultMessage:`Create and copy link`},createLinkDisabledTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.createLinkDisabledTooltip`,defaultMessage:`You do not have permission to create the link`},removeLinkDisabledTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.removeLinkDisabledTooltip`,defaultMessage:`You do not have permission to remove the link`},sharedLinkSettingsLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkSettingsLabel`,defaultMessage:`Link Settings`},sharedLinkUrlLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkUrlLabel`,defaultMessage:`Shared link URL`},sharedLinkEmailLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkEmailLabel`,defaultMessage:`Send Shared Link`},sharedLinkPubliclyAvailable:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkPubliclyAvailable`,defaultMessage:`This content is publicly available to anyone with the link.`},sharedLinkEditablePubliclyAvailable:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkEditablePubliclyAvailable`,defaultMessage:`Publicly available for anyone to view and download. Any logged in users with the link can edit.`},sharedLinkElevatedEditableCompanyAvailable:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkElevatedEditableCompanyAvailable`,defaultMessage:`People who have access to this link can edit.`},sharedLinkOtpOffPrompt:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkOtpOffPrompt`,defaultMessage:`This content is publicly available to anyone with the link. Protect this link with a One-Time Passcode. {enableLink}`},sharedLinkOtpOpen:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkOtpOpen`,defaultMessage:`Access is allowed after verifying the One-Time Passcode.`},sharedLinkOtpAccessListCount:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkOtpAccessListCount`,defaultMessage:`{count, plural, one {# item} other {# items}} on the Access List. {configureLink}`},sharedLinkOtpAccessList:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkOtpAccessList`,defaultMessage:`Access is allowed for people on the Access List after verifying the One-Time Passcode. {configureLink}`},sharedLinkEnableOtp:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkEnableOtp`,defaultMessage:`Enable`},sharedLinkConfigureAccessList:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkConfigureAccessList`,defaultMessage:`Configure`},expirationIconLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.expirationIconLabel`,defaultMessage:`Expires`},expirationIconTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.expirationIconTooltip`,defaultMessage:`This link will expire and be inaccessible on {expirationDate}`},openAccessLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.openAccessLevelLabel`,defaultMessage:`People with the link`},openAccessLevelLabelOtp:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.openAccessLevelLabelOtp`,defaultMessage:`Authorized people with the link`},openAccessLevelDescription:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.openAccessLevelDescription`,defaultMessage:`Publicly accessible and no sign-in required`},companyAccessLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.companyAccessLevelLabel`,defaultMessage:`People in your company`},companyAccessLevelDescription:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.companyAccessLevelDescription`,defaultMessage:`Anyone in your company with the link or people invited to this {item} can access`},enterpriseAccessLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.enterpriseAccessLevelLabel`,defaultMessage:`People in {enterprise}`},enterpriseAccessLevelDescription:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.enterpriseAccessLevelDescription`,defaultMessage:`Anyone at {enterprise} with the link or people invited to this {item} can access`},collaboratorsAccessLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.collaboratorsAccessLevelLabel`,defaultMessage:`Invited people only`},collaboratorsAccessLevelDescription:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.collaboratorsAccessLevelDescription`,defaultMessage:`Only invited people can access this {item}`},fileAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.fileAccessLevelItem`,defaultMessage:`file`},folderAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.folderAccessLevelItem`,defaultMessage:`folder`},hubsAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.hubsAccessLevelItem`,defaultMessage:`hub`},promptAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.promptAccessLevelItem`,defaultMessage:`prompt`},webLinkAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.webLinkAccessLevelItem`,defaultMessage:`bookmark`},workflowAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.workflowAccessLevelItem`,defaultMessage:`workflow`},disabledAccessLevelTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.disabledAccessLevelTooltip`,defaultMessage:`This option is not available due to a security policy`},canEditPermissionLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.canEditPermissionLevelLabel`,defaultMessage:`Can edit`},canDownloadPermissionLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.canDownloadPermissionLevelLabel`,defaultMessage:`Can view and download`},canPreviewPermissionLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.canPreviewPermissionLevelLabel`,defaultMessage:`Can view only`},canEditBoxNoteDisabledTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.canEditBoxNoteDisabledTooltip`,defaultMessage:`This permission can only be changed in Box Notes`},autoCreateCopyErrorNoticeText:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.autoCreateCopyErrorNoticeText`,defaultMessage:`Shared link created. Click Copy to share.`},autoCreateCopySuccessNoticeText:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.autoCreateCopySuccessNoticeText`,defaultMessage:`Shared link created and copied to clipboard.`},autoCopySuccessNoticeText:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.autoCopySuccessNoticeText`,defaultMessage:`Shared link copied to clipboard.`}});export{messages as default};
1
+ import{defineMessages}from"react-intl";var messages=defineMessages({closeButton:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.closeButton`,defaultMessage:`Close`},shareLinkLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.shareLinkLabel`,defaultMessage:`Share Link`},sharedLinkToggleLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkToggleLabel`,defaultMessage:`Shared link`},sharedLinkToggleTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkToggleTooltip`,defaultMessage:`Create and copy link`},createLinkDisabledTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.createLinkDisabledTooltip`,defaultMessage:`You do not have permission to create the link`},removeLinkDisabledTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.removeLinkDisabledTooltip`,defaultMessage:`You do not have permission to remove the link`},sharedLinkSettingsLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkSettingsLabel`,defaultMessage:`Link Settings`},sharedLinkUrlLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkUrlLabel`,defaultMessage:`Shared link URL`},sharedLinkEmailLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkEmailLabel`,defaultMessage:`Send Shared Link`},sharedLinkPubliclyAvailable:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkPubliclyAvailable`,defaultMessage:`This content is publicly available to anyone with the link.`},sharedLinkEditablePubliclyAvailable:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkEditablePubliclyAvailable`,defaultMessage:`Publicly available for anyone to view and download. Any logged in users with the link can edit.`},sharedLinkElevatedEditableCompanyAvailable:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkElevatedEditableCompanyAvailable`,defaultMessage:`People who have access to this link can edit.`},sharedLinkOtpOffPrompt:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkOtpOffPrompt`,defaultMessage:`This content is publicly available to anyone with the link. Protect this link with a One-Time Passcode. {enableLink}`},sharedLinkOtpOpen:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkOtpOpen`,defaultMessage:`Access is allowed after verifying the One-Time Passcode.`},sharedLinkOtpAccessListCount:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkOtpAccessListCount`,defaultMessage:`{count, plural, one {# item} other {# items}} on the Access List. {configureLink}`},sharedLinkOtpAccessList:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkOtpAccessList`,defaultMessage:`Access is allowed for people on the Access List after verifying the One-Time Passcode. {configureLink}`},sharedLinkEnableOtp:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkEnableOtp`,defaultMessage:`Enable`},sharedLinkConfigureAccessList:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.sharedLinkConfigureAccessList`,defaultMessage:`Configure`},expirationIconLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.expirationIconLabel`,defaultMessage:`Expires`},expirationIconTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.expirationIconTooltip`,defaultMessage:`This link will expire and be inaccessible on {expirationDate}`},openAccessLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.openAccessLevelLabel`,defaultMessage:`People with the link`},openAccessLevelLabelOtp:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.openAccessLevelLabelOtp`,defaultMessage:`Authorized people`},openAccessLevelDescription:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.openAccessLevelDescription`,defaultMessage:`Publicly accessible and no sign-in required`},companyAccessLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.companyAccessLevelLabel`,defaultMessage:`People in your company`},companyAccessLevelDescription:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.companyAccessLevelDescription`,defaultMessage:`Anyone in your company with the link or people invited to this {item} can access`},enterpriseAccessLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.enterpriseAccessLevelLabel`,defaultMessage:`People in {enterprise}`},enterpriseAccessLevelDescription:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.enterpriseAccessLevelDescription`,defaultMessage:`Anyone at {enterprise} with the link or people invited to this {item} can access`},collaboratorsAccessLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.collaboratorsAccessLevelLabel`,defaultMessage:`Invited people only`},collaboratorsAccessLevelDescription:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.collaboratorsAccessLevelDescription`,defaultMessage:`Only invited people can access this {item}`},fileAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.fileAccessLevelItem`,defaultMessage:`file`},folderAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.folderAccessLevelItem`,defaultMessage:`folder`},hubsAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.hubsAccessLevelItem`,defaultMessage:`hub`},promptAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.promptAccessLevelItem`,defaultMessage:`prompt`},webLinkAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.webLinkAccessLevelItem`,defaultMessage:`bookmark`},workflowAccessLevelItem:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.workflowAccessLevelItem`,defaultMessage:`workflow`},disabledAccessLevelTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.disabledAccessLevelTooltip`,defaultMessage:`This option is not available due to a security policy`},canEditPermissionLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.canEditPermissionLevelLabel`,defaultMessage:`Can edit`},canDownloadPermissionLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.canDownloadPermissionLevelLabel`,defaultMessage:`Can view and download`},canPreviewPermissionLevelLabel:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.canPreviewPermissionLevelLabel`,defaultMessage:`Can view only`},canEditBoxNoteDisabledTooltip:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.canEditBoxNoteDisabledTooltip`,defaultMessage:`This permission can only be changed in Box Notes`},autoCreateCopyErrorNoticeText:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.autoCreateCopyErrorNoticeText`,defaultMessage:`Shared link created. Click Copy to share.`},autoCreateCopySuccessNoticeText:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.autoCreateCopySuccessNoticeText`,defaultMessage:`Shared link created and copied to clipboard.`},autoCopySuccessNoticeText:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.autoCopySuccessNoticeText`,defaultMessage:`Shared link copied to clipboard.`},copyWithEmptyAllowlistNotice:{id:`groupSharedFeatures.usm.unifiedShareFormModal.sharedLinkSection.copyWithEmptyAllowlistNotice`,defaultMessage:`Link copied. Consider adding recipients to the access list`}});export{messages as default};
@@ -214,5 +214,10 @@ declare const messages: {
214
214
  description: string;
215
215
  id: string;
216
216
  };
217
+ copyWithEmptyAllowlistNotice: {
218
+ defaultMessage: string;
219
+ description: string;
220
+ id: string;
221
+ };
217
222
  };
218
223
  export default messages;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@box/unified-share-modal",
3
- "version": "3.4.29",
3
+ "version": "3.4.30",
4
4
  "license": "SEE LICENSE IN LICENSE",
5
5
  "peerDependencies": {
6
6
  "@box/blueprint-web": "^17.9.0",