@scion/components 13.0.0 → 14.0.2
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.
- package/_index.scss +1 -23
- package/dimension/dimension.directive.d.ts +1 -1
- package/dimension/{scion-components-dimension.d.ts → index.d.ts} +0 -0
- package/esm2020/dimension/dimension.directive.mjs +3 -3
- package/esm2020/dimension/dimension.module.mjs +5 -7
- package/esm2020/sashbox/element-ref.directive.mjs +3 -3
- package/esm2020/sashbox/sash-initializer.directive.mjs +3 -3
- package/esm2020/sashbox/sash.directive.mjs +4 -4
- package/esm2020/sashbox/sashbox.component.mjs +6 -6
- package/esm2020/sashbox/sashbox.module.mjs +6 -8
- package/esm2020/splitter/splitter.component.mjs +3 -3
- package/esm2020/splitter/splitter.module.mjs +5 -7
- package/esm2020/throbber/ellipsis-throbber/ellipsis-throbber.component.mjs +3 -3
- package/esm2020/throbber/ripple-throbber/ripple-throbber.component.mjs +3 -3
- package/esm2020/throbber/roller-throbber/roller-throbber.component.mjs +3 -3
- package/esm2020/throbber/spinner-throbber/spinner-throbber.component.mjs +3 -3
- package/esm2020/throbber/throbber.component.mjs +8 -8
- package/esm2020/throbber/throbber.module.mjs +5 -7
- package/esm2020/viewport/native-scrollbar-track-size-provider.service.mjs +3 -3
- package/esm2020/viewport/scrollable.directive.mjs +3 -3
- package/esm2020/viewport/scrollbar/scrollbar.component.mjs +3 -3
- package/esm2020/viewport/viewport.component.mjs +54 -64
- package/esm2020/viewport/viewport.module.mjs +6 -8
- package/fesm2015/scion-components-dimension.mjs +7 -9
- package/fesm2015/scion-components-dimension.mjs.map +1 -1
- package/fesm2015/scion-components-sashbox.mjs +21 -23
- package/fesm2015/scion-components-sashbox.mjs.map +1 -1
- package/fesm2015/scion-components-splitter.mjs +7 -9
- package/fesm2015/scion-components-splitter.mjs.map +1 -1
- package/fesm2015/scion-components-throbber.mjs +20 -22
- package/fesm2015/scion-components-throbber.mjs.map +1 -1
- package/fesm2015/scion-components-viewport.mjs +67 -78
- package/fesm2015/scion-components-viewport.mjs.map +1 -1
- package/fesm2015/scion-components.mjs.map +1 -1
- package/fesm2020/scion-components-dimension.mjs +7 -9
- package/fesm2020/scion-components-dimension.mjs.map +1 -1
- package/fesm2020/scion-components-sashbox.mjs +21 -23
- package/fesm2020/scion-components-sashbox.mjs.map +1 -1
- package/fesm2020/scion-components-splitter.mjs +7 -9
- package/fesm2020/scion-components-splitter.mjs.map +1 -1
- package/fesm2020/scion-components-throbber.mjs +20 -22
- package/fesm2020/scion-components-throbber.mjs.map +1 -1
- package/fesm2020/scion-components-viewport.mjs +66 -78
- package/fesm2020/scion-components-viewport.mjs.map +1 -1
- package/fesm2020/scion-components.mjs.map +1 -1
- package/{scion-components.d.ts → index.d.ts} +0 -0
- package/package.json +13 -13
- package/sashbox/element-ref.directive.d.ts +1 -1
- package/sashbox/{scion-components-sashbox.d.ts → index.d.ts} +0 -0
- package/sashbox/sash-initializer.directive.d.ts +1 -1
- package/sashbox/sash.directive.d.ts +2 -2
- package/sashbox/sashbox.component.d.ts +1 -1
- package/splitter/{scion-components-splitter.d.ts → index.d.ts} +0 -0
- package/splitter/splitter.component.d.ts +1 -1
- package/throbber/ellipsis-throbber/ellipsis-throbber.component.d.ts +1 -1
- package/throbber/{scion-components-throbber.d.ts → index.d.ts} +0 -0
- package/throbber/ripple-throbber/ripple-throbber.component.d.ts +1 -1
- package/throbber/roller-throbber/roller-throbber.component.d.ts +1 -1
- package/throbber/spinner-throbber/spinner-throbber.component.d.ts +1 -1
- package/throbber/throbber.component.d.ts +1 -1
- package/viewport/_scrollbar.scss +3 -1
- package/viewport/{scion-components-viewport.d.ts → index.d.ts} +0 -0
- package/viewport/scrollable.directive.d.ts +1 -1
- package/viewport/scrollbar/scrollbar.component.d.ts +1 -1
- package/viewport/viewport.component.d.ts +26 -21
- package/_components.scss +0 -1
- package/dimension/package.json +0 -10
- package/sashbox/package.json +0 -10
- package/splitter/package.json +0 -10
- package/throbber/package.json +0 -10
- package/viewport/package.json +0 -10
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scion-components-throbber.mjs","sources":["../../../../projects/scion/components/throbber/src/ellipsis-throbber/ellipsis-throbber.component.ts","../../../../projects/scion/components/throbber/src/ellipsis-throbber/ellipsis-throbber.component.html","../../../../projects/scion/components/throbber/src/ripple-throbber/ripple-throbber.component.ts","../../../../projects/scion/components/throbber/src/ripple-throbber/ripple-throbber.component.html","../../../../projects/scion/components/throbber/src/roller-throbber/roller-throbber.component.ts","../../../../projects/scion/components/throbber/src/roller-throbber/roller-throbber.component.html","../../../../projects/scion/components/throbber/src/spinner-throbber/spinner-throbber.component.ts","../../../../projects/scion/components/throbber/src/spinner-throbber/spinner-throbber.component.html","../../../../projects/scion/components/throbber/src/throbber.component.ts","../../../../projects/scion/components/throbber/src/throbber.component.html","../../../../projects/scion/components/throbber/src/throbber.module.ts","../../../../projects/scion/components/throbber/src/public_api.ts","../../../../projects/scion/components/throbber/src/scion-components-throbber.ts"],"sourcesContent":["/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component} from '@angular/core';\n\n/**\n * Represents a throbber as an ellipsis consisting of three horizontally arranged points that appear one after the other.\n *\n * Throbber type: `ellipsis`\n */\n@Component({\n selector: 'sci-ellipsis-throbber',\n templateUrl: './ellipsis-throbber.component.html',\n styleUrls: ['./ellipsis-throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciEllipsisThrobberComponent {\n}\n","<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component} from '@angular/core';\n\n/**\n * Represents a throbber with a rippled, centric wave effect, similar to throwing a stone into water.\n *\n * Throbber type: `ripple`\n */\n@Component({\n selector: 'sci-ripple-throbber',\n templateUrl: './ripple-throbber.component.html',\n styleUrls: ['./ripple-throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciRippleThrobberComponent {\n}\n","<div class=\"circle\"></div>\n<div class=\"circle\"></div>\n","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component} from '@angular/core';\n\n/**\n * Represents a circular throbber with points rotating around the center of a circle. Points have a delayed acceleration, which leads to an accordion effect.\n *\n * Throbber type: `roller`\n */\n@Component({\n selector: 'sci-roller-throbber',\n templateUrl: './roller-throbber.component.html',\n styleUrls: ['./roller-throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciRollerThrobberComponent {\n}\n","<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component} from '@angular/core';\n\n/**\n * Represents a classic spinner throbber with strokes arranged radially. The strokes light up one after the other in clockwise direction\n * and then then fade out again.\n *\n * Throbber type: `spinner`\n */\n@Component({\n selector: 'sci-spinner-throbber',\n templateUrl: './spinner-throbber.component.html',\n styleUrls: ['./spinner-throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciSpinnerThrobberComponent {\n}\n","<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component, Input} from '@angular/core';\n\n/**\n * Animated graphical control to indicate the execution of an action.\n *\n * Choose between different throbber presentations by setting the `type` property: `ellipsis`, `ripple`, `roller`, `spinner`.\n *\n * ### CSS styling:\n *\n * You can override the following CSS variables:\n *\n * - sci-throbber-color: Sets the color of the throbber (by default, uses `lightgray`).\n * - sci-throbber-size: Defines the size of the throbber. Most throbbers are quadratic having the same width and height.\n * For non-quadratic throbbers, the size usually specifies the height (by default, uses `50px`).\n * - sci-throbber-duration: Sets the duration of a single animation cycle (by default, uses `1.25s`).\n *\n * Example:\n *\n * ```css\n *\n * sci-throbber {\n * --sci-throbber-color: blue;\n * --sci-throbber-size: 50px;\n * --sci-throbber-duration: 1s\n * }\n * ```\n */\n@Component({\n selector: 'sci-throbber',\n templateUrl: './throbber.component.html',\n styleUrls: ['./throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciThrobberComponent {\n\n /**\n * Chooses between different throbber presentation. If not set, uses `spinner` type.\n *\n * - **ellipsis**\n * Represents a throbber as an ellipsis consisting of three horizontally arranged points that appear one after the other.\n * - **ripple**\n * Represents a throbber with a rippled, centric wave effect, similar to throwing a stone into water.\n * - **roller**\n * Represents a circular throbber with points rotating around the center of a circle. Points have a delayed acceleration, which leads to an accordion effect.\n * - **spinner** (default)\n * Represents a classic spinner throbber with strokes arranged radially. The strokes light up one after the other in clockwise direction and then then fade out again.\n */\n @Input()\n public type: 'ellipsis' | 'ripple' | 'roller' | 'spinner' = 'spinner';\n}\n","<ng-container [ngSwitch]=\"type\">\n <sci-ellipsis-throbber *ngSwitchCase=\"'ellipsis'\"></sci-ellipsis-throbber>\n <sci-ripple-throbber *ngSwitchCase=\"'ripple'\"></sci-ripple-throbber>\n <sci-roller-throbber *ngSwitchCase=\"'roller'\"></sci-roller-throbber>\n <sci-spinner-throbber *ngSwitchCase=\"'spinner'\"></sci-spinner-throbber>\n <sci-spinner-throbber *ngSwitchDefault></sci-spinner-throbber>\n</ng-container>","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {NgModule} from '@angular/core';\nimport {CommonModule} from '@angular/common';\nimport {SciThrobberComponent} from './throbber.component';\nimport {SciEllipsisThrobberComponent} from './ellipsis-throbber/ellipsis-throbber.component';\nimport {SciRippleThrobberComponent} from './ripple-throbber/ripple-throbber.component';\nimport {SciRollerThrobberComponent} from './roller-throbber/roller-throbber.component';\nimport {SciSpinnerThrobberComponent} from './spinner-throbber/spinner-throbber.component';\n\n/**\n * Provides {@link SciThrobberComponent}, an animated graphical control to indicate the execution of an action.\n */\n@NgModule({\n declarations: [\n SciThrobberComponent,\n SciEllipsisThrobberComponent,\n SciRippleThrobberComponent,\n SciRollerThrobberComponent,\n SciSpinnerThrobberComponent,\n ],\n imports: [\n CommonModule,\n ],\n exports: [\n SciThrobberComponent,\n ],\n})\nexport class SciThrobberModule {\n}\n","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\n/*\n * Secondary entrypoint: '@scion/components/throbber'\n *\n * @see https://github.com/ng-packagr/ng-packagr/blob/master/docs/secondary-entrypoints.md\n */\nexport {SciThrobberModule} from './throbber.module';\nexport {SciThrobberComponent} from './throbber.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;AAAA;;;;;;;;;AAYA;;;;;MAWa,4BAA4B;;yHAA5B,4BAA4B;6GAA5B,4BAA4B,6DCvBzC,yFAGA;2FDoBa,4BAA4B;kBANxC,SAAS;+BACE,uBAAuB,mBAGhB,uBAAuB,CAAC,MAAM;;;AErBjD;;;;;;;;;AAYA;;;;;MAWa,0BAA0B;;uHAA1B,0BAA0B;2GAA1B,0BAA0B,2DCvBvC,8DAEA;2FDqBa,0BAA0B;kBANtC,SAAS;+BACE,qBAAqB,mBAGd,uBAAuB,CAAC,MAAM;;;AErBjD;;;;;;;;;AAYA;;;;;MAWa,0BAA0B;;uHAA1B,0BAA0B;2GAA1B,0BAA0B,2DCvBvC,wOAOyB;2FDgBZ,0BAA0B;kBANtC,SAAS;+BACE,qBAAqB,mBAGd,uBAAuB,CAAC,MAAM;;;AErBjD;;;;;;;;;AAYA;;;;;;MAYa,2BAA2B;;wHAA3B,2BAA2B;4GAA3B,2BAA2B,4DCxBxC,wWAW0B;2FDab,2BAA2B;kBANvC,SAAS;+BACE,sBAAsB,mBAGf,uBAAuB,CAAC,MAAM;;;AEtBjD;;;;;;;;;AAYA;;;;;;;;;;;;;;;;;;;;;;;;;MA+Ba,oBAAoB;IANjC;;;;;;;;;;;;;QAqBS,SAAI,GAAiD,SAAS,CAAC;KACvE;;iHAhBY,oBAAoB;qGAApB,oBAAoB,8EC3CjC,waAMe;2FDqCF,oBAAoB;kBANhC,SAAS;+BACE,cAAc,mBAGP,uBAAuB,CAAC,MAAM;8BAiBxC,IAAI;sBADV,KAAK;;;AEzDR;;;;;;;;;AAkBA;;;MAkBa,iBAAiB;;8GAAjB,iBAAiB;+GAAjB,iBAAiB,iBAb1B,oBAAoB;QACpB,4BAA4B;QAC5B,0BAA0B;QAC1B,0BAA0B;QAC1B,2BAA2B,aAG3B,YAAY,aAGZ,oBAAoB;+GAGX,iBAAiB,YAPnB;YACP,YAAY;SACb;2FAKU,iBAAiB;kBAf7B,QAAQ;mBAAC;oBACR,YAAY,EAAE;wBACZ,oBAAoB;wBACpB,4BAA4B;wBAC5B,0BAA0B;wBAC1B,0BAA0B;wBAC1B,2BAA2B;qBAC5B;oBACD,OAAO,EAAE;wBACP,YAAY;qBACb;oBACD,OAAO,EAAE;wBACP,oBAAoB;qBACrB;iBACF;;;ACnCD;;;;;;;;;;ACAA;;;;;;"}
|
|
1
|
+
{"version":3,"file":"scion-components-throbber.mjs","sources":["../../../../projects/scion/components/throbber/src/ellipsis-throbber/ellipsis-throbber.component.ts","../../../../projects/scion/components/throbber/src/ellipsis-throbber/ellipsis-throbber.component.html","../../../../projects/scion/components/throbber/src/ripple-throbber/ripple-throbber.component.ts","../../../../projects/scion/components/throbber/src/ripple-throbber/ripple-throbber.component.html","../../../../projects/scion/components/throbber/src/roller-throbber/roller-throbber.component.ts","../../../../projects/scion/components/throbber/src/roller-throbber/roller-throbber.component.html","../../../../projects/scion/components/throbber/src/spinner-throbber/spinner-throbber.component.ts","../../../../projects/scion/components/throbber/src/spinner-throbber/spinner-throbber.component.html","../../../../projects/scion/components/throbber/src/throbber.component.ts","../../../../projects/scion/components/throbber/src/throbber.component.html","../../../../projects/scion/components/throbber/src/throbber.module.ts","../../../../projects/scion/components/throbber/src/public_api.ts","../../../../projects/scion/components/throbber/src/scion-components-throbber.ts"],"sourcesContent":["/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component} from '@angular/core';\n\n/**\n * Represents a throbber as an ellipsis consisting of three horizontally arranged points that appear one after the other.\n *\n * Throbber type: `ellipsis`\n */\n@Component({\n selector: 'sci-ellipsis-throbber',\n templateUrl: './ellipsis-throbber.component.html',\n styleUrls: ['./ellipsis-throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciEllipsisThrobberComponent {\n}\n","<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component} from '@angular/core';\n\n/**\n * Represents a throbber with a rippled, centric wave effect, similar to throwing a stone into water.\n *\n * Throbber type: `ripple`\n */\n@Component({\n selector: 'sci-ripple-throbber',\n templateUrl: './ripple-throbber.component.html',\n styleUrls: ['./ripple-throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciRippleThrobberComponent {\n}\n","<div class=\"circle\"></div>\n<div class=\"circle\"></div>\n","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component} from '@angular/core';\n\n/**\n * Represents a circular throbber with points rotating around the center of a circle. Points have a delayed acceleration, which leads to an accordion effect.\n *\n * Throbber type: `roller`\n */\n@Component({\n selector: 'sci-roller-throbber',\n templateUrl: './roller-throbber.component.html',\n styleUrls: ['./roller-throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciRollerThrobberComponent {\n}\n","<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>\n<div class=\"point\"></div>","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component} from '@angular/core';\n\n/**\n * Represents a classic spinner throbber with strokes arranged radially. The strokes light up one after the other in clockwise direction\n * and then then fade out again.\n *\n * Throbber type: `spinner`\n */\n@Component({\n selector: 'sci-spinner-throbber',\n templateUrl: './spinner-throbber.component.html',\n styleUrls: ['./spinner-throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciSpinnerThrobberComponent {\n}\n","<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>\n<div class=\"stroke\"></div>","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {ChangeDetectionStrategy, Component, Input} from '@angular/core';\n\n/**\n * Animated graphical control to indicate the execution of an action.\n *\n * Choose between different throbber presentations by setting the `type` property: `ellipsis`, `ripple`, `roller`, `spinner`.\n *\n * ### CSS styling:\n *\n * You can override the following CSS variables:\n *\n * - sci-throbber-color: Sets the color of the throbber (by default, uses `lightgray`).\n * - sci-throbber-size: Defines the size of the throbber. Most throbbers are quadratic having the same width and height.\n * For non-quadratic throbbers, the size usually specifies the height (by default, uses `50px`).\n * - sci-throbber-duration: Sets the duration of a single animation cycle (by default, uses `1.25s`).\n *\n * Example:\n *\n * ```css\n *\n * sci-throbber {\n * --sci-throbber-color: blue;\n * --sci-throbber-size: 50px;\n * --sci-throbber-duration: 1s\n * }\n * ```\n */\n@Component({\n selector: 'sci-throbber',\n templateUrl: './throbber.component.html',\n styleUrls: ['./throbber.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SciThrobberComponent {\n\n /**\n * Chooses between different throbber presentation. If not set, uses `spinner` type.\n *\n * - **ellipsis**\n * Represents a throbber as an ellipsis consisting of three horizontally arranged points that appear one after the other.\n * - **ripple**\n * Represents a throbber with a rippled, centric wave effect, similar to throwing a stone into water.\n * - **roller**\n * Represents a circular throbber with points rotating around the center of a circle. Points have a delayed acceleration, which leads to an accordion effect.\n * - **spinner** (default)\n * Represents a classic spinner throbber with strokes arranged radially. The strokes light up one after the other in clockwise direction and then then fade out again.\n */\n @Input()\n public type: 'ellipsis' | 'ripple' | 'roller' | 'spinner' = 'spinner';\n}\n","<ng-container [ngSwitch]=\"type\">\n <sci-ellipsis-throbber *ngSwitchCase=\"'ellipsis'\"></sci-ellipsis-throbber>\n <sci-ripple-throbber *ngSwitchCase=\"'ripple'\"></sci-ripple-throbber>\n <sci-roller-throbber *ngSwitchCase=\"'roller'\"></sci-roller-throbber>\n <sci-spinner-throbber *ngSwitchCase=\"'spinner'\"></sci-spinner-throbber>\n <sci-spinner-throbber *ngSwitchDefault></sci-spinner-throbber>\n</ng-container>","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\nimport {NgModule} from '@angular/core';\nimport {CommonModule} from '@angular/common';\nimport {SciThrobberComponent} from './throbber.component';\nimport {SciEllipsisThrobberComponent} from './ellipsis-throbber/ellipsis-throbber.component';\nimport {SciRippleThrobberComponent} from './ripple-throbber/ripple-throbber.component';\nimport {SciRollerThrobberComponent} from './roller-throbber/roller-throbber.component';\nimport {SciSpinnerThrobberComponent} from './spinner-throbber/spinner-throbber.component';\n\n/**\n * Provides {@link SciThrobberComponent}, an animated graphical control to indicate the execution of an action.\n */\n@NgModule({\n declarations: [\n SciThrobberComponent,\n SciEllipsisThrobberComponent,\n SciRippleThrobberComponent,\n SciRollerThrobberComponent,\n SciSpinnerThrobberComponent,\n ],\n imports: [\n CommonModule,\n ],\n exports: [\n SciThrobberComponent,\n ],\n})\nexport class SciThrobberModule {\n}\n","/*\n * Copyright (c) 2018-2019 Swiss Federal Railways\n *\n * This program and the accompanying materials are made\n * available under the terms of the Eclipse Public License 2.0\n * which is available at https://www.eclipse.org/legal/epl-2.0/\n *\n * SPDX-License-Identifier: EPL-2.0\n */\n\n/*\n * Secondary entrypoint: '@scion/components/throbber'\n *\n * @see https://github.com/ng-packagr/ng-packagr/blob/master/docs/secondary-entrypoints.md\n */\nexport {SciThrobberModule} from './throbber.module';\nexport {SciThrobberComponent} from './throbber.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["i2.SciEllipsisThrobberComponent","i3.SciRippleThrobberComponent","i4.SciRollerThrobberComponent","i5.SciSpinnerThrobberComponent"],"mappings":";;;;;AAAA;;;;;;;;AAQG;AAIH;;;;AAIG;MAOU,4BAA4B,CAAA;;yHAA5B,4BAA4B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAA5B,4BAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,4BAA4B,6DCvBzC,yFAGA,EAAA,MAAA,EAAA,CAAA,mlBAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAA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AA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,iBAb1B,oBAAoB;QACpB,4BAA4B;QAC5B,0BAA0B;QAC1B,0BAA0B;AAC1B,QAAA,2BAA2B,CAAA,EAAA,OAAA,EAAA,CAG3B,YAAY,CAAA,EAAA,OAAA,EAAA,CAGZ,oBAAoB,CAAA,EAAA,CAAA,CAAA;AAGX,iBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,YAN1B,YAAY,CAAA,EAAA,CAAA,CAAA;2FAMH,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAf7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE;wBACZ,oBAAoB;wBACpB,4BAA4B;wBAC5B,0BAA0B;wBAC1B,0BAA0B;wBAC1B,2BAA2B;AAC5B,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACP,YAAY;AACb,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACP,oBAAoB;AACrB,qBAAA;iBACF,CAAA;;;ACnCD;;;;;;;;AAQG;;ACRH;;AAEG;;;;"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Injectable, Inject, NgZone, Component, ChangeDetectionStrategy, ViewChild, HostBinding, Input, Directive, EventEmitter, Output, HostListener, NgModule } from '@angular/core';
|
|
3
|
-
import * as
|
|
2
|
+
import { Injectable, Inject, NgZone, Component, ChangeDetectionStrategy, ViewChild, HostBinding, Input, Directive, EventEmitter, ViewEncapsulation, Output, HostListener, NgModule } from '@angular/core';
|
|
3
|
+
import * as i2 from '@angular/common';
|
|
4
4
|
import { DOCUMENT, CommonModule } from '@angular/common';
|
|
5
5
|
import { coerceElement } from '@angular/cdk/coercion';
|
|
6
6
|
import { BehaviorSubject, Subject, fromEvent, of, merge, timer } from 'rxjs';
|
|
7
7
|
import { debounceTime, startWith, map, distinctUntilChanged, takeUntil, switchMap, first, withLatestFrom, takeWhile } from 'rxjs/operators';
|
|
8
|
+
import * as i3 from '@angular/cdk/scrolling';
|
|
9
|
+
import { ScrollingModule } from '@angular/cdk/scrolling';
|
|
8
10
|
import { fromDimension$, fromMutation$ } from '@scion/toolkit/observable';
|
|
9
11
|
import { subscribeInside, filterArray } from '@scion/toolkit/operators';
|
|
10
|
-
import * as i4 from '@angular/cdk/scrolling';
|
|
11
|
-
import { ScrollingModule } from '@angular/cdk/scrolling';
|
|
12
12
|
|
|
13
13
|
/*
|
|
14
14
|
* Copyright (c) 2018-2019 Swiss Federal Railways
|
|
@@ -98,9 +98,9 @@ class SciNativeScrollbarTrackSizeProvider {
|
|
|
98
98
|
this._destroy$.next();
|
|
99
99
|
}
|
|
100
100
|
}
|
|
101
|
-
SciNativeScrollbarTrackSizeProvider.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
102
|
-
SciNativeScrollbarTrackSizeProvider.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
103
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
101
|
+
SciNativeScrollbarTrackSizeProvider.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciNativeScrollbarTrackSizeProvider, deps: [{ token: DOCUMENT }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
102
|
+
SciNativeScrollbarTrackSizeProvider.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciNativeScrollbarTrackSizeProvider, providedIn: 'root' });
|
|
103
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciNativeScrollbarTrackSizeProvider, decorators: [{
|
|
104
104
|
type: Injectable,
|
|
105
105
|
args: [{ providedIn: 'root' }]
|
|
106
106
|
}], ctorParameters: function () {
|
|
@@ -409,9 +409,9 @@ class SciScrollbarComponent {
|
|
|
409
409
|
* @internal
|
|
410
410
|
*/
|
|
411
411
|
SciScrollbarComponent.VIEWPORT_RESIZE_DEBOUNCE_TIME = 50;
|
|
412
|
-
SciScrollbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
413
|
-
SciScrollbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
414
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
412
|
+
SciScrollbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciScrollbarComponent, deps: [{ token: i0.ElementRef }, { token: DOCUMENT }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
413
|
+
SciScrollbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.2", type: SciScrollbarComponent, selector: "sci-scrollbar", inputs: { direction: "direction", setViewport: ["viewport", "setViewport"] }, host: { properties: { "class.vertical": "this.vertical", "class.horizontal": "this.horizontal", "class.scrolling": "this.scrolling" } }, viewQueries: [{ propertyName: "thumbElement", first: true, predicate: ["thumb_handle"], descendants: true, static: true }], ngImport: i0, template: "<!-- scrolltrack to move the viewport client upwards (paging) -->\n<div class=\"scrolltrack-start\" (mousedown)=\"onScrollTrackMouseDown($event, 'up')\"></div>\n\n<!-- scrollthumb -->\n<div #thumb_handle\n class=\"thumb-handle\"\n [class.vertical]=\"vertical\"\n [class.horizontal]=\"horizontal\"\n (mousedown)=\"onMouseDown($event)\"\n (touchstart)=\"onTouchStart($event)\"\n (touchmove)=\"onTouchMove($event)\"\n (touchend)=\"onTouchEnd($event)\"\n (touchcancel)=\"onTouchEnd($event)\">\n <div class=\"thumb\"\n [class.vertical]=\"vertical\"\n [class.horizontal]=\"horizontal\">\n </div>\n</div>\n\n<!-- scrolltrack to move the viewport client downwards (paging) -->\n<div class=\"scrolltrack-end\" (mousedown)=\"onScrollTrackMouseDown($event, 'down')\"></div>\n", styles: ["@charset \"UTF-8\";:host{display:flex;border:2px solid transparent;box-sizing:border-box;--sci-scrollbar-color: rgb(78, 78, 78);--\\275sci-scrollbar-thumb-position-fr: 0;--\\275sci-scrollbar-thumb-size-fr: 0}:host.vertical{flex-direction:column}:host.horizontal{flex-direction:row}:host>div.scrolltrack-start{flex-grow:var(--\\275sci-scrollbar-thumb-position-fr)}:host>div.thumb-handle{flex-basis:20px;display:flex;flex-grow:var(--\\275sci-scrollbar-thumb-size-fr);align-items:center}:host>div.thumb-handle.vertical{flex-direction:column}:host>div.thumb-handle.horizontal{flex-direction:row}:host>div.thumb-handle>div.thumb{flex:auto;border-radius:4px;background-color:var(--sci-scrollbar-color);opacity:.4;transition-duration:125ms;transition-property:width,height;transition-timing-function:ease-out}:host>div.thumb-handle>div.thumb.vertical{width:60%}:host>div.thumb-handle>div.thumb.horizontal{height:60%}:host>div.scrolltrack-end{flex-grow:calc(1 - (var(--\\275sci-scrollbar-thumb-position-fr) + var(--\\275sci-scrollbar-thumb-size-fr)))}:host-context:not(.overflow){display:none}:host-context:hover>div.thumb-handle>div.thumb,:host-context(.scrolling)>div.thumb-handle>div.thumb{background-color:var(--sci-scrollbar-color);opacity:.75}:host-context:hover>div.thumb-handle>div.thumb.vertical,:host-context(.scrolling)>div.thumb-handle>div.thumb.vertical{width:100%}:host-context:hover>div.thumb-handle>div.thumb.horizontal,:host-context(.scrolling)>div.thumb-handle>div.thumb.horizontal{height:100%}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
414
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciScrollbarComponent, decorators: [{
|
|
415
415
|
type: Component,
|
|
416
416
|
args: [{ selector: 'sci-scrollbar', changeDetection: ChangeDetectionStrategy.OnPush, template: "<!-- scrolltrack to move the viewport client upwards (paging) -->\n<div class=\"scrolltrack-start\" (mousedown)=\"onScrollTrackMouseDown($event, 'up')\"></div>\n\n<!-- scrollthumb -->\n<div #thumb_handle\n class=\"thumb-handle\"\n [class.vertical]=\"vertical\"\n [class.horizontal]=\"horizontal\"\n (mousedown)=\"onMouseDown($event)\"\n (touchstart)=\"onTouchStart($event)\"\n (touchmove)=\"onTouchMove($event)\"\n (touchend)=\"onTouchEnd($event)\"\n (touchcancel)=\"onTouchEnd($event)\">\n <div class=\"thumb\"\n [class.vertical]=\"vertical\"\n [class.horizontal]=\"horizontal\">\n </div>\n</div>\n\n<!-- scrolltrack to move the viewport client downwards (paging) -->\n<div class=\"scrolltrack-end\" (mousedown)=\"onScrollTrackMouseDown($event, 'down')\"></div>\n", styles: ["@charset \"UTF-8\";:host{display:flex;border:2px solid transparent;box-sizing:border-box;--sci-scrollbar-color: rgb(78, 78, 78);--\\275sci-scrollbar-thumb-position-fr: 0;--\\275sci-scrollbar-thumb-size-fr: 0}:host.vertical{flex-direction:column}:host.horizontal{flex-direction:row}:host>div.scrolltrack-start{flex-grow:var(--\\275sci-scrollbar-thumb-position-fr)}:host>div.thumb-handle{flex-basis:20px;display:flex;flex-grow:var(--\\275sci-scrollbar-thumb-size-fr);align-items:center}:host>div.thumb-handle.vertical{flex-direction:column}:host>div.thumb-handle.horizontal{flex-direction:row}:host>div.thumb-handle>div.thumb{flex:auto;border-radius:4px;background-color:var(--sci-scrollbar-color);opacity:.4;transition-duration:125ms;transition-property:width,height;transition-timing-function:ease-out}:host>div.thumb-handle>div.thumb.vertical{width:60%}:host>div.thumb-handle>div.thumb.horizontal{height:60%}:host>div.scrolltrack-end{flex-grow:calc(1 - (var(--\\275sci-scrollbar-thumb-position-fr) + var(--\\275sci-scrollbar-thumb-size-fr)))}:host-context:not(.overflow){display:none}:host-context:hover>div.thumb-handle>div.thumb,:host-context(.scrolling)>div.thumb-handle>div.thumb{background-color:var(--sci-scrollbar-color);opacity:.75}:host-context:hover>div.thumb-handle>div.thumb.vertical,:host-context(.scrolling)>div.thumb-handle>div.thumb.vertical{width:100%}:host-context:hover>div.thumb-handle>div.thumb.horizontal,:host-context(.scrolling)>div.thumb-handle>div.thumb.horizontal{height:100%}\n"] }]
|
|
417
417
|
}], ctorParameters: function () {
|
|
@@ -514,9 +514,9 @@ class SciScrollableDirective {
|
|
|
514
514
|
this._destroy$.next();
|
|
515
515
|
}
|
|
516
516
|
}
|
|
517
|
-
SciScrollableDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
518
|
-
SciScrollableDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "
|
|
519
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
517
|
+
SciScrollableDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciScrollableDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: SciNativeScrollbarTrackSizeProvider }], target: i0.ɵɵFactoryTarget.Directive });
|
|
518
|
+
SciScrollableDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.1.2", type: SciScrollableDirective, selector: "[sciScrollable]", inputs: { isDisplayNativeScrollbar: ["sciScrollableDisplayNativeScrollbar", "isDisplayNativeScrollbar"] }, usesOnChanges: true, ngImport: i0 });
|
|
519
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciScrollableDirective, decorators: [{
|
|
520
520
|
type: Directive,
|
|
521
521
|
args: [{
|
|
522
522
|
selector: '[sciScrollable]',
|
|
@@ -536,7 +536,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImpor
|
|
|
536
536
|
* SPDX-License-Identifier: EPL-2.0
|
|
537
537
|
*/
|
|
538
538
|
/**
|
|
539
|
-
* Represents a viewport with
|
|
539
|
+
* Represents a viewport with slotted content (`<ng-content>`) used as scrollable content. By default, content is added to a CSS grid layout.
|
|
540
540
|
*
|
|
541
541
|
* The viewport component displays scrollbars when its content overflows. Scrollbars are displayed on top of the content, not next to it.
|
|
542
542
|
* The component uses the native scrollbars of the operating system if they are already sitting on top, or falls back and renders scrollbars on top otherwise.
|
|
@@ -568,24 +568,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImpor
|
|
|
568
568
|
* For the complete documentation on the flex layout and its features, refer to https://developer.mozilla.org/en-US/docs/Web/CSS/flex.
|
|
569
569
|
*
|
|
570
570
|
*
|
|
571
|
-
* ## Layouting the viewport content
|
|
572
|
-
*
|
|
573
|
-
* `NgContent` is added to a CSS grid container with, by default, a single column, filling remaining space vertically and horizontally.
|
|
571
|
+
* ## Layouting the viewport's slotted content
|
|
574
572
|
*
|
|
575
|
-
*
|
|
573
|
+
* By default, the viewport's content is added to a CSS grid container with a single column, filling remaining space vertically and horizontally.
|
|
574
|
+
* Using the `::part(content)` pseudo element selector, you can configure the grid container or apply a different layout, such as a flex or flow layout.
|
|
576
575
|
*
|
|
577
|
-
*
|
|
578
|
-
*
|
|
579
|
-
*
|
|
580
|
-
*
|
|
581
|
-
*
|
|
582
|
-
*
|
|
583
|
-
*
|
|
576
|
+
* #### Example of adding slotted content to a CSS flex container.
|
|
577
|
+
* ```css
|
|
578
|
+
* sci-viewport::part(content) {
|
|
579
|
+
* display: flex;
|
|
580
|
+
* flex-direction: column;
|
|
581
|
+
* }
|
|
582
|
+
* ```
|
|
584
583
|
*
|
|
584
|
+
* #### Example of configuring CSS grid container with two columns
|
|
585
585
|
* ```css
|
|
586
|
-
* sci-viewport {
|
|
587
|
-
*
|
|
588
|
-
*
|
|
586
|
+
* sci-viewport::part(content) {
|
|
587
|
+
* grid-template-columns: 1fr 1fr;
|
|
588
|
+
* gap: 1em;
|
|
589
589
|
* }
|
|
590
590
|
* ```
|
|
591
591
|
*
|
|
@@ -606,7 +606,6 @@ class SciViewportComponent {
|
|
|
606
606
|
this.host = host;
|
|
607
607
|
this.nativeScrollbarTrackSizeProvider = nativeScrollbarTrackSizeProvider;
|
|
608
608
|
this._scrollbarStyle = 'on-top';
|
|
609
|
-
this.tabindex = -1; // make the viewport programmatically focusable but do not include it in the tab order
|
|
610
609
|
/**
|
|
611
610
|
* Emits upon a scroll event.
|
|
612
611
|
*
|
|
@@ -616,7 +615,7 @@ class SciViewportComponent {
|
|
|
616
615
|
}
|
|
617
616
|
/** @internal */
|
|
618
617
|
set setViewport(viewport) {
|
|
619
|
-
this.
|
|
618
|
+
this._viewportElement = coerceElement(viewport);
|
|
620
619
|
}
|
|
621
620
|
/** @internal */
|
|
622
621
|
set setViewportClient(viewportClient) {
|
|
@@ -633,7 +632,8 @@ class SciViewportComponent {
|
|
|
633
632
|
return this._scrollbarStyle;
|
|
634
633
|
}
|
|
635
634
|
focus() {
|
|
636
|
-
|
|
635
|
+
var _a;
|
|
636
|
+
(_a = this._viewportElement) === null || _a === void 0 ? void 0 : _a.focus();
|
|
637
637
|
}
|
|
638
638
|
onScroll(event) {
|
|
639
639
|
this.scroll.emit(event);
|
|
@@ -644,7 +644,7 @@ class SciViewportComponent {
|
|
|
644
644
|
* @see Element.scrollTop
|
|
645
645
|
*/
|
|
646
646
|
get scrollTop() {
|
|
647
|
-
return this.
|
|
647
|
+
return this._viewportElement.scrollTop;
|
|
648
648
|
}
|
|
649
649
|
/**
|
|
650
650
|
* Sets the number of pixels that the viewport client is scrolled vertically.
|
|
@@ -652,7 +652,7 @@ class SciViewportComponent {
|
|
|
652
652
|
* @see Element.scrollTop
|
|
653
653
|
*/
|
|
654
654
|
set scrollTop(scrollTop) {
|
|
655
|
-
this.
|
|
655
|
+
this._viewportElement.scrollTop = scrollTop;
|
|
656
656
|
}
|
|
657
657
|
/**
|
|
658
658
|
* Returns the number of pixels that the viewport client is scrolled horizontally.
|
|
@@ -660,7 +660,7 @@ class SciViewportComponent {
|
|
|
660
660
|
* @see Element.scrollLeft
|
|
661
661
|
*/
|
|
662
662
|
get scrollLeft() {
|
|
663
|
-
return this.
|
|
663
|
+
return this._viewportElement.scrollLeft;
|
|
664
664
|
}
|
|
665
665
|
/**
|
|
666
666
|
* Sets the number of pixels that the viewport client is scrolled horizontally.
|
|
@@ -668,7 +668,7 @@ class SciViewportComponent {
|
|
|
668
668
|
* @see Element.scrollLeft
|
|
669
669
|
*/
|
|
670
670
|
set scrollLeft(scrollLeft) {
|
|
671
|
-
this.
|
|
671
|
+
this._viewportElement.scrollLeft = scrollLeft;
|
|
672
672
|
}
|
|
673
673
|
/**
|
|
674
674
|
* Returns the height of the viewport client.
|
|
@@ -676,7 +676,7 @@ class SciViewportComponent {
|
|
|
676
676
|
* @see Element.scrollHeight
|
|
677
677
|
*/
|
|
678
678
|
get scrollHeight() {
|
|
679
|
-
return this.
|
|
679
|
+
return this._viewportElement.scrollHeight;
|
|
680
680
|
}
|
|
681
681
|
/**
|
|
682
682
|
* Returns the width of the viewport client.
|
|
@@ -684,13 +684,13 @@ class SciViewportComponent {
|
|
|
684
684
|
* @see Element.scrollWidth
|
|
685
685
|
*/
|
|
686
686
|
get scrollWidth() {
|
|
687
|
-
return this.
|
|
687
|
+
return this._viewportElement.scrollWidth;
|
|
688
688
|
}
|
|
689
689
|
/**
|
|
690
690
|
* Returns the viewport {HTMLElement}.
|
|
691
691
|
*/
|
|
692
692
|
get viewportElement() {
|
|
693
|
-
return this.
|
|
693
|
+
return this._viewportElement;
|
|
694
694
|
}
|
|
695
695
|
/**
|
|
696
696
|
* Returns the viewport client {HTMLElement}.
|
|
@@ -703,16 +703,18 @@ class SciViewportComponent {
|
|
|
703
703
|
*
|
|
704
704
|
* @param element - the element to be checked
|
|
705
705
|
* @param fit - control if the element must fully or partially fit into the viewport
|
|
706
|
+
*
|
|
707
|
+
* @throws if the element is not contained in the viewport's slotted content.
|
|
706
708
|
*/
|
|
707
709
|
isElementInView(element, fit) {
|
|
708
710
|
const elLeft = this.computeOffset(element, 'left');
|
|
709
|
-
const elRight = elLeft + element.offsetWidth;
|
|
711
|
+
const elRight = elLeft + coerceElement(element).offsetWidth;
|
|
710
712
|
const elTop = this.computeOffset(element, 'top');
|
|
711
|
-
const elBottom = elTop + element.offsetHeight;
|
|
712
|
-
const vpLeft = this.
|
|
713
|
-
const vpRight = vpLeft + this.
|
|
714
|
-
const vpTop = this.
|
|
715
|
-
const vpBottom = vpTop + this.
|
|
713
|
+
const elBottom = elTop + coerceElement(element).offsetHeight;
|
|
714
|
+
const vpLeft = this._viewportElement.scrollLeft;
|
|
715
|
+
const vpRight = vpLeft + this._viewportElement.clientWidth;
|
|
716
|
+
const vpTop = this._viewportElement.scrollTop;
|
|
717
|
+
const vpBottom = vpTop + this._viewportElement.clientHeight;
|
|
716
718
|
switch (fit) {
|
|
717
719
|
case 'full':
|
|
718
720
|
return (elLeft >= vpLeft && elRight <= vpRight) && (elTop >= vpTop && elBottom <= vpBottom);
|
|
@@ -727,36 +729,37 @@ class SciViewportComponent {
|
|
|
727
729
|
*
|
|
728
730
|
* @param element - the element to scroll into the viewport
|
|
729
731
|
* @param offset - the gap between the element and the viewport
|
|
732
|
+
*
|
|
733
|
+
* @throws if the element is not contained in the viewport's slotted content.
|
|
730
734
|
*/
|
|
731
735
|
scrollIntoView(element, offset = 50) {
|
|
732
|
-
this.
|
|
733
|
-
this.
|
|
736
|
+
this._viewportElement.scrollTop = this.computeOffset(element, 'top') - offset;
|
|
737
|
+
this._viewportElement.scrollLeft = this.computeOffset(element, 'left') - offset;
|
|
734
738
|
}
|
|
735
739
|
/**
|
|
736
740
|
* Computes the distance of the element to the viewport's left or top border.
|
|
741
|
+
*
|
|
742
|
+
* @throws if the element is not contained in the viewport's slotted content.
|
|
737
743
|
*/
|
|
738
744
|
computeOffset(element, border) {
|
|
739
|
-
if (!isChildOf(element, this._viewport)) {
|
|
740
|
-
throw Error('element not a child of the viewport');
|
|
741
|
-
}
|
|
742
745
|
let offset = 0;
|
|
743
|
-
let el = element;
|
|
746
|
+
let el = coerceElement(element);
|
|
744
747
|
do {
|
|
745
748
|
offset += (border === 'left' ? el.offsetLeft : el.offsetTop);
|
|
746
749
|
el = el.offsetParent;
|
|
747
|
-
|
|
750
|
+
if (el === null) {
|
|
751
|
+
throw Error(`[ElementNotContainedError] Element not contained in the viewport's slotted content`);
|
|
752
|
+
}
|
|
753
|
+
} while (el !== this.host.nativeElement);
|
|
748
754
|
return offset;
|
|
749
755
|
}
|
|
750
756
|
}
|
|
751
|
-
SciViewportComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
752
|
-
SciViewportComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
753
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
757
|
+
SciViewportComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciViewportComponent, deps: [{ token: i0.ElementRef }, { token: SciNativeScrollbarTrackSizeProvider }], target: i0.ɵɵFactoryTarget.Component });
|
|
758
|
+
SciViewportComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.2", type: SciViewportComponent, selector: "sci-viewport", inputs: { scrollbarStyle: "scrollbarStyle" }, outputs: { scroll: "scroll" }, host: { listeners: { "focus": "focus()" } }, viewQueries: [{ propertyName: "setViewport", first: true, predicate: ["viewport"], descendants: true, static: true }, { propertyName: "setViewportClient", first: true, predicate: ["viewport_client"], descendants: true, static: true }], ngImport: i0, template: "<!-- viewport and viewport client -->\n<div #viewport\n class=\"viewport\"\n tabindex=\"-1\"\n sciScrollable [sciScrollableDisplayNativeScrollbar]=\"scrollbarStyle === 'native'\"\n cdkScrollable\n (scroll)=\"onScroll($event)\">\n <div #viewport_client class=\"viewport-client\" part=\"content\">\n <slot></slot>\n </div>\n</div>\n\n<!-- render emulated scrollbars which sit on-top -->\n<ng-container *ngIf=\"scrollbarStyle === 'on-top' && (nativeScrollbarTrackSizeProvider.trackSize$ | async) !== null\">\n <sci-scrollbar [direction]=\"'vscroll'\" [viewport]=\"viewport\"></sci-scrollbar>\n <sci-scrollbar [direction]=\"'hscroll'\" [viewport]=\"viewport\"></sci-scrollbar>\n</ng-container>\n", styles: [":host{--sci-viewport-content-grid-template-columns: auto;--sci-viewport-content-grid-template-rows: unset;--sci-viewport-content-grid-auto-columns: unset;--sci-viewport-content-grid-auto-rows: auto;--sci-viewport-content-grid-gap: 0 0;--sci-viewport-scrollbar-color: rgb(78, 78, 78);display:grid;grid-template-columns:100%;grid-template-rows:100%;position:relative;overflow:hidden;outline:none}:host:not(:hover):not(:active) sci-scrollbar:not(.scrolling){opacity:0}:host>div.viewport{display:grid;position:relative;outline:none;-webkit-overflow-scrolling:touch}:host>div.viewport>div.viewport-client{display:grid;grid-template-columns:var(--sci-viewport-content-grid-template-columns);grid-template-rows:var(--sci-viewport-content-grid-template-rows);grid-auto-rows:var(--sci-viewport-content-grid-auto-rows);grid-auto-columns:var(--sci-viewport-content-grid-auto-columns);gap:var(--sci-viewport-content-grid-gap)}:host>sci-scrollbar{--sci-scrollbar-color: var(--sci-viewport-scrollbar-color);position:absolute;transition-duration:1s;transition-property:opacity;transition-timing-function:ease-out}:host>sci-scrollbar.vertical{top:0;right:0;bottom:0;left:unset;width:12px}:host>sci-scrollbar.horizontal{top:unset;right:0;bottom:0;left:0;height:12px}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.CdkScrollable, selector: "[cdk-scrollable], [cdkScrollable]" }, { kind: "component", type: SciScrollbarComponent, selector: "sci-scrollbar", inputs: ["direction", "viewport"] }, { kind: "directive", type: SciScrollableDirective, selector: "[sciScrollable]", inputs: ["sciScrollableDisplayNativeScrollbar"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }], encapsulation: i0.ViewEncapsulation.ShadowDom });
|
|
759
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciViewportComponent, decorators: [{
|
|
754
760
|
type: Component,
|
|
755
|
-
args: [{ selector: 'sci-viewport', template: "<!-- viewport and viewport client -->\n<div #viewport\n class=\"viewport\"\n tabindex=\"-1\"\n sciScrollable [sciScrollableDisplayNativeScrollbar]=\"scrollbarStyle === 'native'\"\n cdkScrollable\n (scroll)=\"onScroll($event)\">\n <div #viewport_client class=\"viewport-client\">\n <
|
|
756
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: SciNativeScrollbarTrackSizeProvider }]; }, propDecorators: {
|
|
757
|
-
type: HostBinding,
|
|
758
|
-
args: ['attr.tabindex']
|
|
759
|
-
}], setViewport: [{
|
|
761
|
+
args: [{ selector: 'sci-viewport', encapsulation: ViewEncapsulation.ShadowDom, template: "<!-- viewport and viewport client -->\n<div #viewport\n class=\"viewport\"\n tabindex=\"-1\"\n sciScrollable [sciScrollableDisplayNativeScrollbar]=\"scrollbarStyle === 'native'\"\n cdkScrollable\n (scroll)=\"onScroll($event)\">\n <div #viewport_client class=\"viewport-client\" part=\"content\">\n <slot></slot>\n </div>\n</div>\n\n<!-- render emulated scrollbars which sit on-top -->\n<ng-container *ngIf=\"scrollbarStyle === 'on-top' && (nativeScrollbarTrackSizeProvider.trackSize$ | async) !== null\">\n <sci-scrollbar [direction]=\"'vscroll'\" [viewport]=\"viewport\"></sci-scrollbar>\n <sci-scrollbar [direction]=\"'hscroll'\" [viewport]=\"viewport\"></sci-scrollbar>\n</ng-container>\n", styles: [":host{--sci-viewport-content-grid-template-columns: auto;--sci-viewport-content-grid-template-rows: unset;--sci-viewport-content-grid-auto-columns: unset;--sci-viewport-content-grid-auto-rows: auto;--sci-viewport-content-grid-gap: 0 0;--sci-viewport-scrollbar-color: rgb(78, 78, 78);display:grid;grid-template-columns:100%;grid-template-rows:100%;position:relative;overflow:hidden;outline:none}:host:not(:hover):not(:active) sci-scrollbar:not(.scrolling){opacity:0}:host>div.viewport{display:grid;position:relative;outline:none;-webkit-overflow-scrolling:touch}:host>div.viewport>div.viewport-client{display:grid;grid-template-columns:var(--sci-viewport-content-grid-template-columns);grid-template-rows:var(--sci-viewport-content-grid-template-rows);grid-auto-rows:var(--sci-viewport-content-grid-auto-rows);grid-auto-columns:var(--sci-viewport-content-grid-auto-columns);gap:var(--sci-viewport-content-grid-gap)}:host>sci-scrollbar{--sci-scrollbar-color: var(--sci-viewport-scrollbar-color);position:absolute;transition-duration:1s;transition-property:opacity;transition-timing-function:ease-out}:host>sci-scrollbar.vertical{top:0;right:0;bottom:0;left:unset;width:12px}:host>sci-scrollbar.horizontal{top:unset;right:0;bottom:0;left:0;height:12px}\n"] }]
|
|
762
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: SciNativeScrollbarTrackSizeProvider }]; }, propDecorators: { setViewport: [{
|
|
760
763
|
type: ViewChild,
|
|
761
764
|
args: ['viewport', { static: true }]
|
|
762
765
|
}], setViewportClient: [{
|
|
@@ -770,18 +773,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImpor
|
|
|
770
773
|
type: HostListener,
|
|
771
774
|
args: ['focus']
|
|
772
775
|
}] } });
|
|
773
|
-
/**
|
|
774
|
-
* Returns 'true' if the given element is a child element of the parent element.
|
|
775
|
-
*/
|
|
776
|
-
function isChildOf(element, parent) {
|
|
777
|
-
while (element.parentElement !== null) {
|
|
778
|
-
element = element.parentElement;
|
|
779
|
-
if (element === parent) {
|
|
780
|
-
return true;
|
|
781
|
-
}
|
|
782
|
-
}
|
|
783
|
-
return false;
|
|
784
|
-
}
|
|
785
776
|
|
|
786
777
|
/*
|
|
787
778
|
* Copyright (c) 2018-2019 Swiss Federal Railways
|
|
@@ -797,18 +788,16 @@ function isChildOf(element, parent) {
|
|
|
797
788
|
*/
|
|
798
789
|
class SciViewportModule {
|
|
799
790
|
}
|
|
800
|
-
SciViewportModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
801
|
-
SciViewportModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "
|
|
791
|
+
SciViewportModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciViewportModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
792
|
+
SciViewportModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.1.2", ngImport: i0, type: SciViewportModule, declarations: [SciViewportComponent,
|
|
802
793
|
SciScrollbarComponent,
|
|
803
794
|
SciScrollableDirective], imports: [CommonModule,
|
|
804
795
|
ScrollingModule], exports: [SciViewportComponent,
|
|
805
796
|
SciScrollbarComponent,
|
|
806
797
|
SciScrollableDirective] });
|
|
807
|
-
SciViewportModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
]] });
|
|
811
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: SciViewportModule, decorators: [{
|
|
798
|
+
SciViewportModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciViewportModule, imports: [CommonModule,
|
|
799
|
+
ScrollingModule] });
|
|
800
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.2", ngImport: i0, type: SciViewportModule, decorators: [{
|
|
812
801
|
type: NgModule,
|
|
813
802
|
args: [{
|
|
814
803
|
imports: [
|