mirror of
https://github.com/HolgerHatGarKeineNode/einundzwanzig-nostr.git
synced 2025-12-13 05:26:47 +00:00
- Added the `simplesoftwareio/simple-qrcode` package to the project - Created a new JavaScript file `nostrZap.js` to handle Nostr events - Added the `nostrZap` function to the Alpine.js data property in `app.js` - Updated the `services.php` configuration file to include the `nostr` environment variable - Created a new database migration to add a `payment_event` field to the `einundzwanzig_plebs` table - Made adjustments in the `Election:year.blade.php` view file to handle potential null values - Updated `composer.lock` and `package.json` with the new dependencies
27 lines
859 B
JavaScript
27 lines
859 B
JavaScript
import {Alpine, Livewire} from '../../vendor/livewire/livewire/dist/livewire.esm';
|
|
|
|
import nostrApp from "./nostrApp.js";
|
|
import nostrLogin from "./nostrLogin.js";
|
|
import nostrZap from "./nostrZap.js";
|
|
import electionAdminCharts from "./electionAdminCharts.js";
|
|
|
|
import './bootstrap';
|
|
|
|
// Light switcher
|
|
document.querySelectorAll('.light-switch').forEach(lightSwitch => lightSwitch.checked = true);
|
|
document.documentElement.classList.add('dark');
|
|
document.querySelector('html').style.colorScheme = 'dark';
|
|
localStorage.setItem('dark-mode', true);
|
|
document.dispatchEvent(new CustomEvent('darkMode', { detail: { mode: 'on' } }));
|
|
|
|
Alpine.store('nostr', {
|
|
user: null,
|
|
});
|
|
|
|
Alpine.data('nostrApp', nostrApp);
|
|
Alpine.data('nostrLogin', nostrLogin);
|
|
Alpine.data('nostrZap', nostrZap);
|
|
Alpine.data('electionAdminCharts', electionAdminCharts);
|
|
|
|
Livewire.start();
|