platform-calendar-seatmap 2.1.15 → 2.1.16
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/.github/workflows/main.yml +49 -49
- package/README.md +36 -36
- package/custom.d.ts +8 -8
- package/dist/components/actionsHandler/ActionsHandler.d.ts +3 -2
- package/dist/components/elementSelector/dropdown/sections/images/Images.d.ts +3 -0
- package/dist/components/elementSelector/dropdown/sections/lines/Lines.d.ts +7 -0
- package/dist/components/elementSelector/icons/ElementSelectorIcons.d.ts +15 -0
- package/dist/components/elements/line/Line.d.ts +7 -0
- package/dist/helpers/functions/seatMap.d.ts +3 -0
- package/dist/helpers/types/line.d.ts +22 -0
- package/dist/hooks/useElementWrapperActionHandlers.d.ts +4 -3
- package/dist/index.js +1 -1
- package/dist/index.js.LICENSE.txt +0 -980
- package/dist/store/reducers/elementSelector/types.d.ts +2 -2
- package/dist/store/reducers/main/actionCreators.d.ts +3 -2
- package/dist/store/reducers/main/actionTypes.d.ts +2 -1
- package/dist/store/reducers/main/selectors.d.ts +2 -1
- package/dist/store/reducers/main/types.d.ts +11 -4
- package/dist/store/reducers/rootReducer.d.ts +1 -1
- package/dist/store/reducers/seatMap/selectors.d.ts +15 -1
- package/dist/store/reducers/seatMap/types.d.ts +3 -2
- package/package.json +60 -60
- package/tsconfig.json +36 -36
- package/LICENSE +0 -21
|
@@ -1,49 +1,49 @@
|
|
|
1
|
-
name: Publish to npm
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches:
|
|
6
|
-
- main_needtofix
|
|
7
|
-
|
|
8
|
-
jobs:
|
|
9
|
-
publish:
|
|
10
|
-
runs-on: ubuntu-latest
|
|
11
|
-
|
|
12
|
-
steps:
|
|
13
|
-
- name: Checkout code
|
|
14
|
-
uses: actions/checkout@v2
|
|
15
|
-
|
|
16
|
-
- name: Set up Node.js
|
|
17
|
-
uses: actions/setup-node@v3
|
|
18
|
-
with:
|
|
19
|
-
node-version: '20'
|
|
20
|
-
registry-url: 'https://registry.npmjs.org/'
|
|
21
|
-
|
|
22
|
-
- name: Set Git user configuration
|
|
23
|
-
run: |
|
|
24
|
-
git config --global user.name "Boomtech dev"
|
|
25
|
-
git config --global user.email "dev@boomte.ch"
|
|
26
|
-
|
|
27
|
-
- name: Install dependencies
|
|
28
|
-
run: npm install
|
|
29
|
-
|
|
30
|
-
- name: Run build
|
|
31
|
-
run: npm run build
|
|
32
|
-
|
|
33
|
-
- name: Run build
|
|
34
|
-
run: git status
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
- name: Bump version (patch)
|
|
38
|
-
run: |
|
|
39
|
-
npm version patch
|
|
40
|
-
git push origin main
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
- name: Configure npm for authentication
|
|
44
|
-
run: echo "//registry.npmjs.org/:_authToken=${{secrets.NPM_TOKEN}}" > ~/.npmrc
|
|
45
|
-
|
|
46
|
-
- name: Publish to npm
|
|
47
|
-
run: npm publish
|
|
48
|
-
env:
|
|
49
|
-
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
|
1
|
+
name: Publish to npm
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main_needtofix
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
publish:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
|
|
12
|
+
steps:
|
|
13
|
+
- name: Checkout code
|
|
14
|
+
uses: actions/checkout@v2
|
|
15
|
+
|
|
16
|
+
- name: Set up Node.js
|
|
17
|
+
uses: actions/setup-node@v3
|
|
18
|
+
with:
|
|
19
|
+
node-version: '20'
|
|
20
|
+
registry-url: 'https://registry.npmjs.org/'
|
|
21
|
+
|
|
22
|
+
- name: Set Git user configuration
|
|
23
|
+
run: |
|
|
24
|
+
git config --global user.name "Boomtech dev"
|
|
25
|
+
git config --global user.email "dev@boomte.ch"
|
|
26
|
+
|
|
27
|
+
- name: Install dependencies
|
|
28
|
+
run: npm install
|
|
29
|
+
|
|
30
|
+
- name: Run build
|
|
31
|
+
run: npm run build
|
|
32
|
+
|
|
33
|
+
- name: Run build
|
|
34
|
+
run: git status
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
- name: Bump version (patch)
|
|
38
|
+
run: |
|
|
39
|
+
npm version patch
|
|
40
|
+
git push origin main
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
- name: Configure npm for authentication
|
|
44
|
+
run: echo "//registry.npmjs.org/:_authToken=${{secrets.NPM_TOKEN}}" > ~/.npmrc
|
|
45
|
+
|
|
46
|
+
- name: Publish to npm
|
|
47
|
+
run: npm publish
|
|
48
|
+
env:
|
|
49
|
+
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
package/README.md
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
# Boom Calendar
|
|
2
|
-
|
|
3
|
-
Powerful and customizable calendar package.
|
|
4
|
-
|
|
5
|
-
# Installation
|
|
6
|
-
|
|
7
|
-
```js
|
|
8
|
-
npm install --save platform-calendar-seatmap
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
# Code Example
|
|
12
|
-
|
|
13
|
-
Here's an example of basic usage:
|
|
14
|
-
|
|
15
|
-
```js
|
|
16
|
-
import React from 'react';
|
|
17
|
-
import SeatMap from 'platform-calendar-seatmap';
|
|
18
|
-
|
|
19
|
-
const App = () => {
|
|
20
|
-
return <SeatMap />;
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
export default App;
|
|
24
|
-
```
|
|
25
|
-
|
|
26
|
-
How to start project locally:
|
|
27
|
-
|
|
28
|
-
npm i in root directory
|
|
29
|
-
|
|
30
|
-
npm start in root directory
|
|
31
|
-
|
|
32
|
-
npm i in example folder
|
|
33
|
-
|
|
34
|
-
npm start in example folder
|
|
35
|
-
|
|
36
|
-
Full documentation is on the way.
|
|
1
|
+
# Boom Calendar
|
|
2
|
+
|
|
3
|
+
Powerful and customizable calendar package.
|
|
4
|
+
|
|
5
|
+
# Installation
|
|
6
|
+
|
|
7
|
+
```js
|
|
8
|
+
npm install --save platform-calendar-seatmap
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
# Code Example
|
|
12
|
+
|
|
13
|
+
Here's an example of basic usage:
|
|
14
|
+
|
|
15
|
+
```js
|
|
16
|
+
import React from 'react';
|
|
17
|
+
import SeatMap from 'platform-calendar-seatmap';
|
|
18
|
+
|
|
19
|
+
const App = () => {
|
|
20
|
+
return <SeatMap />;
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
export default App;
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
How to start project locally:
|
|
27
|
+
|
|
28
|
+
npm i in root directory
|
|
29
|
+
|
|
30
|
+
npm start in root directory
|
|
31
|
+
|
|
32
|
+
npm i in example folder
|
|
33
|
+
|
|
34
|
+
npm start in example folder
|
|
35
|
+
|
|
36
|
+
Full documentation is on the way.
|
package/custom.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
declare module '*.svg' {
|
|
2
|
-
import * as React from 'react';
|
|
3
|
-
const ReactComponent: React.FC<React.SVGProps<SVGSVGElement> & { title?: string }>;
|
|
4
|
-
|
|
5
|
-
export default ReactComponent;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
declare module '*.module.css';
|
|
1
|
+
declare module '*.svg' {
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
const ReactComponent: React.FC<React.SVGProps<SVGSVGElement> & { title?: string }>;
|
|
4
|
+
|
|
5
|
+
export default ReactComponent;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
declare module '*.module.css';
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { T_Seat, T_SeatMap } from 'platform-calendar-helpers';
|
|
1
|
+
import { T_BackgroundImage, T_Seat, T_SeatMap } from 'platform-calendar-helpers';
|
|
2
2
|
type actions = {
|
|
3
|
-
save: () => (T_SeatMap & {
|
|
3
|
+
save: () => (Omit<T_SeatMap, 'ticketColors'> & {
|
|
4
4
|
backgroundColor: string;
|
|
5
|
+
backgroundImage?: T_BackgroundImage;
|
|
5
6
|
ticketColors: Record<string, string>;
|
|
6
7
|
seatSize: number;
|
|
7
8
|
zoomMode: 'buttons' | 'wheel' | 'both';
|
|
@@ -19,6 +19,21 @@ export declare const TableIcon: FC<{
|
|
|
19
19
|
size?: number;
|
|
20
20
|
className?: string;
|
|
21
21
|
}>;
|
|
22
|
+
/** Image: landscape picture with mountain and sun */
|
|
23
|
+
export declare const ImageIcon: FC<{
|
|
24
|
+
size?: number;
|
|
25
|
+
className?: string;
|
|
26
|
+
}>;
|
|
27
|
+
/** Line: diagonal line */
|
|
28
|
+
export declare const LineIcon: FC<{
|
|
29
|
+
size?: number;
|
|
30
|
+
className?: string;
|
|
31
|
+
}>;
|
|
32
|
+
/** Object shapes: rectangle + ellipse + polygon */
|
|
33
|
+
export declare const ObjectShapesIcon: FC<{
|
|
34
|
+
size?: number;
|
|
35
|
+
className?: string;
|
|
36
|
+
}>;
|
|
22
37
|
/** Text: capital T */
|
|
23
38
|
export declare const TextIcon: FC<{
|
|
24
39
|
size?: number;
|
|
@@ -10,12 +10,15 @@ declare const removeFakeElementsFromSeatMap: (_seatMap: T_SeatMap) => {
|
|
|
10
10
|
text: import("platform-calendar-helpers").T_Element_Text[];
|
|
11
11
|
aisles: any;
|
|
12
12
|
arcSection: any;
|
|
13
|
+
lines: any;
|
|
13
14
|
};
|
|
14
15
|
id: number;
|
|
15
16
|
name: string;
|
|
16
17
|
backgroundColor?: string;
|
|
18
|
+
backgroundImage?: import("platform-calendar-helpers").T_BackgroundImage;
|
|
17
19
|
seatSize?: number;
|
|
18
20
|
zoomMode?: "buttons" | "wheel" | "both";
|
|
21
|
+
ticketColors?: string[];
|
|
19
22
|
};
|
|
20
23
|
declare const addFakeElementsToSeatMap: (_seatMap: T_SeatMap) => T_SeatMap;
|
|
21
24
|
/**
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* LOCAL LINE TYPES
|
|
3
|
+
* These mirror the types from platform-calendar-helpers for local use
|
|
4
|
+
*/
|
|
5
|
+
export type T_LineStyle = 'solid' | 'dashed' | 'dotted';
|
|
6
|
+
export type T_Element_Line = {
|
|
7
|
+
id: string;
|
|
8
|
+
title: string;
|
|
9
|
+
position: {
|
|
10
|
+
top: number;
|
|
11
|
+
left: number;
|
|
12
|
+
};
|
|
13
|
+
length: number;
|
|
14
|
+
thickness: number;
|
|
15
|
+
color: string;
|
|
16
|
+
style: T_LineStyle;
|
|
17
|
+
opacity: number;
|
|
18
|
+
rotate: number;
|
|
19
|
+
zIndex: number;
|
|
20
|
+
};
|
|
21
|
+
export declare const LINE_ELEMENT_TYPE: "lines";
|
|
22
|
+
export declare const D_ELEMENT_LINE: T_Element_Line;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { T_Element, T_ElementType } from 'platform-calendar-helpers';
|
|
2
2
|
import { T_Element_Aisle } from 'helpers/types/aisle';
|
|
3
|
-
|
|
4
|
-
type
|
|
3
|
+
import { T_Element_Line } from 'helpers/types/line';
|
|
4
|
+
/** Element type union: helpers + local types */
|
|
5
|
+
type T_ElementType_SeatMap = T_ElementType | 'aisles' | 'lines';
|
|
5
6
|
type T_Props = {
|
|
6
|
-
element: T_Element | T_Element_Aisle;
|
|
7
|
+
element: T_Element | T_Element_Aisle | T_Element_Line;
|
|
7
8
|
elementType: T_ElementType_SeatMap;
|
|
8
9
|
};
|
|
9
10
|
declare const useElementWrapperActionHandlers: ({ element, elementType }: T_Props) => {
|