| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141 |
- 'use strict';
- Object.defineProperty(exports, '__esModule', { value: true });
- var defaults = require('./defaults.js');
- var runtime = require('../../../utils/vue/props/runtime.js');
- var typescript = require('../../../utils/typescript.js');
- const itemSize = runtime.buildProp({
- type: runtime.definePropType([Number, Function]),
- required: true
- });
- const estimatedItemSize = runtime.buildProp({
- type: Number
- });
- const cache = runtime.buildProp({
- type: Number,
- default: 2
- });
- const direction = runtime.buildProp({
- type: String,
- values: ["ltr", "rtl"],
- default: "ltr"
- });
- const initScrollOffset = runtime.buildProp({
- type: Number,
- default: 0
- });
- const total = runtime.buildProp({
- type: Number,
- required: true
- });
- const layout = runtime.buildProp({
- type: String,
- values: ["horizontal", "vertical"],
- default: defaults.VERTICAL
- });
- const virtualizedProps = runtime.buildProps({
- className: {
- type: String,
- default: ""
- },
- containerElement: {
- type: runtime.definePropType([String, Object]),
- default: "div"
- },
- data: {
- type: runtime.definePropType(Array),
- default: () => typescript.mutable([])
- },
- direction,
- height: {
- type: [String, Number],
- required: true
- },
- innerElement: {
- type: [String, Object],
- default: "div"
- },
- style: {
- type: runtime.definePropType([Object, String, Array])
- },
- useIsScrolling: Boolean,
- width: {
- type: [Number, String],
- required: false
- },
- perfMode: {
- type: Boolean,
- default: true
- },
- scrollbarAlwaysOn: Boolean
- });
- const virtualizedListProps = runtime.buildProps({
- cache,
- estimatedItemSize,
- layout,
- initScrollOffset,
- total,
- itemSize,
- ...virtualizedProps
- });
- const scrollbarSize = {
- type: Number,
- default: 6
- };
- const startGap = { type: Number, default: 0 };
- const endGap = { type: Number, default: 2 };
- const virtualizedGridProps = runtime.buildProps({
- columnCache: cache,
- columnWidth: itemSize,
- estimatedColumnWidth: estimatedItemSize,
- estimatedRowHeight: estimatedItemSize,
- initScrollLeft: initScrollOffset,
- initScrollTop: initScrollOffset,
- itemKey: {
- type: runtime.definePropType(Function),
- default: ({
- columnIndex,
- rowIndex
- }) => `${rowIndex}:${columnIndex}`
- },
- rowCache: cache,
- rowHeight: itemSize,
- totalColumn: total,
- totalRow: total,
- hScrollbarSize: scrollbarSize,
- vScrollbarSize: scrollbarSize,
- scrollbarStartGap: startGap,
- scrollbarEndGap: endGap,
- role: String,
- ...virtualizedProps
- });
- const virtualizedScrollbarProps = runtime.buildProps({
- alwaysOn: Boolean,
- class: String,
- layout,
- total,
- ratio: {
- type: Number,
- required: true
- },
- clientSize: {
- type: Number,
- required: true
- },
- scrollFrom: {
- type: Number,
- required: true
- },
- scrollbarSize,
- startGap,
- endGap,
- visible: Boolean
- });
- exports.virtualizedGridProps = virtualizedGridProps;
- exports.virtualizedListProps = virtualizedListProps;
- exports.virtualizedProps = virtualizedProps;
- exports.virtualizedScrollbarProps = virtualizedScrollbarProps;
- //# sourceMappingURL=props.js.map
|