spr migrated books, and tester
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Soleprint Wrapper - Development Tools Sidebar
|
||||
# Pawprint Wrapper - Development Tools Sidebar
|
||||
|
||||
A collapsible sidebar that provides development and testing tools for any soleprint-managed room (like amar) without interfering with the managed application.
|
||||
A collapsible sidebar that provides development and testing tools for any pawprint-managed nest (like amar) without interfering with the managed application.
|
||||
|
||||
## Features
|
||||
|
||||
@@ -12,7 +12,7 @@ A collapsible sidebar that provides development and testing tools for any solepr
|
||||
|
||||
### 🌍 Environment Info
|
||||
- Display backend and frontend URLs
|
||||
- Room name and deployment info
|
||||
- Nest name and deployment info
|
||||
- Quick reference during development
|
||||
|
||||
### ⌨️ Keyboard Shortcuts
|
||||
@@ -40,7 +40,7 @@ wrapper/
|
||||
Open `index.html` in your browser to see the sidebar in action:
|
||||
|
||||
```bash
|
||||
cd core_room/wrapper
|
||||
cd core_nest/wrapper
|
||||
python3 -m http.server 8080
|
||||
# Open http://localhost:8080
|
||||
```
|
||||
@@ -68,7 +68,7 @@ Edit `config.json` to customize:
|
||||
|
||||
```json
|
||||
{
|
||||
"room_name": "amar",
|
||||
"nest_name": "amar",
|
||||
"wrapper": {
|
||||
"enabled": true,
|
||||
"environment": {
|
||||
@@ -208,10 +208,10 @@ getSidebarHTML() {
|
||||
|
||||
### Add New Features
|
||||
|
||||
Extend the `SoleprintSidebar` class in `sidebar.js`:
|
||||
Extend the `PawprintSidebar` class in `sidebar.js`:
|
||||
|
||||
```javascript
|
||||
class SoleprintSidebar {
|
||||
class PawprintSidebar {
|
||||
async fetchJiraInfo() {
|
||||
const response = await fetch('https://artery.mcrn.ar/jira/VET-123');
|
||||
const data = await response.json();
|
||||
@@ -294,8 +294,8 @@ Planned features (see `../WRAPPER_DESIGN.md`):
|
||||
## Related Documentation
|
||||
|
||||
- `../WRAPPER_DESIGN.md` - Complete architecture design
|
||||
- `../../../soleprint/CLAUDE.md` - Soleprint framework overview
|
||||
- `../../README.md` - Core room documentation
|
||||
- `../../../pawprint/CLAUDE.md` - Pawprint framework overview
|
||||
- `../../README.md` - Core nest documentation
|
||||
|
||||
## Contributing
|
||||
|
||||
@@ -303,9 +303,9 @@ To add a new panel or feature:
|
||||
|
||||
1. Add HTML in `getSidebarHTML()`
|
||||
2. Add styling in `sidebar.css`
|
||||
3. Add logic as methods on `SoleprintSidebar` class
|
||||
3. Add logic as methods on `PawprintSidebar` class
|
||||
4. Update this README with usage instructions
|
||||
|
||||
## License
|
||||
|
||||
Part of the Soleprint development tools ecosystem.
|
||||
Part of the Pawprint development tools ecosystem.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Soleprint Wrapper - Demo</title>
|
||||
<title>Pawprint Wrapper - Demo</title>
|
||||
<link rel="stylesheet" href="sidebar.css">
|
||||
<style>
|
||||
/* Demo page styles */
|
||||
@@ -19,7 +19,7 @@
|
||||
transition: margin-right 0.3s ease;
|
||||
}
|
||||
|
||||
#soleprint-sidebar.expanded ~ #demo-content {
|
||||
#pawprint-sidebar.expanded ~ #demo-content {
|
||||
margin-right: var(--sidebar-width);
|
||||
}
|
||||
|
||||
@@ -105,14 +105,14 @@
|
||||
|
||||
<div id="demo-content">
|
||||
<div class="demo-header">
|
||||
<h1>🐾 Soleprint Wrapper</h1>
|
||||
<p>Development tools sidebar for any soleprint-managed room</p>
|
||||
<h1>🐾 Pawprint Wrapper</h1>
|
||||
<p>Development tools sidebar for any pawprint-managed nest</p>
|
||||
</div>
|
||||
|
||||
<div class="demo-section">
|
||||
<h2>👋 Quick Start</h2>
|
||||
<p>
|
||||
This is a standalone demo of the Soleprint Wrapper sidebar.
|
||||
This is a standalone demo of the Pawprint Wrapper sidebar.
|
||||
Click the toggle button on the right edge of the screen, or press
|
||||
<span class="kbd">Ctrl</span> + <span class="kbd">Shift</span> + <span class="kbd">P</span>
|
||||
to open the sidebar.
|
||||
@@ -156,7 +156,7 @@
|
||||
<ul>
|
||||
<li><code>sidebar.css</code> - Visual styling (dark theme, animations)</li>
|
||||
<li><code>sidebar.js</code> - Logic (login, logout, toggle, state management)</li>
|
||||
<li><code>config.json</code> - Configuration (users, URLs, room info)</li>
|
||||
<li><code>config.json</code> - Configuration (users, URLs, nest info)</li>
|
||||
</ul>
|
||||
<p style="margin-top: 16px;">
|
||||
To integrate with your app, simply include these in your HTML:
|
||||
@@ -184,7 +184,7 @@
|
||||
<div class="demo-section">
|
||||
<h2>📚 Documentation</h2>
|
||||
<p>
|
||||
See <code>WRAPPER_DESIGN.md</code> in <code>core_room/</code> for the complete
|
||||
See <code>WRAPPER_DESIGN.md</code> in <code>core_nest/</code> for the complete
|
||||
architecture design, including Docker integration patterns and alternative approaches.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* Soleprint Wrapper - Sidebar Styles */
|
||||
/* Pawprint Wrapper - Sidebar Styles */
|
||||
|
||||
:root {
|
||||
--sidebar-width: 320px;
|
||||
@@ -26,7 +26,7 @@ body {
|
||||
}
|
||||
|
||||
/* Sidebar Container */
|
||||
#soleprint-sidebar {
|
||||
#pawprint-sidebar {
|
||||
position: fixed;
|
||||
right: 0;
|
||||
top: 0;
|
||||
@@ -44,7 +44,7 @@ body {
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
#soleprint-sidebar.expanded {
|
||||
#pawprint-sidebar.expanded {
|
||||
transform: translateX(0);
|
||||
}
|
||||
|
||||
@@ -76,7 +76,7 @@ body {
|
||||
transition: transform 0.3s;
|
||||
}
|
||||
|
||||
#soleprint-sidebar.expanded ~ #sidebar-toggle .icon {
|
||||
#pawprint-sidebar.expanded ~ #sidebar-toggle .icon {
|
||||
transform: scaleX(-1);
|
||||
}
|
||||
|
||||
@@ -94,7 +94,7 @@ body {
|
||||
color: var(--sidebar-accent);
|
||||
}
|
||||
|
||||
.sidebar-header .room-name {
|
||||
.sidebar-header .nest-name {
|
||||
font-size: 12px;
|
||||
opacity: 0.7;
|
||||
text-transform: uppercase;
|
||||
@@ -262,20 +262,20 @@ body {
|
||||
}
|
||||
|
||||
/* Scrollbar */
|
||||
#soleprint-sidebar::-webkit-scrollbar {
|
||||
#pawprint-sidebar::-webkit-scrollbar {
|
||||
width: 8px;
|
||||
}
|
||||
|
||||
#soleprint-sidebar::-webkit-scrollbar-track {
|
||||
#pawprint-sidebar::-webkit-scrollbar-track {
|
||||
background: #1a1a1a;
|
||||
}
|
||||
|
||||
#soleprint-sidebar::-webkit-scrollbar-thumb {
|
||||
#pawprint-sidebar::-webkit-scrollbar-thumb {
|
||||
background: #444;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
#soleprint-sidebar::-webkit-scrollbar-thumb:hover {
|
||||
#pawprint-sidebar::-webkit-scrollbar-thumb:hover {
|
||||
background: #555;
|
||||
}
|
||||
|
||||
@@ -290,7 +290,7 @@ body {
|
||||
|
||||
/* Responsive */
|
||||
@media (max-width: 768px) {
|
||||
#soleprint-sidebar {
|
||||
#pawprint-sidebar {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// Soleprint Wrapper - Sidebar Logic
|
||||
// Pawprint Wrapper - Sidebar Logic
|
||||
|
||||
class SoleprintSidebar {
|
||||
class PawprintSidebar {
|
||||
constructor() {
|
||||
this.config = null;
|
||||
this.currentUser = null;
|
||||
@@ -30,12 +30,12 @@ class SoleprintSidebar {
|
||||
try {
|
||||
const response = await fetch('/wrapper/config.json');
|
||||
this.config = await response.json();
|
||||
console.log('[Soleprint] Config loaded:', this.config.room_name);
|
||||
console.log('[Pawprint] Config loaded:', this.config.nest_name);
|
||||
} catch (error) {
|
||||
console.error('[Soleprint] Failed to load config:', error);
|
||||
console.error('[Pawprint] Failed to load config:', error);
|
||||
// Use default config
|
||||
this.config = {
|
||||
room_name: 'default',
|
||||
nest_name: 'default',
|
||||
wrapper: {
|
||||
environment: {
|
||||
backend_url: 'http://localhost:8000',
|
||||
@@ -49,7 +49,7 @@ class SoleprintSidebar {
|
||||
|
||||
createSidebar() {
|
||||
const sidebar = document.createElement('div');
|
||||
sidebar.id = 'soleprint-sidebar';
|
||||
sidebar.id = 'pawprint-sidebar';
|
||||
sidebar.innerHTML = this.getSidebarHTML();
|
||||
document.body.appendChild(sidebar);
|
||||
this.sidebar = sidebar;
|
||||
@@ -59,7 +59,7 @@ class SoleprintSidebar {
|
||||
const button = document.createElement('button');
|
||||
button.id = 'sidebar-toggle';
|
||||
button.innerHTML = '<span class="icon">◀</span>';
|
||||
button.title = 'Toggle Soleprint Sidebar (Ctrl+Shift+P)';
|
||||
button.title = 'Toggle Pawprint Sidebar (Ctrl+Shift+P)';
|
||||
document.body.appendChild(button);
|
||||
this.toggleBtn = button;
|
||||
}
|
||||
@@ -69,8 +69,8 @@ class SoleprintSidebar {
|
||||
|
||||
return `
|
||||
<div class="sidebar-header">
|
||||
<h2>🐾 Soleprint</h2>
|
||||
<div class="room-name">${this.config.room_name}</div>
|
||||
<h2>🐾 Pawprint</h2>
|
||||
<div class="nest-name">${this.config.nest_name}</div>
|
||||
</div>
|
||||
|
||||
<div class="sidebar-content">
|
||||
@@ -83,7 +83,7 @@ class SoleprintSidebar {
|
||||
<div id="current-user-display" style="display: none;">
|
||||
<div class="current-user">
|
||||
Logged in as: <strong id="current-username"></strong>
|
||||
<button class="logout-btn" onclick="soleprintSidebar.logout()">
|
||||
<button class="logout-btn" onclick="pawprintSidebar.logout()">
|
||||
Logout
|
||||
</button>
|
||||
</div>
|
||||
@@ -91,7 +91,7 @@ class SoleprintSidebar {
|
||||
|
||||
<div class="user-cards">
|
||||
${users.map(user => `
|
||||
<div class="user-card" data-user-id="${user.id}" onclick="soleprintSidebar.loginAs('${user.id}')">
|
||||
<div class="user-card" data-user-id="${user.id}" onclick="pawprintSidebar.loginAs('${user.id}')">
|
||||
<div class="icon">${user.icon}</div>
|
||||
<div class="info">
|
||||
<span class="label">${user.label}</span>
|
||||
@@ -119,7 +119,7 @@ class SoleprintSidebar {
|
||||
</div>
|
||||
|
||||
<div class="sidebar-footer">
|
||||
Soleprint Dev Tools
|
||||
Pawprint Dev Tools
|
||||
</div>
|
||||
`;
|
||||
}
|
||||
@@ -144,11 +144,11 @@ class SoleprintSidebar {
|
||||
|
||||
saveSidebarState() {
|
||||
const isExpanded = this.sidebar.classList.contains('expanded');
|
||||
localStorage.setItem('soleprint_sidebar_expanded', isExpanded);
|
||||
localStorage.setItem('pawprint_sidebar_expanded', isExpanded);
|
||||
}
|
||||
|
||||
loadSidebarState() {
|
||||
const isExpanded = localStorage.getItem('soleprint_sidebar_expanded') === 'true';
|
||||
const isExpanded = localStorage.getItem('pawprint_sidebar_expanded') === 'true';
|
||||
if (isExpanded) {
|
||||
this.sidebar.classList.add('expanded');
|
||||
}
|
||||
@@ -214,7 +214,7 @@ class SoleprintSidebar {
|
||||
}, 1000);
|
||||
|
||||
} catch (error) {
|
||||
console.error('[Soleprint] Login error:', error);
|
||||
console.error('[Pawprint] Login error:', error);
|
||||
this.showStatus(`✗ Login failed: ${error.message}`, 'error');
|
||||
}
|
||||
}
|
||||
@@ -241,7 +241,7 @@ class SoleprintSidebar {
|
||||
this.currentUser = JSON.parse(userInfo);
|
||||
this.updateCurrentUserDisplay();
|
||||
} catch (error) {
|
||||
console.error('[Soleprint] Failed to parse user info:', error);
|
||||
console.error('[Pawprint] Failed to parse user info:', error);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -275,12 +275,12 @@ class SoleprintSidebar {
|
||||
}
|
||||
|
||||
// Initialize sidebar when DOM is ready
|
||||
const soleprintSidebar = new SoleprintSidebar();
|
||||
const pawprintSidebar = new PawprintSidebar();
|
||||
|
||||
if (document.readyState === 'loading') {
|
||||
document.addEventListener('DOMContentLoaded', () => soleprintSidebar.init());
|
||||
document.addEventListener('DOMContentLoaded', () => pawprintSidebar.init());
|
||||
} else {
|
||||
soleprintSidebar.init();
|
||||
pawprintSidebar.init();
|
||||
}
|
||||
|
||||
console.log('[Soleprint] Sidebar script loaded');
|
||||
console.log('[Pawprint] Sidebar script loaded');
|
||||
|
||||
Reference in New Issue
Block a user