@prozilla-os/core 1.0.7 → 1.0.9

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 CHANGED
@@ -1 +1,163 @@
1
- # @prozilla-os/core
1
+ <div align="center">
2
+ <br />
3
+ <p>
4
+ <a href="https://os.prozilla.dev/"><img src="https://os.prozilla.dev/assets/logo.png" height="200" alt="ProzillaOS" /></a>
5
+ </p>
6
+ <p>
7
+ <a href="https://github.com/prozilla-os/ProzillaOS/blob/main/LICENSE.md"><img alt="License" src="https://img.shields.io/github/license/Prozilla/ProzillaOS?style=flat-square&color=FF4D5B&label=License"></a>
8
+ <a href="https://github.com/prozilla-os/ProzillaOS"><img alt="Stars" src="https://img.shields.io/github/stars/Prozilla/ProzillaOS?style=flat-square&color=FED24C&label=%E2%AD%90"></a>
9
+ <a href="https://github.com/prozilla-os/ProzillaOS"><img alt="Forks" src="https://img.shields.io/github/forks/Prozilla/ProzillaOS?style=flat-square&color=4D9CFF&label=Forks&logo=github"></a>
10
+ <a href="https://www.npmjs.com/package/prozilla-os"><img alt="NPM Version" src="https://img.shields.io/npm/v/prozilla-os?logo=npm&style=flat-square&label=prozilla-os&color=FF4D5B"></a>
11
+ </p>
12
+ </div>
13
+
14
+ ## About
15
+
16
+ `@prozilla-os/core` is a React component library written in TypeScript for building web-based operating systems, made by Prozilla.
17
+
18
+ ## Installation
19
+
20
+ ```sh
21
+ $ npm install @prozilla-os/core
22
+ $ yarn add @prozilla-os/core
23
+ $ pnpm add @prozilla-os/core
24
+ ```
25
+
26
+ ## Usage
27
+
28
+ ```tsx
29
+ import { Desktop, ModalsView, ProzillaOS, Taskbar, WindowsView } from "@prozilla-os/core";
30
+
31
+ function App() {
32
+ return (
33
+ <ProzillaOS systemName="Example" tagLine="Power by ProzillaOS">
34
+ <Taskbar/>
35
+ <WindowsView/>
36
+ <ModalsView/>
37
+ <Desktop/>
38
+ </ProzillaOS>
39
+ );
40
+ }
41
+ ```
42
+
43
+ <br />
44
+
45
+ ### `<ProzillaOS>` props
46
+
47
+ ```tsx
48
+ {
49
+
50
+ systemName: string,
51
+
52
+ tagLine: string,
53
+
54
+ config: {
55
+ apps: new AppsConfig({
56
+
57
+ apps: App[]
58
+
59
+ }),
60
+ desktop: new DesktopConfig({
61
+
62
+ /** Array of URLs of wallpaper images */
63
+ wallpapers: string[],
64
+
65
+ /** URL of default wallpaper image */
66
+ defaultWallpaper: string,
67
+
68
+ /**
69
+ * @default 1
70
+ */
71
+ defaultIconSize: 0 | 1 | 2,
72
+
73
+ /**
74
+ * 0: vertical, 1: horizontal
75
+ * @default 0
76
+ * */
77
+ defaultIconDirection: 0 | 1
78
+
79
+ }),
80
+ modals: new ModalsConfig({
81
+
82
+ /**
83
+ * Default size of a dialog box
84
+ * @default new Vector2(400, 200)
85
+ */
86
+ defaultDialogSize: Vector2,
87
+
88
+ /**
89
+ * Default size of a file selector
90
+ * @default new Vector2(700, 400)
91
+ */
92
+ defaultFileSelectorSize: Vector2
93
+
94
+ }),
95
+ taskbar: new TaskbarConfig({
96
+
97
+ /**
98
+ * Height of the taskbar in CSS pixels
99
+ * @default 3 * 16
100
+ */
101
+ height: number
102
+
103
+ }),
104
+ tracking: new TrackingConfig({
105
+
106
+ /**
107
+ * Enable tracking
108
+ * @default true
109
+ */
110
+ enabled: boolean,
111
+
112
+ /** Google Analytics measurement ID */
113
+ GAMeasurementId: string
114
+
115
+ }),
116
+ virtualDrive: new VirtualDriveConfig({
117
+
118
+ fileIcon: string,
119
+ infoFileIcon: string,
120
+ textFileIcon: string,
121
+ codeFileIcon: string,
122
+
123
+ folderIcon: string,
124
+ imagesFolderIcon: string,
125
+ textFolderIcon: string,
126
+ folderLinkIcon: string
127
+
128
+ }),
129
+ windows: new WindowsConfig({
130
+
131
+ /**
132
+ * @default 32
133
+ */
134
+ screenMargin: number,
135
+
136
+ /**
137
+ * @default "-"
138
+ */
139
+ titleSeparator: string,
140
+
141
+ /**
142
+ * If the user's screen is smaller than these values, windows will always be maximized
143
+ * @default new Vector2(350, 350)
144
+ */
145
+ minScreenSize: Vector2
146
+
147
+ })
148
+ }
149
+
150
+ }
151
+ ```
152
+
153
+ ## Links
154
+
155
+ - [Website/demo][website]
156
+ - [GitHub][github]
157
+ - [npm][npm]
158
+ - [Ko-fi][ko-fi]
159
+
160
+ [website]: https://os.prozilla.dev/
161
+ [github]: https://github.com/prozilla-os/ProzillaOS/tree/convert-to-monorepo/packages/core
162
+ [npm]: https://www.npmjs.com/package/@prozilla-os/core
163
+ [ko-fi]: https://ko-fi.com/prozilla
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@prozilla-os/core",
3
- "version": "1.0.7",
3
+ "description": "A React component library written in TypeScript for building web-based operating systems, made by Prozilla.",
4
+ "version": "1.0.9",
4
5
  "author": {
5
6
  "name": "Prozilla",
6
7
  "email": "business@prozilla.dev",
@@ -24,7 +25,7 @@
24
25
  "react-error-boundary": "^4.0.13",
25
26
  "react-ga4": "^2.1.0",
26
27
  "react-svg": "^16.1.34",
27
- "@prozilla-os/file-explorer": "1.0.4"
28
+ "@prozilla-os/file-explorer": "1.0.6"
28
29
  },
29
30
  "devDependencies": {
30
31
  "@types/node": "^20.14.5",
@@ -13,7 +13,7 @@ export interface DesktopConfigOptions {
13
13
  defaultIconSize: 0 | 1 | 2;
14
14
 
15
15
  /**
16
- * @description 0: vertical, 1: horizontal
16
+ * 0: vertical, 1: horizontal
17
17
  * @default 0
18
18
  * */
19
19
  defaultIconDirection: 0 | 1;
@@ -3,13 +3,13 @@ import { Vector2 } from "../../math/vector2";
3
3
 
4
4
  export interface ModalsConfigOptions {
5
5
  /**
6
- * @description Default size of a dialog box
6
+ * Default size of a dialog box
7
7
  * @default new Vector2(400, 200)
8
8
  */
9
9
  defaultDialogSize: Vector2;
10
10
 
11
11
  /**
12
- * @description Default size of a file selector
12
+ * Default size of a file selector
13
13
  * @default new Vector2(700, 400)
14
14
  */
15
15
  defaultFileSelectorSize: Vector2;
@@ -2,7 +2,7 @@ import { OptionalInterface } from "../../../types/util";
2
2
 
3
3
  export interface TaskbarConfigOptions {
4
4
  /**
5
- * @description Height of the taskbar in CSS pixels
5
+ * Height of the taskbar in CSS pixels
6
6
  * @default 3 * 16
7
7
  */
8
8
  height: number;
@@ -13,7 +13,7 @@ export interface WindowsConfigOptions {
13
13
  titleSeparator: string;
14
14
 
15
15
  /**
16
- * @description If the user's screen is smaller than these values, windows will always be maximized
16
+ * If the user's screen is smaller than these values, windows will always be maximized
17
17
  * @default new Vector2(350, 350)
18
18
  */
19
19
  minScreenSize: Vector2;