@iankibetsh/shframework 5.6.2 → 5.6.4

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/dist/library.js CHANGED
@@ -258,11 +258,14 @@ function formatDate(date, format){
258
258
  if (!format) {
259
259
  format = 'lll';
260
260
  }
261
+
261
262
  const formatMap = {
262
263
  'lll': "MMM d, yyyy, h:mm a",
263
264
  'LLL': "MMMM d, yyyy, h:mm a",
265
+ 'll': "MMMM d, yyyy",
264
266
  'LL': "MMMM d, yyyy",
265
267
  'L': "MM/dd/yyyy",
268
+ 'l': "MM/dd/yyyy",
266
269
  'YYYY-MM-DD': 'yyyy-MM-dd',
267
270
  'YYYY/MM/DD': 'yyyy/MM/dd',
268
271
  'YYYY': 'yyyy',
@@ -4494,6 +4497,13 @@ const doEmitAction = (callBack,item)=>{
4494
4497
  }
4495
4498
  };
4496
4499
 
4500
+ const actionSuccessful = (res)=>{
4501
+ doEmitAction('actionSuccessful',res,props.record);
4502
+ };
4503
+
4504
+ const actionFailed = (res)=>{
4505
+ doEmitAction('actionFailed',res,props.record);
4506
+ };
4497
4507
  const {user} = pinia.storeToRefs(useUserStore());
4498
4508
 
4499
4509
  return (_ctx, _cache) => {
@@ -4506,9 +4516,9 @@ return (_ctx, _cache) => {
4506
4516
  (['confirmAction','confirmaction','confirm-action','confirm'].includes(__props.action.type))
4507
4517
  ? (vue.openBlock(), vue.createBlock(script$j, {
4508
4518
  key: 0,
4509
- onActionSuccessful: _cache[0] || (_cache[0] = $event => (doEmitAction('actionSuccessful',__props.record))),
4510
- onActionFailed: _cache[1] || (_cache[1] = $event => (doEmitAction('actionFailed',__props.record))),
4511
- onActionCanceled: _cache[2] || (_cache[2] = $event => (doEmitAction('actionCanceled',__props.record))),
4519
+ onActionSuccessful: actionSuccessful,
4520
+ onActionFailed: actionFailed,
4521
+ onActionCanceled: _cache[0] || (_cache[0] = $event => (doEmitAction('actionCanceled',__props.record))),
4512
4522
  "loading-message": __props.action.label,
4513
4523
  class: vue.normalizeClass(__props.action.class + __props.actionClass),
4514
4524
  url: url.value
@@ -4527,9 +4537,9 @@ return (_ctx, _cache) => {
4527
4537
  : (['silentAction','silentaction','silent-action','silent'].includes(__props.action.type))
4528
4538
  ? (vue.openBlock(), vue.createBlock(script$i, {
4529
4539
  key: 1,
4530
- onActionSuccessful: _cache[3] || (_cache[3] = $event => (doEmitAction('actionSuccessful',__props.record))),
4531
- onActionFailed: _cache[4] || (_cache[4] = $event => (doEmitAction('actionFailed',__props.record))),
4532
- onActionCanceled: _cache[5] || (_cache[5] = $event => (doEmitAction('actionCanceled',__props.record))),
4540
+ onActionSuccessful: actionSuccessful,
4541
+ onActionFailed: actionFailed,
4542
+ onActionCanceled: _cache[1] || (_cache[1] = $event => (doEmitAction('actionCanceled',__props.record))),
4533
4543
  "loading-message": __props.action.label,
4534
4544
  class: vue.normalizeClass(__props.action.class +' '+ __props.actionClass),
4535
4545
  url: url.value
@@ -4571,7 +4581,7 @@ return (_ctx, _cache) => {
4571
4581
  },
4572
4582
  __props.actionClass
4573
4583
  ]),
4574
- onClick: _cache[6] || (_cache[6] = $event => (doEmitAction(__props.action.emits, __props.record)))
4584
+ onClick: _cache[2] || (_cache[2] = $event => (doEmitAction(__props.action.emits, __props.record)))
4575
4585
  }, [
4576
4586
  (__props.action.icon)
4577
4587
  ? (vue.openBlock(), vue.createElementBlock("span", {
package/dist/library.mjs CHANGED
@@ -247,11 +247,14 @@ function formatDate(date, format){
247
247
  if (!format) {
248
248
  format = 'lll';
249
249
  }
250
+
250
251
  const formatMap = {
251
252
  'lll': "MMM d, yyyy, h:mm a",
252
253
  'LLL': "MMMM d, yyyy, h:mm a",
254
+ 'll': "MMMM d, yyyy",
253
255
  'LL': "MMMM d, yyyy",
254
256
  'L': "MM/dd/yyyy",
257
+ 'l': "MM/dd/yyyy",
255
258
  'YYYY-MM-DD': 'yyyy-MM-dd',
256
259
  'YYYY/MM/DD': 'yyyy/MM/dd',
257
260
  'YYYY': 'yyyy',
@@ -4483,6 +4486,13 @@ const doEmitAction = (callBack,item)=>{
4483
4486
  }
4484
4487
  };
4485
4488
 
4489
+ const actionSuccessful = (res)=>{
4490
+ doEmitAction('actionSuccessful',res,props.record);
4491
+ };
4492
+
4493
+ const actionFailed = (res)=>{
4494
+ doEmitAction('actionFailed',res,props.record);
4495
+ };
4486
4496
  const {user} = storeToRefs(useUserStore());
4487
4497
 
4488
4498
  return (_ctx, _cache) => {
@@ -4495,9 +4505,9 @@ return (_ctx, _cache) => {
4495
4505
  (['confirmAction','confirmaction','confirm-action','confirm'].includes(__props.action.type))
4496
4506
  ? (openBlock(), createBlock(script$j, {
4497
4507
  key: 0,
4498
- onActionSuccessful: _cache[0] || (_cache[0] = $event => (doEmitAction('actionSuccessful',__props.record))),
4499
- onActionFailed: _cache[1] || (_cache[1] = $event => (doEmitAction('actionFailed',__props.record))),
4500
- onActionCanceled: _cache[2] || (_cache[2] = $event => (doEmitAction('actionCanceled',__props.record))),
4508
+ onActionSuccessful: actionSuccessful,
4509
+ onActionFailed: actionFailed,
4510
+ onActionCanceled: _cache[0] || (_cache[0] = $event => (doEmitAction('actionCanceled',__props.record))),
4501
4511
  "loading-message": __props.action.label,
4502
4512
  class: normalizeClass(__props.action.class + __props.actionClass),
4503
4513
  url: url.value
@@ -4516,9 +4526,9 @@ return (_ctx, _cache) => {
4516
4526
  : (['silentAction','silentaction','silent-action','silent'].includes(__props.action.type))
4517
4527
  ? (openBlock(), createBlock(script$i, {
4518
4528
  key: 1,
4519
- onActionSuccessful: _cache[3] || (_cache[3] = $event => (doEmitAction('actionSuccessful',__props.record))),
4520
- onActionFailed: _cache[4] || (_cache[4] = $event => (doEmitAction('actionFailed',__props.record))),
4521
- onActionCanceled: _cache[5] || (_cache[5] = $event => (doEmitAction('actionCanceled',__props.record))),
4529
+ onActionSuccessful: actionSuccessful,
4530
+ onActionFailed: actionFailed,
4531
+ onActionCanceled: _cache[1] || (_cache[1] = $event => (doEmitAction('actionCanceled',__props.record))),
4522
4532
  "loading-message": __props.action.label,
4523
4533
  class: normalizeClass(__props.action.class +' '+ __props.actionClass),
4524
4534
  url: url.value
@@ -4560,7 +4570,7 @@ return (_ctx, _cache) => {
4560
4570
  },
4561
4571
  __props.actionClass
4562
4572
  ]),
4563
- onClick: _cache[6] || (_cache[6] = $event => (doEmitAction(__props.action.emits, __props.record)))
4573
+ onClick: _cache[2] || (_cache[2] = $event => (doEmitAction(__props.action.emits, __props.record)))
4564
4574
  }, [
4565
4575
  (__props.action.icon)
4566
4576
  ? (openBlock(), createElementBlock("span", {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iankibetsh/shframework",
3
- "version": "5.6.2",
3
+ "version": "5.6.4",
4
4
  "description": "Vue library for handling laravel backend",
5
5
  "main": "dist/library.js",
6
6
  "module": "dist/library.mjs",