albinasoft-ui-package 1.1.44 → 1.1.45
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/LICENSE +21 -21
- package/dist/assets/css/custom-autocomplete-input.css +49 -49
- package/dist/assets/css/custom-datatable.css +2 -2
- package/dist/assets/css/custom-datetime-picker.css +779 -779
- package/dist/assets/css/custom-progress-bar.css +37 -37
- package/dist/assets/css/custom-select.css +62 -62
- package/dist/assets/css/custom-simple-select.css +117 -117
- package/dist/assets/css/custom-timeline.css +43 -43
- package/dist/assets/css/custom-treeview.css +83 -83
- package/dist/assets/css/dark.css +2159 -2159
- package/dist/assets/css/main.css +26664 -26664
- package/dist/components/AlbinaForm.d.ts +28 -28
- package/dist/components/AlbinaForm.js +88 -88
- package/dist/components/CustomAutocompleteInput.d.ts +23 -23
- package/dist/components/CustomAutocompleteInput.js +185 -185
- package/dist/components/CustomButton.d.ts +14 -14
- package/dist/components/CustomButton.js +98 -98
- package/dist/components/CustomCheckbox.d.ts +20 -20
- package/dist/components/CustomCheckbox.js +58 -58
- package/dist/components/CustomDatatable.d.ts +42 -42
- package/dist/components/CustomDatatable.js +92 -92
- package/dist/components/CustomDateTimePicker.d.ts +33 -33
- package/dist/components/CustomDateTimePicker.js +91 -91
- package/dist/components/CustomDivider.d.ts +51 -51
- package/dist/components/CustomDivider.js +87 -87
- package/dist/components/CustomFileUploader.d.ts +65 -65
- package/dist/components/CustomFileUploader.js +460 -460
- package/dist/components/CustomForm.d.ts +225 -225
- package/dist/components/CustomForm.js +259 -259
- package/dist/components/CustomInput.d.ts +37 -37
- package/dist/components/CustomInput.js +85 -85
- package/dist/components/CustomModal.d.ts +15 -15
- package/dist/components/CustomModal.js +17 -17
- package/dist/components/CustomPhoneInput.d.ts +29 -29
- package/dist/components/CustomPhoneInput.js +251 -251
- package/dist/components/CustomProgressBar.d.ts +9 -9
- package/dist/components/CustomProgressBar.js +40 -40
- package/dist/components/CustomRadioButton.d.ts +25 -25
- package/dist/components/CustomRadioButton.js +34 -34
- package/dist/components/CustomRichTextbox.d.ts +14 -14
- package/dist/components/CustomRichTextbox.js +89 -89
- package/dist/components/CustomSelect.d.ts +32 -32
- package/dist/components/CustomSelect.js +193 -193
- package/dist/components/CustomSimpleSelect.d.ts +21 -21
- package/dist/components/CustomSimpleSelect.js +64 -64
- package/dist/components/CustomTab.d.ts +44 -44
- package/dist/components/CustomTab.js +122 -122
- package/dist/components/CustomText.d.ts +72 -72
- package/dist/components/CustomText.js +158 -158
- package/dist/components/CustomTextarea.d.ts +22 -22
- package/dist/components/CustomTextarea.js +33 -33
- package/dist/components/CustomTimeline.d.ts +30 -30
- package/dist/components/CustomTimeline.js +80 -80
- package/dist/components/CustomTreeView.d.ts +20 -20
- package/dist/components/CustomTreeView.js +197 -168
- package/dist/index.d.ts +22 -22
- package/dist/index.js +48 -48
- package/package.json +44 -44
- package/readme.md +9 -9
@@ -1,91 +1,91 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
|
-
};
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
-
exports.TimeFormat = exports.CustomDateTimePicker = void 0;
|
7
|
-
var react_1 = __importDefault(require("react"));
|
8
|
-
var react_bootstrap_1 = require("react-bootstrap");
|
9
|
-
var fa_1 = require("react-icons/fa");
|
10
|
-
var react_datepicker_1 = __importDefault(require("react-datepicker"));
|
11
|
-
require("../assets/css/custom-datetime-picker.css");
|
12
|
-
var TimeFormat;
|
13
|
-
(function (TimeFormat) {
|
14
|
-
TimeFormat["H"] = "HH";
|
15
|
-
TimeFormat["M"] = "mm";
|
16
|
-
TimeFormat["HM"] = "HH:mm";
|
17
|
-
})(TimeFormat || (TimeFormat = {}));
|
18
|
-
exports.TimeFormat = TimeFormat;
|
19
|
-
// Manuel Türkçe locale objesi
|
20
|
-
var customTrLocale = {
|
21
|
-
localize: {
|
22
|
-
month: function (n) {
|
23
|
-
var months = [
|
24
|
-
"Ocak",
|
25
|
-
"Şubat",
|
26
|
-
"Mart",
|
27
|
-
"Nisan",
|
28
|
-
"Mayıs",
|
29
|
-
"Haziran",
|
30
|
-
"Temmuz",
|
31
|
-
"Ağustos",
|
32
|
-
"Eylül",
|
33
|
-
"Ekim",
|
34
|
-
"Kasım",
|
35
|
-
"Aralık",
|
36
|
-
];
|
37
|
-
return months[n];
|
38
|
-
},
|
39
|
-
day: function (n) {
|
40
|
-
var days = ["Pzr", "Pts", "Sal", "Çrş", "Prş", "Cum", "Cts"];
|
41
|
-
return days[n];
|
42
|
-
},
|
43
|
-
},
|
44
|
-
formatLong: {
|
45
|
-
date: function () { return "dd.MM.yyyy"; },
|
46
|
-
time: function () { return "HH:mm"; },
|
47
|
-
dateTime: function () { return "dd.MM.yyyy HH:mm"; },
|
48
|
-
},
|
49
|
-
options: {
|
50
|
-
weekStartsOn: 1,
|
51
|
-
},
|
52
|
-
};
|
53
|
-
var CustomDateTimePicker = function (_a) {
|
54
|
-
var id = _a.id, name = _a.name, label = _a.label, value = _a.value, placeholder = _a.placeholder, _b = _a.required, required = _b === void 0 ? false : _b, errorMessage = _a.errorMessage, _c = _a.conditionalErrorVisible, conditionalErrorVisible = _c === void 0 ? false : _c, conditionalErrorMessage = _a.conditionalErrorMessage, tooltip = _a.tooltip, description = _a.description, _d = _a.disabled, disabled = _d === void 0 ? false : _d, className = _a.className, style = _a.style, showTimeSelect = _a.showTimeSelect, showTimeSelectOnly = _a.showTimeSelectOnly, showYearDropdown = _a.showYearDropdown, _e = _a.timeFormat, timeFormat = _e === void 0 ? TimeFormat.HM : _e, timeIntervals = _a.timeIntervals, submitted = _a.submitted, onChange = _a.onChange;
|
55
|
-
// Eğer form gönderildiyse ve required field boşsa hata durumu geçerli olsun.
|
56
|
-
var isInvalid = submitted && required && !value;
|
57
|
-
return (react_1.default.createElement("div", { className: "col-12", style: style },
|
58
|
-
react_1.default.createElement("div", { className: "form-group" },
|
59
|
-
react_1.default.createElement("label", { htmlFor: id, className: "form-label" }, label),
|
60
|
-
react_1.default.createElement("div", { className: "position-relative" },
|
61
|
-
react_1.default.createElement(react_bootstrap_1.OverlayTrigger, { placement: "bottom", overlay: tooltip ? (react_1.default.createElement(react_bootstrap_1.Tooltip, { id: "tooltip-".concat(id) }, tooltip)) : (react_1.default.createElement(react_1.default.Fragment, null)) },
|
62
|
-
react_1.default.createElement("div", null,
|
63
|
-
react_1.default.createElement(react_datepicker_1.default, { id: id, name: name, selected: value, onChange: onChange, className: "form-control ".concat(className || "", " ").concat(submitted ? (isInvalid ? "is-invalid" : "is-valid") : ""), placeholderText: placeholder, disabled: disabled, required: required, showTimeSelect: showTimeSelect || false, showTimeSelectOnly: showTimeSelectOnly || false, showYearDropdown: showYearDropdown || false, showTimeCaption: false, timeFormat: timeFormat, locale: customTrLocale, dateFormat: showTimeSelectOnly
|
64
|
-
? timeFormat
|
65
|
-
: showTimeSelect
|
66
|
-
? "dd.MM.yyyy HH:mm"
|
67
|
-
: "dd.MM.yyyy", timeIntervals: timeFormat === TimeFormat.H
|
68
|
-
? 60
|
69
|
-
: timeFormat === TimeFormat.M
|
70
|
-
? 1
|
71
|
-
: timeIntervals
|
72
|
-
? timeIntervals
|
73
|
-
: 30 }))),
|
74
|
-
react_1.default.createElement("div", { className: "invalid-feedback text-danger mt-2 ".concat(isInvalid ? "d-flex" : "") },
|
75
|
-
react_1.default.createElement("div", { className: "description-icon" },
|
76
|
-
react_1.default.createElement(fa_1.FaExclamationTriangle, null)),
|
77
|
-
react_1.default.createElement("div", { className: "description-text" },
|
78
|
-
react_1.default.createElement("span", null, errorMessage || "Tarih seçimi zorunludur."))),
|
79
|
-
conditionalErrorVisible && (react_1.default.createElement("div", { className: "conditional-error-message text-warning mt-2" },
|
80
|
-
react_1.default.createElement("div", { className: "description-icon" },
|
81
|
-
react_1.default.createElement(fa_1.FaExclamationTriangle, null)),
|
82
|
-
react_1.default.createElement("div", { className: "description-text" },
|
83
|
-
react_1.default.createElement("span", null, conditionalErrorMessage)))),
|
84
|
-
description && (react_1.default.createElement("div", { className: "form-description text-secondary mt-2" },
|
85
|
-
react_1.default.createElement("div", { className: "description-icon" },
|
86
|
-
react_1.default.createElement(fa_1.FaInfoCircle, null)),
|
87
|
-
react_1.default.createElement("div", { className: "description-text" },
|
88
|
-
react_1.default.createElement("span", null, description))))))));
|
89
|
-
};
|
90
|
-
exports.CustomDateTimePicker = CustomDateTimePicker;
|
91
|
-
exports.default = CustomDateTimePicker;
|
1
|
+
"use strict";
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
|
+
};
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
exports.TimeFormat = exports.CustomDateTimePicker = void 0;
|
7
|
+
var react_1 = __importDefault(require("react"));
|
8
|
+
var react_bootstrap_1 = require("react-bootstrap");
|
9
|
+
var fa_1 = require("react-icons/fa");
|
10
|
+
var react_datepicker_1 = __importDefault(require("react-datepicker"));
|
11
|
+
require("../assets/css/custom-datetime-picker.css");
|
12
|
+
var TimeFormat;
|
13
|
+
(function (TimeFormat) {
|
14
|
+
TimeFormat["H"] = "HH";
|
15
|
+
TimeFormat["M"] = "mm";
|
16
|
+
TimeFormat["HM"] = "HH:mm";
|
17
|
+
})(TimeFormat || (TimeFormat = {}));
|
18
|
+
exports.TimeFormat = TimeFormat;
|
19
|
+
// Manuel Türkçe locale objesi
|
20
|
+
var customTrLocale = {
|
21
|
+
localize: {
|
22
|
+
month: function (n) {
|
23
|
+
var months = [
|
24
|
+
"Ocak",
|
25
|
+
"Şubat",
|
26
|
+
"Mart",
|
27
|
+
"Nisan",
|
28
|
+
"Mayıs",
|
29
|
+
"Haziran",
|
30
|
+
"Temmuz",
|
31
|
+
"Ağustos",
|
32
|
+
"Eylül",
|
33
|
+
"Ekim",
|
34
|
+
"Kasım",
|
35
|
+
"Aralık",
|
36
|
+
];
|
37
|
+
return months[n];
|
38
|
+
},
|
39
|
+
day: function (n) {
|
40
|
+
var days = ["Pzr", "Pts", "Sal", "Çrş", "Prş", "Cum", "Cts"];
|
41
|
+
return days[n];
|
42
|
+
},
|
43
|
+
},
|
44
|
+
formatLong: {
|
45
|
+
date: function () { return "dd.MM.yyyy"; },
|
46
|
+
time: function () { return "HH:mm"; },
|
47
|
+
dateTime: function () { return "dd.MM.yyyy HH:mm"; },
|
48
|
+
},
|
49
|
+
options: {
|
50
|
+
weekStartsOn: 1,
|
51
|
+
},
|
52
|
+
};
|
53
|
+
var CustomDateTimePicker = function (_a) {
|
54
|
+
var id = _a.id, name = _a.name, label = _a.label, value = _a.value, placeholder = _a.placeholder, _b = _a.required, required = _b === void 0 ? false : _b, errorMessage = _a.errorMessage, _c = _a.conditionalErrorVisible, conditionalErrorVisible = _c === void 0 ? false : _c, conditionalErrorMessage = _a.conditionalErrorMessage, tooltip = _a.tooltip, description = _a.description, _d = _a.disabled, disabled = _d === void 0 ? false : _d, className = _a.className, style = _a.style, showTimeSelect = _a.showTimeSelect, showTimeSelectOnly = _a.showTimeSelectOnly, showYearDropdown = _a.showYearDropdown, _e = _a.timeFormat, timeFormat = _e === void 0 ? TimeFormat.HM : _e, timeIntervals = _a.timeIntervals, submitted = _a.submitted, onChange = _a.onChange;
|
55
|
+
// Eğer form gönderildiyse ve required field boşsa hata durumu geçerli olsun.
|
56
|
+
var isInvalid = submitted && required && !value;
|
57
|
+
return (react_1.default.createElement("div", { className: "col-12", style: style },
|
58
|
+
react_1.default.createElement("div", { className: "form-group" },
|
59
|
+
react_1.default.createElement("label", { htmlFor: id, className: "form-label" }, label),
|
60
|
+
react_1.default.createElement("div", { className: "position-relative" },
|
61
|
+
react_1.default.createElement(react_bootstrap_1.OverlayTrigger, { placement: "bottom", overlay: tooltip ? (react_1.default.createElement(react_bootstrap_1.Tooltip, { id: "tooltip-".concat(id) }, tooltip)) : (react_1.default.createElement(react_1.default.Fragment, null)) },
|
62
|
+
react_1.default.createElement("div", null,
|
63
|
+
react_1.default.createElement(react_datepicker_1.default, { id: id, name: name, selected: value, onChange: onChange, className: "form-control ".concat(className || "", " ").concat(submitted ? (isInvalid ? "is-invalid" : "is-valid") : ""), placeholderText: placeholder, disabled: disabled, required: required, showTimeSelect: showTimeSelect || false, showTimeSelectOnly: showTimeSelectOnly || false, showYearDropdown: showYearDropdown || false, showTimeCaption: false, timeFormat: timeFormat, locale: customTrLocale, dateFormat: showTimeSelectOnly
|
64
|
+
? timeFormat
|
65
|
+
: showTimeSelect
|
66
|
+
? "dd.MM.yyyy HH:mm"
|
67
|
+
: "dd.MM.yyyy", timeIntervals: timeFormat === TimeFormat.H
|
68
|
+
? 60
|
69
|
+
: timeFormat === TimeFormat.M
|
70
|
+
? 1
|
71
|
+
: timeIntervals
|
72
|
+
? timeIntervals
|
73
|
+
: 30 }))),
|
74
|
+
react_1.default.createElement("div", { className: "invalid-feedback text-danger mt-2 ".concat(isInvalid ? "d-flex" : "") },
|
75
|
+
react_1.default.createElement("div", { className: "description-icon" },
|
76
|
+
react_1.default.createElement(fa_1.FaExclamationTriangle, null)),
|
77
|
+
react_1.default.createElement("div", { className: "description-text" },
|
78
|
+
react_1.default.createElement("span", null, errorMessage || "Tarih seçimi zorunludur."))),
|
79
|
+
conditionalErrorVisible && (react_1.default.createElement("div", { className: "conditional-error-message text-warning mt-2" },
|
80
|
+
react_1.default.createElement("div", { className: "description-icon" },
|
81
|
+
react_1.default.createElement(fa_1.FaExclamationTriangle, null)),
|
82
|
+
react_1.default.createElement("div", { className: "description-text" },
|
83
|
+
react_1.default.createElement("span", null, conditionalErrorMessage)))),
|
84
|
+
description && (react_1.default.createElement("div", { className: "form-description text-secondary mt-2" },
|
85
|
+
react_1.default.createElement("div", { className: "description-icon" },
|
86
|
+
react_1.default.createElement(fa_1.FaInfoCircle, null)),
|
87
|
+
react_1.default.createElement("div", { className: "description-text" },
|
88
|
+
react_1.default.createElement("span", null, description))))))));
|
89
|
+
};
|
90
|
+
exports.CustomDateTimePicker = CustomDateTimePicker;
|
91
|
+
exports.default = CustomDateTimePicker;
|
@@ -1,51 +1,51 @@
|
|
1
|
-
import React from 'react';
|
2
|
-
declare enum Color {
|
3
|
-
DEFAULT = "currentColor",
|
4
|
-
PRIMARY = "text-primary",
|
5
|
-
SECONDARY = "text-secondary",
|
6
|
-
SUCCESS = "text-success",
|
7
|
-
WARNING = "text-warning",
|
8
|
-
DANGER = "text-danger",
|
9
|
-
INFO = "text-info",
|
10
|
-
DARK = "text-dark",
|
11
|
-
LIGHT = "text-light"
|
12
|
-
}
|
13
|
-
declare enum Alignment {
|
14
|
-
LEFT = "left",
|
15
|
-
CENTER = "center",
|
16
|
-
RIGHT = "right"
|
17
|
-
}
|
18
|
-
declare enum Thickness {
|
19
|
-
T1 = "1px",
|
20
|
-
T2 = "2px",
|
21
|
-
T3 = "3px",
|
22
|
-
T4 = "4px",
|
23
|
-
T5 = "5px",
|
24
|
-
T6 = "6px",
|
25
|
-
T8 = "8px",
|
26
|
-
T10 = "10px",
|
27
|
-
T12 = "12px",
|
28
|
-
T16 = "16px",
|
29
|
-
T24 = "24px"
|
30
|
-
}
|
31
|
-
declare enum Width {
|
32
|
-
W10 = "10%",
|
33
|
-
W25 = "25%",
|
34
|
-
W33 = "33%",
|
35
|
-
W50 = "50%",
|
36
|
-
W66 = "66%",
|
37
|
-
W75 = "75%",
|
38
|
-
W100 = "100%"
|
39
|
-
}
|
40
|
-
interface CustomDividerProps {
|
41
|
-
id?: string;
|
42
|
-
color?: Color;
|
43
|
-
thickness?: Thickness;
|
44
|
-
width?: Width;
|
45
|
-
alignment?: Alignment;
|
46
|
-
className?: string;
|
47
|
-
style?: React.CSSProperties;
|
48
|
-
}
|
49
|
-
declare const CustomDivider: React.FC<CustomDividerProps>;
|
50
|
-
export { CustomDivider, Color, Alignment, Thickness, Width };
|
51
|
-
export default CustomDivider;
|
1
|
+
import React from 'react';
|
2
|
+
declare enum Color {
|
3
|
+
DEFAULT = "currentColor",
|
4
|
+
PRIMARY = "text-primary",
|
5
|
+
SECONDARY = "text-secondary",
|
6
|
+
SUCCESS = "text-success",
|
7
|
+
WARNING = "text-warning",
|
8
|
+
DANGER = "text-danger",
|
9
|
+
INFO = "text-info",
|
10
|
+
DARK = "text-dark",
|
11
|
+
LIGHT = "text-light"
|
12
|
+
}
|
13
|
+
declare enum Alignment {
|
14
|
+
LEFT = "left",
|
15
|
+
CENTER = "center",
|
16
|
+
RIGHT = "right"
|
17
|
+
}
|
18
|
+
declare enum Thickness {
|
19
|
+
T1 = "1px",
|
20
|
+
T2 = "2px",
|
21
|
+
T3 = "3px",
|
22
|
+
T4 = "4px",
|
23
|
+
T5 = "5px",
|
24
|
+
T6 = "6px",
|
25
|
+
T8 = "8px",
|
26
|
+
T10 = "10px",
|
27
|
+
T12 = "12px",
|
28
|
+
T16 = "16px",
|
29
|
+
T24 = "24px"
|
30
|
+
}
|
31
|
+
declare enum Width {
|
32
|
+
W10 = "10%",
|
33
|
+
W25 = "25%",
|
34
|
+
W33 = "33%",
|
35
|
+
W50 = "50%",
|
36
|
+
W66 = "66%",
|
37
|
+
W75 = "75%",
|
38
|
+
W100 = "100%"
|
39
|
+
}
|
40
|
+
interface CustomDividerProps {
|
41
|
+
id?: string;
|
42
|
+
color?: Color;
|
43
|
+
thickness?: Thickness;
|
44
|
+
width?: Width;
|
45
|
+
alignment?: Alignment;
|
46
|
+
className?: string;
|
47
|
+
style?: React.CSSProperties;
|
48
|
+
}
|
49
|
+
declare const CustomDivider: React.FC<CustomDividerProps>;
|
50
|
+
export { CustomDivider, Color, Alignment, Thickness, Width };
|
51
|
+
export default CustomDivider;
|
@@ -1,87 +1,87 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __assign = (this && this.__assign) || function () {
|
3
|
-
__assign = Object.assign || function(t) {
|
4
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
5
|
-
s = arguments[i];
|
6
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
7
|
-
t[p] = s[p];
|
8
|
-
}
|
9
|
-
return t;
|
10
|
-
};
|
11
|
-
return __assign.apply(this, arguments);
|
12
|
-
};
|
13
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
14
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
15
|
-
};
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
exports.Width = exports.Thickness = exports.Alignment = exports.Color = exports.CustomDivider = void 0;
|
18
|
-
var react_1 = __importDefault(require("react"));
|
19
|
-
var Color;
|
20
|
-
(function (Color) {
|
21
|
-
Color["DEFAULT"] = "currentColor";
|
22
|
-
Color["PRIMARY"] = "text-primary";
|
23
|
-
Color["SECONDARY"] = "text-secondary";
|
24
|
-
Color["SUCCESS"] = "text-success";
|
25
|
-
Color["WARNING"] = "text-warning";
|
26
|
-
Color["DANGER"] = "text-danger";
|
27
|
-
Color["INFO"] = "text-info";
|
28
|
-
Color["DARK"] = "text-dark";
|
29
|
-
Color["LIGHT"] = "text-light";
|
30
|
-
})(Color || (Color = {}));
|
31
|
-
exports.Color = Color;
|
32
|
-
var Alignment;
|
33
|
-
(function (Alignment) {
|
34
|
-
Alignment["LEFT"] = "left";
|
35
|
-
Alignment["CENTER"] = "center";
|
36
|
-
Alignment["RIGHT"] = "right";
|
37
|
-
})(Alignment || (Alignment = {}));
|
38
|
-
exports.Alignment = Alignment;
|
39
|
-
var Thickness;
|
40
|
-
(function (Thickness) {
|
41
|
-
Thickness["T1"] = "1px";
|
42
|
-
Thickness["T2"] = "2px";
|
43
|
-
Thickness["T3"] = "3px";
|
44
|
-
Thickness["T4"] = "4px";
|
45
|
-
Thickness["T5"] = "5px";
|
46
|
-
Thickness["T6"] = "6px";
|
47
|
-
Thickness["T8"] = "8px";
|
48
|
-
Thickness["T10"] = "10px";
|
49
|
-
Thickness["T12"] = "12px";
|
50
|
-
Thickness["T16"] = "16px";
|
51
|
-
Thickness["T24"] = "24px";
|
52
|
-
})(Thickness || (Thickness = {}));
|
53
|
-
exports.Thickness = Thickness;
|
54
|
-
var Width;
|
55
|
-
(function (Width) {
|
56
|
-
Width["W10"] = "10%";
|
57
|
-
Width["W25"] = "25%";
|
58
|
-
Width["W33"] = "33%";
|
59
|
-
Width["W50"] = "50%";
|
60
|
-
Width["W66"] = "66%";
|
61
|
-
Width["W75"] = "75%";
|
62
|
-
Width["W100"] = "100%";
|
63
|
-
})(Width || (Width = {}));
|
64
|
-
exports.Width = Width;
|
65
|
-
var CustomDivider = function (_a) {
|
66
|
-
var id = _a.id, _b = _a.color, color = _b === void 0 ? Color.DEFAULT : _b, // Varsayılan renk (gri ton)
|
67
|
-
_c = _a.thickness, // Varsayılan renk (gri ton)
|
68
|
-
thickness = _c === void 0 ? Thickness.T1 : _c, // Varsayılan kalınlık
|
69
|
-
_d = _a.width, // Varsayılan kalınlık
|
70
|
-
width = _d === void 0 ? Width.W100 : _d, // Varsayılan genişlik
|
71
|
-
_e = _a.alignment, // Varsayılan genişlik
|
72
|
-
alignment = _e === void 0 ? Alignment.CENTER : _e, // Varsayılan hizalama
|
73
|
-
_f = _a.className, // Varsayılan hizalama
|
74
|
-
className = _f === void 0 ? '' : _f, _g = _a.style, style = _g === void 0 ? {} : _g;
|
75
|
-
var combinedClassName = "".concat(color, " ").concat(className).trim();
|
76
|
-
// Hizalama stilini belirleme
|
77
|
-
var alignmentStyle = {
|
78
|
-
marginLeft: alignment === 'left' ? '0' : 'auto',
|
79
|
-
marginRight: alignment === 'right' ? '0' : 'auto',
|
80
|
-
};
|
81
|
-
return (react_1.default.createElement("hr", { id: id || "custom-divider-".concat(Date.now()),
|
82
|
-
//className={`custom-divider ${className}`.trim()}
|
83
|
-
className: "custom-divider ".concat(combinedClassName), style: __assign(__assign({ border: 'none', borderTop: "".concat(thickness, " solid"), // Çizgiyi oluştur
|
84
|
-
width: width }, alignmentStyle), style) }));
|
85
|
-
};
|
86
|
-
exports.CustomDivider = CustomDivider;
|
87
|
-
exports.default = CustomDivider;
|
1
|
+
"use strict";
|
2
|
+
var __assign = (this && this.__assign) || function () {
|
3
|
+
__assign = Object.assign || function(t) {
|
4
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
5
|
+
s = arguments[i];
|
6
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
7
|
+
t[p] = s[p];
|
8
|
+
}
|
9
|
+
return t;
|
10
|
+
};
|
11
|
+
return __assign.apply(this, arguments);
|
12
|
+
};
|
13
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
14
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
15
|
+
};
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
+
exports.Width = exports.Thickness = exports.Alignment = exports.Color = exports.CustomDivider = void 0;
|
18
|
+
var react_1 = __importDefault(require("react"));
|
19
|
+
var Color;
|
20
|
+
(function (Color) {
|
21
|
+
Color["DEFAULT"] = "currentColor";
|
22
|
+
Color["PRIMARY"] = "text-primary";
|
23
|
+
Color["SECONDARY"] = "text-secondary";
|
24
|
+
Color["SUCCESS"] = "text-success";
|
25
|
+
Color["WARNING"] = "text-warning";
|
26
|
+
Color["DANGER"] = "text-danger";
|
27
|
+
Color["INFO"] = "text-info";
|
28
|
+
Color["DARK"] = "text-dark";
|
29
|
+
Color["LIGHT"] = "text-light";
|
30
|
+
})(Color || (Color = {}));
|
31
|
+
exports.Color = Color;
|
32
|
+
var Alignment;
|
33
|
+
(function (Alignment) {
|
34
|
+
Alignment["LEFT"] = "left";
|
35
|
+
Alignment["CENTER"] = "center";
|
36
|
+
Alignment["RIGHT"] = "right";
|
37
|
+
})(Alignment || (Alignment = {}));
|
38
|
+
exports.Alignment = Alignment;
|
39
|
+
var Thickness;
|
40
|
+
(function (Thickness) {
|
41
|
+
Thickness["T1"] = "1px";
|
42
|
+
Thickness["T2"] = "2px";
|
43
|
+
Thickness["T3"] = "3px";
|
44
|
+
Thickness["T4"] = "4px";
|
45
|
+
Thickness["T5"] = "5px";
|
46
|
+
Thickness["T6"] = "6px";
|
47
|
+
Thickness["T8"] = "8px";
|
48
|
+
Thickness["T10"] = "10px";
|
49
|
+
Thickness["T12"] = "12px";
|
50
|
+
Thickness["T16"] = "16px";
|
51
|
+
Thickness["T24"] = "24px";
|
52
|
+
})(Thickness || (Thickness = {}));
|
53
|
+
exports.Thickness = Thickness;
|
54
|
+
var Width;
|
55
|
+
(function (Width) {
|
56
|
+
Width["W10"] = "10%";
|
57
|
+
Width["W25"] = "25%";
|
58
|
+
Width["W33"] = "33%";
|
59
|
+
Width["W50"] = "50%";
|
60
|
+
Width["W66"] = "66%";
|
61
|
+
Width["W75"] = "75%";
|
62
|
+
Width["W100"] = "100%";
|
63
|
+
})(Width || (Width = {}));
|
64
|
+
exports.Width = Width;
|
65
|
+
var CustomDivider = function (_a) {
|
66
|
+
var id = _a.id, _b = _a.color, color = _b === void 0 ? Color.DEFAULT : _b, // Varsayılan renk (gri ton)
|
67
|
+
_c = _a.thickness, // Varsayılan renk (gri ton)
|
68
|
+
thickness = _c === void 0 ? Thickness.T1 : _c, // Varsayılan kalınlık
|
69
|
+
_d = _a.width, // Varsayılan kalınlık
|
70
|
+
width = _d === void 0 ? Width.W100 : _d, // Varsayılan genişlik
|
71
|
+
_e = _a.alignment, // Varsayılan genişlik
|
72
|
+
alignment = _e === void 0 ? Alignment.CENTER : _e, // Varsayılan hizalama
|
73
|
+
_f = _a.className, // Varsayılan hizalama
|
74
|
+
className = _f === void 0 ? '' : _f, _g = _a.style, style = _g === void 0 ? {} : _g;
|
75
|
+
var combinedClassName = "".concat(color, " ").concat(className).trim();
|
76
|
+
// Hizalama stilini belirleme
|
77
|
+
var alignmentStyle = {
|
78
|
+
marginLeft: alignment === 'left' ? '0' : 'auto',
|
79
|
+
marginRight: alignment === 'right' ? '0' : 'auto',
|
80
|
+
};
|
81
|
+
return (react_1.default.createElement("hr", { id: id || "custom-divider-".concat(Date.now()),
|
82
|
+
//className={`custom-divider ${className}`.trim()}
|
83
|
+
className: "custom-divider ".concat(combinedClassName), style: __assign(__assign({ border: 'none', borderTop: "".concat(thickness, " solid"), // Çizgiyi oluştur
|
84
|
+
width: width }, alignmentStyle), style) }));
|
85
|
+
};
|
86
|
+
exports.CustomDivider = CustomDivider;
|
87
|
+
exports.default = CustomDivider;
|
@@ -1,65 +1,65 @@
|
|
1
|
-
import React from "react";
|
2
|
-
export declare enum AllowedTypes {
|
3
|
-
PDF = "pdf",
|
4
|
-
FILE = "file",
|
5
|
-
IMAGE = "image",
|
6
|
-
VIDEO = "video",
|
7
|
-
VISUAL = "visual",
|
8
|
-
ALL = "all"
|
9
|
-
}
|
10
|
-
export interface FileUploaderTranslations {
|
11
|
-
dropAreaText: string;
|
12
|
-
fileLimitMultiText: string;
|
13
|
-
fileLimitSingleText: string;
|
14
|
-
uploadButtonText: string;
|
15
|
-
removeButtonTitle: string;
|
16
|
-
uploadSuccessToast: string;
|
17
|
-
uploadErrorToast: string;
|
18
|
-
uploadWarningLimit: string;
|
19
|
-
uploadWarningExceed: string;
|
20
|
-
fileSizeError: string;
|
21
|
-
fileTypeError: string;
|
22
|
-
noFileSelectedWarning: string;
|
23
|
-
}
|
24
|
-
export declare const defaultTranslations: FileUploaderTranslations;
|
25
|
-
export interface CustomFileUploaderProps {
|
26
|
-
/** Sunucuya dosyaların yükleneceği URL */
|
27
|
-
url: string;
|
28
|
-
/** Çoklu dosya seçimine izin verilsin mi? */
|
29
|
-
multi: boolean;
|
30
|
-
/** İzin verilen dosya türü */
|
31
|
-
allowedTypes: AllowedTypes;
|
32
|
-
/** Eğer multi true ise aynı anda seçilebilecek maksimum dosya sayısı */
|
33
|
-
maxFile: number;
|
34
|
-
/** Her bir dosya için maksimum boyut (byte cinsinden) */
|
35
|
-
maxSize: number;
|
36
|
-
/**
|
37
|
-
* Opsiyonel: Yükleme tamamlandığında dönen dosya isimlerini almak için callback.
|
38
|
-
*/
|
39
|
-
onUploadComplete?: (uploadedFileNames: string[]) => void;
|
40
|
-
/**
|
41
|
-
* Opsiyonel: Yüklenmiş bir dosya kaldırıldığında, dosya adı bilgisini parent bileşene bildirmek için callback.
|
42
|
-
*/
|
43
|
-
onRemoveUploaded?: (fileName: string) => void;
|
44
|
-
/** Opsiyonel: Yükleyici için gösterilecek label */
|
45
|
-
label?: string;
|
46
|
-
/**
|
47
|
-
* Opsiyonel: Pending (henüz yüklenmemiş) dosya sayısını parent'a iletecek callback.
|
48
|
-
*/
|
49
|
-
onPendingChange?: (pendingFileCount: number) => void;
|
50
|
-
/**
|
51
|
-
* Opsiyonel: Çoklu dil desteği için kullanılan çeviri metinleri.
|
52
|
-
*/
|
53
|
-
translations?: FileUploaderTranslations;
|
54
|
-
/**
|
55
|
-
* Eğer bu prop’un değeri değişirse uploader içini temizle
|
56
|
-
*/
|
57
|
-
clearTrigger?: any;
|
58
|
-
/**
|
59
|
-
* Yükleme işlemi sırasında yükleme durumunu parent'a bildirmek için callback.
|
60
|
-
* Bu, yükleme işlemi başladığında ve bittiğinde çağrılabilir.
|
61
|
-
*/
|
62
|
-
onUploadingChange?: (uploading: boolean) => void;
|
63
|
-
}
|
64
|
-
declare const CustomFileUploader: React.FC<CustomFileUploaderProps>;
|
65
|
-
export default CustomFileUploader;
|
1
|
+
import React from "react";
|
2
|
+
export declare enum AllowedTypes {
|
3
|
+
PDF = "pdf",
|
4
|
+
FILE = "file",
|
5
|
+
IMAGE = "image",
|
6
|
+
VIDEO = "video",
|
7
|
+
VISUAL = "visual",
|
8
|
+
ALL = "all"
|
9
|
+
}
|
10
|
+
export interface FileUploaderTranslations {
|
11
|
+
dropAreaText: string;
|
12
|
+
fileLimitMultiText: string;
|
13
|
+
fileLimitSingleText: string;
|
14
|
+
uploadButtonText: string;
|
15
|
+
removeButtonTitle: string;
|
16
|
+
uploadSuccessToast: string;
|
17
|
+
uploadErrorToast: string;
|
18
|
+
uploadWarningLimit: string;
|
19
|
+
uploadWarningExceed: string;
|
20
|
+
fileSizeError: string;
|
21
|
+
fileTypeError: string;
|
22
|
+
noFileSelectedWarning: string;
|
23
|
+
}
|
24
|
+
export declare const defaultTranslations: FileUploaderTranslations;
|
25
|
+
export interface CustomFileUploaderProps {
|
26
|
+
/** Sunucuya dosyaların yükleneceği URL */
|
27
|
+
url: string;
|
28
|
+
/** Çoklu dosya seçimine izin verilsin mi? */
|
29
|
+
multi: boolean;
|
30
|
+
/** İzin verilen dosya türü */
|
31
|
+
allowedTypes: AllowedTypes;
|
32
|
+
/** Eğer multi true ise aynı anda seçilebilecek maksimum dosya sayısı */
|
33
|
+
maxFile: number;
|
34
|
+
/** Her bir dosya için maksimum boyut (byte cinsinden) */
|
35
|
+
maxSize: number;
|
36
|
+
/**
|
37
|
+
* Opsiyonel: Yükleme tamamlandığında dönen dosya isimlerini almak için callback.
|
38
|
+
*/
|
39
|
+
onUploadComplete?: (uploadedFileNames: string[]) => void;
|
40
|
+
/**
|
41
|
+
* Opsiyonel: Yüklenmiş bir dosya kaldırıldığında, dosya adı bilgisini parent bileşene bildirmek için callback.
|
42
|
+
*/
|
43
|
+
onRemoveUploaded?: (fileName: string) => void;
|
44
|
+
/** Opsiyonel: Yükleyici için gösterilecek label */
|
45
|
+
label?: string;
|
46
|
+
/**
|
47
|
+
* Opsiyonel: Pending (henüz yüklenmemiş) dosya sayısını parent'a iletecek callback.
|
48
|
+
*/
|
49
|
+
onPendingChange?: (pendingFileCount: number) => void;
|
50
|
+
/**
|
51
|
+
* Opsiyonel: Çoklu dil desteği için kullanılan çeviri metinleri.
|
52
|
+
*/
|
53
|
+
translations?: FileUploaderTranslations;
|
54
|
+
/**
|
55
|
+
* Eğer bu prop’un değeri değişirse uploader içini temizle
|
56
|
+
*/
|
57
|
+
clearTrigger?: any;
|
58
|
+
/**
|
59
|
+
* Yükleme işlemi sırasında yükleme durumunu parent'a bildirmek için callback.
|
60
|
+
* Bu, yükleme işlemi başladığında ve bittiğinde çağrılabilir.
|
61
|
+
*/
|
62
|
+
onUploadingChange?: (uploading: boolean) => void;
|
63
|
+
}
|
64
|
+
declare const CustomFileUploader: React.FC<CustomFileUploaderProps>;
|
65
|
+
export default CustomFileUploader;
|