UNPKG

@angular/material

Version:
1 lines 33.7 kB
{"version":3,"file":"checkbox.mjs","sources":["../../../../../../src/material/checkbox/checkbox-config.ts","../../../../../../src/material/checkbox/checkbox.ts","../../../../../../src/material/checkbox/checkbox.html","../../../../../../src/material/checkbox/checkbox-required-validator.ts","../../../../../../src/material/checkbox/checkbox-module.ts","../../../../../../src/material/checkbox/public-api.ts","../../../../../../src/material/checkbox/index.ts","../../../../../../src/material/checkbox/checkbox_public_index.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.io/license\n */\nimport {InjectionToken} from '@angular/core';\nimport {ThemePalette} from '@angular/material/core';\n\n/** Default `mat-checkbox` options that can be overridden. */\nexport interface MatCheckboxDefaultOptions {\n /** Default theme color palette to be used for checkboxes. */\n color?: ThemePalette;\n /** Default checkbox click action for checkboxes. */\n clickAction?: MatCheckboxClickAction;\n}\n\n/** Injection token to be used to override the default options for `mat-checkbox`. */\nexport const MAT_CHECKBOX_DEFAULT_OPTIONS = new InjectionToken<MatCheckboxDefaultOptions>(\n 'mat-checkbox-default-options',\n {\n providedIn: 'root',\n factory: MAT_CHECKBOX_DEFAULT_OPTIONS_FACTORY,\n },\n);\n\n/** @docs-private */\nexport function MAT_CHECKBOX_DEFAULT_OPTIONS_FACTORY(): MatCheckboxDefaultOptions {\n return {\n color: 'accent',\n clickAction: 'check-indeterminate',\n };\n}\n\n/**\n * Checkbox click action when user click on input element.\n * noop: Do not toggle checked or indeterminate.\n * check: Only toggle checked status, ignore indeterminate.\n * check-indeterminate: Toggle checked status, set indeterminate to false. Default behavior.\n * undefined: Same as `check-indeterminate`.\n */\nexport type MatCheckboxClickAction = 'noop' | 'check' | 'check-indeterminate' | undefined;\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.io/license\n */\n\nimport {FocusableOption, FocusMonitor, FocusOrigin} from '@angular/cdk/a11y';\nimport {BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {\n AfterViewChecked,\n Attribute,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n EventEmitter,\n forwardRef,\n Inject,\n Input,\n NgZone,\n OnDestroy,\n Optional,\n Output,\n ViewChild,\n ViewEncapsulation,\n AfterViewInit,\n} from '@angular/core';\nimport {ControlValueAccessor, NG_VALUE_ACCESSOR} from '@angular/forms';\nimport {\n CanColor,\n CanDisable,\n CanDisableRipple,\n HasTabIndex,\n MatRipple,\n mixinColor,\n mixinDisabled,\n mixinDisableRipple,\n mixinTabIndex,\n} from '@angular/material/core';\nimport {ANIMATION_MODULE_TYPE} from '@angular/platform-browser/animations';\nimport {\n MAT_CHECKBOX_DEFAULT_OPTIONS,\n MatCheckboxDefaultOptions,\n MAT_CHECKBOX_DEFAULT_OPTIONS_FACTORY,\n} from './checkbox-config';\n\n// Increasing integer for generating unique ids for checkbox components.\nlet nextUniqueId = 0;\n\n// Default checkbox configuration.\nconst defaults = MAT_CHECKBOX_DEFAULT_OPTIONS_FACTORY();\n\n/**\n * Provider Expression that allows mat-checkbox to register as a ControlValueAccessor.\n * This allows it to support [(ngModel)].\n * @docs-private\n */\nexport const MAT_CHECKBOX_CONTROL_VALUE_ACCESSOR: any = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => MatCheckbox),\n multi: true,\n};\n\n/**\n * Represents the different states that require custom transitions between them.\n * @docs-private\n */\nexport const enum TransitionCheckState {\n /** The initial state of the component before any user interaction. */\n Init,\n /** The state representing the component when it's becoming checked. */\n Checked,\n /** The state representing the component when it's becoming unchecked. */\n Unchecked,\n /** The state representing the component when it's becoming indeterminate. */\n Indeterminate,\n}\n\n/** Change event object emitted by MatCheckbox. */\nexport class MatCheckboxChange {\n /** The source MatCheckbox of the event. */\n source: MatCheckbox;\n /** The new `checked` value of the checkbox. */\n checked: boolean;\n}\n\n// Boilerplate for applying mixins to MatCheckbox.\n/** @docs-private */\nconst _MatCheckboxBase = mixinTabIndex(\n mixinColor(\n mixinDisableRipple(\n mixinDisabled(\n class {\n constructor(public _elementRef: ElementRef) {}\n },\n ),\n ),\n ),\n);\n\n/**\n * A material design checkbox component. Supports all of the functionality of an HTML5 checkbox,\n * and exposes a similar API. A MatCheckbox can be either checked, unchecked, indeterminate, or\n * disabled. Note that all additional accessibility attributes are taken care of by the component,\n * so there is no need to provide them yourself. However, if you want to omit a label and still\n * have the checkbox be accessible, you may supply an [aria-label] input.\n * See: https://material.io/design/components/selection-controls.html\n */\n@Component({\n selector: 'mat-checkbox',\n templateUrl: 'checkbox.html',\n styleUrls: ['checkbox.css'],\n exportAs: 'matCheckbox',\n host: {\n 'class': 'mat-checkbox',\n '[id]': 'id',\n '[attr.tabindex]': 'null',\n '[class.mat-checkbox-indeterminate]': 'indeterminate',\n '[class.mat-checkbox-checked]': 'checked',\n '[class.mat-checkbox-disabled]': 'disabled',\n '[class.mat-checkbox-label-before]': 'labelPosition == \"before\"',\n '[class._mat-animation-noopable]': `_animationMode === 'NoopAnimations'`,\n },\n providers: [MAT_CHECKBOX_CONTROL_VALUE_ACCESSOR],\n inputs: ['disableRipple', 'color', 'tabIndex'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class MatCheckbox\n extends _MatCheckboxBase\n implements\n ControlValueAccessor,\n AfterViewInit,\n AfterViewChecked,\n OnDestroy,\n CanColor,\n CanDisable,\n HasTabIndex,\n CanDisableRipple,\n FocusableOption\n{\n /**\n * Attached to the aria-label attribute of the host element. In most cases, aria-labelledby will\n * take precedence so this may be omitted.\n */\n @Input('aria-label') ariaLabel: string = '';\n\n /**\n * Users can specify the `aria-labelledby` attribute which will be forwarded to the input element\n */\n @Input('aria-labelledby') ariaLabelledby: string | null = null;\n\n /** The 'aria-describedby' attribute is read after the element's label and field type. */\n @Input('aria-describedby') ariaDescribedby: string;\n\n private _uniqueId: string = `mat-checkbox-${++nextUniqueId}`;\n\n /** A unique id for the checkbox input. If none is supplied, it will be auto-generated. */\n @Input() id: string = this._uniqueId;\n\n /** Returns the unique id for the visual hidden input. */\n get inputId(): string {\n return `${this.id || this._uniqueId}-input`;\n }\n\n /** Whether the checkbox is required. */\n @Input()\n get required(): boolean {\n return this._required;\n }\n set required(value: BooleanInput) {\n this._required = coerceBooleanProperty(value);\n }\n private _required: boolean;\n\n /** Whether the label should appear after or before the checkbox. Defaults to 'after' */\n @Input() labelPosition: 'before' | 'after' = 'after';\n\n /** Name value will be applied to the input element if present */\n @Input() name: string | null = null;\n\n /** Event emitted when the checkbox's `checked` value changes. */\n @Output() readonly change: EventEmitter<MatCheckboxChange> =\n new EventEmitter<MatCheckboxChange>();\n\n /** Event emitted when the checkbox's `indeterminate` value changes. */\n @Output() readonly indeterminateChange: EventEmitter<boolean> = new EventEmitter<boolean>();\n\n /** The value attribute of the native input element */\n @Input() value: string;\n\n /** The native `<input type=\"checkbox\">` element */\n @ViewChild('input') _inputElement: ElementRef<HTMLInputElement>;\n\n /** Reference to the ripple instance of the checkbox. */\n @ViewChild(MatRipple) ripple: MatRipple;\n\n /**\n * Called when the checkbox is blurred. Needed to properly implement ControlValueAccessor.\n * @docs-private\n */\n _onTouched: () => any = () => {};\n\n private _currentAnimationClass: string = '';\n\n private _currentCheckState: TransitionCheckState = TransitionCheckState.Init;\n\n private _controlValueAccessorChangeFn: (value: any) => void = () => {};\n\n constructor(\n elementRef: ElementRef<HTMLElement>,\n private _changeDetectorRef: ChangeDetectorRef,\n private _focusMonitor: FocusMonitor,\n private _ngZone: NgZone,\n @Attribute('tabindex') tabIndex: string,\n @Optional() @Inject(ANIMATION_MODULE_TYPE) public _animationMode?: string,\n @Optional()\n @Inject(MAT_CHECKBOX_DEFAULT_OPTIONS)\n private _options?: MatCheckboxDefaultOptions,\n ) {\n super(elementRef);\n this._options = this._options || defaults;\n this.color = this.defaultColor = this._options.color || defaults.color;\n this.tabIndex = parseInt(tabIndex) || 0;\n }\n\n ngAfterViewInit() {\n this._focusMonitor.monitor(this._elementRef, true).subscribe(focusOrigin => {\n if (!focusOrigin) {\n // When a focused element becomes disabled, the browser *immediately* fires a blur event.\n // Angular does not expect events to be raised during change detection, so any state change\n // (such as a form control's 'ng-touched') will cause a changed-after-checked error.\n // See https://github.com/angular/angular/issues/17793. To work around this, we defer\n // telling the form control it has been touched until the next tick.\n Promise.resolve().then(() => {\n this._onTouched();\n this._changeDetectorRef.markForCheck();\n });\n }\n });\n\n this._syncIndeterminate(this._indeterminate);\n }\n\n // TODO: Delete next major revision.\n ngAfterViewChecked() {}\n\n ngOnDestroy() {\n this._focusMonitor.stopMonitoring(this._elementRef);\n }\n\n /**\n * Whether the checkbox is checked.\n */\n @Input()\n get checked(): boolean {\n return this._checked;\n }\n set checked(value: boolean) {\n if (value != this.checked) {\n this._checked = value;\n this._changeDetectorRef.markForCheck();\n }\n }\n private _checked: boolean = false;\n\n /**\n * Whether the checkbox is disabled. This fully overrides the implementation provided by\n * mixinDisabled, but the mixin is still required because mixinTabIndex requires it.\n */\n @Input()\n override get disabled(): boolean {\n return this._disabled;\n }\n override set disabled(value: BooleanInput) {\n const newValue = coerceBooleanProperty(value);\n\n if (newValue !== this.disabled) {\n this._disabled = newValue;\n this._changeDetectorRef.markForCheck();\n }\n }\n private _disabled: boolean = false;\n\n /**\n * Whether the checkbox is indeterminate. This is also known as \"mixed\" mode and can be used to\n * represent a checkbox with three states, e.g. a checkbox that represents a nested list of\n * checkable items. Note that whenever checkbox is manually clicked, indeterminate is immediately\n * set to false.\n */\n @Input()\n get indeterminate(): boolean {\n return this._indeterminate;\n }\n set indeterminate(value: BooleanInput) {\n const changed = value != this._indeterminate;\n this._indeterminate = coerceBooleanProperty(value);\n\n if (changed) {\n if (this._indeterminate) {\n this._transitionCheckState(TransitionCheckState.Indeterminate);\n } else {\n this._transitionCheckState(\n this.checked ? TransitionCheckState.Checked : TransitionCheckState.Unchecked,\n );\n }\n this.indeterminateChange.emit(this._indeterminate);\n }\n\n this._syncIndeterminate(this._indeterminate);\n }\n private _indeterminate: boolean = false;\n\n _isRippleDisabled() {\n return this.disableRipple || this.disabled;\n }\n\n /** Method being called whenever the label text changes. */\n _onLabelTextChange() {\n // Since the event of the `cdkObserveContent` directive runs outside of the zone, the checkbox\n // component will be only marked for check, but no actual change detection runs automatically.\n // Instead of going back into the zone in order to trigger a change detection which causes\n // *all* components to be checked (if explicitly marked or not using OnPush), we only trigger\n // an explicit change detection for the checkbox view and its children.\n this._changeDetectorRef.detectChanges();\n }\n\n // Implemented as part of ControlValueAccessor.\n writeValue(value: any) {\n this.checked = !!value;\n }\n\n // Implemented as part of ControlValueAccessor.\n registerOnChange(fn: (value: any) => void) {\n this._controlValueAccessorChangeFn = fn;\n }\n\n // Implemented as part of ControlValueAccessor.\n registerOnTouched(fn: any) {\n this._onTouched = fn;\n }\n\n // Implemented as part of ControlValueAccessor.\n setDisabledState(isDisabled: boolean) {\n this.disabled = isDisabled;\n }\n\n _getAriaChecked(): 'true' | 'false' | 'mixed' {\n if (this.checked) {\n return 'true';\n }\n\n return this.indeterminate ? 'mixed' : 'false';\n }\n\n private _transitionCheckState(newState: TransitionCheckState) {\n let oldState = this._currentCheckState;\n let element: HTMLElement = this._elementRef.nativeElement;\n\n if (oldState === newState) {\n return;\n }\n if (this._currentAnimationClass.length > 0) {\n element.classList.remove(this._currentAnimationClass);\n }\n\n this._currentAnimationClass = this._getAnimationClassForCheckStateTransition(\n oldState,\n newState,\n );\n this._currentCheckState = newState;\n\n if (this._currentAnimationClass.length > 0) {\n element.classList.add(this._currentAnimationClass);\n\n // Remove the animation class to avoid animation when the checkbox is moved between containers\n const animationClass = this._currentAnimationClass;\n\n this._ngZone.runOutsideAngular(() => {\n setTimeout(() => {\n element.classList.remove(animationClass);\n }, 1000);\n });\n }\n }\n\n private _emitChangeEvent() {\n const event = new MatCheckboxChange();\n event.source = this;\n event.checked = this.checked;\n\n this._controlValueAccessorChangeFn(this.checked);\n this.change.emit(event);\n\n // Assigning the value again here is redundant, but we have to do it in case it was\n // changed inside the `change` listener which will cause the input to be out of sync.\n if (this._inputElement) {\n this._inputElement.nativeElement.checked = this.checked;\n }\n }\n\n /** Toggles the `checked` state of the checkbox. */\n toggle(): void {\n this.checked = !this.checked;\n }\n\n /**\n * Event handler for checkbox input element.\n * Toggles checked state if element is not disabled.\n * Do not toggle on (change) event since IE doesn't fire change event when\n * indeterminate checkbox is clicked.\n * @param event\n */\n _onInputClick(event: Event) {\n const clickAction = this._options?.clickAction;\n\n // We have to stop propagation for click events on the visual hidden input element.\n // By default, when a user clicks on a label element, a generated click event will be\n // dispatched on the associated input element. Since we are using a label element as our\n // root container, the click event on the `checkbox` will be executed twice.\n // The real click event will bubble up, and the generated click event also tries to bubble up.\n // This will lead to multiple click events.\n // Preventing bubbling for the second event will solve that issue.\n event.stopPropagation();\n\n // If resetIndeterminate is false, and the current state is indeterminate, do nothing on click\n if (!this.disabled && clickAction !== 'noop') {\n // When user manually click on the checkbox, `indeterminate` is set to false.\n if (this.indeterminate && clickAction !== 'check') {\n Promise.resolve().then(() => {\n this._indeterminate = false;\n this.indeterminateChange.emit(this._indeterminate);\n });\n }\n\n this.toggle();\n this._transitionCheckState(\n this._checked ? TransitionCheckState.Checked : TransitionCheckState.Unchecked,\n );\n\n // Emit our custom change event if the native input emitted one.\n // It is important to only emit it, if the native input triggered one, because\n // we don't want to trigger a change event, when the `checked` variable changes for example.\n this._emitChangeEvent();\n } else if (!this.disabled && clickAction === 'noop') {\n // Reset native input when clicked with noop. The native checkbox becomes checked after\n // click, reset it to be align with `checked` value of `mat-checkbox`.\n this._inputElement.nativeElement.checked = this.checked;\n this._inputElement.nativeElement.indeterminate = this.indeterminate;\n }\n }\n\n /** Focuses the checkbox. */\n focus(origin?: FocusOrigin, options?: FocusOptions): void {\n if (origin) {\n this._focusMonitor.focusVia(this._inputElement, origin, options);\n } else {\n this._inputElement.nativeElement.focus(options);\n }\n }\n\n _onInteractionEvent(event: Event) {\n // We always have to stop propagation on the change event.\n // Otherwise the change event, from the input element, will bubble up and\n // emit its event object to the `change` output.\n event.stopPropagation();\n }\n\n private _getAnimationClassForCheckStateTransition(\n oldState: TransitionCheckState,\n newState: TransitionCheckState,\n ): string {\n // Don't transition if animations are disabled.\n if (this._animationMode === 'NoopAnimations') {\n return '';\n }\n\n let animSuffix: string = '';\n\n switch (oldState) {\n case TransitionCheckState.Init:\n // Handle edge case where user interacts with checkbox that does not have [(ngModel)] or\n // [checked] bound to it.\n if (newState === TransitionCheckState.Checked) {\n animSuffix = 'unchecked-checked';\n } else if (newState == TransitionCheckState.Indeterminate) {\n animSuffix = 'unchecked-indeterminate';\n } else {\n return '';\n }\n break;\n case TransitionCheckState.Unchecked:\n animSuffix =\n newState === TransitionCheckState.Checked\n ? 'unchecked-checked'\n : 'unchecked-indeterminate';\n break;\n case TransitionCheckState.Checked:\n animSuffix =\n newState === TransitionCheckState.Unchecked\n ? 'checked-unchecked'\n : 'checked-indeterminate';\n break;\n case TransitionCheckState.Indeterminate:\n animSuffix =\n newState === TransitionCheckState.Checked\n ? 'indeterminate-checked'\n : 'indeterminate-unchecked';\n break;\n }\n\n return `mat-checkbox-anim-${animSuffix}`;\n }\n\n /**\n * Syncs the indeterminate value with the checkbox DOM node.\n *\n * We sync `indeterminate` directly on the DOM node, because in Ivy the check for whether a\n * property is supported on an element boils down to `if (propName in element)`. Domino's\n * HTMLInputElement doesn't have an `indeterminate` property so Ivy will warn during\n * server-side rendering.\n */\n private _syncIndeterminate(value: boolean) {\n const nativeCheckbox = this._inputElement;\n\n if (nativeCheckbox) {\n nativeCheckbox.nativeElement.indeterminate = value;\n }\n }\n}\n","<label [attr.for]=\"inputId\" class=\"mat-checkbox-layout\" #label>\n <span class=\"mat-checkbox-inner-container\"\n [class.mat-checkbox-inner-container-no-side-margin]=\"!checkboxLabel.textContent || !checkboxLabel.textContent.trim()\">\n <input #input\n class=\"mat-checkbox-input cdk-visually-hidden\" type=\"checkbox\"\n [id]=\"inputId\"\n [required]=\"required\"\n [checked]=\"checked\"\n [attr.value]=\"value\"\n [disabled]=\"disabled\"\n [attr.name]=\"name\"\n [tabIndex]=\"tabIndex\"\n [attr.aria-label]=\"ariaLabel || null\"\n [attr.aria-labelledby]=\"ariaLabelledby\"\n [attr.aria-checked]=\"_getAriaChecked()\"\n [attr.aria-describedby]=\"ariaDescribedby\"\n (change)=\"_onInteractionEvent($event)\"\n (click)=\"_onInputClick($event)\">\n <span matRipple class=\"mat-checkbox-ripple mat-focus-indicator\"\n [matRippleTrigger]=\"label\"\n [matRippleDisabled]=\"_isRippleDisabled()\"\n [matRippleRadius]=\"20\"\n [matRippleCentered]=\"true\"\n [matRippleAnimation]=\"{enterDuration: _animationMode === 'NoopAnimations' ? 0 : 150}\">\n <span class=\"mat-ripple-element mat-checkbox-persistent-ripple\"></span>\n </span>\n <span class=\"mat-checkbox-frame\"></span>\n <span class=\"mat-checkbox-background\">\n <svg version=\"1.1\"\n focusable=\"false\"\n class=\"mat-checkbox-checkmark\"\n viewBox=\"0 0 24 24\"\n xml:space=\"preserve\"\n aria-hidden=\"true\">\n <path class=\"mat-checkbox-checkmark-path\"\n fill=\"none\"\n stroke=\"white\"\n d=\"M4.1,12.7 9,17.6 20.3,6.3\"/>\n </svg>\n <!-- Element for rendering the indeterminate state checkbox. -->\n <span class=\"mat-checkbox-mixedmark\"></span>\n </span>\n </span>\n <span class=\"mat-checkbox-label\" #checkboxLabel (cdkObserveContent)=\"_onLabelTextChange()\">\n <!-- Add an invisible span so JAWS can read the label -->\n <span style=\"display:none\">&nbsp;</span>\n <ng-content></ng-content>\n </span>\n</label>\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.io/license\n */\n\nimport {Directive, forwardRef, Provider} from '@angular/core';\nimport {CheckboxRequiredValidator, NG_VALIDATORS} from '@angular/forms';\n\nexport const MAT_CHECKBOX_REQUIRED_VALIDATOR: Provider = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => MatCheckboxRequiredValidator),\n multi: true,\n};\n\n/**\n * Validator for Material checkbox's required attribute in template-driven checkbox.\n * Current CheckboxRequiredValidator only work with `input type=checkbox` and does not\n * work with `mat-checkbox`.\n */\n@Directive({\n selector: `mat-checkbox[required][formControlName],\n mat-checkbox[required][formControl], mat-checkbox[required][ngModel]`,\n providers: [MAT_CHECKBOX_REQUIRED_VALIDATOR],\n})\nexport class MatCheckboxRequiredValidator extends CheckboxRequiredValidator {}\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.io/license\n */\n\nimport {ObserversModule} from '@angular/cdk/observers';\nimport {NgModule} from '@angular/core';\nimport {MatCommonModule, MatRippleModule} from '@angular/material/core';\nimport {MatCheckbox} from './checkbox';\nimport {MatCheckboxRequiredValidator} from './checkbox-required-validator';\n\n/** This module is used by both original and MDC-based checkbox implementations. */\n@NgModule({\n exports: [MatCheckboxRequiredValidator],\n declarations: [MatCheckboxRequiredValidator],\n})\nexport class _MatCheckboxRequiredValidatorModule {}\n\n@NgModule({\n imports: [MatRippleModule, MatCommonModule, ObserversModule, _MatCheckboxRequiredValidatorModule],\n exports: [MatCheckbox, MatCommonModule, _MatCheckboxRequiredValidatorModule],\n declarations: [MatCheckbox],\n})\nexport class MatCheckboxModule {}\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.io/license\n */\n\nexport * from './checkbox';\nexport * from './checkbox-config';\nexport * from './checkbox-module';\nexport * from './checkbox-required-validator';\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.io/license\n */\n\nexport * from './public-api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"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