Use resolves
This commit is contained in:
@@ -19,7 +19,7 @@ module.exports = (env, argv) => {
|
|||||||
devtool: isDev ? 'inline-source-map' : false,
|
devtool: isDev ? 'inline-source-map' : false,
|
||||||
watch: isDev,
|
watch: isDev,
|
||||||
entry: {
|
entry: {
|
||||||
app: path.resolve(SRC, 'scripts', 'app.js')
|
app: path.resolve(SRC, 'app.js')
|
||||||
},
|
},
|
||||||
output: {
|
output: {
|
||||||
path: DIST,
|
path: DIST,
|
||||||
@@ -93,9 +93,11 @@ module.exports = (env, argv) => {
|
|||||||
new VueLoaderPlugin()
|
new VueLoaderPlugin()
|
||||||
],
|
],
|
||||||
resolve: {
|
resolve: {
|
||||||
extensions: ['.js', '.vue', '...'],
|
extensions: ['.vue', '.scss', '...'],
|
||||||
alias: {
|
alias: {
|
||||||
'@scripts': path.resolve(SRC, 'scripts')
|
'@components': path.resolve(SRC, 'components'),
|
||||||
|
'@scripts': path.resolve(SRC, 'scripts'),
|
||||||
|
'@styles': path.resolve(SRC, 'styles')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import Project from './components/project.vue';
|
import Project from '@components/project';
|
||||||
import Admin from './components/admin.vue';
|
import Admin from '@components/admin';
|
||||||
import Upload from './components/upload.vue';
|
import Upload from '@components/upload';
|
||||||
|
|
||||||
const aoRoutes = {
|
const aoRoutes = {
|
||||||
'project': Project,
|
'project': Project,
|
||||||
|
|||||||
@@ -1,15 +1,15 @@
|
|||||||
//Librairies
|
//Librairies
|
||||||
import Api from './api.js';
|
import Api from '@scripts/api';
|
||||||
import Lang from './lang.js';
|
import Lang from '@scripts/lang';
|
||||||
import Projects from './projects.js';
|
import Projects from '@scripts/projects';
|
||||||
import User from './user.js';
|
import User from '@scripts/user';
|
||||||
import { createApp } from 'vue';
|
import { createApp } from 'vue';
|
||||||
|
|
||||||
//Main template
|
//Main template
|
||||||
import Spot from '../Spot.vue';
|
import Spot from './Spot';
|
||||||
|
|
||||||
//Style
|
//Style
|
||||||
import Css from './../styles/spot.scss';
|
import Css from '@styles/spot';
|
||||||
|
|
||||||
//App Configuration from PHP
|
//App Configuration from PHP
|
||||||
const appConfig = JSON.parse(document.getElementById('app-config').textContent);
|
const appConfig = JSON.parse(document.getElementById('app-config').textContent);
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import SpotIcon from './spotIcon.vue';
|
import SpotIcon from '@components/spotIcon';
|
||||||
import SpotButton from './spotButton.vue';
|
import SpotButton from '@components/spotButton';
|
||||||
import AdminInput from './adminInput.vue';
|
import AdminInput from '@components/adminInput';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -4,14 +4,14 @@ import { Map, NavigationControl, Marker, LngLatBounds, LngLat, Popup } from 'map
|
|||||||
import { createApp, ref, provide, inject } from 'vue';
|
import { createApp, ref, provide, inject } from 'vue';
|
||||||
import Simplebar from 'simplebar-vue';
|
import Simplebar from 'simplebar-vue';
|
||||||
|
|
||||||
import lightbox from '../scripts/lightbox.js';
|
import lightbox from '@scripts/lightbox';
|
||||||
import { getOuterWidth } from '../scripts/common.js';
|
import { getOuterWidth } from '@scripts/common';
|
||||||
|
|
||||||
import SpotIcon from './spotIcon.vue';
|
import SpotIcon from '@components/spotIcon';
|
||||||
import SpotIconStack from './spotIconStack.vue';
|
import SpotIconStack from '@components/spotIconStack';
|
||||||
import SpotButton from './spotButton.vue';
|
import SpotButton from '@components/spotButton';
|
||||||
import ProjectPost from './projectPost.vue';
|
import ProjectPost from '@components/projectPost';
|
||||||
import ProjectPopup from './projectPopup.vue';
|
import ProjectPopup from '@components/projectPopup';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<script>
|
<script>
|
||||||
import spotIcon from './spotIcon.vue';
|
import spotIcon from '@components/spotIcon';
|
||||||
import projectRelTime from './projectRelTime.vue';
|
import projectRelTime from '@components/projectRelTime';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -1,9 +1,9 @@
|
|||||||
<script>
|
<script>
|
||||||
import projectMapLink from './projectMapLink.vue';
|
import projectMapLink from '@components/projectMapLink';
|
||||||
import spotIcon from './spotIcon.vue';
|
import spotIcon from '@components/spotIcon';
|
||||||
import projectRelTime from './projectRelTime.vue';
|
import projectRelTime from '@components/projectRelTime';
|
||||||
import projectMediaLink from './projectMediaLink.vue';
|
import projectMediaLink from '@components/projectMediaLink';
|
||||||
import { options } from '../scripts/lightbox';
|
import { options } from '@scripts/lightbox';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
<script>
|
<script>
|
||||||
import spotIcon from './spotIcon.vue';
|
import spotIcon from '@components/spotIcon';
|
||||||
import spotIconStack from './spotIconStack.vue';
|
import spotIconStack from '@components/spotIconStack';
|
||||||
import spotButton from './spotButton.vue';
|
import spotButton from '@components/spotButton';
|
||||||
import projectMediaLink from './projectMediaLink.vue';
|
import projectMediaLink from '@components/projectMediaLink';
|
||||||
import projectMapLink from './projectMapLink.vue';
|
import projectMapLink from '@components/projectMapLink';
|
||||||
import projectRelTime from './projectRelTime.vue';
|
import projectRelTime from '@components/projectRelTime';
|
||||||
import { LngLat } from 'maplibre-gl';
|
import { LngLat } from 'maplibre-gl';
|
||||||
import { copyTextToClipboard } from '../scripts/common.js';
|
import { copyTextToClipboard } from '@scripts/common';
|
||||||
|
|
||||||
import autosize from 'autosize';
|
import autosize from 'autosize';
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<script>
|
<script>
|
||||||
import spotIcon from './spotIcon.vue';
|
import spotIcon from '@components/spotIcon';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<script>
|
<script>
|
||||||
import SpotIcon from './spotIcon.vue';
|
import SpotIcon from '@components/spotIcon';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<script>
|
<script>
|
||||||
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome';
|
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome';
|
||||||
import { getIcon } from '../scripts/icons.js';
|
import { getIcon } from '@scripts/icons';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
@@ -55,3 +55,17 @@ export default {
|
|||||||
</span>
|
</span>
|
||||||
<FontAwesomeIcon v-else :icon="iconDefinition" :class="classNames" :fixed-width="resolvedFixedWidth" :width-auto="resolvedAutoWidth" :size="resolvedSize" :transform="resolvedTransform" />
|
<FontAwesomeIcon v-else :icon="iconDefinition" :class="classNames" :fixed-width="resolvedFixedWidth" :width-auto="resolvedAutoWidth" :size="resolvedSize" :transform="resolvedTransform" />
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
@use "@styles/var";
|
||||||
|
|
||||||
|
.spot-icon {
|
||||||
|
&.margin-right {
|
||||||
|
margin-right: var.$elem-spacing;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.margin-left {
|
||||||
|
margin-left: var.$elem-spacing;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<script>
|
<script>
|
||||||
import { FontAwesomeLayers } from '@fortawesome/vue-fontawesome';
|
import { FontAwesomeLayers } from '@fortawesome/vue-fontawesome';
|
||||||
import spotIcon from './spotIcon.vue';
|
import spotIcon from '@components/spotIcon';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -4,8 +4,8 @@ import Uppy from '@uppy/core';
|
|||||||
import XHRUpload from '@uppy/xhr-upload';
|
import XHRUpload from '@uppy/xhr-upload';
|
||||||
import '@uppy/core/css/style.min.css';
|
import '@uppy/core/css/style.min.css';
|
||||||
|
|
||||||
import SpotIcon from './spotIcon.vue';
|
import SpotIcon from '@components/spotIcon';
|
||||||
import SpotButton from './spotButton.vue';
|
import SpotButton from '@components/spotButton';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'upload',
|
name: 'upload',
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { getDragPosition } from './common.js';
|
import { getDragPosition } from '@scripts/common';
|
||||||
|
|
||||||
$.prototype.defaultVal = function(sDefaultValue)
|
$.prototype.defaultVal = function(sDefaultValue)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import { icon } from '@fortawesome/fontawesome-svg-core';
|
import { icon } from '@fortawesome/fontawesome-svg-core';
|
||||||
import { getIcon } from './icons.js';
|
import { getIcon } from '@scripts/icons';
|
||||||
|
|
||||||
const defaults = {
|
const defaults = {
|
||||||
albumLabel: 'Image %1 of %2',
|
albumLabel: 'Image %1 of %2',
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
/* Animations */
|
/* Animations */
|
||||||
|
|
||||||
|
|||||||
@@ -1,11 +0,0 @@
|
|||||||
@use "var";
|
|
||||||
|
|
||||||
.spot-icon {
|
|
||||||
&.margin-right {
|
|
||||||
margin-right: var.$elem-spacing;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.margin-left {
|
|
||||||
margin-left: var.$elem-spacing;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
@use "common";
|
@use "@styles/common";
|
||||||
@use "var";
|
@use "@styles/var";
|
||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
body.lb-disable-scrolling {
|
body.lb-disable-scrolling {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
@use "var";
|
@use "@styles/var";
|
||||||
|
|
||||||
@media only screen and (max-width: 800px) {
|
@media only screen and (max-width: 800px) {
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
@use "var";
|
@use "@styles/var";
|
||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
#admin {
|
#admin {
|
||||||
margin: 1em;
|
margin: 1em;
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
@use "var";
|
@use "@styles/var";
|
||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
#feed {
|
#feed {
|
||||||
#feed-panel {
|
#feed-panel {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
@use "common";
|
@use "@styles/common";
|
||||||
@use "var";
|
@use "@styles/var";
|
||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
$thumbnail-max-size: 60px;
|
$thumbnail-max-size: 60px;
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
@use "common";
|
@use "@styles/common";
|
||||||
@use "var";
|
@use "@styles/var";
|
||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
$panel-width: 30vw;
|
$panel-width: 30vw;
|
||||||
$panel-width-max: "400px + 3 * #{var.$block-spacing}";
|
$panel-width-max: "400px + 3 * #{var.$block-spacing}";
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
@use "var";
|
@use "@styles/var";
|
||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
@use 'page.project.map' as map;
|
@use '@styles/page.project.map' as map;
|
||||||
@use 'page.project.panel' as panel;
|
@use '@styles/page.project.panel' as panel;
|
||||||
@use 'page.project.feed' as feed;
|
@use '@styles/page.project.feed' as feed;
|
||||||
@use 'page.project.settings' as settings;
|
@use '@styles/page.project.settings' as settings;
|
||||||
|
|
||||||
#projects {
|
#projects {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
@use "common";
|
@use "@styles/common";
|
||||||
@use "var";
|
@use "@styles/var";
|
||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
#settings {
|
#settings {
|
||||||
#settings-panel {
|
#settings-panel {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
@use "var";
|
@use "@styles/var";
|
||||||
@use "color";
|
@use "@styles/color";
|
||||||
|
|
||||||
#upload {
|
#upload {
|
||||||
padding: 1em;
|
padding: 1em;
|
||||||
|
|||||||
@@ -1,16 +1,15 @@
|
|||||||
/* Site Global CSS */
|
/* Site Global CSS */
|
||||||
@use "sass:meta";
|
@use "sass:meta";
|
||||||
@use 'common';
|
@use '@styles/common';
|
||||||
|
|
||||||
/* Modules */
|
/* Modules */
|
||||||
@use 'fa';
|
@use '@styles/lightbox';
|
||||||
@use 'lightbox';
|
@import 'simplebar-vue/dist/simplebar.min.css';
|
||||||
@import '../../node_modules/simplebar-vue/dist/simplebar.min.css';
|
@include meta.load-css('@styles/vue');
|
||||||
@include meta.load-css('vue');
|
|
||||||
|
|
||||||
/* Pages Specific CSS */
|
/* Pages Specific CSS */
|
||||||
@include meta.load-css('page.project');
|
@include meta.load-css('@styles/page.project');
|
||||||
@include meta.load-css('page.upload');
|
@include meta.load-css('@styles/page.upload');
|
||||||
@include meta.load-css('page.admin');
|
@include meta.load-css('@styles/page.admin');
|
||||||
|
|
||||||
@include meta.load-css('mobile');
|
@include meta.load-css('@styles/mobile');
|
||||||
Reference in New Issue
Block a user