UNPKG

@angular/material

Version:
1 lines 33.6 kB
{"version":3,"file":"bottom-sheet.mjs","sources":["../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/bottom-sheet/bottom-sheet-container.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/bottom-sheet/bottom-sheet-container.html","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/bottom-sheet/bottom-sheet-config.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/bottom-sheet/bottom-sheet-ref.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/bottom-sheet/bottom-sheet.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/bottom-sheet/bottom-sheet-module.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {CdkDialogContainer} from '@angular/cdk/dialog';\nimport {BreakpointObserver, Breakpoints} from '@angular/cdk/layout';\nimport {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n OnDestroy,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport {Subscription} from 'rxjs';\nimport {CdkPortalOutlet} from '@angular/cdk/portal';\nimport {_animationsDisabled} from '../core';\n\nconst ENTER_ANIMATION = '_mat-bottom-sheet-enter';\nconst EXIT_ANIMATION = '_mat-bottom-sheet-exit';\n\n/**\n * Internal component that wraps user-provided bottom sheet content.\n * @docs-private\n */\n@Component({\n selector: 'mat-bottom-sheet-container',\n templateUrl: 'bottom-sheet-container.html',\n styleUrl: 'bottom-sheet-container.css',\n // In Ivy embedded views will be change detected from their declaration place, rather than where\n // they were stamped out. This means that we can't have the bottom sheet container be OnPush,\n // because it might cause the sheets that were opened from a template not to be out of date.\n // tslint:disable-next-line:validate-decorators\n changeDetection: ChangeDetectionStrategy.Default,\n encapsulation: ViewEncapsulation.None,\n host: {\n 'class': 'mat-bottom-sheet-container',\n '[class.mat-bottom-sheet-container-animations-enabled]': '!_animationsDisabled',\n '[class.mat-bottom-sheet-container-enter]': '_animationState === \"visible\"',\n '[class.mat-bottom-sheet-container-exit]': '_animationState === \"hidden\"',\n 'tabindex': '-1',\n '[attr.role]': '_config.role',\n '[attr.aria-modal]': '_config.ariaModal',\n '[attr.aria-label]': '_config.ariaLabel',\n '(animationstart)': '_handleAnimationEvent(true, $event.animationName)',\n '(animationend)': '_handleAnimationEvent(false, $event.animationName)',\n '(animationcancel)': '_handleAnimationEvent(false, $event.animationName)',\n },\n imports: [CdkPortalOutlet],\n})\nexport class MatBottomSheetContainer extends CdkDialogContainer implements OnDestroy {\n private _breakpointSubscription: Subscription;\n protected _animationsDisabled = _animationsDisabled();\n\n /** The state of the bottom sheet animations. */\n _animationState: 'void' | 'visible' | 'hidden' = 'void';\n\n /** Emits whenever the state of the animation changes. */\n _animationStateChanged = new EventEmitter<{\n toState: 'visible' | 'hidden';\n phase: 'start' | 'done';\n }>();\n\n /** Whether the component has been destroyed. */\n private _destroyed: boolean;\n\n constructor(...args: unknown[]);\n\n constructor() {\n super();\n\n const breakpointObserver = inject(BreakpointObserver);\n\n this._breakpointSubscription = breakpointObserver\n .observe([Breakpoints.Medium, Breakpoints.Large, Breakpoints.XLarge])\n .subscribe(() => {\n const classList = (this._elementRef.nativeElement as HTMLElement).classList;\n\n classList.toggle(\n 'mat-bottom-sheet-container-medium',\n breakpointObserver.isMatched(Breakpoints.Medium),\n );\n classList.toggle(\n 'mat-bottom-sheet-container-large',\n breakpointObserver.isMatched(Breakpoints.Large),\n );\n classList.toggle(\n 'mat-bottom-sheet-container-xlarge',\n breakpointObserver.isMatched(Breakpoints.XLarge),\n );\n });\n }\n\n /** Begin animation of bottom sheet entrance into view. */\n enter(): void {\n if (!this._destroyed) {\n this._animationState = 'visible';\n this._changeDetectorRef.markForCheck();\n this._changeDetectorRef.detectChanges();\n if (this._animationsDisabled) {\n this._simulateAnimation(ENTER_ANIMATION);\n }\n }\n }\n\n /** Begin animation of the bottom sheet exiting from view. */\n exit(): void {\n if (!this._destroyed) {\n this._elementRef.nativeElement.setAttribute('mat-exit', '');\n this._animationState = 'hidden';\n this._changeDetectorRef.markForCheck();\n if (this._animationsDisabled) {\n this._simulateAnimation(EXIT_ANIMATION);\n }\n }\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n this._breakpointSubscription.unsubscribe();\n this._destroyed = true;\n }\n\n private _simulateAnimation(name: typeof ENTER_ANIMATION | typeof EXIT_ANIMATION) {\n this._ngZone.run(() => {\n this._handleAnimationEvent(true, name);\n setTimeout(() => this._handleAnimationEvent(false, name));\n });\n }\n\n protected override _trapFocus(): void {\n // The bottom sheet starts off-screen and animates in, and at the same time we trap focus\n // within it. With some styles this appears to cause the page to jump around. See:\n // https://github.com/angular/components/issues/30774. Preventing the browser from\n // scrolling resolves the issue and isn't really necessary since the bottom sheet\n // normally isn't scrollable.\n super._trapFocus({preventScroll: true});\n }\n\n protected _handleAnimationEvent(isStart: boolean, animationName: string) {\n const isEnter = animationName === ENTER_ANIMATION;\n const isExit = animationName === EXIT_ANIMATION;\n\n if (isEnter || isExit) {\n this._animationStateChanged.emit({\n toState: isEnter ? 'visible' : 'hidden',\n phase: isStart ? 'start' : 'done',\n });\n }\n }\n}\n","<ng-template cdkPortalOutlet></ng-template>\r\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {InjectionToken, Injector, ViewContainerRef} from '@angular/core';\nimport {Direction} from '@angular/cdk/bidi';\nimport {ScrollStrategy} from '@angular/cdk/overlay';\n\n/** Options for where to set focus to automatically on dialog open */\nexport type AutoFocusTarget = 'dialog' | 'first-tabbable' | 'first-heading';\n\n/** Injection token that can be used to access the data that was passed in to a bottom sheet. */\nexport const MAT_BOTTOM_SHEET_DATA = new InjectionToken<any>('MatBottomSheetData');\n\n/**\n * Configuration used when opening a bottom sheet.\n */\nexport class MatBottomSheetConfig<D = any> {\n /** The view container to place the overlay for the bottom sheet into. */\n viewContainerRef?: ViewContainerRef;\n\n /**\n * Injector used for the instantiation of the component to be attached. If provided,\n * takes precedence over the injector indirectly provided by `ViewContainerRef`.\n */\n injector?: Injector;\n\n /** Extra CSS classes to be added to the bottom sheet container. */\n panelClass?: string | string[];\n\n /** Text layout direction for the bottom sheet. */\n direction?: Direction;\n\n /** Data being injected into the child component. */\n data?: D | null = null;\n\n /** Whether the bottom sheet has a backdrop. */\n hasBackdrop?: boolean = true;\n\n /** Custom class for the backdrop. */\n backdropClass?: string;\n\n /** Whether the user can use escape or clicking outside to close the bottom sheet. */\n disableClose?: boolean = false;\n\n /** Aria label to assign to the bottom sheet element. */\n ariaLabel?: string | null = null;\n\n /**\n * Whether this is a modal dialog. Used to set the `aria-modal` attribute. Off by default,\n * because it can interfere with other overlay-based components (e.g. `mat-select`) and because\n * it is redundant since the dialog marks all outside content as `aria-hidden` anyway.\n */\n ariaModal?: boolean = false;\n\n /**\n * Whether the bottom sheet should close when the user goes backwards/forwards in history.\n * Note that this usually doesn't include clicking on links (unless the user is using\n * the `HashLocationStrategy`).\n */\n closeOnNavigation?: boolean = true;\n\n /**\n * Where the bottom sheet should focus on open.\n * @breaking-change 14.0.0 Remove boolean option from autoFocus. Use string or\n * AutoFocusTarget instead.\n */\n autoFocus?: AutoFocusTarget | string | boolean = 'first-tabbable';\n\n /**\n * Whether the bottom sheet should restore focus to the\n * previously-focused element, after it's closed.\n */\n restoreFocus?: boolean = true;\n\n /** Scroll strategy to be used for the bottom sheet. */\n scrollStrategy?: ScrollStrategy;\n\n /** Height for the bottom sheet. */\n height?: string = '';\n\n /** Minimum height for the bottom sheet. If a number is provided, assumes pixel units. */\n minHeight?: number | string;\n\n /** Maximum height for the bottom sheet. If a number is provided, assumes pixel units. */\n maxHeight?: number | string;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {ComponentRef} from '@angular/core';\nimport {DialogRef} from '@angular/cdk/dialog';\nimport {ESCAPE, hasModifierKey} from '@angular/cdk/keycodes';\nimport {merge, Observable, Subject} from 'rxjs';\nimport {filter, take} from 'rxjs/operators';\nimport {MatBottomSheetConfig} from './bottom-sheet-config';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\n\n/**\n * Reference to a bottom sheet dispatched from the bottom sheet service.\n */\nexport class MatBottomSheetRef<T = any, R = any> {\n /** Instance of the component making up the content of the bottom sheet. */\n get instance(): T {\n return this._ref.componentInstance!;\n }\n\n /**\n * `ComponentRef` of the component opened into the bottom sheet. Will be\n * null when the bottom sheet is opened using a `TemplateRef`.\n */\n get componentRef(): ComponentRef<T> | null {\n return this._ref.componentRef;\n }\n\n /**\n * Instance of the component into which the bottom sheet content is projected.\n * @docs-private\n */\n containerInstance: MatBottomSheetContainer;\n\n /** Whether the user is allowed to close the bottom sheet. */\n disableClose: boolean | undefined;\n\n /** Subject for notifying the user that the bottom sheet has opened and appeared. */\n private readonly _afterOpened = new Subject<void>();\n\n /** Result to be passed down to the `afterDismissed` stream. */\n private _result: R | undefined;\n\n /** Handle to the timeout that's running as a fallback in case the exit animation doesn't fire. */\n private _closeFallbackTimeout: ReturnType<typeof setTimeout>;\n\n constructor(\n private _ref: DialogRef<R, T>,\n config: MatBottomSheetConfig,\n containerInstance: MatBottomSheetContainer,\n ) {\n this.containerInstance = containerInstance;\n this.disableClose = config.disableClose;\n\n // Emit when opening animation completes\n containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phase === 'done' && event.toState === 'visible'),\n take(1),\n )\n .subscribe(() => {\n this._afterOpened.next();\n this._afterOpened.complete();\n });\n\n // Dispose overlay when closing animation is complete\n containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phase === 'done' && event.toState === 'hidden'),\n take(1),\n )\n .subscribe(() => {\n clearTimeout(this._closeFallbackTimeout);\n this._ref.close(this._result);\n });\n\n _ref.overlayRef.detachments().subscribe(() => {\n this._ref.close(this._result);\n });\n\n merge(\n this.backdropClick(),\n this.keydownEvents().pipe(filter(event => event.keyCode === ESCAPE)),\n ).subscribe(event => {\n if (\n !this.disableClose &&\n (event.type !== 'keydown' || !hasModifierKey(event as KeyboardEvent))\n ) {\n event.preventDefault();\n this.dismiss();\n }\n });\n }\n\n /**\n * Dismisses the bottom sheet.\n * @param result Data to be passed back to the bottom sheet opener.\n */\n dismiss(result?: R): void {\n if (!this.containerInstance) {\n return;\n }\n\n // Transition the backdrop in parallel to the bottom sheet.\n this.containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phase === 'start'),\n take(1),\n )\n .subscribe(() => {\n // The logic that disposes of the overlay depends on the exit animation completing, however\n // it isn't guaranteed if the parent view is destroyed while it's running. Add a fallback\n // timeout which will clean everything up if the animation hasn't fired within the specified\n // amount of time plus 100ms. We don't need to run this outside the NgZone, because for the\n // vast majority of cases the timeout will have been cleared before it has fired.\n this._closeFallbackTimeout = setTimeout(() => this._ref.close(this._result), 500);\n this._ref.overlayRef.detachBackdrop();\n });\n\n this._result = result;\n this.containerInstance.exit();\n this.containerInstance = null!;\n }\n\n /** Gets an observable that is notified when the bottom sheet is finished closing. */\n afterDismissed(): Observable<R | undefined> {\n return this._ref.closed;\n }\n\n /** Gets an observable that is notified when the bottom sheet has opened and appeared. */\n afterOpened(): Observable<void> {\n return this._afterOpened;\n }\n\n /**\n * Gets an observable that emits when the overlay's backdrop has been clicked.\n */\n backdropClick(): Observable<MouseEvent> {\n return this._ref.backdropClick;\n }\n\n /**\n * Gets an observable that emits when keydown events are targeted on the overlay.\n */\n keydownEvents(): Observable<KeyboardEvent> {\n return this._ref.keydownEvents;\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {Dialog} from '@angular/cdk/dialog';\nimport {createBlockScrollStrategy, createGlobalPositionStrategy} from '@angular/cdk/overlay';\nimport {ComponentType} from '@angular/cdk/portal';\nimport {Injectable, TemplateRef, InjectionToken, OnDestroy, inject, Injector} from '@angular/core';\nimport {MAT_BOTTOM_SHEET_DATA, MatBottomSheetConfig} from './bottom-sheet-config';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\nimport {MatBottomSheetRef} from './bottom-sheet-ref';\nimport {_animationsDisabled} from '../core';\n\n/** Injection token that can be used to specify default bottom sheet options. */\nexport const MAT_BOTTOM_SHEET_DEFAULT_OPTIONS = new InjectionToken<MatBottomSheetConfig>(\n 'mat-bottom-sheet-default-options',\n);\n\n/**\n * Service to trigger Material Design bottom sheets.\n */\n@Injectable({providedIn: 'root'})\nexport class MatBottomSheet implements OnDestroy {\n private _injector = inject(Injector);\n private _parentBottomSheet = inject(MatBottomSheet, {optional: true, skipSelf: true});\n private _animationsDisabled = _animationsDisabled();\n private _defaultOptions = inject<MatBottomSheetConfig>(MAT_BOTTOM_SHEET_DEFAULT_OPTIONS, {\n optional: true,\n });\n\n private _bottomSheetRefAtThisLevel: MatBottomSheetRef<any> | null = null;\n private _dialog = inject(Dialog);\n\n /** Reference to the currently opened bottom sheet. */\n get _openedBottomSheetRef(): MatBottomSheetRef<any> | null {\n const parent = this._parentBottomSheet;\n return parent ? parent._openedBottomSheetRef : this._bottomSheetRefAtThisLevel;\n }\n\n set _openedBottomSheetRef(value: MatBottomSheetRef<any> | null) {\n if (this._parentBottomSheet) {\n this._parentBottomSheet._openedBottomSheetRef = value;\n } else {\n this._bottomSheetRefAtThisLevel = value;\n }\n }\n\n constructor(...args: unknown[]);\n constructor() {}\n\n /**\n * Opens a bottom sheet containing the given component.\n * @param component Type of the component to load into the bottom sheet.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened bottom sheet.\n */\n open<T, D = any, R = any>(\n component: ComponentType<T>,\n config?: MatBottomSheetConfig<D>,\n ): MatBottomSheetRef<T, R>;\n\n /**\n * Opens a bottom sheet containing the given template.\n * @param template TemplateRef to instantiate as the bottom sheet content.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened bottom sheet.\n */\n open<T, D = any, R = any>(\n template: TemplateRef<T>,\n config?: MatBottomSheetConfig<D>,\n ): MatBottomSheetRef<T, R>;\n\n open<T, D = any, R = any>(\n componentOrTemplateRef: ComponentType<T> | TemplateRef<T>,\n config?: MatBottomSheetConfig<D>,\n ): MatBottomSheetRef<T, R> {\n const _config = {...(this._defaultOptions || new MatBottomSheetConfig()), ...config};\n let ref: MatBottomSheetRef<T, R>;\n\n this._dialog.open<R, D, T>(componentOrTemplateRef, {\n ..._config,\n // Disable closing since we need to sync it up to the animation ourselves.\n disableClose: true,\n // Disable closing on detachments so that we can sync up the animation.\n closeOnOverlayDetachments: false,\n maxWidth: '100%',\n container: MatBottomSheetContainer,\n scrollStrategy: _config.scrollStrategy || createBlockScrollStrategy(this._injector),\n positionStrategy: createGlobalPositionStrategy(this._injector)\n .centerHorizontally()\n .bottom('0'),\n disableAnimations: this._animationsDisabled,\n templateContext: () => ({bottomSheetRef: ref}),\n providers: (cdkRef, _cdkConfig, container) => {\n ref = new MatBottomSheetRef(cdkRef, _config, container as MatBottomSheetContainer);\n return [\n {provide: MatBottomSheetRef, useValue: ref},\n {provide: MAT_BOTTOM_SHEET_DATA, useValue: _config.data},\n ];\n },\n });\n\n // When the bottom sheet is dismissed, clear the reference to it.\n ref!.afterDismissed().subscribe(() => {\n // Clear the bottom sheet ref if it hasn't already been replaced by a newer one.\n if (this._openedBottomSheetRef === ref) {\n this._openedBottomSheetRef = null;\n }\n });\n\n if (this._openedBottomSheetRef) {\n // If a bottom sheet is already in view, dismiss it and enter the\n // new bottom sheet after exit animation is complete.\n this._openedBottomSheetRef.afterDismissed().subscribe(() => ref.containerInstance?.enter());\n this._openedBottomSheetRef.dismiss();\n } else {\n // If no bottom sheet is in view, enter the new bottom sheet.\n ref!.containerInstance.enter();\n }\n\n this._openedBottomSheetRef = ref!;\n return ref!;\n }\n\n /**\n * Dismisses the currently-visible bottom sheet.\n * @param result Data to pass to the bottom sheet instance.\n */\n dismiss<R = any>(result?: R): void {\n if (this._openedBottomSheetRef) {\n this._openedBottomSheetRef.dismiss(result);\n }\n }\n\n ngOnDestroy() {\n if (this._bottomSheetRefAtThisLevel) {\n this._bottomSheetRefAtThisLevel.dismiss();\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {DialogModule} from '@angular/cdk/dialog';\nimport {PortalModule} from '@angular/cdk/portal';\nimport {NgModule} from '@angular/core';\nimport {BidiModule} from '@angular/cdk/bidi';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\nimport {MatBottomSheet} from './bottom-sheet';\n\n@NgModule({\n imports: [DialogModule, PortalModule, MatBottomSheetContainer],\n exports: [MatBottomSheetContainer, BidiModule],\n providers: [MatBottomSheet],\n})\nexport class MatBottomSheetModule {}\n"],"names":["ENTER_ANIMATION","EXIT_ANIMATION","MatBottomSheetContainer","CdkDialogContainer","_breakpointSubscription","_animationsDisabled","_animationState","_animationStateChanged","EventEmitter","_destroyed","constructor","breakpointObserver","inject","BreakpointObserver","observe","Breakpoints","Medium","Large","XLarge","subscribe","classList","_elementRef","nativeElement","toggle","isMatched","enter","_changeDetectorRef","markForCheck","detectChanges","_simulateAnimation","exit","setAttribute","ngOnDestroy","unsubscribe","name","_ngZone","run","_handleAnimationEvent","setTimeout","_trapFocus","preventScroll","isStart","animationName","isEnter","isExit","emit","toState","phase","deps","target","i0","ɵɵFactoryTarget","Component","isStandalone","selector","host","attributes","listeners","properties","classAttribute","usesInheritance","ngImport","template","styles","dependencies","kind","type","CdkPortalOutlet","inputs","outputs","exportAs","changeDetection","ChangeDetectionStrategy","Default","encapsulation","ViewEncapsulation","None","decorators","imports","MAT_BOTTOM_SHEET_DATA","InjectionToken","MatBottomSheetConfig","viewContainerRef","injector","panelClass","direction","data","hasBackdrop","backdropClass","disableClose","ariaLabel","ariaModal","closeOnNavigation","autoFocus","restoreFocus","scrollStrategy","height","minHeight","maxHeight","MatBottomSheetRef","_ref","instance","componentInstance","componentRef","containerInstance","_afterOpened","Subject","_result","_closeFallbackTimeout","config","pipe","filter","event","take","next","complete","clearTimeout","close","overlayRef","detachments","merge","backdropClick","keydownEvents","keyCode","ESCAPE","hasModifierKey","preventDefault","dismiss","result","detachBackdrop","afterDismissed","closed","afterOpened","MAT_BOTTOM_SHEET_DEFAULT_OPTIONS","MatBottomSheet","_injector","Injector","_parentBottomSheet","optional","skipSelf","_defaultOptions","_bottomSheetRefAtThisLevel","_dialog","Dialog","_openedBottomSheetRef","parent","value","open","componentOrTemplateRef","_config","ref","closeOnOverlayDetachments","maxWidth","container","createBlockScrollStrategy","positionStrategy","createGlobalPositionStrategy","centerHorizontally","bottom","disableAnimations","templateContext","bottomSheetRef","providers","cdkRef","_cdkConfig","provide","useValue","Injectable","ɵprov","ɵɵngDeclareInjectable","minVersion","version","providedIn","MatBottomSheetModule","NgModule","DialogModule","PortalModule","exports","BidiModule","args"],"mappings":";;;;;;;;;;;;AAsBA,MAAMA,eAAe,GAAG,yBAAyB;AACjD,MAAMC,cAAc,GAAG,wBAAwB;AA+BzC,MAAOC,uBAAwB,SAAQC,kBAAkB,CAAA;EACrDC,uBAAuB;EACrBC,mBAAmB,GAAGA,mBAAmB,EAAE;AAGrDC,EAAAA,eAAe,GAAkC,MAAM;AAGvDC,EAAAA,sBAAsB,GAAG,IAAIC,YAAY,EAGrC;EAGIC,UAAU;AAIlBC,EAAAA,WAAAA,GAAA;AACE,IAAA,KAAK,EAAE;AAEP,IAAA,MAAMC,kBAAkB,GAAGC,MAAM,CAACC,kBAAkB,CAAC;IAErD,IAAI,CAACT,uBAAuB,GAAGO,kBAAkB,CAC9CG,OAAO,CAAC,CAACC,WAAW,CAACC,MAAM,EAAED,WAAW,CAACE,KAAK,EAAEF,WAAW,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