...
 
Commits (4)
This diff is collapsed.
......@@ -13,38 +13,38 @@
"author": "Paolo Barbolini",
"license": "MIT",
"dependencies": {
"@sentry/browser": "^4.4.0",
"core-js": "^2.5.7",
"pdfjs-dist": "^2.0.489",
"@sentry/browser": "^4.6.4",
"core-js": "^3.0.0",
"pdfjs-dist": "^2.0.943",
"request-idle-polyfill": "^1.0.1",
"serviceworker-webpack-plugin": "^1.0.1",
"vue": "^2.5.17",
"vue-awesome": "^3.2.0",
"vue-router": "^3.0.1",
"vue-timers": "^1.7.3"
"vue": "^2.6.10",
"vue-awesome": "^3.5.0",
"vue-router": "^3.0.2",
"vue-timers": "^1.10.0"
},
"devDependencies": {
"@vue/test-utils": "^1.0.0-beta.25",
"@vue/test-utils": "^1.0.0-beta.29",
"babel-eslint": "^10.0.1",
"clean-webpack-plugin": "^0.1.19",
"copy-webpack-plugin": "^4.5.3",
"css-loader": "^1.0.0",
"eslint": "^5.7.0",
"eslint-config-google": "^0.11.0",
"eslint-loader": "^2.1.1",
"eslint-plugin-vue": "^4.7.1",
"clean-webpack-plugin": "^2.0.1",
"copy-webpack-plugin": "^5.0.1",
"css-loader": "^2.1.1",
"eslint": "^5.15.3",
"eslint-config-google": "^0.12.0",
"eslint-loader": "^2.1.2",
"eslint-plugin-vue": "^5.2.2",
"html-webpack-plugin": "^3.2.0",
"mini-css-extract-plugin": "^0.4.4",
"node-sass": "^4.9.4",
"mini-css-extract-plugin": "^0.5.0",
"node-sass": "^4.11.0",
"optimize-css-assets-webpack-plugin": "^5.0.1",
"sass-loader": "^7.1.0",
"terser-webpack-plugin": "^1.1.0",
"vue-loader": "^15.4.2",
"vue-server-renderer": "^2.5.17",
"vue-template-compiler": "^2.5.17",
"webpack": "^4.20.2",
"webpack-cli": "^3.1.2",
"webpack-dev-server": "^3.1.14",
"webpack-merge": "^4.1.4"
"terser-webpack-plugin": "^1.2.3",
"vue-loader": "^15.7.0",
"vue-server-renderer": "^2.6.10",
"vue-template-compiler": "^2.6.10",
"webpack": "^4.29.6",
"webpack-cli": "^3.3.0",
"webpack-dev-server": "^3.2.1",
"webpack-merge": "^4.2.1"
}
}
......@@ -6,7 +6,8 @@
:key="item.name"
:name="item.title"
:filter="filter"
:to="{ name: 'post', params: { id: item.id }}" />
:to="{ name: 'post', params: { id: item.id }}"
/>
</ul>
</div>
</template>
......
<template>
<li
v-show="visible"
class="column-item">
class="column-item"
>
<router-link
:to="to"
v-html="displayName" />
v-html="displayName"
/>
</li>
</template>
......
......@@ -2,7 +2,8 @@
<div class="offline-page">
<icon
name="hammer"
scale="3" />
scale="3"
/>
<p>
Al momento sei offline,
......
<template>
<div
v-if="pdf"
class="pdf">
class="pdf"
>
<pdf-page
v-for="page in pdf.numPages"
:key="page"
:pdf="pdf"
:page="page" />
:page="page"
/>
</div>
</template>
......
<template>
<div
ref="pdfPage"
class="pdf-page" />
class="pdf-page"
/>
</template>
<script>
......
<template>
<div
v-show="visible"
class="schedule-column">
class="schedule-column"
>
<h3 class="center">
{{ name }}
</h3>
......@@ -12,7 +13,8 @@
:key="item.name"
:name="item.name"
:filter="filter"
:to="{ name: 'schedule', params: { type: type, name: item.name }}" />
:to="{ name: 'schedule', params: { type: type, name: item.name }}"
/>
</ul>
</div>
</template>
......
......@@ -5,19 +5,22 @@
:items="classes"
:filter="filter"
name="Classi"
type="classi" />
type="classi"
/>
<schedule-column
:items="teachers"
:filter="filter"
name="Docenti"
type="docenti" />
type="docenti"
/>
<schedule-column
:items="classrooms"
:filter="filter"
name="Aule"
type="aule" />
type="aule"
/>
</div>
</div>
</template>
......
......@@ -6,13 +6,15 @@
<div
class="search"
@click="searchVisible = true">
@click="searchVisible = true"
>
<icon name="search" />
</div>
<div
:class="{ 'active': searchVisible }"
class="search-bar">
class="search-bar"
>
<div @click="searchVisible = false">
<icon name="arrow-left" />
</div>
......@@ -23,7 +25,8 @@
type="text"
placeholder="Cerca"
@keyup.enter="blurSearch()"
@keyup.esc="searchVisible = false">
@keyup.esc="searchVisible = false"
>
</div>
</div>
</template>
......
......@@ -65,16 +65,19 @@
Icona fornita da
<a
href="https://www.freepik.com"
title="Freepik">Freepik</a>
title="Freepik"
>Freepik</a>
tramite
<a
href="https://www.flaticon.com/"
title="Flaticon">flaticon.com</a>
title="Flaticon"
>flaticon.com</a>
sotto licenza
<a
href="https://creativecommons.org/licenses/by/3.0/deed.it"
title="Creative Commons BY 3.0"
target="_blank">CC 3.0 BY</a>
target="_blank"
>CC 3.0 BY</a>
</p>
<!-- https://www.flaticon.com/free-icon/time-zone_806237#term=clock&page=2&position=35 -->
</div>
......
......@@ -4,10 +4,12 @@
<div
:class="{ 'pdf-container': loaded && !offline }"
class="container">
class="container"
>
<p
v-if="loaded && !pdfUrl"
class="bold center no-pdf">
class="bold center no-pdf"
>
Questo articolo non contiene un pdf.<br>
<a :href="articleUrl">Vai all'articolo</a>
</p>
......@@ -16,10 +18,12 @@
v-if="loaded"
:url="pdfUrl"
class="article"
@pdf-loaded="pdfLoaded = true" />
@pdf-loaded="pdfLoaded = true"
/>
<loading
v-else
:offline="offline" />
:offline="offline"
/>
</div>
</div>
</template>
......@@ -27,7 +31,6 @@
<script>
import TopHeading from '@/components/TopHeading';
import Loading from '@/components/Loading';
import Offline from '@/components/Offline';
const Pdf = () => import(/* webpackChunkName: "pdf" */ '@/components/Pdf');
......@@ -38,7 +41,6 @@ export default {
TopHeading,
Loading,
Pdf,
Offline,
},
props: {
......
......@@ -2,16 +2,19 @@
<div class="articles-page">
<top-heading
:last-update="loaded ? items.date : null"
title="Avvisi" />
title="Avvisi"
/>
<div class="container clear-container">
<article-columns
v-if="loaded"
:items="items.posts || []"
:filter="searchQuery" />
:filter="searchQuery"
/>
<loading
v-else
:offline="offline" />
:offline="offline"
/>
</div>
</div>
</template>
......@@ -20,7 +23,6 @@
import TopHeading from '@/components/TopHeading';
import Loading from '@/components/Loading';
import ArticleColumns from '@/components/ArticleColumns';
import Offline from '@/components/Offline';
import IstitutoGobetti from '@/istitutogobetti';
......@@ -29,7 +31,6 @@ export default {
TopHeading,
Loading,
ArticleColumns,
Offline,
},
props: {
......
......@@ -2,17 +2,20 @@
<div class="schedule-page">
<top-heading
:last-update="loaded ? item.date : null"
:title="name || 'Orario'" />
:title="name || 'Orario'"
/>
<div class="last-container">
<div
v-if="loaded"
ref="schedule"
class="schedule"
v-html="schedule" />
v-html="schedule"
/>
<loading
v-else
:offline="offline" />
:offline="offline"
/>
</div>
</div>
</template>
......@@ -20,8 +23,6 @@
<script>
import TopHeading from '@/components/TopHeading';
import Loading from '@/components/Loading';
import ScheduleColumns from '@/components/ScheduleColumns';
import Offline from '@/components/Offline';
import IstitutoGobetti from '@/istitutogobetti';
import DB from '@/db';
......@@ -30,8 +31,6 @@ export default {
components: {
TopHeading,
Loading,
ScheduleColumns,
Offline,
},
props: {
......
......@@ -3,7 +3,8 @@
<top-heading
:last-update="loaded ? items.date : null"
:offline="offline"
title="Orari" />
title="Orari"
/>
<div class="container clear-container">
<ul class="highlighted-schedules">
......@@ -13,16 +14,19 @@
:name="item.name"
:filter="searchQuery"
:to="{ name: 'schedule',
params: { type: item.type, name: item.name }}" />
params: { type: item.type, name: item.name }}"
/>
</ul>
<schedule-columns
v-if="loaded"
:items="items.items || []"
:filter="searchQuery" />
:filter="searchQuery"
/>
<loading
v-else
:offline="offline" />
:offline="offline"
/>
</div>
</div>
</template>
......@@ -32,7 +36,6 @@ import TopHeading from '@/components/TopHeading';
import Loading from '@/components/Loading';
import ScheduleColumns from '@/components/ScheduleColumns';
import ColumnItem from '@/components/ColumnItem';
import Offline from '@/components/Offline';
import IstitutoGobetti from '@/istitutogobetti';
import DB from '@/db';
......@@ -43,7 +46,6 @@ export default {
Loading,
ScheduleColumns,
ColumnItem,
Offline,
},
props: {
......
......@@ -28,8 +28,6 @@ self.addEventListener('install', (event) => {
});
self.addEventListener('activate', (event) => {
self.clients.claim();
event.waitUntil(
caches.keys().then((cacheNames) => {
return Promise.all(
......@@ -39,7 +37,7 @@ self.addEventListener('activate', (event) => {
}
})
);
})
}).then(self.clients.claim())
);
});
......
import 'core-js/fn/symbol/iterator.js'; // Edge browser sucks
import 'core-js/features/symbol/iterator.js'; // Edge browser sucks
const corsProxies = [
'https://cors.paolo565.org/',
......