react-native-resource-calendar 1.1.8 → 1.1.10
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/README.md +1 -0
- package/dist/index.d.mts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -2
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -294,6 +294,7 @@ The `Calendar` component accepts a flexible set of props for customizing layout,
|
|
|
294
294
|
| **`onDisabledBlockPress`** | `(block: DisabledBlock) => void` | — | Tap on a disabled block (e.g., lunch). |
|
|
295
295
|
| **`onEventPress`** | `(event: Event) => void` | — | Tap on an event. |
|
|
296
296
|
| **`onEventLongPress`** | `(event: Event) => void` | — | Long-press on an event. The calendar also preps internal drag state here. |
|
|
297
|
+
| **`scrollsToTop`** | `boolean` | `true` | iOS only. When `true`, tapping the status bar scrolls the timeline back to the top. Set to `false` if another scroll view in your screen should handle this gesture instead. |
|
|
297
298
|
|
|
298
299
|
---
|
|
299
300
|
|
package/dist/index.d.mts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -1391,7 +1391,8 @@ var CalendarInner = (props) => {
|
|
|
1391
1391
|
eventStyleOverrides,
|
|
1392
1392
|
overLappingLayoutMode = "stacked",
|
|
1393
1393
|
mode = "day",
|
|
1394
|
-
activeResourceId
|
|
1394
|
+
activeResourceId,
|
|
1395
|
+
scrollsToTop = true
|
|
1395
1396
|
} = props;
|
|
1396
1397
|
const numberOfColumns = mode === "day" ? numberOfColumnsProp : mode === "week" ? 7 : 3;
|
|
1397
1398
|
const isMultiDay = mode !== "day";
|
|
@@ -1882,7 +1883,7 @@ var CalendarInner = (props) => {
|
|
|
1882
1883
|
top: 0,
|
|
1883
1884
|
left: TIME_LABEL_WIDTH,
|
|
1884
1885
|
paddingLeft: TIME_LABEL_WIDTH,
|
|
1885
|
-
width: width - TIME_LABEL_WIDTH,
|
|
1886
|
+
width: (layout?.width ?? width) - TIME_LABEL_WIDTH,
|
|
1886
1887
|
height: "100%",
|
|
1887
1888
|
backgroundColor: "rgba(0, 0, 0, 0.1)",
|
|
1888
1889
|
zIndex: 1
|
|
@@ -1894,6 +1895,7 @@ var CalendarInner = (props) => {
|
|
|
1894
1895
|
onScroll: verticalScrollHandler,
|
|
1895
1896
|
ref: verticalScrollViewRef,
|
|
1896
1897
|
scrollEventThrottle: 16,
|
|
1898
|
+
scrollsToTop,
|
|
1897
1899
|
snapToInterval: hourHeight,
|
|
1898
1900
|
decelerationRate: "fast",
|
|
1899
1901
|
snapToAlignment: "start",
|