@articles-media/articles-dev-box 1.1.2 → 1.1.3
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 -1
- package/dist/GameMenuPrimaryButtonGroup.js +6 -6
- package/dist/GlobalBody.js +2 -2
- package/dist/GlobalHead.js +2 -2
- package/dist/{SettingsModal-DxRRcKLZ.js → SettingsModal-VLREmj2k.js} +8 -4
- package/dist/SettingsModal.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -45,7 +45,7 @@ npm run dev
|
|
|
45
45
|
| GameMenu | All in one component that handles the sidebar and menu-bar inside a game page. | Catching Game and School Run use Static Panel for sidebarStyle and Corner Button for menuBarStyle. Ice Slide uses Floating Panel for sidebarStyle and Bar for menuBarStyle. |
|
|
46
46
|
| GameMenuPrimaryButtonGroup | The common button groups for landing page and menu content across our games | Catching Game and Move Match |
|
|
47
47
|
| NicknameInput | Handles nickname UI on landing page | Catching Game |
|
|
48
|
-
| GlobalHead | Not used at this time, allows for
|
|
48
|
+
| GlobalHead | Not used at this time, allows for head element related tags to be added to site without other logic. | |
|
|
49
49
|
| GlobalBody | Easy way to add future logic and components to all projects with ease. For now handling the font awesome script. Also shows connection status to required servers in development. Will ping the main and auth server as they are needed for some dev-box features. | |
|
|
50
50
|
| ViewUserModal | View user profile data and recent activity. | |
|
|
51
51
|
| SettingsModal | All in one component to handle game settings UI across multiple games. | |
|
|
@@ -9,7 +9,7 @@ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
|
9
9
|
* @param {string} [props.owner] Optional GitHub owner
|
|
10
10
|
* @param {string} [props.repo] Optional GitHub repo
|
|
11
11
|
*/
|
|
12
|
-
function PrimaryButtonGroup({ useStore, type, owner, repo, LeaveGameOverride, SidebarOverride, SettingsOverride }) {
|
|
12
|
+
function PrimaryButtonGroup({ useStore, type, owner, repo, LeaveGameOverride, SidebarOverride, SettingsOverride, InfoOverride, CreditsOverride, GithubOverride, FullscreenOverride }) {
|
|
13
13
|
if (!useStore) return null;
|
|
14
14
|
const { isFullscreen, requestFullscreen, exitFullscreen } = useFullscreen();
|
|
15
15
|
const setShowSettingsModal = useStore((state) => state.setShowSettingsModal);
|
|
@@ -21,7 +21,7 @@ function PrimaryButtonGroup({ useStore, type, owner, repo, LeaveGameOverride, Si
|
|
|
21
21
|
const setSidebar = useStore((state) => state.setSidebar);
|
|
22
22
|
switch (type) {
|
|
23
23
|
case "Landing": return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
24
|
-
/* @__PURE__ */ jsxs("div", {
|
|
24
|
+
SettingsOverride ? SettingsOverride : /* @__PURE__ */ jsxs("div", {
|
|
25
25
|
className: "w-50 d-flex",
|
|
26
26
|
children: [/* @__PURE__ */ jsxs(ArticlesButton, {
|
|
27
27
|
className: `w-100`,
|
|
@@ -39,7 +39,7 @@ function PrimaryButtonGroup({ useStore, type, owner, repo, LeaveGameOverride, Si
|
|
|
39
39
|
children: darkMode ? /* @__PURE__ */ jsx("i", { className: "fad fa-sun" }) : /* @__PURE__ */ jsx("i", { className: "fad fa-moon" })
|
|
40
40
|
})]
|
|
41
41
|
}),
|
|
42
|
-
/* @__PURE__ */ jsxs(ArticlesButton, {
|
|
42
|
+
InfoOverride ? InfoOverride : /* @__PURE__ */ jsxs(ArticlesButton, {
|
|
43
43
|
className: `w-50`,
|
|
44
44
|
small: true,
|
|
45
45
|
onClick: () => {
|
|
@@ -47,7 +47,7 @@ function PrimaryButtonGroup({ useStore, type, owner, repo, LeaveGameOverride, Si
|
|
|
47
47
|
},
|
|
48
48
|
children: [/* @__PURE__ */ jsx("i", { className: "fad fa-info-square" }), "Info"]
|
|
49
49
|
}),
|
|
50
|
-
/* @__PURE__ */ jsx("a", {
|
|
50
|
+
GithubOverride ? GithubOverride : /* @__PURE__ */ jsx("a", {
|
|
51
51
|
href: `https://github.com/${owner || process.env.NEXT_PUBLIC_OWNER}/${repo || process.env.NEXT_PUBLIC_REPO}`,
|
|
52
52
|
target: "_blank",
|
|
53
53
|
rel: "noopener noreferrer",
|
|
@@ -59,7 +59,7 @@ function PrimaryButtonGroup({ useStore, type, owner, repo, LeaveGameOverride, Si
|
|
|
59
59
|
children: [/* @__PURE__ */ jsx("i", { className: "fab fa-github" }), "Github"]
|
|
60
60
|
})
|
|
61
61
|
}),
|
|
62
|
-
/* @__PURE__ */ jsxs(ArticlesButton, {
|
|
62
|
+
CreditsOverride ? CreditsOverride : /* @__PURE__ */ jsxs(ArticlesButton, {
|
|
63
63
|
className: `w-50`,
|
|
64
64
|
small: true,
|
|
65
65
|
onClick: () => {
|
|
@@ -78,7 +78,7 @@ function PrimaryButtonGroup({ useStore, type, owner, repo, LeaveGameOverride, Si
|
|
|
78
78
|
children: [/* @__PURE__ */ jsx("i", { className: "fad fa-arrow-alt-square-left" }), /* @__PURE__ */ jsx("span", { children: "Leave Game" })]
|
|
79
79
|
})
|
|
80
80
|
}),
|
|
81
|
-
/* @__PURE__ */ jsxs(ArticlesButton, {
|
|
81
|
+
FullscreenOverride ? FullscreenOverride : /* @__PURE__ */ jsxs(ArticlesButton, {
|
|
82
82
|
small: true,
|
|
83
83
|
className: "w-50",
|
|
84
84
|
active: isFullscreen,
|
package/dist/GlobalBody.js
CHANGED
|
@@ -6,11 +6,11 @@ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
|
6
6
|
//#region src/components/Global/GlobalBody.jsx
|
|
7
7
|
var import_classnames = /* @__PURE__ */ __toESM(require_classnames(), 1);
|
|
8
8
|
var StatusModal = lazy(() => import("./StatusModal-DkHAimHp.js"));
|
|
9
|
-
function GlobalBody(
|
|
9
|
+
function GlobalBody({ fontawesome = true }) {
|
|
10
10
|
const [statusModal, setStatusModal] = useState(false);
|
|
11
11
|
const { data: mainSiteStatus, error: mainSiteStatusError, isLoading: mainSiteStatusLoading, mutate: mainSiteStatusMutate } = useMainSiteStatus({ disable: process.env.NODE_ENV !== "development" });
|
|
12
12
|
const { data: authSiteStatus, error: authSiteStatusError, isLoading: authSiteStatusLoading, mutate: authSiteStatusMutate } = useAuthSiteStatus({ disable: process.env.NODE_ENV !== "development" });
|
|
13
|
-
return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx("link", {
|
|
13
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [fontawesome && /* @__PURE__ */ jsx("link", {
|
|
14
14
|
rel: "stylesheet",
|
|
15
15
|
href: `https://cdn.articles.media/fonts/fontawesome/css/all.min.css`
|
|
16
16
|
}), process.env.NODE_ENV === "development" && /* @__PURE__ */ jsxs(Fragment, { children: [
|
package/dist/GlobalHead.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Fragment, jsx } from "react/jsx-runtime";
|
|
2
2
|
//#region src/components/Global/GlobalHead.jsx
|
|
3
|
-
function GlobalHead() {
|
|
4
|
-
return /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx("link", {
|
|
3
|
+
function GlobalHead({ fontawesome = false }) {
|
|
4
|
+
return /* @__PURE__ */ jsx(Fragment, { children: fontawesome && /* @__PURE__ */ jsx("link", {
|
|
5
5
|
rel: "stylesheet",
|
|
6
6
|
href: `https://cdn.articles.media/fonts/fontawesome/css/all.min.css`
|
|
7
7
|
}) });
|
|
@@ -169,7 +169,11 @@ function SocketSettings({ useStore }) {
|
|
|
169
169
|
function ControlsTab({ useTouchControlsStore, config }) {
|
|
170
170
|
return /* @__PURE__ */ jsxs("div", {
|
|
171
171
|
className: "",
|
|
172
|
-
children: [
|
|
172
|
+
children: [
|
|
173
|
+
config?.tabs?.Controls?.ControlsPanel && /* @__PURE__ */ jsx(Fragment, { children: config?.tabs?.Controls?.ControlsPanel }),
|
|
174
|
+
useTouchControlsStore && config?.tabs?.Controls?.touchControls && /* @__PURE__ */ jsx(TouchControls, { useTouchControlsStore }),
|
|
175
|
+
config?.tabs?.Controls?.children
|
|
176
|
+
]
|
|
173
177
|
});
|
|
174
178
|
}
|
|
175
179
|
function TouchControls({ useTouchControlsStore }) {
|
|
@@ -238,7 +242,7 @@ function OtherTab({ useStore, config }) {
|
|
|
238
242
|
var package_default = {
|
|
239
243
|
name: "@articles-media/articles-dev-box",
|
|
240
244
|
description: "Shared code, functions, and components for different Articles Media projects.",
|
|
241
|
-
version: "1.1.
|
|
245
|
+
version: "1.1.3",
|
|
242
246
|
type: "module",
|
|
243
247
|
sideEffects: false,
|
|
244
248
|
imports: { "#root/src/*": "./src/*" },
|
|
@@ -437,10 +441,10 @@ function ModalContent({ setShow, useStore, useAudioStore, useTouchControlsStore,
|
|
|
437
441
|
setShow(false);
|
|
438
442
|
},
|
|
439
443
|
children: "Close"
|
|
440
|
-
}), /* @__PURE__ */ jsx(ArticlesButton, {
|
|
444
|
+
}), config?.reset && /* @__PURE__ */ jsx(ArticlesButton, {
|
|
441
445
|
variant: "outline-danger ms-3",
|
|
442
446
|
onClick: () => {
|
|
443
|
-
reset();
|
|
447
|
+
config.reset();
|
|
444
448
|
},
|
|
445
449
|
children: "Reset"
|
|
446
450
|
})] })
|
package/dist/SettingsModal.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as SettingsModal } from "./SettingsModal-
|
|
1
|
+
import { t as SettingsModal } from "./SettingsModal-VLREmj2k.js";
|
|
2
2
|
export { SettingsModal as default };
|
package/dist/index.js
CHANGED
|
@@ -16,7 +16,7 @@ import { t as GameScoreboard } from "./GameScoreboard-CYuTBE_E.js";
|
|
|
16
16
|
import PageTemplateLandingPage from "./PageTemplateLandingPage.js";
|
|
17
17
|
import GlobalHead from "./GlobalHead.js";
|
|
18
18
|
import GlobalBody_default from "./GlobalBody.js";
|
|
19
|
-
import { t as SettingsModal } from "./SettingsModal-
|
|
19
|
+
import { t as SettingsModal } from "./SettingsModal-VLREmj2k.js";
|
|
20
20
|
import CreditsModal from "./CreditsModal.js";
|
|
21
21
|
import InfoModal from "./InfoModal.js";
|
|
22
22
|
import DarkModeHandler from "./DarkModeHandler.js";
|
package/package.json
CHANGED