react-native-resource-calendar 1.0.2 → 1.0.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/index.js +38 -9
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +38 -9
- package/dist/index.mjs.map +1 -1
- package/package.json +7 -6
package/dist/index.js
CHANGED
|
@@ -389,14 +389,24 @@ var TimeLabels = React18__namespace.forwardRef(({
|
|
|
389
389
|
reactNative.Text,
|
|
390
390
|
{
|
|
391
391
|
allowFontScaling: false,
|
|
392
|
-
style: {
|
|
392
|
+
style: {
|
|
393
|
+
textAlign: "center",
|
|
394
|
+
fontFamily: titleFace,
|
|
395
|
+
fontSize: getTextSize(hourHeight),
|
|
396
|
+
fontWeight: "700"
|
|
397
|
+
}
|
|
393
398
|
},
|
|
394
399
|
indexToDate(index).split(" ")[0]
|
|
395
400
|
), /* @__PURE__ */ React18__namespace.createElement(
|
|
396
401
|
reactNative.Text,
|
|
397
402
|
{
|
|
398
403
|
allowFontScaling: false,
|
|
399
|
-
style: {
|
|
404
|
+
style: {
|
|
405
|
+
textAlign: "center",
|
|
406
|
+
fontFamily: titleFace,
|
|
407
|
+
fontSize: getTextSize(hourHeight),
|
|
408
|
+
fontWeight: "700"
|
|
409
|
+
}
|
|
400
410
|
},
|
|
401
411
|
indexToDate(index).split(" ")[1]
|
|
402
412
|
))), isToday && /* @__PURE__ */ React18__namespace.createElement(reactNative.View, { style: [styles.currentTime, {
|
|
@@ -409,6 +419,7 @@ var TimeLabels = React18__namespace.forwardRef(({
|
|
|
409
419
|
style: {
|
|
410
420
|
textAlign: "center",
|
|
411
421
|
fontFamily: titleFace,
|
|
422
|
+
fontWeight: "700",
|
|
412
423
|
fontSize: getTextSize(hourHeight),
|
|
413
424
|
color: "red"
|
|
414
425
|
}
|
|
@@ -482,7 +493,8 @@ var Badge = ({
|
|
|
482
493
|
style: {
|
|
483
494
|
color: textColor,
|
|
484
495
|
fontSize,
|
|
485
|
-
fontFamily: titleFace
|
|
496
|
+
fontFamily: titleFace,
|
|
497
|
+
fontWeight: "600"
|
|
486
498
|
}
|
|
487
499
|
},
|
|
488
500
|
value
|
|
@@ -604,7 +616,8 @@ var ResourceComponent = ({ id, onResourcePress, APPOINTMENT_BLOCK_WIDTH }) => {
|
|
|
604
616
|
{
|
|
605
617
|
style: {
|
|
606
618
|
fontSize: 14,
|
|
607
|
-
fontFamily: titleFace
|
|
619
|
+
fontFamily: titleFace,
|
|
620
|
+
fontWeight: "700"
|
|
608
621
|
},
|
|
609
622
|
numberOfLines: 1,
|
|
610
623
|
allowFontScaling: false
|
|
@@ -757,7 +770,16 @@ var EventGridBlocksSkia = ({
|
|
|
757
770
|
const onTouchesUp = React18__namespace.useCallback(() => {
|
|
758
771
|
setPressedRow(null);
|
|
759
772
|
}, []);
|
|
760
|
-
const longPressGesture = reactNativeGestureHandler.Gesture.LongPress().onBegin((e) =>
|
|
773
|
+
const longPressGesture = reactNativeGestureHandler.Gesture.LongPress().onBegin((e) => {
|
|
774
|
+
"worklet";
|
|
775
|
+
Animated2.runOnJS(onPressBegin)(Math.floor(e.y / rowHeight));
|
|
776
|
+
}).onEnd((e) => {
|
|
777
|
+
"worklet";
|
|
778
|
+
Animated2.runOnJS(onSlotPress)(Math.floor(e.y / rowHeight));
|
|
779
|
+
}).onFinalize(() => {
|
|
780
|
+
"worklet";
|
|
781
|
+
Animated2.runOnJS(onTouchesUp)();
|
|
782
|
+
});
|
|
761
783
|
return /* @__PURE__ */ React18__namespace.createElement(reactNativeGestureHandler.GestureDetector, { gesture: longPressGesture }, /* @__PURE__ */ React18__namespace.createElement(reactNative.View, null, /* @__PURE__ */ React18__namespace.createElement(reactNativeSkia.Canvas, { style: { width: APPOINTMENT_BLOCK_WIDTH, height: segmentHeight } }, firstRects.map(({ x, y, width: w, height: h, row }, idx) => /* @__PURE__ */ React18__namespace.createElement(React18__namespace.Fragment, { key: idx }, /* @__PURE__ */ React18__namespace.createElement(
|
|
762
784
|
reactNativeSkia.Rect,
|
|
763
785
|
{
|
|
@@ -872,7 +894,8 @@ var DisabledBlockComponent = ({
|
|
|
872
894
|
allowFontScaling: false,
|
|
873
895
|
style: {
|
|
874
896
|
fontFamily: titleFace,
|
|
875
|
-
fontSize: getTextSize(hourHeight)
|
|
897
|
+
fontSize: getTextSize(hourHeight),
|
|
898
|
+
fontWeight: "600"
|
|
876
899
|
}
|
|
877
900
|
},
|
|
878
901
|
minutesToTime(disabledBlock?.from),
|
|
@@ -884,7 +907,8 @@ var DisabledBlockComponent = ({
|
|
|
884
907
|
allowFontScaling: false,
|
|
885
908
|
style: {
|
|
886
909
|
fontFamily: titleFace,
|
|
887
|
-
fontSize: getTextSize(hourHeight)
|
|
910
|
+
fontSize: getTextSize(hourHeight),
|
|
911
|
+
fontWeight: "600"
|
|
888
912
|
}
|
|
889
913
|
},
|
|
890
914
|
disabledBlock?.title
|
|
@@ -1127,7 +1151,8 @@ var DraggableEvent = ({
|
|
|
1127
1151
|
allowFontScaling: false,
|
|
1128
1152
|
style: [{
|
|
1129
1153
|
fontFamily: titleFace,
|
|
1130
|
-
fontSize: getTextSize(hourHeight)
|
|
1154
|
+
fontSize: getTextSize(hourHeight),
|
|
1155
|
+
fontWeight: "700"
|
|
1131
1156
|
}, resolved?.title]
|
|
1132
1157
|
},
|
|
1133
1158
|
selectedEvent?.title
|
|
@@ -1137,7 +1162,8 @@ var DraggableEvent = ({
|
|
|
1137
1162
|
allowFontScaling: false,
|
|
1138
1163
|
style: [{
|
|
1139
1164
|
fontFamily: timeFace,
|
|
1140
|
-
fontSize: getTextSize(hourHeight)
|
|
1165
|
+
fontSize: getTextSize(hourHeight),
|
|
1166
|
+
fontWeight: "600"
|
|
1141
1167
|
}, resolved?.desc]
|
|
1142
1168
|
},
|
|
1143
1169
|
selectedEvent?.description
|
|
@@ -1318,11 +1344,13 @@ var CalendarInner = (props) => {
|
|
|
1318
1344
|
Haptics__namespace.impactAsync(Haptics__namespace.ImpactFeedbackStyle.Light);
|
|
1319
1345
|
}, []);
|
|
1320
1346
|
const panGesture = reactNativeGestureHandler.Gesture.Pan().manualActivation(!isIOS).enabled(layout !== null).shouldCancelWhenOutside(false).onTouchesMove((_evt, stateManager) => {
|
|
1347
|
+
"worklet";
|
|
1321
1348
|
if (isIOS) return;
|
|
1322
1349
|
if (selectedEvent)
|
|
1323
1350
|
stateManager.activate();
|
|
1324
1351
|
else stateManager.end();
|
|
1325
1352
|
}).onUpdate((evt) => {
|
|
1353
|
+
"worklet";
|
|
1326
1354
|
if (!evt || evt.y == null || evt.x == null) return;
|
|
1327
1355
|
let draggable = false;
|
|
1328
1356
|
let pullable = false;
|
|
@@ -1411,6 +1439,7 @@ var CalendarInner = (props) => {
|
|
|
1411
1439
|
}
|
|
1412
1440
|
}
|
|
1413
1441
|
}).onEnd(() => {
|
|
1442
|
+
"worklet";
|
|
1414
1443
|
autoScrollSpeed.value = 0;
|
|
1415
1444
|
autoScrollXSpeed.value = 0;
|
|
1416
1445
|
lastXScrollTime.value = 0;
|