generated from SolidWorx/project-template
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into dependabot/composer/phpstan/phpstan-1.12.6
- Loading branch information
Showing
95 changed files
with
5,009 additions
and
859 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,7 +24,7 @@ APP_SECRET=47b97ece4477939b634285f38da2e0fc | |
# IMPORTANT: You MUST configure your server version, either here or in config/packages/doctrine.yaml | ||
# | ||
DATABASE_URL="sqlite:///%kernel.project_dir%/var/data.db" | ||
# DATABASE_URL="mysql://app:!ChangeMe!@127.0.0.1:3306/app?serverVersion=8.0.32&charset=utf8mb4" | ||
# DATABASE_URL="mysql://127.0.0.1:3306/SolidTrack?serverVersion=8.0.32&charset=utf8mb4" | ||
# DATABASE_URL="mysql://app:[email protected]:3306/app?serverVersion=10.11.2-MariaDB&charset=utf8mb4" | ||
# DATABASE_URL="postgresql://app:[email protected]:5432/app?serverVersion=15&charset=utf8" | ||
###< doctrine/doctrine-bundle ### | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,2 @@ | ||
import './bootstrap.js'; | ||
/* | ||
* Welcome to your app's main JavaScript file! | ||
* | ||
* This file will be included onto the page via the importmap() Twig function, | ||
* which should already be in your base.html.twig. | ||
*/ | ||
import './styles/app.css' | ||
|
||
console.log('This log comes from assets/app.js - welcome to AssetMapper! 🎉') | ||
import './styles/app.scss' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
import { Controller } from '@hotwired/stimulus'; | ||
|
||
export default class extends Controller { | ||
connect() { | ||
this.element.addEventListener('chartjs:pre-connect', this._onPreConnect); | ||
this.element.addEventListener('chartjs:connect', this._onConnect); | ||
} | ||
|
||
disconnect() { | ||
// You should always remove listeners when the controller is disconnected to avoid side effects | ||
this.element.removeEventListener('chartjs:pre-connect', this._onPreConnect); | ||
this.element.removeEventListener('chartjs:connect', this._onConnect); | ||
} | ||
|
||
_onPreConnect(event) { | ||
// The chart is not yet created | ||
// You can access the config that will be passed to "new Chart()" | ||
console.log(event.detail.config); | ||
|
||
// For instance you can format Y axis | ||
// To avoid overriding existing config, you should distinguish 3 cases: | ||
// # 1. No existing scales config => add a new scales config | ||
event.detail.config.options.scales = { | ||
y: { | ||
ticks: { | ||
callback: function (value, index, values) { | ||
/* ... */ | ||
console.log({value, index, values}) | ||
}, | ||
}, | ||
}, | ||
}; | ||
// # 2. Existing scales config without Y axis config => add new Y axis config | ||
event.detail.config.options.scales.y = { | ||
ticks: { | ||
callback: function (value, index, values) { | ||
/* ... */ | ||
console.log({value, index, values}) | ||
}, | ||
}, | ||
}; | ||
// # 3. Existing Y axis config => update it | ||
event.detail.config.options.scales.y.ticks = { | ||
callback: function (value, index, values) { | ||
/* ... */ | ||
console.log({value, index, values}) | ||
}, | ||
}; | ||
} | ||
|
||
_onConnect(event) { | ||
// The chart was just created | ||
console.log(event.detail.chart); // You can access the chart instance using the event details | ||
|
||
// For instance you can listen to additional events | ||
event.detail.chart.options.onHover = (mouseEvent) => { | ||
/* ... */ | ||
}; | ||
event.detail.chart.options.onClick = (mouseEvent) => { | ||
/* ... */ | ||
}; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
import { Controller } from '@hotwired/stimulus'; | ||
|
||
/* stimulusFetch: 'lazy' */ | ||
export default class extends Controller { | ||
static targets = [ 'timer' ] | ||
|
||
static values = { | ||
time: Number | ||
} | ||
|
||
declare timerTarget: HTMLElement | ||
declare timeValue: number | ||
|
||
private timerInterval: any | ||
|
||
private readonly MILLIS_PER_SECOND = 1000; | ||
|
||
connect() { | ||
this.start() | ||
} | ||
|
||
disconnect() { | ||
clearInterval(this.timerInterval); | ||
} | ||
|
||
start() { | ||
this.update(); | ||
this.timerInterval = setInterval(this.update.bind(this), this.MILLIS_PER_SECOND); | ||
} | ||
|
||
update() { | ||
const currentTime = new Date().getTime(); // get current time in milliseconds | ||
const elapsedTime = currentTime - this.timeValue; // calculate elapsed time in milliseconds | ||
const seconds = Math.floor(elapsedTime / this.MILLIS_PER_SECOND) % 60; // calculate seconds | ||
const minutes = Math.floor(elapsedTime / this.MILLIS_PER_SECOND / 60) % 60; // calculate minutes | ||
const hours = Math.floor(elapsedTime / this.MILLIS_PER_SECOND / 60 / 60); // calculate hours | ||
|
||
this.timerTarget.innerHTML = this.pad(hours) + ":" + this.pad(minutes) + ":" + this.pad(seconds); // update the display | ||
} | ||
|
||
pad(number: number) { | ||
return (number < 10 ? "0" : "") + number; | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
@import '@tabler/core'; | ||
@import '@tabler/core/src/scss/vendor/tom-select'; | ||
|
||
:root { | ||
--tblr-font-sans-serif: 'Inter'; | ||
--tblr-nav-link-font-size: 1.2rem; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.