prozilla-os 2.0.0 → 2.0.5

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.
Files changed (4) hide show
  1. package/README.md +107 -113
  2. package/dist/main.js +1215 -1131
  3. package/dist/main.js.map +1 -1
  4. package/package.json +17 -17
package/README.md CHANGED
@@ -4,9 +4,9 @@
4
4
  <a href="https://os.prozilla.dev/"><img src="https://os.prozilla.dev/assets/logo.svg?v=2" height="200" alt="ProzillaOS" /></a>
5
5
  </p>
6
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>
7
+ <a href="https://github.com/prozilla-os/ProzillaOS/blob/main/LICENSE"><img alt="License" src="https://img.shields.io/github/license/prozilla-os/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-os/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-os/ProzillaOS?style=flat-square&color=4D9CFF&label=Forks&logo=github"></a>
10
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
11
  </p>
12
12
  </div>
@@ -38,6 +38,7 @@ pnpm add prozilla-os
38
38
  - [`@prozilla-os/media-viewer`][media-viewer] - Media viewer app
39
39
  - [`@prozilla-os/browser`][browser] - Browser app
40
40
  - [`@prozilla-os/calculator`][calculator] - Calculator app
41
+ - [`@prozilla-os/app-center`][app-center] - App center
41
42
 
42
43
  ## Usage
43
44
 
@@ -64,126 +65,118 @@ function App() {
64
65
 
65
66
  ### Configuration
66
67
 
67
- ```tsx
68
+ ```ts
68
69
  interface ProzillaOSProps {
70
+ systemName?: string;
71
+ tagLine?: string;
72
+ skin?: Skin;
73
+ config?: {
74
+ apps?: Partial<AppsConfigOptions>;
75
+ desktop?: Partial<DesktopConfigOptions>;
76
+ misc?: Partial<MiscConfigOptions>;
77
+ modals?: Partial<ModalsConfigOptions>;
78
+ taskbar?: Partial<TaskbarConfigOptions>;
79
+ tracking?: Partial<TrackingConfigOptions>;
80
+ windows?: Partial<WindowsConfigOptions>;
81
+ virtualDrive?: Partial<VirtualDriveConfigOptions>;
82
+ };
83
+ children?: ReactNode;
84
+ }
85
+ ```
69
86
 
70
- systemName: string,
71
-
72
- tagLine: string,
73
-
74
- skin: new Skin({
75
-
76
- appIcons: Record<number, string> | undefined,
77
-
78
- appNames: Record<number, string> | undefined,
79
-
80
- wallpapers: string[],
81
-
82
- defaultWallpaper: string,
83
-
84
- fileIcons: {
85
- generic: string;
86
- info: string | undefined;
87
- text: string | undefined;
88
- code: string | undefined;
89
- },
90
-
91
- folderIcons: {
92
- generic: string;
93
- images: string | undefined;
94
- text: string | undefined;
95
- link: string | undefined;
96
- },
97
-
98
- loadStyleSheet: () => void | undefined
99
-
100
- })
101
-
102
- config: {
103
- apps: new AppsConfig({
104
-
105
- apps: App[]
106
-
107
- }),
108
- desktop: new DesktopConfig({
109
-
110
- /**
111
- * @default 1
112
- */
113
- defaultIconSize: 0 | 1 | 2,
114
-
115
- /**
116
- * 0: vertical, 1: horizontal
117
- * @default 0
118
- * */
119
- defaultIconDirection: 0 | 1
120
-
121
- }),
122
- misc: new MiscConfig({
123
-
124
- /**
125
- * @default 250
126
- */
127
- doubleClickDelay: number
128
-
129
- })
130
- modals: new ModalsConfig({
131
-
132
- /**
133
- * Default size of a dialog box
134
- * @default new Vector2(400, 200)
135
- */
136
- defaultDialogSize: Vector2,
137
-
138
- /**
139
- * Default size of a file selector
140
- * @default new Vector2(700, 400)
141
- */
142
- defaultFileSelectorSize: Vector2
143
-
144
- }),
145
- taskbar: new TaskbarConfig({
146
-
147
- /**
148
- * Height of the taskbar in CSS pixels
149
- * @default 3 * 16
150
- */
151
- height: number
87
+ ```ts
88
+ interface SkinOptions {
89
+ systemIcon: string;
90
+ appIcons?: { [key: string]: string };
91
+ appNames?: { [key: string]: string };
92
+ wallpapers: string[];
93
+ defaultWallpaper: string;
94
+ fileIcons: {
95
+ generic: string;
96
+ info?: string;
97
+ text?: string;
98
+ code?: string;
99
+ external?: string;
100
+ video?: string;
101
+ audio?: string;
102
+ };
103
+ folderIcons: {
104
+ generic: string;
105
+ images?: string;
106
+ text?: string;
107
+ link?: string;
108
+ video?: string;
109
+ audio?: string;
110
+ };
111
+ loadStyleSheet?: () => void;
112
+ defaultTheme?: Theme;
113
+ }
114
+ ```
152
115
 
153
- }),
154
- tracking: new TrackingConfig({
116
+ ```ts
117
+ interface AppsConfigOptions {
118
+ apps: App[];
119
+ }
155
120
 
156
- /**
157
- * Enable tracking
158
- * @default true
159
- */
160
- enabled: boolean,
121
+ interface DesktopConfigOptions {
122
+ /** @default 1 */
123
+ defaultIconSize: 0 | 1 | 2;
124
+ /** 0: vertical, 1: horizontal @default 0 */
125
+ defaultIconDirection: 0 | 1;
126
+ }
161
127
 
162
- /** Google Analytics measurement ID */
163
- GAMeasurementId: string
128
+ interface MiscConfigOptions {
129
+ /** @default 250 */
130
+ doubleClickDelay: number;
131
+ }
164
132
 
165
- }),
166
- windows: new WindowsConfig({
133
+ interface ModalsConfigOptions {
134
+ /** Default size of a dialog box @default new Vector2(400, 200) */
135
+ defaultDialogSize: Vector2;
136
+ /** Default size of a file selector @default new Vector2(700, 400) */
137
+ defaultFileSelectorSize: Vector2;
138
+ }
167
139
 
168
- /**
169
- * @default 32
170
- */
171
- screenMargin: number,
140
+ interface TaskbarConfigOptions {
141
+ /** Height of the taskbar in CSS pixels @default 3 * 16 */
142
+ height: number;
143
+ }
172
144
 
173
- /**
174
- * @default "-"
175
- */
176
- titleSeparator: string,
145
+ interface TrackingConfigOptions {
146
+ /** Enable tracking @default true */
147
+ enabled: boolean;
148
+ /** Google Analytics measurement ID */
149
+ GAMeasurementId: string;
150
+ }
177
151
 
178
- /**
179
- * If the user's screen is smaller than these values, windows will always be maximized
180
- * @default new Vector2(350, 350)
181
- */
182
- minScreenSize: Vector2
183
-
184
- })
185
- }
152
+ interface WindowsConfigOptions {
153
+ /** @default 32 */
154
+ screenMargin: number;
155
+ /** @default "-" */
156
+ titleSeparator: string;
157
+ /** If the user's screen is smaller than these values, windows will always be maximized @default new Vector2(350, 350) */
158
+ minScreenSize: Vector2;
159
+ }
186
160
 
161
+ interface VirtualDriveConfigOptions {
162
+ /** Enables persistent storage of the virtual drive. */
163
+ saveData: false | {
164
+ enableCompression: boolean;
165
+ prefix?: string;
166
+ migrations?: [string, string][];
167
+ };
168
+ /** Configure the data that is loaded initially. */
169
+ defaultData: {
170
+ includePicturesFolder?: boolean;
171
+ includeAudioFolder?: boolean;
172
+ includeVideoFolder?: boolean;
173
+ includeDocumentsFolder?: boolean;
174
+ includeDesktopFolder?: boolean;
175
+ includeSourceTree?: boolean;
176
+ includeAppsFolder?: boolean;
177
+ includeScriptsFolder?: boolean;
178
+ loadData?: (virtualRoot: VirtualRoot) => void;
179
+ };
187
180
  }
188
181
  ```
189
182
 
@@ -211,4 +204,5 @@ interface ProzillaOSProps {
211
204
  [settings]: https://www.npmjs.com/package/@prozilla-os/settings
212
205
  [media-viewer]: https://www.npmjs.com/package/@prozilla-os/media-viewer
213
206
  [browser]: https://www.npmjs.com/package/@prozilla-os/browser
207
+ [app-center]: https://www.npmjs.com/package/@prozilla-os/app-center
214
208
  [calculator]: https://www.npmjs.com/package/@prozilla-os/calculator