@iankibetsh/shframework 4.5.9 → 4.6.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.
@@ -31,38 +31,6 @@
31
31
  opacity: 0.5;
32
32
  }
33
33
 
34
- .permissions-main {
35
- background: #edeff2;
36
- }
37
- .permissions-main div#permissions-nav {
38
- padding: 0;
39
- }
40
- .permissions-main div#permissions-nav ul {
41
- padding-left: 0;
42
- max-height: 400px;
43
- overflow-y: auto;
44
- }
45
- .permissions-main div#permissions-nav ul li.active {
46
- border-right: none !important;
47
- position: relative;
48
- top: 0;
49
- left: 0;
50
- background: #88b3b370;
51
- border-radius: 10px;
52
- }
53
- .permissions-main div#permissions-nav ul li {
54
- list-style: none;
55
- padding-inline-start: 10px;
56
- display: flex;
57
- gap: 5px;
58
- }
59
- .permissions-main div#permissions-nav ul li label {
60
- padding: 8px 0;
61
- cursor: pointer;
62
- height: 100%;
63
- flex-grow: 1;
64
- }
65
-
66
34
  .colored-toast.swal2-icon-success {
67
35
  background-color: #a5dc86 !important;
68
36
  }
@@ -95,6 +63,38 @@
95
63
  color: white;
96
64
  }
97
65
 
66
+ .permissions-main {
67
+ background: #edeff2;
68
+ }
69
+ .permissions-main div#permissions-nav {
70
+ padding: 0;
71
+ }
72
+ .permissions-main div#permissions-nav ul {
73
+ padding-left: 0;
74
+ max-height: 400px;
75
+ overflow-y: auto;
76
+ }
77
+ .permissions-main div#permissions-nav ul li.active {
78
+ border-right: none !important;
79
+ position: relative;
80
+ top: 0;
81
+ left: 0;
82
+ background: #88b3b370;
83
+ border-radius: 10px;
84
+ }
85
+ .permissions-main div#permissions-nav ul li {
86
+ list-style: none;
87
+ padding-inline-start: 10px;
88
+ display: flex;
89
+ gap: 5px;
90
+ }
91
+ .permissions-main div#permissions-nav ul li label {
92
+ padding: 8px 0;
93
+ cursor: pointer;
94
+ height: 100%;
95
+ flex-grow: 1;
96
+ }
97
+
98
98
  .sh-selected-item{
99
99
  line-height: unset!important;
100
100
  }
package/dist/library.js CHANGED
@@ -4907,7 +4907,7 @@ const _hoisted_66 = ["title", "onClick"];
4907
4907
 
4908
4908
  const __default__ = {
4909
4909
  name: 'sh-table',
4910
- props: ['endPoint', 'headers', 'cacheKey', 'query', 'pageCount', 'actions', 'hideCount', 'hideLoadMore', 'links', 'reload', 'hideSearch', 'sharedData', 'searchPlaceholder', 'event', 'displayMore', 'displayMoreBtnClass', 'moreDetailsColumns', 'moreDetailsFields', 'hasDownload', 'downloadFields', 'tableHover', 'hideIds', 'paginationStyle', 'hasRange','noRecordsMessage'],
4910
+ props: ['endPoint', 'headers', 'cacheKey', 'query', 'pageCount', 'actions', 'hideCount', 'hideLoadMore', 'links', 'reload', 'hideSearch', 'sharedData', 'searchPlaceholder', 'event', 'displayMore', 'displayMoreBtnClass', 'moreDetailsColumns', 'moreDetailsFields', 'hasDownload', 'downloadFields', 'tableHover', 'hideIds', 'paginationStyle', 'hasRange','selectedRange','noRecordsMessage'],
4911
4911
  data(){
4912
4912
  return {
4913
4913
  order_by: '',
@@ -5226,6 +5226,7 @@ const noRecordsComponent = vue.inject('noRecordsComponent', script$i);
5226
5226
 
5227
5227
  const {user} = pinia.storeToRefs(useUserStore());
5228
5228
 
5229
+
5229
5230
  return (_ctx, _cache) => {
5230
5231
  const _component_router_link = vue.resolveComponent("router-link");
5231
5232
 
@@ -5282,7 +5283,10 @@ return (_ctx, _cache) => {
5282
5283
  ], 2 /* CLASS */),
5283
5284
  (__props.hasRange)
5284
5285
  ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_12$3, [
5285
- vue.createVNode(script$e, { onRangeSelected: _ctx.rangeChanged }, null, 8 /* PROPS */, ["onRangeSelected"])
5286
+ vue.createVNode(script$e, {
5287
+ onRangeSelected: _ctx.rangeChanged,
5288
+ selected: __props.selectedRange
5289
+ }, null, 8 /* PROPS */, ["onRangeSelected", "selected"])
5286
5290
  ]))
5287
5291
  : vue.createCommentVNode("v-if", true)
5288
5292
  ])
@@ -7257,7 +7261,7 @@ const useShFetch = (url, path, cacheKey) => {
7257
7261
  * Fetches data from the given URL and updates the status, loading state, error, and data refs.
7258
7262
  * If a cacheKey is provided and there is cached data for that key, the cached data is used instead of fetching.
7259
7263
  */
7260
- const reFetchData = () => {
7264
+ const reFetchData = (dataUrl) => {
7261
7265
  loading.value = true;
7262
7266
  status.value = 'loading';
7263
7267
  if (cacheKey && shStorage.getItem(cacheKey)) {
@@ -7265,7 +7269,7 @@ const useShFetch = (url, path, cacheKey) => {
7265
7269
  status.value = 'success';
7266
7270
  loading.value = false;
7267
7271
  } else {
7268
- shApis.doGet(url).then(response => {
7272
+ shApis.doGet(dataUrl ?? url).then(response => {
7269
7273
  status.value = 'success';
7270
7274
  let res = response.data;
7271
7275
  if (path) {
package/dist/library.mjs CHANGED
@@ -4895,7 +4895,7 @@ const _hoisted_66 = ["title", "onClick"];
4895
4895
 
4896
4896
  const __default__ = {
4897
4897
  name: 'sh-table',
4898
- props: ['endPoint', 'headers', 'cacheKey', 'query', 'pageCount', 'actions', 'hideCount', 'hideLoadMore', 'links', 'reload', 'hideSearch', 'sharedData', 'searchPlaceholder', 'event', 'displayMore', 'displayMoreBtnClass', 'moreDetailsColumns', 'moreDetailsFields', 'hasDownload', 'downloadFields', 'tableHover', 'hideIds', 'paginationStyle', 'hasRange','noRecordsMessage'],
4898
+ props: ['endPoint', 'headers', 'cacheKey', 'query', 'pageCount', 'actions', 'hideCount', 'hideLoadMore', 'links', 'reload', 'hideSearch', 'sharedData', 'searchPlaceholder', 'event', 'displayMore', 'displayMoreBtnClass', 'moreDetailsColumns', 'moreDetailsFields', 'hasDownload', 'downloadFields', 'tableHover', 'hideIds', 'paginationStyle', 'hasRange','selectedRange','noRecordsMessage'],
4899
4899
  data(){
4900
4900
  return {
4901
4901
  order_by: '',
@@ -5214,6 +5214,7 @@ const noRecordsComponent = inject('noRecordsComponent', script$i);
5214
5214
 
5215
5215
  const {user} = storeToRefs(useUserStore());
5216
5216
 
5217
+
5217
5218
  return (_ctx, _cache) => {
5218
5219
  const _component_router_link = resolveComponent("router-link");
5219
5220
 
@@ -5270,7 +5271,10 @@ return (_ctx, _cache) => {
5270
5271
  ], 2 /* CLASS */),
5271
5272
  (__props.hasRange)
5272
5273
  ? (openBlock(), createElementBlock("div", _hoisted_12$3, [
5273
- createVNode(script$e, { onRangeSelected: _ctx.rangeChanged }, null, 8 /* PROPS */, ["onRangeSelected"])
5274
+ createVNode(script$e, {
5275
+ onRangeSelected: _ctx.rangeChanged,
5276
+ selected: __props.selectedRange
5277
+ }, null, 8 /* PROPS */, ["onRangeSelected", "selected"])
5274
5278
  ]))
5275
5279
  : createCommentVNode("v-if", true)
5276
5280
  ])
@@ -7245,7 +7249,7 @@ const useShFetch = (url, path, cacheKey) => {
7245
7249
  * Fetches data from the given URL and updates the status, loading state, error, and data refs.
7246
7250
  * If a cacheKey is provided and there is cached data for that key, the cached data is used instead of fetching.
7247
7251
  */
7248
- const reFetchData = () => {
7252
+ const reFetchData = (dataUrl) => {
7249
7253
  loading.value = true;
7250
7254
  status.value = 'loading';
7251
7255
  if (cacheKey && shStorage.getItem(cacheKey)) {
@@ -7253,7 +7257,7 @@ const useShFetch = (url, path, cacheKey) => {
7253
7257
  status.value = 'success';
7254
7258
  loading.value = false;
7255
7259
  } else {
7256
- shApis.doGet(url).then(response => {
7260
+ shApis.doGet(dataUrl ?? url).then(response => {
7257
7261
  status.value = 'success';
7258
7262
  let res = response.data;
7259
7263
  if (path) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iankibetsh/shframework",
3
- "version": "4.5.9",
3
+ "version": "4.6.1",
4
4
  "description": "Vue library for handling laravel backend",
5
5
  "main": "dist/library.js",
6
6
  "module": "dist/library.mjs",