1 | import { ShCard, ShCardHeader, ShCardBox, ShCardWidget, ShCardGroup, ShCardWithTabs } from './components/sh-card';
|
2 | import ShNotifications from './components/sh-notifications';
|
3 | import { ShButton, ShButtonGroup } from './components/sh-button';
|
4 | import ShButtonUpload from './components/sh-button-upload';
|
5 | import ShBannerTabs from './components/sh-banner-tabs';
|
6 | import { ShCheckbox, ShCheckboxGroup } from './components/sh-checkbox';
|
7 | import { ShRadio, ShRadioGroup } from './components/sh-radio';
|
8 | import { ShStatistics, ShStatisticsItem } from './components/sh-statistics';
|
9 | import ShInput from './components/sh-input';
|
10 | import ModalProgrammatic, { ShModal } from './components/sh-modal';
|
11 | import ShDialog from './components/sh-dialog';
|
12 | import ShImage from './components/sh-image';
|
13 | import { ShTable, ShTableColumn } from './components/sh-table';
|
14 | import { ShTableCellActions } from './components/sh-table-cell';
|
15 | import { ShTag, ShTagButton, ShTagCreator, ShTagIcon } from './components/sh-tag';
|
16 | import { ShField, ShFieldGroup } from './components/sh-field';
|
17 | import ShIcon from './components/sh-icon';
|
18 | import ShTextarea from './components/sh-textarea';
|
19 | import ShSwitch from './components/sh-switch';
|
20 | import ShPageHeader from './components/sh-page-header';
|
21 | import ShDragableTags from './components/sh-dragable-tags';
|
22 | import { ShDropdown, ShDropdownItem } from './components/sh-dropdown';
|
23 | import ShNotificationBanner from './components/sh-notification-banner';
|
24 | import ShBlankslate from './components/sh-blankslate';
|
25 | import ShActionBarLayout from './components/sh-action-bar-layout';
|
26 | import ShActionPage from './components/sh-action-page';
|
27 | import ShLoading from './components/sh-loading';
|
28 | import ShPhotosGrid from './components/sh-photos-grid';
|
29 | import {ShHistory, ShComment, ShCustomerData} from './components/sh-history';
|
30 | import ShSingleColumnLayout from './layouts/single-column';
|
31 | import ShTwoColumnsLayout from './layouts/two-columns';
|
32 | import ShReadMore from './directives/sh-read-more/sh-read-more';
|
33 | import ShRedactor from './components/sh-redactor';
|
34 | import ShChannelTabs from './components/sh-channel-tabs';
|
35 | import { ShAddress, ShData } from './components/sh-address';
|
36 | import ShImageSelector from './components/sh-image-selector';
|
37 | import ShUploadField from './components/sh-upload-field';
|
38 | import ShLabel from './components/sh-label';
|
39 | import ShProductCard from './components/sh-product-card';
|
40 | import ShAutocompleter from './components/sh-autocompleter';
|
41 | import ShPaginationList from './components/sh-pagination-list';
|
42 | import ShCategoriesSelect from './components/sh-categories-select';
|
43 | import ShProductPrice from './components/sh-product-price';
|
44 | import ShColorpicker from './components/sh-colorpicker';
|
45 |
|
46 |
|
47 | const components = {
|
48 | ShData,
|
49 | ShAddress,
|
50 | ShDragableTags,
|
51 | ShHistory,
|
52 | ShComment,
|
53 | ShCustomerData,
|
54 | ShCard,
|
55 | ShCardBox,
|
56 | ShCardHeader,
|
57 | ShCardWidget,
|
58 | ShCardGroup,
|
59 | ShCardWithTabs,
|
60 | ShButton,
|
61 | ShButtonGroup,
|
62 | ShButtonUpload,
|
63 | ShUploadField,
|
64 | ShTwoColumnsLayout,
|
65 | ShSingleColumnLayout,
|
66 | ShNotifications,
|
67 | ShCheckbox,
|
68 | ShCheckboxGroup,
|
69 | ShRadio,
|
70 | ShRadioGroup,
|
71 | ShInput,
|
72 | ShModal,
|
73 | ShTable,
|
74 | ShTableColumn,
|
75 | ShTableCellActions,
|
76 | ShTag,
|
77 | ShTagIcon,
|
78 | ShTagCreator,
|
79 | ShField,
|
80 | ShFieldGroup,
|
81 | ShTagButton,
|
82 | ShIcon,
|
83 | ShSwitch,
|
84 | ShImage,
|
85 | ShTextarea,
|
86 | ShDropdown,
|
87 | ShDropdownItem,
|
88 | ShPageHeader,
|
89 | ShNotificationBanner,
|
90 | ShBlankslate,
|
91 | ShActionBarLayout,
|
92 | ShActionPage,
|
93 | ShPhotosGrid,
|
94 | ShStatistics,
|
95 | ShStatisticsItem,
|
96 | ShBannerTabs,
|
97 | ShRedactor,
|
98 | ShChannelTabs,
|
99 | ShImageSelector,
|
100 | ShLabel,
|
101 | ShProductCard,
|
102 | ShAutocompleter,
|
103 | ShPaginationList,
|
104 | ShCategoriesSelect,
|
105 | ShProductPrice,
|
106 | ShColorpicker,
|
107 | };
|
108 |
|
109 | const directives = {
|
110 | 'read-more': ShReadMore
|
111 | };
|
112 |
|
113 |
|
114 | import en from './locale/en_US.json';
|
115 | import pl from './locale/pl_PL.json';
|
116 |
|
117 | export default function install(Vue, opts = {}) {
|
118 | if (opts.i18n) {
|
119 | opts.i18n.mergeLocaleMessage('en', en);
|
120 | opts.i18n.mergeLocaleMessage('pl', pl);
|
121 | }
|
122 | Object.keys(components).forEach((name) =>{
|
123 |
|
124 | Vue.component(name, components[name]);
|
125 | });
|
126 | Object.keys(directives).forEach((name) => {
|
127 | Vue.directive(name, directives[name])
|
128 | });
|
129 |
|
130 | Vue.use(ShLoading.loading);
|
131 | Vue.prototype.$shdialog = ShDialog;
|
132 | Vue.prototype.$shmodal = ModalProgrammatic;
|
133 | }
|
134 | export {
|
135 | ShDialog,
|
136 | ModalProgrammatic,
|
137 | ShData,
|
138 | ShAddress,
|
139 | ShDragableTags,
|
140 | ShCard,
|
141 | ShCardBox,
|
142 | ShHistory,
|
143 | ShComment,
|
144 | ShCustomerData,
|
145 | ShCardHeader,
|
146 | ShCardWidget,
|
147 | ShCardGroup,
|
148 | ShCardWithTabs,
|
149 | ShButton,
|
150 | ShButtonGroup,
|
151 | ShButtonUpload,
|
152 | ShUploadField,
|
153 | ShTwoColumnsLayout,
|
154 | ShSingleColumnLayout,
|
155 | ShNotifications,
|
156 | ShCheckbox,
|
157 | ShCheckboxGroup,
|
158 | ShRadio,
|
159 | ShRadioGroup,
|
160 | ShInput,
|
161 | ShModal,
|
162 | ShTable,
|
163 | ShTableColumn,
|
164 | ShTableCellActions,
|
165 | ShTag,
|
166 | ShTagIcon,
|
167 | ShTagCreator,
|
168 | ShField,
|
169 | ShFieldGroup,
|
170 | ShTagButton,
|
171 | ShIcon,
|
172 | ShSwitch,
|
173 | ShImage,
|
174 | ShTextarea,
|
175 | ShDropdown,
|
176 | ShDropdownItem,
|
177 | ShPageHeader,
|
178 | ShNotificationBanner,
|
179 | ShBlankslate,
|
180 | ShActionBarLayout,
|
181 | ShActionPage,
|
182 | ShPhotosGrid,
|
183 | ShStatistics,
|
184 | ShStatisticsItem,
|
185 | ShBannerTabs,
|
186 | ShRedactor,
|
187 | ShChannelTabs,
|
188 | ShImageSelector,
|
189 | ShLabel,
|
190 | ShProductCard,
|
191 | ShAutocompleter,
|
192 | ShPaginationList,
|
193 | ShCategoriesSelect,
|
194 | ShProductPrice,
|
195 | ShColorpicker,
|
196 | }
|
197 |
|
198 |
|