Skip to content

Commit 65c6c06

Browse files
committed
Update dependencies, enhance globe component, and improve API documentation
- Updated package dependencies including @auth/prisma-adapter and eslint. - Enhanced globe component with improved color configurations and adaptive settings for dark mode. - Added floating token generator in API documentation for better user experience. - Updated README with new Discord link and improved API documentation with detailed authentication instructions. - Refactored styles for Swagger UI to support light and dark modes. Files changed: - package.json, package-lock.json: Updated dependencies. - src/components/ui/globe.tsx: Enhanced globe configuration and added dark mode support. - src/pages/api-docs.tsx: Implemented floating token generator and improved documentation. - src/utils/swagger.ts: Updated API documentation with detailed authentication instructions. - src/styles/swagger-overrides.css: Refactored styles for light and dark modes.
1 parent 47752dc commit 65c6c06

File tree

9 files changed

+7954
-2793
lines changed

9 files changed

+7954
-2793
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,7 @@ This project is licensed under the Apache License - see the [LICENSE.md](LICENSE
288288

289289
- **Documentation**: Check our documentation
290290
- **Issues**: Report bugs and request features on GitHub Issues
291-
- **Discord**: Join our Discord community for support at [https://discord.gg/jQZVcMbdKU](https://discord.gg/jQZVcMbdKU)
291+
- **Discord**: Join our Discord community for support at [https://discord.gg/eyTT9k2KZq](https://discord.gg/eyTT9k2KZq) look for ask multisig platform.
292292

293293

294294
---

package-lock.json

Lines changed: 5071 additions & 2736 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@
2121
"test:ci": "jest --ci --coverage --watchAll=false"
2222
},
2323
"dependencies": {
24-
"@auth/prisma-adapter": "^1.6.0",
24+
"@auth/prisma-adapter": "^2.11.1",
2525
"@hookform/resolvers": "^3.9.0",
2626
"@jinglescode/nostr-chat-plugin": "^0.0.11",
27-
"@meshsdk/core": "^1.9.0-beta.77",
28-
"@meshsdk/core-csl": "^1.9.0-beta.77",
29-
"@meshsdk/core-cst": "^1.9.0-beta.77",
30-
"@meshsdk/react": "^1.9.0-beta.77",
27+
"@meshsdk/core": "^1.9.0-beta.87",
28+
"@meshsdk/core-csl": "^1.9.0-beta.87",
29+
"@meshsdk/core-cst": "^1.9.0-beta.87",
30+
"@meshsdk/react": "^1.9.0-beta.87",
3131
"@octokit/core": "^6.1.2",
3232
"@prisma/client": "^6.17.1",
3333
"@radix-ui/react-accordion": "^1.2.0",
@@ -105,8 +105,8 @@
105105
"@types/swagger-ui-react": "^5.18.0",
106106
"@typescript-eslint/eslint-plugin": "^8.1.0",
107107
"@typescript-eslint/parser": "^8.1.0",
108-
"eslint": "^8.57.0",
109-
"eslint-config-next": "^14.2.4",
108+
"eslint": "^9.39.1",
109+
"eslint-config-next": "^15.5.7",
110110
"jest": "^30.1.3",
111111
"postcss": "^8.4.39",
112112
"prettier": "^3.3.2",
@@ -119,5 +119,14 @@
119119
"ct3aMetadata": {
120120
"initVersion": "7.37.0"
121121
},
122-
"packageManager": "[email protected]"
122+
"packageManager": "[email protected]",
123+
"overrides": {
124+
"ip": "^2.0.1",
125+
"rimraf": "^6.1.2",
126+
"glob": "^11.0.0",
127+
"three-mesh-bvh": "^0.9.3",
128+
"node-domexception": "^2.0.2",
129+
"lodash.get": "^4.4.2",
130+
"lodash.isequal": "^4.5.0"
131+
}
123132
}

src/components/ui/globe.tsx

Lines changed: 37 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ export function Globe({ globeConfig, data }: WorldProps) {
9595
_buildData();
9696
_buildMaterial();
9797
}
98-
}, [globeRef.current]);
98+
}, [globeRef.current, globeConfig]);
9999

100100
const _buildMaterial = () => {
101101
if (!globeRef.current) return;
@@ -106,10 +106,18 @@ export function Globe({ globeConfig, data }: WorldProps) {
106106
emissiveIntensity: number;
107107
shininess: number;
108108
};
109-
globeMaterial.color = new Color(globeConfig.globeColor);
110-
globeMaterial.emissive = new Color(globeConfig.emissive);
111-
globeMaterial.emissiveIntensity = globeConfig.emissiveIntensity || 0.1;
112-
globeMaterial.shininess = globeConfig.shininess || 0.9;
109+
globeMaterial.color = new Color(globeConfig.globeColor || defaultProps.globeColor);
110+
globeMaterial.emissive = new Color(globeConfig.emissive || defaultProps.emissive);
111+
globeMaterial.emissiveIntensity = globeConfig.emissiveIntensity ?? defaultProps.emissiveIntensity;
112+
globeMaterial.shininess = globeConfig.shininess ?? defaultProps.shininess;
113+
114+
// Update atmosphere if globe ref is available
115+
if (globeRef.current) {
116+
globeRef.current
117+
.showAtmosphere(globeConfig.showAtmosphere ?? defaultProps.showAtmosphere)
118+
.atmosphereColor(globeConfig.atmosphereColor || defaultProps.atmosphereColor)
119+
.atmosphereAltitude(globeConfig.atmosphereAltitude ?? defaultProps.atmosphereAltitude);
120+
}
113121
};
114122

115123
const _buildData = () => {
@@ -179,7 +187,8 @@ export function Globe({ globeConfig, data }: WorldProps) {
179187
return (e as { arcAlt: number }).arcAlt * 1;
180188
})
181189
.arcStroke(() => {
182-
return [0.32, 0.28, 0.3][Math.round(Math.random() * 2)] || null;
190+
// Enhanced stroke widths for better visibility
191+
return [0.4, 0.35, 0.38][Math.round(Math.random() * 2)] || 0.35;
183192
})
184193
.arcDashLength(defaultProps.arcLength)
185194
.arcDashInitialGap((e) => (e as { order: number }).order * 1)
@@ -191,7 +200,7 @@ export function Globe({ globeConfig, data }: WorldProps) {
191200
.pointColor((e) => (e as { color: string }).color)
192201
.pointsMerge(true)
193202
.pointAltitude(0.0)
194-
.pointRadius(2);
203+
.pointRadius(globeConfig.pointSize || defaultProps.pointSize);
195204

196205
globeRef.current
197206
.ringsData([])
@@ -246,34 +255,46 @@ export function WebGLRendererConfig() {
246255
export function World(props: WorldProps) {
247256
const { globeConfig } = props;
248257
const scene = new Scene();
249-
scene.fog = new Fog(0xffffff, 400, 2000);
258+
// Enhanced fog for better depth perception
259+
scene.fog = new Fog(0x000000, 400, 2000);
250260
return (
251-
<Canvas scene={scene} camera={new PerspectiveCamera(50, aspect, 180, 1800)}>
261+
<Canvas
262+
scene={scene}
263+
camera={new PerspectiveCamera(50, aspect, 180, 1800)}
264+
gl={{ antialias: true, alpha: true }}
265+
>
252266
<WebGLRendererConfig />
253-
<ambientLight color={globeConfig.ambientLight} intensity={0.6} />
267+
<ambientLight
268+
color={globeConfig.ambientLight || "#4a90e2"}
269+
intensity={0.7}
270+
/>
254271
<directionalLight
255-
color={globeConfig.directionalLeftLight}
272+
color={globeConfig.directionalLeftLight || "#ffffff"}
256273
position={new Vector3(-400, 100, 400)}
274+
intensity={0.8}
257275
/>
258276
<directionalLight
259-
color={globeConfig.directionalTopLight}
277+
color={globeConfig.directionalTopLight || "#a0c4ff"}
260278
position={new Vector3(-200, 500, 200)}
279+
intensity={0.6}
261280
/>
262281
<pointLight
263-
color={globeConfig.pointLight}
282+
color={globeConfig.pointLight || "#ffffff"}
264283
position={new Vector3(-200, 500, 200)}
265-
intensity={0.8}
284+
intensity={1.0}
266285
/>
267286
<Globe {...props} />
268287
<OrbitControls
269288
enablePan={false}
270289
enableZoom={false}
271290
minDistance={cameraZ}
272291
maxDistance={cameraZ}
273-
autoRotateSpeed={1}
274-
autoRotate={true}
292+
autoRotateSpeed={globeConfig.autoRotateSpeed ?? 0.5}
293+
autoRotate={globeConfig.autoRotate ?? true}
275294
minPolarAngle={Math.PI / 3.5}
276295
maxPolarAngle={Math.PI - Math.PI / 3}
296+
enableDamping={true}
297+
dampingFactor={0.05}
277298
/>
278299
</Canvas>
279300
);

src/env.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ export const env = createEnv({
1313
.default("development"),
1414
BLOB_READ_WRITE_TOKEN: z.string(),
1515
GITHUB_TOKEN: z.string(),
16+
JWT_SECRET: z.string().min(32),
1617
// NEXTAUTH_SECRET:
1718
// process.env.NODE_ENV === "production"
1819
// ? z.string()
@@ -55,6 +56,7 @@ export const env = createEnv({
5556
process.env.NEXT_PUBLIC_BLOCKFROST_API_KEY_PREPROD,
5657
BLOB_READ_WRITE_TOKEN: process.env.BLOB_READ_WRITE_TOKEN,
5758
GITHUB_TOKEN: process.env.GITHUB_TOKEN,
59+
JWT_SECRET: process.env.JWT_SECRET,
5860
},
5961
/**
6062
* Run `build` or `dev` with `SKIP_ENV_VALIDATION` to skip env validation. This is especially

0 commit comments

Comments
 (0)