@openremote/or-scheduler 1.12.0-snapshot.20251212165311

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 ADDED
@@ -0,0 +1,31 @@
1
+ # @openremote/or-scheduler \<or-scheduler\>
2
+ [![NPM Version][npm-image]][npm-url]
3
+ [![Linux Build][travis-image]][travis-url]
4
+ [![Test Coverage][coveralls-image]][coveralls-url]
5
+
6
+ Web Component for displaying a scheduling dialog.
7
+
8
+ ## Install
9
+ ```bash
10
+ npm i @openremote/or-scheduler
11
+ yarn add @openremote/or-scheduler
12
+ ```
13
+
14
+ ## Usage
15
+ For a full list of properties, methods and options refer to the TypeDoc generated [documentation]().
16
+
17
+
18
+ ## Supported Browsers
19
+ The last 2 versions of all modern browsers are supported, including Chrome, Safari, Opera, Firefox, Edge. In addition,
20
+ Internet Explorer 11 is also supported.
21
+
22
+
23
+ ## License
24
+ [GNU AGPL](https://www.gnu.org/licenses/agpl-3.0.en.html)
25
+
26
+ [npm-image]: https://img.shields.io/npm/v/live-xxx.svg
27
+ [npm-url]: https://npmjs.org/package/@openremote/or-scheduler
28
+ [travis-image]: https://img.shields.io/travis/live-js/live-xxx/master.svg
29
+ [travis-url]: https://travis-ci.org/live-js/live-xxx
30
+ [coveralls-image]: https://img.shields.io/coveralls/live-js/live-xxx/master.svg
31
+ [coveralls-url]: https://coveralls.io/r/live-js/live-xxx?branch=master
@@ -0,0 +1,185 @@
1
+
2
+ import type { RuleParts, RulePartKey, Frequency, LabeledEventTypes, *, OrSchedulerChangedEvent, OrScheduler } from "./lib/index.d.ts";
3
+
4
+ /**
5
+ * This type can be used to create scoped tags for your components.
6
+ *
7
+ * Usage:
8
+ *
9
+ * ```ts
10
+ * import type { ScopedElements } from "path/to/library/jsx-integration";
11
+ *
12
+ * declare module "my-library" {
13
+ * namespace JSX {
14
+ * interface IntrinsicElements
15
+ * extends ScopedElements<'test-', ''> {}
16
+ * }
17
+ * }
18
+ * ```
19
+ *
20
+ * @deprecated Runtime scoped elements result in duplicate types and can confusing for developers. It is recommended to use the `prefix` and `suffix` options to generate new types instead.
21
+ */
22
+ export type ScopedElements<
23
+ Prefix extends string = "",
24
+ Suffix extends string = ""
25
+ > = {
26
+ [Key in keyof CustomElements as `${Prefix}${Key}${Suffix}`]: CustomElements[Key];
27
+ };
28
+
29
+ type BaseProps<T extends HTMLElement> = {
30
+
31
+ /** Content added between the opening and closing tags of the element */
32
+ children?: any;
33
+ /** Used for declaratively styling one or more elements using CSS (Cascading Stylesheets) */
34
+ class?: string;
35
+ /** Used for declaratively styling one or more elements using CSS (Cascading Stylesheets) */
36
+ className?: string;
37
+ /** Takes an object where the key is the class name(s) and the value is a boolean expression. When true, the class is applied, and when false, it is removed. */
38
+ classList?: Record<string, boolean | undefined>;
39
+ /** Specifies the text direction of the element. */
40
+ dir?: "ltr" | "rtl";
41
+ /** Contains a space-separated list of the part names of the element that should be exposed on the host element. */
42
+ exportparts?: string;
43
+ /** For <label> and <output>, lets you associate the label with some control. */
44
+ htmlFor?: string;
45
+ /** Specifies whether the element should be hidden. */
46
+ hidden?: boolean | string;
47
+ /** A unique identifier for the element. */
48
+ id?: string;
49
+ /** Keys tell React which array item each component corresponds to */
50
+ key?: string | number;
51
+ /** Specifies the language of the element. */
52
+ lang?: string;
53
+ /** Contains a space-separated list of the part names of the element. Part names allows CSS to select and style specific elements in a shadow tree via the ::part pseudo-element. */
54
+ part?: string;
55
+ /** Use the ref attribute with a variable to assign a DOM element to the variable once the element is rendered. */
56
+ ref?: T | ((e: T) => void);
57
+ /** Adds a reference for a custom element slot */
58
+ slot?: string;
59
+ /** Prop for setting inline styles */
60
+ style?: Record<string, string | number>;
61
+ /** Overrides the default Tab button behavior. Avoid using values other than -1 and 0. */
62
+ tabIndex?: number;
63
+ /** Specifies the tooltip text for the element. */
64
+ title?: string;
65
+ /** Passing 'no' excludes the element content from being translated. */
66
+ translate?: "yes" | "no";
67
+ /** The popover global attribute is used to designate an element as a popover element. */
68
+ popover?: "auto" | "hint" | "manual";
69
+ /** Turns an element element into a popover control button; takes the ID of the popover element to control as its value. */
70
+ popovertarget?: "top" | "bottom" | "left" | "right" | "auto";
71
+ /** Specifies the action to be performed on a popover element being controlled by a control element. */
72
+ popovertargetaction?: "show" | "hide" | "toggle";
73
+
74
+ } ;
75
+
76
+ type BaseEvents = {
77
+
78
+
79
+ };
80
+
81
+
82
+
83
+ export type OrSchedulerProps = {
84
+ /** */
85
+ "defaultSchedule"?: OrScheduler['defaultSchedule'];
86
+ /** */
87
+ "defaultEventTypeLabel"?: OrScheduler['defaultEventTypeLabel'];
88
+ /** */
89
+ "disabledFrequencies"?: OrScheduler['disabledFrequencies'];
90
+ /** */
91
+ "disabledRRuleParts"?: OrScheduler['disabledRRuleParts'];
92
+ /** */
93
+ "header"?: OrScheduler['header'];
94
+ /** */
95
+ "isAllDay"?: OrScheduler['isAllDay'];
96
+ /** */
97
+ "schedule"?: OrScheduler['schedule'];
98
+ /** */
99
+ "timezoneOffset"?: OrScheduler['timezoneOffset'];
100
+
101
+ /** */
102
+ "onschedule"?: (e: CustomEvent<OrSchedulerChangedEvent>) => void;
103
+ }
104
+
105
+ export type CustomElements = {
106
+
107
+
108
+ /**
109
+ *
110
+ *
111
+ * ## Attributes & Properties
112
+ *
113
+ * Component attributes and properties that can be applied to the element or by using JavaScript.
114
+ *
115
+ * - `defaultSchedule`: undefined
116
+ * - `defaultEventTypeLabel`: undefined
117
+ * - `disabledFrequencies`: undefined
118
+ * - `disabledRRuleParts`: undefined
119
+ * - `header`: undefined
120
+ * - `isAllDay`: undefined
121
+ * - `schedule`: undefined
122
+ * - `timezoneOffset`: undefined
123
+ *
124
+ * ## Events
125
+ *
126
+ * Events that will be emitted by the component.
127
+ *
128
+ * - `schedule`: undefined
129
+ */
130
+ "or-scheduler": Partial<OrSchedulerProps & BaseProps<OrScheduler> & BaseEvents>;
131
+ }
132
+
133
+ export type CustomCssProperties = {
134
+
135
+ }
136
+
137
+
138
+ declare module 'react' {
139
+ namespace JSX {
140
+ interface IntrinsicElements extends CustomElements {}
141
+ }
142
+ export interface CSSProperties extends CustomCssProperties {}
143
+ }
144
+
145
+ declare module 'preact' {
146
+ namespace JSX {
147
+ interface IntrinsicElements extends CustomElements {}
148
+ }
149
+ export interface CSSProperties extends CustomCssProperties {}
150
+ }
151
+
152
+ declare module '@builder.io/qwik' {
153
+ namespace JSX {
154
+ interface IntrinsicElements extends CustomElements {}
155
+ }
156
+ export interface CSSProperties extends CustomCssProperties {}
157
+ }
158
+
159
+ declare module '@stencil/core' {
160
+ namespace JSX {
161
+ interface IntrinsicElements extends CustomElements {}
162
+ }
163
+ export interface CSSProperties extends CustomCssProperties {}
164
+ }
165
+
166
+ declare module 'hono/jsx' {
167
+ namespace JSX {
168
+ interface IntrinsicElements extends CustomElements {}
169
+ }
170
+ export interface CSSProperties extends CustomCssProperties {}
171
+ }
172
+
173
+ declare module 'react-native' {
174
+ namespace JSX {
175
+ interface IntrinsicElements extends CustomElements {}
176
+ }
177
+ export interface CSSProperties extends CustomCssProperties {}
178
+ }
179
+
180
+ declare global {
181
+ namespace JSX {
182
+ interface IntrinsicElements extends CustomElements {}
183
+ }
184
+ export interface CSSProperties extends CustomCssProperties {}
185
+ }