@progress/kendo-vue-progressbars 5.3.0-dev.202410141143 → 5.3.0-develop.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. package/README.md +26 -32
  2. package/chunkprogressbar/ChunkProgressBar.js +8 -0
  3. package/chunkprogressbar/ChunkProgressBar.mjs +127 -0
  4. package/common/constants.js +8 -0
  5. package/common/constants.mjs +14 -0
  6. package/common/utils.js +8 -0
  7. package/common/utils.mjs +24 -0
  8. package/dist/cdn/js/kendo-vue-progressbars.js +8 -1
  9. package/index.d.mts +397 -0
  10. package/index.d.ts +397 -0
  11. package/index.js +8 -0
  12. package/index.mjs +13 -0
  13. package/package-metadata.js +8 -0
  14. package/package-metadata.mjs +18 -0
  15. package/package.json +25 -47
  16. package/progressbar/ProgressBar.js +8 -0
  17. package/progressbar/ProgressBar.mjs +204 -0
  18. package/dist/es/additionalTypes.ts +0 -21
  19. package/dist/es/chunkprogressbar/ChunkProgressBar.d.ts +0 -44
  20. package/dist/es/chunkprogressbar/ChunkProgressBar.js +0 -172
  21. package/dist/es/chunkprogressbar/interfaces/ChunkProgressBarProps.d.ts +0 -10
  22. package/dist/es/chunkprogressbar/interfaces/ChunkProgressBarProps.js +0 -1
  23. package/dist/es/common/BaseProps.d.ts +0 -78
  24. package/dist/es/common/BaseProps.js +0 -1
  25. package/dist/es/common/constants.d.ts +0 -16
  26. package/dist/es/common/constants.js +0 -16
  27. package/dist/es/common/utils.d.ts +0 -16
  28. package/dist/es/common/utils.js +0 -34
  29. package/dist/es/main.d.ts +0 -7
  30. package/dist/es/main.js +0 -7
  31. package/dist/es/package-metadata.d.ts +0 -5
  32. package/dist/es/package-metadata.js +0 -11
  33. package/dist/es/progressbar/ProgressBar.d.ts +0 -54
  34. package/dist/es/progressbar/ProgressBar.js +0 -244
  35. package/dist/es/progressbar/interfaces/LabelProps.d.ts +0 -9
  36. package/dist/es/progressbar/interfaces/LabelProps.js +0 -1
  37. package/dist/es/progressbar/interfaces/ProgressBarAnimation.d.ts +0 -9
  38. package/dist/es/progressbar/interfaces/ProgressBarAnimation.js +0 -1
  39. package/dist/es/progressbar/interfaces/ProgressBarHandle.d.ts +0 -21
  40. package/dist/es/progressbar/interfaces/ProgressBarHandle.js +0 -4
  41. package/dist/es/progressbar/interfaces/ProgressBarProps.d.ts +0 -29
  42. package/dist/es/progressbar/interfaces/ProgressBarProps.js +0 -1
  43. package/dist/esm/additionalTypes.ts +0 -21
  44. package/dist/esm/chunkprogressbar/ChunkProgressBar.d.ts +0 -44
  45. package/dist/esm/chunkprogressbar/ChunkProgressBar.js +0 -172
  46. package/dist/esm/chunkprogressbar/interfaces/ChunkProgressBarProps.d.ts +0 -10
  47. package/dist/esm/chunkprogressbar/interfaces/ChunkProgressBarProps.js +0 -1
  48. package/dist/esm/common/BaseProps.d.ts +0 -78
  49. package/dist/esm/common/BaseProps.js +0 -1
  50. package/dist/esm/common/constants.d.ts +0 -16
  51. package/dist/esm/common/constants.js +0 -16
  52. package/dist/esm/common/utils.d.ts +0 -16
  53. package/dist/esm/common/utils.js +0 -34
  54. package/dist/esm/main.d.ts +0 -7
  55. package/dist/esm/main.js +0 -7
  56. package/dist/esm/package-metadata.d.ts +0 -5
  57. package/dist/esm/package-metadata.js +0 -11
  58. package/dist/esm/package.json +0 -3
  59. package/dist/esm/progressbar/ProgressBar.d.ts +0 -54
  60. package/dist/esm/progressbar/ProgressBar.js +0 -244
  61. package/dist/esm/progressbar/interfaces/LabelProps.d.ts +0 -9
  62. package/dist/esm/progressbar/interfaces/LabelProps.js +0 -1
  63. package/dist/esm/progressbar/interfaces/ProgressBarAnimation.d.ts +0 -9
  64. package/dist/esm/progressbar/interfaces/ProgressBarAnimation.js +0 -1
  65. package/dist/esm/progressbar/interfaces/ProgressBarHandle.d.ts +0 -21
  66. package/dist/esm/progressbar/interfaces/ProgressBarHandle.js +0 -4
  67. package/dist/esm/progressbar/interfaces/ProgressBarProps.d.ts +0 -29
  68. package/dist/esm/progressbar/interfaces/ProgressBarProps.js +0 -1
  69. package/dist/npm/additionalTypes.ts +0 -21
  70. package/dist/npm/chunkprogressbar/ChunkProgressBar.d.ts +0 -44
  71. package/dist/npm/chunkprogressbar/ChunkProgressBar.js +0 -179
  72. package/dist/npm/chunkprogressbar/interfaces/ChunkProgressBarProps.d.ts +0 -10
  73. package/dist/npm/chunkprogressbar/interfaces/ChunkProgressBarProps.js +0 -2
  74. package/dist/npm/common/BaseProps.d.ts +0 -78
  75. package/dist/npm/common/BaseProps.js +0 -2
  76. package/dist/npm/common/constants.d.ts +0 -16
  77. package/dist/npm/common/constants.js +0 -19
  78. package/dist/npm/common/utils.d.ts +0 -16
  79. package/dist/npm/common/utils.js +0 -41
  80. package/dist/npm/main.d.ts +0 -7
  81. package/dist/npm/main.js +0 -23
  82. package/dist/npm/package-metadata.d.ts +0 -5
  83. package/dist/npm/package-metadata.js +0 -14
  84. package/dist/npm/progressbar/ProgressBar.d.ts +0 -54
  85. package/dist/npm/progressbar/ProgressBar.js +0 -251
  86. package/dist/npm/progressbar/interfaces/LabelProps.d.ts +0 -9
  87. package/dist/npm/progressbar/interfaces/LabelProps.js +0 -2
  88. package/dist/npm/progressbar/interfaces/ProgressBarAnimation.d.ts +0 -9
  89. package/dist/npm/progressbar/interfaces/ProgressBarAnimation.js +0 -2
  90. package/dist/npm/progressbar/interfaces/ProgressBarHandle.d.ts +0 -21
  91. package/dist/npm/progressbar/interfaces/ProgressBarHandle.js +0 -5
  92. package/dist/npm/progressbar/interfaces/ProgressBarProps.d.ts +0 -29
  93. package/dist/npm/progressbar/interfaces/ProgressBarProps.js +0 -2
@@ -0,0 +1,204 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2024 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import { defineComponent as P, h as m, createVNode as r } from "vue";
9
+ import { animate as g, cancelAnimation as x } from "@progress/kendo-vue-animation";
10
+ import { validatePackage as R, getRef as b, isRtl as D, templateRendering as C, getListeners as E, getTemplate as I, classNames as O, getTabIndex as W, setRef as f } from "@progress/kendo-vue-common";
11
+ import { truncateNumber as A, calculatePercentage as o, updateProgress as l } from "../common/utils.mjs";
12
+ import { DEFAULT_ANIMATION_DURATION as B, NO_ANIMATION as U } from "../common/constants.mjs";
13
+ import { packageMetadata as w } from "../package-metadata.mjs";
14
+ const K = /* @__PURE__ */ P({
15
+ name: "KendoProgressBar",
16
+ props: {
17
+ animation: {
18
+ type: [Boolean, Object],
19
+ default: !1
20
+ },
21
+ disabled: {
22
+ type: Boolean,
23
+ default: !1
24
+ },
25
+ reverse: {
26
+ type: Boolean,
27
+ default: !1
28
+ },
29
+ label: String,
30
+ labelRender: [String, Object, Function],
31
+ labelVisible: {
32
+ type: Boolean,
33
+ default: !0
34
+ },
35
+ labelPlacement: {
36
+ type: String,
37
+ default: void 0,
38
+ validator: function(e) {
39
+ return ["start", "center", "end"].includes(e);
40
+ }
41
+ },
42
+ dir: {
43
+ type: String,
44
+ default: void 0
45
+ },
46
+ max: {
47
+ type: Number,
48
+ default: 100
49
+ },
50
+ min: {
51
+ type: Number,
52
+ default: 0
53
+ },
54
+ value: {
55
+ type: Number,
56
+ default: 0
57
+ },
58
+ orientation: {
59
+ type: String,
60
+ default: "horizontal",
61
+ validator: function(e) {
62
+ return ["horizontal", "vertical"].includes(e);
63
+ }
64
+ },
65
+ tabIndex: Number,
66
+ emptyStyle: Object,
67
+ emptyClassName: String,
68
+ progressStyle: Object,
69
+ progressClassName: String,
70
+ ariaLabel: String
71
+ },
72
+ created() {
73
+ R(w), this.currentDir = this.$props.dir;
74
+ },
75
+ mounted() {
76
+ this._progressStatus = b(this, "progressStatus"), this._progressStatusWrap = b(this, "progressStatusWrap"), this.currentDir = this.$props.dir !== void 0 ? this.$props.dir : D(this.$el) ? "rtl" : "ltr", this.animationFrame = g({
77
+ duration: this.animationDuration,
78
+ onStart: this.handleStart,
79
+ onUpdate: this.handleUpdate,
80
+ onEnd: this.handleEnd
81
+ });
82
+ },
83
+ unmounted() {
84
+ x(this.animationFrame);
85
+ },
86
+ data() {
87
+ return {
88
+ currentDir: void 0
89
+ };
90
+ },
91
+ watch: {
92
+ value: function(e, t) {
93
+ this.prevValue = t, this.animationFrame = g({
94
+ duration: this.animationDuration,
95
+ onStart: this.handleStart,
96
+ onUpdate: this.handleUpdate,
97
+ onEnd: this.handleEnd
98
+ });
99
+ }
100
+ },
101
+ computed: {
102
+ wrapperClass() {
103
+ const {
104
+ disabled: e,
105
+ reverse: t,
106
+ orientation: s,
107
+ value: i
108
+ } = this.$props, a = s === "vertical";
109
+ return {
110
+ "k-progressbar": !0,
111
+ "k-progressbar-horizontal": !a,
112
+ "k-progressbar-vertical": a,
113
+ "k-progressbar-reverse": t,
114
+ "k-progressbar-indeterminate": i === null,
115
+ "k-disabled": e
116
+ };
117
+ },
118
+ isVertical() {
119
+ return this.orientation === "vertical";
120
+ },
121
+ animationDuration() {
122
+ const {
123
+ animation: e
124
+ } = this.$props;
125
+ return typeof e != "boolean" && e !== void 0 ? e.duration : e ? B : U;
126
+ }
127
+ },
128
+ render() {
129
+ const {
130
+ disabled: e,
131
+ labelVisible: t,
132
+ labelPlacement: s,
133
+ max: i,
134
+ min: a,
135
+ tabIndex: p,
136
+ emptyStyle: S,
137
+ emptyClassName: d,
138
+ progressStyle: v,
139
+ progressClassName: u
140
+ } = this.$props, n = this.$props.value || 0, y = this.$props.value === null, N = A(n), k = {
141
+ value: n
142
+ }, $ = this.$props.labelRender ? C.call(this, this.$props.labelRender, E.call(this)) : void 0, _ = m("span", {
143
+ class: "k-progress-status"
144
+ }, N), V = I.call(this, {
145
+ h: m,
146
+ template: $,
147
+ defaultRendering: _,
148
+ additionalProps: k
149
+ }), h = t ? this.$props.label ? r("span", {
150
+ class: "k-progress-status"
151
+ }, [this.$props.label]) : V : void 0, c = O("k-progress-status-wrap", {
152
+ "k-progress-start": s === "start",
153
+ "k-progress-center": s === "center",
154
+ "k-progress-end": s === "end" || s === void 0
155
+ });
156
+ return r("div", {
157
+ class: this.wrapperClass,
158
+ dir: this.currentDir,
159
+ tabindex: W(p, e),
160
+ role: "progressbar",
161
+ "aria-valuemin": a,
162
+ "aria-valuemax": i,
163
+ "aria-valuenow": y ? void 0 : n,
164
+ "aria-disabled": e,
165
+ "aria-label": this.$props.ariaLabel
166
+ }, [r("span", {
167
+ class: c + (d ? " " + d : ""),
168
+ style: S
169
+ }, [h]), r("div", {
170
+ class: "k-progressbar-value k-selected",
171
+ style: v,
172
+ ref: f(this, "progressStatus")
173
+ }, [r("span", {
174
+ class: c + (u ? " " + u : ""),
175
+ ref: f(this, "progressStatusWrap")
176
+ }, [h])])]);
177
+ },
178
+ methods: {
179
+ focus() {
180
+ this.$el && this.$el.focus();
181
+ },
182
+ progressStatusElement() {
183
+ return this._progressStatus;
184
+ },
185
+ progressStatusWrapElement() {
186
+ return this._progressStatusWrap;
187
+ },
188
+ handleStart() {
189
+ const e = o(this.min, this.max, this.prevValue);
190
+ l(this._progressStatus, this._progressStatusWrap, e, this.isVertical);
191
+ },
192
+ handleUpdate(e) {
193
+ const t = o(this.min, this.max, this.prevValue + (this.value - this.prevValue) * e);
194
+ l(this._progressStatus, this._progressStatusWrap, t, this.isVertical);
195
+ },
196
+ handleEnd() {
197
+ const e = o(this.min, this.max, this.value);
198
+ l(this._progressStatus, this._progressStatusWrap, e, this.isVertical);
199
+ }
200
+ }
201
+ });
202
+ export {
203
+ K as ProgressBar
204
+ };
@@ -1,21 +0,0 @@
1
- // @ts-ignore
2
- import { DefineComponent } from 'vue';
3
- // @ts-ignore
4
- import * as Vue from 'vue';
5
-
6
- /**
7
- * @hidden
8
- */
9
- // @ts-ignore
10
- type Vue2type = Vue.default;
11
-
12
- /**
13
- * @hidden
14
- */
15
- // @ts-ignore
16
- import { RecordPropsDefinition, ComponentOptions } from 'vue/types/options';
17
- /**
18
- * @hidden
19
- */
20
- // @ts-ignore
21
- export { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type };
@@ -1,44 +0,0 @@
1
- import { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type } from '../additionalTypes';
2
- declare type DefaultData<V> = object | ((this: V) => {});
3
- declare type DefaultMethods<V> = {
4
- [key: string]: (this: V, ...args: any[]) => any;
5
- };
6
- import { ChunkProgressBarProps } from './interfaces/ChunkProgressBarProps';
7
- /**
8
- * @hidden
9
- */
10
- export interface ChunkProgressBarState {
11
- v3: boolean;
12
- }
13
- /**
14
- * @hidden
15
- */
16
- export interface ChunkProgressBarComputed {
17
- [key: string]: any;
18
- }
19
- /**
20
- * @hidden
21
- */
22
- export interface ChunkProgressBarMethods {
23
- [key: string]: any;
24
- }
25
- /**
26
- * @hidden
27
- */
28
- export interface ChunkProgressBarData {
29
- currentActive: boolean;
30
- }
31
- /**
32
- * @hidden
33
- */
34
- export interface ChunkProgressBarAll extends Vue2type, ChunkProgressBarMethods, ChunkProgressBarData, ChunkProgressBarComputed, ChunkProgressBarState {
35
- }
36
- /**
37
- * @hidden
38
- */
39
- declare let ChunkProgressBarVue2: ComponentOptions<ChunkProgressBarAll, DefaultData<ChunkProgressBarData>, DefaultMethods<ChunkProgressBarAll>, ChunkProgressBarComputed, RecordPropsDefinition<ChunkProgressBarProps>>;
40
- /**
41
- * @hidden
42
- */
43
- declare const ChunkProgressBar: DefineComponent<ChunkProgressBarProps, any, ChunkProgressBarData, ChunkProgressBarComputed, ChunkProgressBarMethods, {}, {}, {}, string, ChunkProgressBarProps, ChunkProgressBarProps, {}>;
44
- export { ChunkProgressBar, ChunkProgressBarVue2 };
@@ -1,172 +0,0 @@
1
- var __assign = this && this.__assign || function () {
2
- __assign = Object.assign || function (t) {
3
- for (var s, i = 1, n = arguments.length; i < n; i++) {
4
- s = arguments[i];
5
- for (var p in s) {
6
- if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
7
- }
8
- }
9
- return t;
10
- };
11
- return __assign.apply(this, arguments);
12
- };
13
- // @ts-ignore
14
- import * as Vue from 'vue';
15
- var allVue = Vue;
16
- var gh = allVue.h;
17
- var isV3 = allVue.version && allVue.version[0] === '3';
18
- import { classNames, getDir, getTabIndex } from '@progress/kendo-vue-common';
19
- import { calculateRatio } from '../common/utils';
20
- import { validatePackage } from '@progress/kendo-vue-common';
21
- import { packageMetadata } from '../package-metadata';
22
- /**
23
- * @hidden
24
- */
25
- var ChunkProgressBarVue2 = {
26
- name: 'KendoChunkProgressBar',
27
- props: {
28
- chunkCount: {
29
- type: Number,
30
- default: 5
31
- },
32
- ariaLabel: String,
33
- disabled: Boolean,
34
- reverse: {
35
- type: Boolean,
36
- default: false
37
- },
38
- max: {
39
- type: Number,
40
- default: 100
41
- },
42
- min: {
43
- type: Number,
44
- default: 0
45
- },
46
- value: {
47
- type: Number,
48
- default: 0
49
- },
50
- tabIndex: Number,
51
- emptyStyle: Object,
52
- emptyClassName: String,
53
- progressStyle: Object,
54
- progressClassName: String,
55
- orientation: {
56
- type: String,
57
- default: 'horizontal',
58
- validator: function validator(value) {
59
- return ['horizontal', 'vertical'].includes(value);
60
- }
61
- }
62
- },
63
- created: function created() {
64
- validatePackage(packageMetadata);
65
- },
66
- data: function data() {
67
- return {
68
- currentDir: undefined
69
- };
70
- },
71
- mounted: function mounted() {
72
- this.currentDir = getDir(this.$el, this.$props.dir);
73
- },
74
- // @ts-ignore
75
- setup: !isV3 ? undefined : function () {
76
- var v3 = !!isV3;
77
- return {
78
- v3: v3
79
- };
80
- },
81
- // @ts-ignore
82
- render: function render(createElement) {
83
- var h = gh || createElement;
84
- var _a = this.$props,
85
- chunkCount = _a.chunkCount,
86
- disabled = _a.disabled,
87
- orientation = _a.orientation,
88
- min = _a.min,
89
- max = _a.max,
90
- reverse = _a.reverse,
91
- tabIndex = _a.tabIndex,
92
- emptyStyle = _a.emptyStyle,
93
- emptyClassName = _a.emptyClassName,
94
- progressStyle = _a.progressStyle,
95
- progressClassName = _a.progressClassName;
96
- var value = this.$props.value;
97
- var indeterminateProp = this.$props.value === null;
98
- var isVertical = orientation === 'vertical';
99
- var renderChunks = function renderChunks(count) {
100
- var chunks = [];
101
- var chunkSizePercentage = 100 / count + '%';
102
- var progressRatio = calculateRatio(min, max, value);
103
- var completedChunksCount = Math.floor(progressRatio * count);
104
- var completedChunks = Array(count).fill(false);
105
- var reverseCompletedChunks = isVertical && !reverse || !isVertical && reverse;
106
- for (var i = 0; i < completedChunksCount; i++) {
107
- completedChunks[i] = true;
108
- }
109
- for (var i = 0; i < count; ++i) {
110
- var isComplete = completedChunks[i];
111
- var classes = isComplete ? progressClassName : emptyClassName;
112
- var layoutStyles = {
113
- width: !isVertical ? chunkSizePercentage : undefined,
114
- height: isVertical ? chunkSizePercentage : undefined
115
- };
116
- var styles = isComplete ? progressStyle : emptyStyle;
117
- var mergedStyles = __assign(__assign({}, layoutStyles), styles);
118
- chunks.push(h("li", {
119
- key: i,
120
- "class": classNames('k-progressbar-chunk', {
121
- 'k-first': i === 0,
122
- 'k-last': i === count - 1,
123
- 'k-selected': isComplete
124
- }, classes),
125
- style: mergedStyles
126
- }));
127
- }
128
- return chunks;
129
- };
130
- return h("div", {
131
- "class": classNames('k-progressbar', 'k-chunk-progressbar', {
132
- 'k-progressbar-horizontal': !isVertical,
133
- 'k-progressbar-vertical': isVertical,
134
- 'k-progressbar-reverse': reverse,
135
- 'k-progressbar-indeterminate': indeterminateProp,
136
- 'k-disabled': disabled
137
- }),
138
- dir: this.currentDir,
139
- attrs: this.v3 ? undefined : {
140
- dir: this.currentDir,
141
- tabIndex: getTabIndex(tabIndex, disabled),
142
- role: 'progressbar',
143
- "aria-label": this.$props.ariaLabel,
144
- "aria-valuemin": min,
145
- "aria-valuemax": max,
146
- "aria-valuenow": indeterminateProp ? undefined : value,
147
- "aria-disabled": disabled
148
- },
149
- tabIndex: getTabIndex(tabIndex, disabled),
150
- role: 'progressbar',
151
- "aria-label": this.$props.ariaLabel,
152
- "aria-valuemin": min,
153
- "aria-valuemax": max,
154
- "aria-valuenow": indeterminateProp ? undefined : value,
155
- "aria-disabled": disabled
156
- }, [h("ul", {
157
- "class": 'k-progressbar-chunks k-reset'
158
- }, [renderChunks.call(this, chunkCount)])]);
159
- },
160
- methods: {
161
- focusElement: function focusElement() {
162
- if (this.$el) {
163
- this.$el.focus();
164
- }
165
- }
166
- }
167
- };
168
- /**
169
- * @hidden
170
- */
171
- var ChunkProgressBar = ChunkProgressBarVue2;
172
- export { ChunkProgressBar, ChunkProgressBarVue2 };
@@ -1,10 +0,0 @@
1
- import { BaseProps } from '../../common/BaseProps';
2
- /**
3
- * Represents the props of the [Kendo UI for Vue ChunkProgressBar component]({% slug overview_chunkprogressbar %}).
4
- */
5
- export interface ChunkProgressBarProps extends BaseProps {
6
- /**
7
- * Sets the number of chunks into which the ChunkProgressBar will be split. Defaults to `5`.
8
- */
9
- chunkCount?: number;
10
- }
@@ -1,78 +0,0 @@
1
- /**
2
- * @hidden
3
- */
4
- export interface BaseProps {
5
- /**
6
- * Sets one of the two visually distinct types of progress bar.
7
- *
8
- * @hidden
9
- */
10
- type?: 'linear' | 'circular';
11
- /**
12
- * Sets the value of the progress bar. Has to be between `min` and `max` values. Defaults to `0`.
13
- * Set `null` to enable the indeterminate state of the progress bar.
14
- * See examples ([here]({% slug overview_progressbar %})).
15
- */
16
- value?: number | null;
17
- /**
18
- * The minimum value of the progress bar. Defaults to `0`.
19
- */
20
- min?: number;
21
- /**
22
- * The maximum value of the progress bar. Defaults to `100`.
23
- */
24
- max?: number;
25
- /**
26
- * Represents the `dir` HTML attribute. This is used to switch from LTR to RTL.
27
- */
28
- dir?: string;
29
- /**
30
- * The accessible label of the component.
31
- */
32
- ariaLabel?: string;
33
- /**
34
- * Sets the disabled state of the progress bar.
35
- * See examples ([here]({% slug progressbar_disabled %})).
36
- */
37
- disabled?: boolean;
38
- /**
39
- * Defines the orientation of the progress bar.
40
- * See examples ([here]({% slug progressbar_orientation %})) .
41
- * Defaults to `horizontal`.
42
- */
43
- orientation?: 'horizontal' | 'vertical' | string;
44
- /**
45
- * If set to `true`, the progress bar will be reversed.
46
- * See examples ([here]({% slug progressbar_direction %})).
47
- * Defaults to `false`.
48
- */
49
- reverse?: boolean;
50
- /**
51
- * Specifies a list of CSS classes that will be added to the progress bar element.
52
- */
53
- className?: string;
54
- /**
55
- * The styles that are applied to the inner element which represents the empty portion of the progress bar.
56
- * See examples ([here]({% slug progressbar_appearance %})).
57
- */
58
- emptyStyle?: object;
59
- /**
60
- * Sets additional classes to the inner element which represents the empty portion of the progress bar.
61
- * See examples ([here]({% slug progressbar_appearance %})).
62
- */
63
- emptyClassName?: string;
64
- /**
65
- * The styles that are applied to the inner element which represents the full portion of the progress bar.
66
- * See examples ([here]({% slug progressbar_appearance %})).
67
- */
68
- progressStyle?: object;
69
- /**
70
- * Sets additional classes to the inner element which represents the full portion of the progress bar.
71
- * See examples ([here]({% slug progressbar_appearance %})).
72
- */
73
- progressClassName?: string;
74
- /**
75
- * Sets the `tabIndex` property of the progress bar.
76
- */
77
- tabIndex?: number;
78
- }
@@ -1 +0,0 @@
1
- export {};
@@ -1,16 +0,0 @@
1
- /**
2
- * @hidden
3
- */
4
- export declare const MIN_RATIO = 0.00001;
5
- /**
6
- * @hidden
7
- */
8
- export declare const LABEL_DECIMALS = 3;
9
- /**
10
- * @hidden
11
- */
12
- export declare const DEFAULT_ANIMATION_DURATION = 400;
13
- /**
14
- * @hidden
15
- */
16
- export declare const NO_ANIMATION = 0;
@@ -1,16 +0,0 @@
1
- /**
2
- * @hidden
3
- */
4
- export var MIN_RATIO = 0.00001;
5
- /**
6
- * @hidden
7
- */
8
- export var LABEL_DECIMALS = 3;
9
- /**
10
- * @hidden
11
- */
12
- export var DEFAULT_ANIMATION_DURATION = 400;
13
- /**
14
- * @hidden
15
- */
16
- export var NO_ANIMATION = 0;
@@ -1,16 +0,0 @@
1
- /**
2
- * @hidden
3
- */
4
- export declare const truncateNumber: (value: number) => string;
5
- /**
6
- * @hidden
7
- */
8
- export declare const calculatePercentage: (min: number, max: number, value: number) => number;
9
- /**
10
- * @hidden
11
- */
12
- export declare const updateProgress: (progressRef: any, progressWrapRef: any, percentage: number, isVertical: boolean) => void;
13
- /**
14
- * @hidden
15
- */
16
- export declare const calculateRatio: (min: number, max: number, value: number) => number;
@@ -1,34 +0,0 @@
1
- import { LABEL_DECIMALS, MIN_RATIO } from './constants';
2
- /**
3
- * @hidden
4
- */
5
- export var truncateNumber = function (value) {
6
- var numberParts = value.toString().split('.');
7
- return numberParts.length === 1 ? "".concat(numberParts[0]) : "".concat(numberParts[0], ".").concat(numberParts[1].substr(0, LABEL_DECIMALS));
8
- };
9
- /**
10
- * @hidden
11
- */
12
- export var calculatePercentage = function (min, max, value) {
13
- var onePercent = Math.abs((max - min) / 100);
14
- return Math.abs((value - min) / onePercent);
15
- };
16
- /**
17
- * @hidden
18
- */
19
- export var updateProgress = function (progressRef, progressWrapRef, percentage, isVertical) {
20
- var progressPercentage = Math.max(percentage, 0.01);
21
- var progressWrapPercentage = (100 / progressPercentage) * 100;
22
- if (progressRef && progressWrapRef) {
23
- progressRef.style.width = !isVertical ? "".concat(progressPercentage, "%") : '100%';
24
- progressWrapRef.style.width = !isVertical ? "".concat(progressWrapPercentage, "%") : '100%';
25
- progressRef.style.height = isVertical ? "".concat(progressPercentage, "%") : '100%';
26
- progressWrapRef.style.height = isVertical ? "".concat(progressWrapPercentage, "%") : '100%';
27
- }
28
- };
29
- /**
30
- * @hidden
31
- */
32
- export var calculateRatio = function (min, max, value) {
33
- return Math.max((value - min) / (max - min), MIN_RATIO);
34
- };
package/dist/es/main.d.ts DELETED
@@ -1,7 +0,0 @@
1
- export * from './progressbar/ProgressBar';
2
- export * from './progressbar/interfaces/ProgressBarHandle';
3
- export * from './progressbar/interfaces/ProgressBarProps';
4
- export * from './progressbar/interfaces/ProgressBarAnimation';
5
- export * from './progressbar/interfaces/LabelProps';
6
- export * from './chunkprogressbar/ChunkProgressBar';
7
- export * from './chunkprogressbar/interfaces/ChunkProgressBarProps';
package/dist/es/main.js DELETED
@@ -1,7 +0,0 @@
1
- export * from './progressbar/ProgressBar';
2
- export * from './progressbar/interfaces/ProgressBarHandle';
3
- export * from './progressbar/interfaces/ProgressBarProps';
4
- export * from './progressbar/interfaces/ProgressBarAnimation';
5
- export * from './progressbar/interfaces/LabelProps';
6
- export * from './chunkprogressbar/ChunkProgressBar';
7
- export * from './chunkprogressbar/interfaces/ChunkProgressBarProps';
@@ -1,5 +0,0 @@
1
- import { PackageMetadata } from '@progress/kendo-licensing';
2
- /**
3
- * @hidden
4
- */
5
- export declare const packageMetadata: PackageMetadata;
@@ -1,11 +0,0 @@
1
- /**
2
- * @hidden
3
- */
4
- export var packageMetadata = {
5
- name: '@progress/kendo-vue-progressbars',
6
- productName: 'Kendo UI for Vue',
7
- productCodes: ['KENDOUIVUE', 'KENDOUICOMPLETE'],
8
- publishDate: 1728905610,
9
- version: '',
10
- licensingDocsUrl: 'https://www.telerik.com/kendo-vue-ui/my-license/?utm_medium=product&utm_source=kendovue&utm_campaign=kendo-ui-vue-purchase-license-keys-warning'
11
- };