Skip to content

Commit 0b11922

Browse files
committed
Centralize external dependencies and remove border styling from dashboard tabs
1 parent b34bd88 commit 0b11922

File tree

8 files changed

+24
-9
lines changed

8 files changed

+24
-9
lines changed

public/css/api-keys.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
.dashboard-tabs {
2121
display: flex;
2222
margin-bottom: 20px;
23-
border-bottom: 1px solid var(--border-color);
23+
border-bottom: none;
2424
}
2525

2626
.tab-button {

public/js/components/simple-counter.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* This demonstrates the simplified state management approach using the simple-state.js library.
55
* It provides a much cleaner API compared to the current implementation.
66
*/
7-
import { createStore, StoreConnector } from 'https://esm.sh/@profullstack/[email protected]';
7+
import { createStore, StoreConnector } from '../../js/deps.js';
88

99
// Create a store for our counter component
1010
const counterStore = createStore('counter', {

public/js/deps.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/**
2+
* Dependencies module
3+
*
4+
* This file centralizes all external ESM dependencies to make them easier to manage
5+
* and update. It also allows for potential future bundling or local hosting of these
6+
* dependencies if needed.
7+
*/
8+
9+
// Import and re-export spa-router
10+
export { Router, transitions, renderer, componentLoader } from 'https://esm.sh/@profullstack/[email protected]';
11+
12+
// Import and re-export state-manager
13+
export { createStore, StoreConnector } from 'https://esm.sh/@profullstack/[email protected]';
14+
15+
// Import and re-export localizer
16+
export { localizer, _t } from 'https://esm.sh/@profullstack/[email protected]';

public/js/i18n-setup.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* Uses the enhanced @profullstack/localizer module
44
*/
55

6-
import { localizer } from 'https://esm.sh/@profullstack/[email protected]';
6+
import { localizer } from './deps.js';
77

88
// Available languages
99
const AVAILABLE_LANGUAGES = ['en', 'fr', 'de', 'uk', 'ru', 'pl', 'zh', 'ja', 'ar'];

public/js/i18n.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
// Import the localizer library
88
// In production, this would be imported from the npm package
99
// import { localizer, _t } from '@profullstack/localizer';
10-
// For development, we'll use ESM imports
11-
import { localizer, _t } from 'https://esm.sh/@profullstack/[email protected]';
10+
// For development, we'll use our deps.js file
11+
import { localizer, _t } from './deps.js';
1212
import defaultStateManager from './state-manager.js';
1313

1414
// Store available languages

public/js/main.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,8 @@ function initRouter() {
7373
window.router = router;
7474
}
7575

76-
// Import utilities from spa-router
77-
import { componentLoader } from 'https://esm.sh/@profullstack/[email protected]';
76+
// Import utilities from deps.js
77+
import { componentLoader } from './deps.js';
7878
import {
7979
initLoginPage,
8080
initRegisterPage,

public/js/router.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* Router module for SPA navigation
33
*/
4-
import { Router, transitions, renderer, componentLoader } from 'https://esm.sh/@profullstack/[email protected]';
4+
import { Router, transitions, renderer, componentLoader } from './deps.js';
55
import { localizer } from './i18n-setup.js';
66
import {
77
initLoginPage,

public/views/dashboard.html

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,6 @@ <h3>Excel Options</h3>
390390
.dashboard-tabs {
391391
display: flex;
392392
margin-bottom: 20px;
393-
border-bottom: 1px solid #ddd;
394393
}
395394

396395
.tab-button {

0 commit comments

Comments
 (0)