Compare commits
54 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6a5ecadbdc | ||
|
|
1bdc8b5692 | ||
|
|
aea3b20ff9 | ||
|
|
ee42a064d2 | ||
|
|
89296804be | ||
|
|
29566f4fae | ||
|
|
93c9c2d307 | ||
|
|
a94c06d893 | ||
|
|
7cd8c065b3 | ||
|
|
d44be3b029 | ||
|
|
3243ebdc2e | ||
|
|
0f69a1583b | ||
|
|
15ab433064 | ||
|
|
4aab9afebd | ||
|
|
e0df578dca | ||
|
|
dd320d3dc4 | ||
|
|
5248cfc12e | ||
|
|
1f34cacf25 | ||
|
|
f35d29f56c | ||
|
|
1429943dbe | ||
|
|
2ca1c9949a | ||
|
|
1086086552 | ||
|
|
c0b5ed3e46 | ||
|
|
430bed67c2 | ||
|
|
f75eff8c09 | ||
|
|
f52017585f | ||
|
|
a40b5db6f9 | ||
|
|
f6a52b73de | ||
|
|
75d6cc4676 | ||
|
|
0dbb3402a8 | ||
|
|
64c54171cb | ||
|
|
3d399ee8be | ||
|
|
431103d2ff | ||
|
|
8c45ee58ea | ||
|
|
0b9897e0eb | ||
|
|
d72a8b519d | ||
|
|
53af1d4c1e | ||
|
|
2329ba2cab | ||
|
|
578da8fb38 | ||
|
|
3275b79adf | ||
|
|
b36adf8ebf | ||
|
|
6d9a45941b | ||
|
|
581c8ba1d5 | ||
|
|
56182279f3 | ||
|
|
33da0de509 | ||
|
|
486f33efcf | ||
|
|
b35154f906 | ||
|
|
f984f9e7a2 | ||
|
|
92e0397c61 | ||
|
|
a26163f41d | ||
|
|
bf1ad731fb | ||
|
|
4ded1cce20 | ||
|
|
5fbe47f5ea | ||
|
|
08203f135b |
119
.github/workflows/build.yml
vendored
@@ -1,71 +1,82 @@
|
|||||||
name: Package and Release Extension
|
name: Build and Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
push:
|
inputs:
|
||||||
branches:
|
version:
|
||||||
- test
|
description: 'Release version (pl. v1.0.0)'
|
||||||
|
required: true
|
||||||
|
default: 'v1.0.0'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-release:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
|
|
||||||
- name: Get current date
|
- name: Set up build directories
|
||||||
id: date
|
|
||||||
run: |
|
run: |
|
||||||
echo "DATE=$(date +'%Y.%m.%d. %H:%M')" >> $GITHUB_ENV
|
mkdir -p build/chrome
|
||||||
echo "DATE_FOR_ZIP=$(date +'%Y%m%d-%H%M')" >> $GITHUB_ENV
|
mkdir -p build/firefox
|
||||||
|
|
||||||
- name: Create ZIP file
|
- name: Copy files – Chrome
|
||||||
run: |
|
run: |
|
||||||
zip -r "pre-firxa-${{ env.DATE_FOR_ZIP }}.zip" . -x "*.git*" "*.github*" "*.idea*"
|
rsync -av \
|
||||||
|
--exclude='.git' \
|
||||||
|
--exclude='.gitea' \
|
||||||
|
--exclude='README*' \
|
||||||
|
--exclude='readme*' \
|
||||||
|
--exclude='LICENSE*' \
|
||||||
|
--exclude='license*' \
|
||||||
|
--exclude='*.md' \
|
||||||
|
--exclude='build/' \
|
||||||
|
. build/chrome/
|
||||||
|
|
||||||
- name: Delete previous pre-release
|
- name: Copy files – Firefox
|
||||||
uses: dev-drprasad/delete-tag-and-release@v0.2.1
|
run: |
|
||||||
with:
|
rsync -av \
|
||||||
delete_release: true
|
--exclude='.git' \
|
||||||
tag_name: pre-release
|
--exclude='.gitea' \
|
||||||
env:
|
--exclude='README*' \
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
--exclude='readme*' \
|
||||||
continue-on-error: true
|
--exclude='LICENSE*' \
|
||||||
|
--exclude='license*' \
|
||||||
|
--exclude='*.md' \
|
||||||
|
--exclude='build/' \
|
||||||
|
. build/firefox/
|
||||||
|
|
||||||
- name: Create new pre-release
|
- name: Prepare Chrome build
|
||||||
id: create_release
|
run: |
|
||||||
uses: softprops/action-gh-release@v1
|
rm -f build/chrome/manifest_fox.json
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
- name: Prepare Firefox build
|
||||||
|
run: |
|
||||||
|
rm -f build/firefox/manifest.json
|
||||||
|
mv build/firefox/manifest_fox.json build/firefox/manifest.json
|
||||||
|
|
||||||
|
- name: Create ZIP archives
|
||||||
|
run: |
|
||||||
|
cd build/chrome
|
||||||
|
zip -r ../../firka-extension-chrome-${{ github.event.inputs.version }}.zip .
|
||||||
|
cd ../firefox
|
||||||
|
zip -r ../../firka-extension-firefox-${{ github.event.inputs.version }}.zip .
|
||||||
|
|
||||||
|
- name: Create Release
|
||||||
|
uses: actions/gitea-release@v1
|
||||||
with:
|
with:
|
||||||
tag_name: pre-release
|
token: ${{ secrets.GITEA_TOKEN }}
|
||||||
release_name: Fejlesztői build
|
tag_name: ${{ github.event.inputs.version }}
|
||||||
|
release_name: ${{ github.event.inputs.version }}
|
||||||
body: |
|
body: |
|
||||||
Ez egy kiadás előtti build, amely minden egyes commit után frissül!
|
## Firka Extension ${{ github.event.inputs.version }}
|
||||||
A build automatikusan készült ekkor: ${{ env.DATE }}
|
|
||||||
|
### Letöltések
|
||||||
|
- **Chrome / Chromium** – `firka-extension-chrome-${{ github.event.inputs.version }}.zip`
|
||||||
|
- **Firefox** – `firka-extension-firefox-${{ github.event.inputs.version }}.zip`
|
||||||
|
files: |
|
||||||
|
firka-extension-chrome-${{ github.event.inputs.version }}.zip
|
||||||
|
firka-extension-firefox-${{ github.event.inputs.version }}.zip
|
||||||
draft: false
|
draft: false
|
||||||
prerelease: true
|
prerelease: false
|
||||||
|
|
||||||
- name: Upload ZIP to release
|
|
||||||
if: steps.create_release.outputs.upload_url != ''
|
|
||||||
uses: actions/upload-release-asset@v1
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
|
||||||
asset_path: ./pre-firxa-${{ env.DATE_FOR_ZIP }}.zip
|
|
||||||
asset_name: pre-firxa-${{ env.DATE_FOR_ZIP }}.zip
|
|
||||||
asset_content_type: application/zip
|
|
||||||
|
|
||||||
check-links:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Link Checker
|
|
||||||
id: lychee
|
|
||||||
uses: lycheeverse/lychee-action@v2
|
|
||||||
with:
|
|
||||||
fail: false
|
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
<p align="center">
|
<p align="center">
|
||||||
<img src="https://i.imgur.com/WugwlzI.png" width="150">
|
<img width="150" height="150" alt="firka_logo_128" src="https://github.com/QwIT-Development/firka-extension/blob/main/images/firka_logo_128.png?raw=true" />
|
||||||
<h1 align="center">Firka extension</h1>
|
<h1 align="center">Firka extension</h1>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
|
||||||
<p align="center">
|
<p align="center">
|
||||||
Modern, testre szabható felhasználói felület az e-KRÉTA rendszerhez
|
Modern, testre szabható felhasználói felület az e-KRÉTA rendszerhez
|
||||||
</p>
|
</p>
|
||||||
@@ -23,8 +24,8 @@
|
|||||||
<a href="https://chromewebstore.google.com/detail/firxa/emafoaifbfppcccgfmpcoheonhjnpldj?hl=hu">
|
<a href="https://chromewebstore.google.com/detail/firxa/emafoaifbfppcccgfmpcoheonhjnpldj?hl=hu">
|
||||||
<img src="https://github.com/QwIT-Development/firka-extension/blob/main/images/chrome.png?raw=true" alt="Elérhető a Chrome Web Store-on" width="200">
|
<img src="https://github.com/QwIT-Development/firka-extension/blob/main/images/chrome.png?raw=true" alt="Elérhető a Chrome Web Store-on" width="200">
|
||||||
</a>
|
</a>
|
||||||
<a href="https://addons.mozilla.org/hu/firefox/addon/firxa/">
|
<a href="https://github.com/QwIT-Development/firka-extension/releases">
|
||||||
<img src="https://github.com/QwIT-Development/firka-extension/blob/main/images/firefox.png?raw=true" alt="Elérhető a Firefox add-ons oldalon" width="200">
|
<img src="https://github.com/QwIT-Development/firka-extension/blob/main/images/firefoxact.png?raw=true" alt="Elérhető a Firefox add-ons oldalon" width="200">
|
||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ async function collectAbsencesData() {
|
|||||||
try {
|
try {
|
||||||
const currentDomain = window.location.hostname;
|
const currentDomain = window.location.hostname;
|
||||||
const response = await fetch(
|
const response = await fetch(
|
||||||
`https://${currentDomain}/api/HianyzasokApi/GetHianyzasGrid?sort=MulasztasDatum-desc&page=1&pageSize=100&group=&filter=&data=%7B%7D&_=${Date.now()}`,
|
`https://${currentDomain}/api/HianyzasokApi/GetHianyzasGrid?sort=MulasztasDatum-desc&page=1&pageSize=500&group=&filter=&data=%7B%7D&_=${Date.now()}`,
|
||||||
{
|
{
|
||||||
method: "GET",
|
method: "GET",
|
||||||
credentials: "include",
|
credentials: "include",
|
||||||
@@ -45,592 +45,449 @@ async function collectAbsencesData() {
|
|||||||
justificationStatus = "unjustified";
|
justificationStatus = "unjustified";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const absenceType = item.MulasztasTipus === 1500 ? 'absence' : item.MulasztasTipus === 1499 ? 'late' : 'other';
|
||||||
|
|
||||||
absences.push({
|
absences.push({
|
||||||
date: formattedDate,
|
date: formattedDate,
|
||||||
|
rawDate: date,
|
||||||
|
dateKey: `${date.getFullYear()}-${(date.getMonth() + 1).toString().padStart(2, "0")}-${date.getDate().toString().padStart(2, "0")}`,
|
||||||
lesson: item.Oraszam?.toString() || "",
|
lesson: item.Oraszam?.toString() || "",
|
||||||
subject: item.Targy || "",
|
subject: item.Targy || "",
|
||||||
topic: item.Tema || "",
|
topic: item.Tema || "",
|
||||||
type: item.MulasztasTipus_DNAME || "",
|
type: item.MulasztasTipus_DNAME || "",
|
||||||
|
absenceType: absenceType,
|
||||||
|
absenceTypeId: item.MulasztasTipus,
|
||||||
justified: item.Igazolt_BOOL === true,
|
justified: item.Igazolt_BOOL === true,
|
||||||
justificationStatus: justificationStatus,
|
justificationStatus: justificationStatus,
|
||||||
purposeful: item.TanoraiCeluMulasztas_BNAME || "",
|
purposeful: item.TanoraiCeluMulasztas_BNAME || "",
|
||||||
justificationType: item.IgazolasTipus_DNAME || "",
|
justificationType: item.IgazolasTipus_DNAME || "",
|
||||||
|
minutes: item.KesesPercben || 0,
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
const groupedAbsences = {};
|
const groupedByDate = absences.reduce((groups, absence) => {
|
||||||
absences.forEach((absence) => {
|
const key = absence.dateKey;
|
||||||
if (!groupedAbsences[absence.date]) {
|
if (!groups[key]) {
|
||||||
groupedAbsences[absence.date] = [];
|
groups[key] = [];
|
||||||
}
|
}
|
||||||
groupedAbsences[absence.date].push(absence);
|
groups[key].push(absence);
|
||||||
|
return groups;
|
||||||
|
}, {});
|
||||||
|
|
||||||
|
Object.keys(groupedByDate).forEach(date => {
|
||||||
|
groupedByDate[date].sort((a, b) => parseInt(a.lesson) - parseInt(b.lesson));
|
||||||
});
|
});
|
||||||
|
|
||||||
return { basicData, absences, groupedAbsences };
|
return { basicData, absences, groupedByDate };
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error("Hiba az API hívás során:", error);
|
console.error("Hiba az API hívás során:", error);
|
||||||
return { basicData, absences: [], groupedAbsences: {} };
|
return { basicData, absences: [], groupedByDate: {} };
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function createFilterCard(absences) {
|
function createStatsSection(absences) {
|
||||||
const filterCard = document.createElement('div');
|
const statsSection = document.createElement('div');
|
||||||
filterCard.className = 'filter-card';
|
statsSection.className = 'stats-section';
|
||||||
|
|
||||||
const filterHeader = document.createElement('div');
|
|
||||||
filterHeader.className = 'filter-header';
|
|
||||||
const h2 = document.createElement('h2');
|
|
||||||
h2.textContent = LanguageManager.t('absences.filter_title');
|
|
||||||
filterHeader.appendChild(h2);
|
|
||||||
|
|
||||||
const filterContent = document.createElement('div');
|
|
||||||
filterContent.className = 'filter-content';
|
|
||||||
|
|
||||||
const dateGroup = createFilterGroup(
|
|
||||||
'Calendar.svg',
|
|
||||||
'Dátum',
|
|
||||||
LanguageManager.t('absences.date'),
|
|
||||||
'input',
|
|
||||||
{ type: 'date', id: 'dateFilter', className: 'filter-input' }
|
|
||||||
);
|
|
||||||
filterContent.appendChild(dateGroup);
|
|
||||||
|
|
||||||
const subjectGroup = createSubjectFilterGroup(absences);
|
const statsTitle = document.createElement('h2');
|
||||||
filterContent.appendChild(subjectGroup);
|
statsTitle.className = 'stats-title';
|
||||||
|
statsTitle.textContent = LanguageManager.t('absences.title');
|
||||||
|
statsSection.appendChild(statsTitle);
|
||||||
|
|
||||||
const justificationGroup = createJustificationFilterGroup();
|
const statsGrid = document.createElement('div');
|
||||||
filterContent.appendChild(justificationGroup);
|
statsGrid.className = 'stats-grid';
|
||||||
|
|
||||||
filterCard.appendChild(filterHeader);
|
|
||||||
filterCard.appendChild(filterContent);
|
|
||||||
|
|
||||||
return filterCard;
|
|
||||||
}
|
|
||||||
|
|
||||||
function createFilterGroup(iconName, altText, labelText, elementType, attributes) {
|
const totalAbsences = absences.filter(a => a.absenceType === 'absence').length;
|
||||||
const group = document.createElement('div');
|
const totalLates = absences.filter(a => a.absenceType === 'late').length;
|
||||||
group.className = 'filter-group';
|
const justified = absences.filter(a => a.justificationStatus === 'justified').length;
|
||||||
|
const unjustified = absences.filter(a => a.justificationStatus === 'unjustified').length;
|
||||||
const label = document.createElement('label');
|
const pending = absences.filter(a => a.justificationStatus === 'pending').length;
|
||||||
const img = document.createElement('img');
|
|
||||||
img.src = chrome.runtime.getURL(`icons/${iconName}`);
|
|
||||||
img.alt = altText;
|
|
||||||
img.style.width = '24px';
|
|
||||||
img.style.height = '24px';
|
|
||||||
|
|
||||||
label.appendChild(img);
|
|
||||||
label.appendChild(document.createTextNode(' ' + labelText));
|
|
||||||
|
|
||||||
const element = document.createElement(elementType);
|
|
||||||
Object.assign(element, attributes);
|
|
||||||
|
|
||||||
group.appendChild(label);
|
|
||||||
group.appendChild(element);
|
|
||||||
|
|
||||||
return group;
|
|
||||||
}
|
|
||||||
|
|
||||||
function createSubjectFilterGroup(absences) {
|
|
||||||
const group = document.createElement('div');
|
|
||||||
group.className = 'filter-group';
|
|
||||||
|
|
||||||
const label = document.createElement('label');
|
|
||||||
const img = document.createElement('img');
|
|
||||||
img.src = chrome.runtime.getURL('icons/Subject.svg');
|
|
||||||
img.alt = 'Tantárgy';
|
|
||||||
img.style.width = '24px';
|
|
||||||
img.style.height = '24px';
|
|
||||||
|
|
||||||
label.appendChild(img);
|
|
||||||
label.appendChild(document.createTextNode(' ' + LanguageManager.t('absences.subject')));
|
|
||||||
|
|
||||||
const select = document.createElement('select');
|
|
||||||
select.id = 'subjectFilter';
|
|
||||||
select.className = 'filter-input';
|
|
||||||
|
|
||||||
const defaultOption = document.createElement('option');
|
|
||||||
defaultOption.value = '';
|
|
||||||
defaultOption.textContent = LanguageManager.t('absences.all_subjects');
|
|
||||||
select.appendChild(defaultOption);
|
|
||||||
|
|
||||||
const subjects = [...new Set(absences.map(a => a.subject))].sort();
|
|
||||||
subjects.forEach(subject => {
|
|
||||||
const option = document.createElement('option');
|
|
||||||
option.value = subject;
|
|
||||||
option.textContent = subject;
|
|
||||||
select.appendChild(option);
|
|
||||||
});
|
|
||||||
|
|
||||||
group.appendChild(label);
|
|
||||||
group.appendChild(select);
|
|
||||||
|
|
||||||
return group;
|
|
||||||
}
|
|
||||||
|
|
||||||
function createJustificationFilterGroup() {
|
|
||||||
const group = document.createElement('div');
|
|
||||||
group.className = 'filter-group';
|
|
||||||
|
|
||||||
const label = document.createElement('label');
|
|
||||||
const img = document.createElement('img');
|
|
||||||
img.src = chrome.runtime.getURL('icons/BadgeCheck.svg');
|
|
||||||
img.alt = 'Igazolás';
|
|
||||||
img.style.width = '24px';
|
|
||||||
img.style.height = '24px';
|
|
||||||
|
|
||||||
label.appendChild(img);
|
|
||||||
label.appendChild(document.createTextNode(' ' + LanguageManager.t('absences.justification')));
|
|
||||||
|
|
||||||
const select = document.createElement('select');
|
|
||||||
select.id = 'justificationFilter';
|
|
||||||
select.className = 'filter-input';
|
|
||||||
|
|
||||||
const options = [
|
|
||||||
{ value: '', text: LanguageManager.t('absences.all_types') },
|
|
||||||
{ value: 'justified', text: LanguageManager.t('absences.justified') },
|
|
||||||
{ value: 'unjustified', text: LanguageManager.t('absences.unjustified') },
|
|
||||||
{ value: 'pending', text: LanguageManager.t('absences.pending') }
|
|
||||||
];
|
|
||||||
|
|
||||||
options.forEach(optionData => {
|
|
||||||
const option = document.createElement('option');
|
|
||||||
option.value = optionData.value;
|
|
||||||
option.textContent = optionData.text;
|
|
||||||
select.appendChild(option);
|
|
||||||
});
|
|
||||||
|
|
||||||
group.appendChild(label);
|
|
||||||
group.appendChild(select);
|
|
||||||
|
|
||||||
return group;
|
|
||||||
}
|
|
||||||
|
|
||||||
function createStatsOverview(absences) {
|
|
||||||
const statsOverview = document.createElement('div');
|
|
||||||
statsOverview.className = 'stats-overview';
|
|
||||||
|
|
||||||
const stats = [
|
const stats = [
|
||||||
{ number: absences.length, label: LanguageManager.t('absences.total_absences') },
|
{ type: 'total', number: absences.length, label: LanguageManager.t('absences.total_absences') },
|
||||||
{ number: absences.filter(a => a.justificationStatus === 'justified').length, label: LanguageManager.t('absences.justified') },
|
{ type: 'absence', number: totalAbsences, label: LanguageManager.t('absences.absence_type') },
|
||||||
{ number: absences.filter(a => a.justificationStatus === 'unjustified').length, label: LanguageManager.t('absences.unjustified') },
|
{ type: 'late', number: totalLates, label: LanguageManager.t('absences.late_type') },
|
||||||
{ number: absences.filter(a => a.justificationStatus === 'pending').length, label: LanguageManager.t('absences.pending') }
|
{ type: 'justified', number: justified, label: LanguageManager.t('absences.justified') },
|
||||||
|
{ type: 'unjustified', number: unjustified, label: LanguageManager.t('absences.unjustified') },
|
||||||
|
{ type: 'pending', number: pending, label: LanguageManager.t('absences.pending') },
|
||||||
];
|
];
|
||||||
|
|
||||||
stats.forEach(stat => {
|
stats.forEach(stat => {
|
||||||
const statCard = document.createElement('div');
|
const statCard = document.createElement('div');
|
||||||
statCard.className = 'stat-card';
|
statCard.className = `stat-card ${stat.type}`;
|
||||||
|
|
||||||
const statNumber = document.createElement('div');
|
const statNumber = document.createElement('div');
|
||||||
statNumber.className = 'stat-number';
|
statNumber.className = 'stat-number';
|
||||||
statNumber.textContent = stat.number;
|
statNumber.textContent = stat.number;
|
||||||
|
|
||||||
const statLabel = document.createElement('div');
|
const statLabel = document.createElement('div');
|
||||||
statLabel.className = 'stat-label';
|
statLabel.className = 'stat-label';
|
||||||
statLabel.textContent = stat.label;
|
statLabel.textContent = stat.label;
|
||||||
|
|
||||||
statCard.appendChild(statNumber);
|
statCard.appendChild(statNumber);
|
||||||
statCard.appendChild(statLabel);
|
statCard.appendChild(statLabel);
|
||||||
statsOverview.appendChild(statCard);
|
statsGrid.appendChild(statCard);
|
||||||
});
|
});
|
||||||
|
|
||||||
return statsOverview;
|
statsSection.appendChild(statsGrid);
|
||||||
|
return statsSection;
|
||||||
}
|
}
|
||||||
|
|
||||||
function createAbsencesContainer(absences) {
|
function getSchoolYearStart() {
|
||||||
const container = document.createElement('div');
|
const now = new Date();
|
||||||
container.className = 'absences-container';
|
const year = now.getMonth() >= 8 ? now.getFullYear() : now.getFullYear() - 1;
|
||||||
|
return new Date(year, 8, 1);
|
||||||
const table = document.createElement('table');
|
}
|
||||||
table.className = 'absences-table';
|
|
||||||
|
function createCalendarSection(groupedByDate, absences) {
|
||||||
const thead = document.createElement('thead');
|
const calendarSection = document.createElement('div');
|
||||||
thead.className = 'table-header';
|
calendarSection.className = 'calendar-section';
|
||||||
|
|
||||||
const headerRow = document.createElement('tr');
|
const schoolYearStart = getSchoolYearStart();
|
||||||
const headers = [
|
const now = new Date();
|
||||||
LanguageManager.t('absences.date'),
|
|
||||||
LanguageManager.t('absences.lesson'),
|
const months = [];
|
||||||
LanguageManager.t('absences.subject'),
|
let currentDate = new Date(schoolYearStart);
|
||||||
LanguageManager.t('absences.topic'),
|
|
||||||
LanguageManager.t('absences.status')
|
while (currentDate <= now) {
|
||||||
];
|
months.push({
|
||||||
|
year: currentDate.getFullYear(),
|
||||||
headers.forEach(headerText => {
|
month: currentDate.getMonth()
|
||||||
const th = document.createElement('th');
|
});
|
||||||
th.textContent = headerText;
|
currentDate.setMonth(currentDate.getMonth() + 1);
|
||||||
headerRow.appendChild(th);
|
}
|
||||||
|
|
||||||
|
months.forEach(({ year, month }) => {
|
||||||
|
const monthCalendar = createMonthCalendar(year, month, groupedByDate, absences);
|
||||||
|
calendarSection.appendChild(monthCalendar);
|
||||||
});
|
});
|
||||||
|
|
||||||
thead.appendChild(headerRow);
|
return calendarSection;
|
||||||
|
}
|
||||||
const tbody = document.createElement('tbody');
|
|
||||||
generateAbsencesRows(absences, tbody);
|
function createMonthCalendar(year, month, groupedByDate, absences) {
|
||||||
|
const monthContainer = document.createElement('div');
|
||||||
table.appendChild(thead);
|
monthContainer.className = 'month-container';
|
||||||
table.appendChild(tbody);
|
|
||||||
container.appendChild(table);
|
const monthHeader = document.createElement('div');
|
||||||
|
monthHeader.className = 'month-header';
|
||||||
return container;
|
|
||||||
|
const monthNames = [
|
||||||
|
LanguageManager.t('common.january') || 'Január',
|
||||||
|
LanguageManager.t('common.february') || 'Február',
|
||||||
|
LanguageManager.t('common.march') || 'Március',
|
||||||
|
LanguageManager.t('common.april') || 'Április',
|
||||||
|
LanguageManager.t('common.may') || 'Május',
|
||||||
|
LanguageManager.t('common.june') || 'Június',
|
||||||
|
LanguageManager.t('common.july') || 'Július',
|
||||||
|
LanguageManager.t('common.august') || 'Augusztus',
|
||||||
|
LanguageManager.t('common.september') || 'Szeptember',
|
||||||
|
LanguageManager.t('common.october') || 'Október',
|
||||||
|
LanguageManager.t('common.november') || 'November',
|
||||||
|
LanguageManager.t('common.december') || 'December'
|
||||||
|
];
|
||||||
|
|
||||||
|
monthHeader.textContent = `${monthNames[month]} ${year}`;
|
||||||
|
monthContainer.appendChild(monthHeader);
|
||||||
|
|
||||||
|
const calendarGrid = document.createElement('div');
|
||||||
|
calendarGrid.className = 'calendar-grid';
|
||||||
|
|
||||||
|
const dayNames = [
|
||||||
|
LanguageManager.t('common.mon') || 'H',
|
||||||
|
LanguageManager.t('common.tue') || 'K',
|
||||||
|
LanguageManager.t('common.wed') || 'Sze',
|
||||||
|
LanguageManager.t('common.thu') || 'Cs',
|
||||||
|
LanguageManager.t('common.fri') || 'P',
|
||||||
|
LanguageManager.t('common.sat') || 'Szo',
|
||||||
|
LanguageManager.t('common.sun') || 'V'
|
||||||
|
];
|
||||||
|
|
||||||
|
dayNames.forEach(day => {
|
||||||
|
const dayHeader = document.createElement('div');
|
||||||
|
dayHeader.className = 'calendar-day-header';
|
||||||
|
dayHeader.textContent = day;
|
||||||
|
calendarGrid.appendChild(dayHeader);
|
||||||
|
});
|
||||||
|
|
||||||
|
const firstDay = new Date(year, month, 1);
|
||||||
|
const lastDay = new Date(year, month + 1, 0);
|
||||||
|
const daysInMonth = lastDay.getDate();
|
||||||
|
|
||||||
|
let startDay = firstDay.getDay() - 1;
|
||||||
|
if (startDay < 0) startDay = 6;
|
||||||
|
|
||||||
|
for (let i = 0; i < startDay; i++) {
|
||||||
|
const emptyCell = document.createElement('div');
|
||||||
|
emptyCell.className = 'calendar-day empty';
|
||||||
|
calendarGrid.appendChild(emptyCell);
|
||||||
|
}
|
||||||
|
|
||||||
|
const today = new Date();
|
||||||
|
today.setHours(0, 0, 0, 0);
|
||||||
|
|
||||||
|
for (let day = 1; day <= daysInMonth; day++) {
|
||||||
|
const dateKey = `${year}-${(month + 1).toString().padStart(2, "0")}-${day.toString().padStart(2, "0")}`;
|
||||||
|
const dayAbsences = groupedByDate[dateKey] || [];
|
||||||
|
const currentDayDate = new Date(year, month, day);
|
||||||
|
currentDayDate.setHours(0, 0, 0, 0);
|
||||||
|
|
||||||
|
const dayCell = document.createElement('div');
|
||||||
|
dayCell.className = 'calendar-day';
|
||||||
|
|
||||||
|
if (currentDayDate > today) {
|
||||||
|
dayCell.classList.add('future');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (currentDayDate.getTime() === today.getTime()) {
|
||||||
|
dayCell.classList.add('today');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (dayAbsences.length > 0) {
|
||||||
|
dayCell.classList.add('has-absence');
|
||||||
|
|
||||||
|
const hasUnjustified = dayAbsences.some(a => a.justificationStatus === 'unjustified');
|
||||||
|
const hasPending = dayAbsences.some(a => a.justificationStatus === 'pending');
|
||||||
|
const hasJustified = dayAbsences.some(a => a.justificationStatus === 'justified');
|
||||||
|
const hasAbsence = dayAbsences.some(a => a.absenceType === 'absence');
|
||||||
|
const hasLate = dayAbsences.some(a => a.absenceType === 'late');
|
||||||
|
|
||||||
|
if (hasUnjustified) {
|
||||||
|
dayCell.classList.add('status-unjustified');
|
||||||
|
} else if (hasPending) {
|
||||||
|
dayCell.classList.add('status-pending');
|
||||||
|
} else if (hasJustified) {
|
||||||
|
dayCell.classList.add('status-justified');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (hasAbsence && hasLate) {
|
||||||
|
dayCell.classList.add('type-mixed');
|
||||||
|
} else if (hasLate) {
|
||||||
|
dayCell.classList.add('type-late');
|
||||||
|
}
|
||||||
|
|
||||||
|
dayCell.addEventListener('click', () => {
|
||||||
|
openAbsenceModal(dateKey, dayAbsences);
|
||||||
|
});
|
||||||
|
|
||||||
|
const countBadge = document.createElement('span');
|
||||||
|
countBadge.className = 'absence-count';
|
||||||
|
countBadge.textContent = dayAbsences.length;
|
||||||
|
dayCell.appendChild(countBadge);
|
||||||
|
}
|
||||||
|
|
||||||
|
const dayNumber = document.createElement('span');
|
||||||
|
dayNumber.className = 'day-number';
|
||||||
|
dayNumber.textContent = day;
|
||||||
|
dayCell.appendChild(dayNumber);
|
||||||
|
|
||||||
|
calendarGrid.appendChild(dayCell);
|
||||||
|
}
|
||||||
|
|
||||||
|
monthContainer.appendChild(calendarGrid);
|
||||||
|
return monthContainer;
|
||||||
|
}
|
||||||
|
|
||||||
|
function openAbsenceModal(dateKey, dayAbsences) {
|
||||||
|
const existingModal = document.querySelector('.absence-modal-overlay');
|
||||||
|
if (existingModal) {
|
||||||
|
existingModal.remove();
|
||||||
|
}
|
||||||
|
|
||||||
|
const overlay = document.createElement('div');
|
||||||
|
overlay.className = 'absence-modal-overlay';
|
||||||
|
|
||||||
|
const modal = document.createElement('div');
|
||||||
|
modal.className = 'absence-modal';
|
||||||
|
|
||||||
|
const modalHeader = document.createElement('div');
|
||||||
|
modalHeader.className = 'modal-header';
|
||||||
|
|
||||||
|
const dateParts = dateKey.split('-');
|
||||||
|
const displayDate = new Date(parseInt(dateParts[0]), parseInt(dateParts[1]) - 1, parseInt(dateParts[2]));
|
||||||
|
const dayNames = [
|
||||||
|
LanguageManager.t('common.sunday') || 'Vasárnap',
|
||||||
|
LanguageManager.t('common.monday') || 'Hétfő',
|
||||||
|
LanguageManager.t('common.tuesday') || 'Kedd',
|
||||||
|
LanguageManager.t('common.wednesday') || 'Szerda',
|
||||||
|
LanguageManager.t('common.thursday') || 'Csütörtök',
|
||||||
|
LanguageManager.t('common.friday') || 'Péntek',
|
||||||
|
LanguageManager.t('common.saturday') || 'Szombat'
|
||||||
|
];
|
||||||
|
|
||||||
|
const modalTitle = document.createElement('h2');
|
||||||
|
modalTitle.textContent = `${dateParts[0]}.${dateParts[1]}.${dateParts[2]}. - ${dayNames[displayDate.getDay()]}`;
|
||||||
|
|
||||||
|
modalHeader.appendChild(modalTitle);
|
||||||
|
|
||||||
|
const modalContent = document.createElement('div');
|
||||||
|
modalContent.className = 'modal-content';
|
||||||
|
|
||||||
|
dayAbsences.forEach(absence => {
|
||||||
|
const absenceCard = document.createElement('div');
|
||||||
|
absenceCard.className = `modal-absence-card ${absence.justificationStatus}`;
|
||||||
|
|
||||||
|
const headerRow = document.createElement('div');
|
||||||
|
headerRow.className = 'modal-card-header';
|
||||||
|
|
||||||
|
const lessonSpan = document.createElement('span');
|
||||||
|
lessonSpan.className = 'modal-lesson';
|
||||||
|
lessonSpan.textContent = `${absence.lesson}.`;
|
||||||
|
|
||||||
|
const typeIndicator = document.createElement('span');
|
||||||
|
typeIndicator.className = `type-indicator ${absence.absenceType}`;
|
||||||
|
typeIndicator.textContent = absence.absenceType === 'late'
|
||||||
|
? (LanguageManager.t('absences.late_type') || 'Késés')
|
||||||
|
: (LanguageManager.t('absences.absence_type') || 'Hiányzás');
|
||||||
|
|
||||||
|
const statusBadge = document.createElement('span');
|
||||||
|
statusBadge.className = `modal-status-badge ${absence.justificationStatus}`;
|
||||||
|
let statusText = '';
|
||||||
|
if (absence.justificationStatus === 'justified') {
|
||||||
|
statusText = LanguageManager.t('absences.justified') || 'Igazolt';
|
||||||
|
} else if (absence.justificationStatus === 'unjustified') {
|
||||||
|
statusText = LanguageManager.t('absences.unjustified') || 'Igazolatlan';
|
||||||
|
} else {
|
||||||
|
statusText = LanguageManager.t('absences.pending') || 'Igazolásra vár';
|
||||||
|
}
|
||||||
|
statusBadge.textContent = statusText;
|
||||||
|
|
||||||
|
headerRow.appendChild(lessonSpan);
|
||||||
|
headerRow.appendChild(typeIndicator);
|
||||||
|
headerRow.appendChild(statusBadge);
|
||||||
|
|
||||||
|
const subjectDiv = document.createElement('div');
|
||||||
|
subjectDiv.className = 'modal-subject';
|
||||||
|
subjectDiv.textContent = absence.subject;
|
||||||
|
|
||||||
|
const infoRow = document.createElement('div');
|
||||||
|
infoRow.className = 'modal-info-row';
|
||||||
|
|
||||||
|
if (absence.topic) {
|
||||||
|
const topicSpan = document.createElement('span');
|
||||||
|
topicSpan.className = 'modal-info-item';
|
||||||
|
topicSpan.textContent = absence.topic;
|
||||||
|
infoRow.appendChild(topicSpan);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (absence.justificationType) {
|
||||||
|
const justificationSpan = document.createElement('span');
|
||||||
|
justificationSpan.className = 'modal-info-item';
|
||||||
|
justificationSpan.textContent = absence.justificationType;
|
||||||
|
infoRow.appendChild(justificationSpan);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (absence.absenceType === 'late' && absence.minutes > 0) {
|
||||||
|
const minutesSpan = document.createElement('span');
|
||||||
|
minutesSpan.className = 'modal-info-item modal-minutes';
|
||||||
|
minutesSpan.textContent = `${absence.minutes} ${LanguageManager.t('absences.minutes') || 'perc'}`;
|
||||||
|
infoRow.appendChild(minutesSpan);
|
||||||
|
}
|
||||||
|
|
||||||
|
absenceCard.appendChild(headerRow);
|
||||||
|
absenceCard.appendChild(subjectDiv);
|
||||||
|
if (infoRow.children.length > 0) {
|
||||||
|
absenceCard.appendChild(infoRow);
|
||||||
|
}
|
||||||
|
|
||||||
|
modalContent.appendChild(absenceCard);
|
||||||
|
});
|
||||||
|
|
||||||
|
modal.appendChild(modalHeader);
|
||||||
|
modal.appendChild(modalContent);
|
||||||
|
overlay.appendChild(modal);
|
||||||
|
|
||||||
|
overlay.addEventListener('click', (e) => {
|
||||||
|
if (e.target === overlay) {
|
||||||
|
overlay.remove();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const handleEscape = (e) => {
|
||||||
|
if (e.key === 'Escape') {
|
||||||
|
overlay.remove();
|
||||||
|
document.removeEventListener('keydown', handleEscape);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
document.addEventListener('keydown', handleEscape);
|
||||||
|
|
||||||
|
document.body.appendChild(overlay);
|
||||||
|
|
||||||
|
requestAnimationFrame(() => {
|
||||||
|
overlay.classList.add('visible');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function createLegend() {
|
||||||
|
const legend = document.createElement('div');
|
||||||
|
legend.className = 'calendar-legend';
|
||||||
|
|
||||||
|
const legendItems = [
|
||||||
|
{ class: 'status-justified', label: LanguageManager.t('absences.justified') || 'Igazolt' },
|
||||||
|
{ class: 'status-pending', label: LanguageManager.t('absences.pending') || 'Igazolásra vár' },
|
||||||
|
{ class: 'status-unjustified', label: LanguageManager.t('absences.unjustified') || 'Igazolatlan' },
|
||||||
|
{ class: 'type-late-legend', label: LanguageManager.t('absences.late_type') || 'Késés', isType: true },
|
||||||
|
];
|
||||||
|
|
||||||
|
legendItems.forEach(item => {
|
||||||
|
const legendItem = document.createElement('div');
|
||||||
|
legendItem.className = 'legend-item';
|
||||||
|
|
||||||
|
const legendColor = document.createElement('div');
|
||||||
|
legendColor.className = `legend-color ${item.class}`;
|
||||||
|
|
||||||
|
const legendLabel = document.createElement('span');
|
||||||
|
legendLabel.textContent = item.label;
|
||||||
|
|
||||||
|
legendItem.appendChild(legendColor);
|
||||||
|
legendItem.appendChild(legendLabel);
|
||||||
|
legend.appendChild(legendItem);
|
||||||
|
});
|
||||||
|
|
||||||
|
return legend;
|
||||||
}
|
}
|
||||||
|
|
||||||
async function transformAbsencesPage() {
|
async function transformAbsencesPage() {
|
||||||
const { basicData, absences, groupedAbsences } = await collectAbsencesData();
|
const { basicData, absences, groupedByDate } = await collectAbsencesData();
|
||||||
|
|
||||||
document.body.textContent = '';
|
document.body.textContent = '';
|
||||||
|
|
||||||
const container = document.createElement('div');
|
const container = document.createElement('div');
|
||||||
container.className = 'kreta-container';
|
container.className = 'kreta-container';
|
||||||
|
|
||||||
const headerDiv = document.createElement('div');
|
const headerDiv = document.createElement('div');
|
||||||
const parser = new DOMParser();
|
const template = document.createElement('template');
|
||||||
const doc = parser.parseFromString(await createTemplate.header(), 'text/html');
|
template.innerHTML = await createTemplate.header();
|
||||||
const tempDiv = doc.body;
|
const tempDiv = template.content;
|
||||||
while (tempDiv.firstChild) {
|
while (tempDiv.firstChild) {
|
||||||
headerDiv.appendChild(tempDiv.firstChild);
|
headerDiv.appendChild(tempDiv.firstChild);
|
||||||
}
|
}
|
||||||
container.appendChild(headerDiv);
|
container.appendChild(headerDiv);
|
||||||
|
|
||||||
const main = document.createElement('main');
|
const main = document.createElement('main');
|
||||||
main.className = 'kreta-main';
|
main.className = 'kreta-main';
|
||||||
const filterCard = createFilterCard(absences);
|
|
||||||
main.appendChild(filterCard);
|
const pageContent = document.createElement('div');
|
||||||
const statsOverview = createStatsOverview(absences);
|
pageContent.className = 'absences-page';
|
||||||
main.appendChild(statsOverview);
|
|
||||||
const absencesContainer = createAbsencesContainer(absences);
|
const statsSection = createStatsSection(absences);
|
||||||
main.appendChild(absencesContainer);
|
pageContent.appendChild(statsSection);
|
||||||
|
|
||||||
|
const legend = createLegend();
|
||||||
|
pageContent.appendChild(legend);
|
||||||
|
|
||||||
|
const calendarSection = createCalendarSection(groupedByDate, absences);
|
||||||
|
pageContent.appendChild(calendarSection);
|
||||||
|
|
||||||
|
main.appendChild(pageContent);
|
||||||
container.appendChild(main);
|
container.appendChild(main);
|
||||||
document.body.appendChild(container);
|
document.body.appendChild(container);
|
||||||
|
|
||||||
|
|
||||||
setupUserDropdown();
|
setupUserDropdown();
|
||||||
setupMobileNavigation();
|
|
||||||
|
|
||||||
setupEventListeners();
|
|
||||||
setupFilters();
|
|
||||||
|
|
||||||
loadingScreen.hide();
|
loadingScreen.hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
function generateAbsencesRows(absences, tbody) {
|
|
||||||
const groupedByDate = absences.reduce((groups, absence) => {
|
|
||||||
const date = absence.date;
|
|
||||||
if (!groups[date]) {
|
|
||||||
groups[date] = [];
|
|
||||||
}
|
|
||||||
groups[date].push(absence);
|
|
||||||
return groups;
|
|
||||||
}, {});
|
|
||||||
|
|
||||||
const sortedDates = Object.keys(groupedByDate).sort(
|
|
||||||
(a, b) => new Date(b) - new Date(a),
|
|
||||||
);
|
|
||||||
|
|
||||||
sortedDates.forEach((date) => {
|
|
||||||
const dateAbsences = groupedByDate[date];
|
|
||||||
const divider = document.createElement('tr');
|
|
||||||
divider.className = 'date-group-divider';
|
|
||||||
divider.style.display = 'none';
|
|
||||||
tbody.appendChild(divider);
|
|
||||||
|
|
||||||
dateAbsences.forEach((absence) => {
|
|
||||||
const row = document.createElement('tr');
|
|
||||||
row.className = 'table-row';
|
|
||||||
row.dataset.subject = absence.subject;
|
|
||||||
row.dataset.justified = absence.justified;
|
|
||||||
row.dataset.date = absence.date;
|
|
||||||
row.dataset.dateGroup = date;
|
|
||||||
|
|
||||||
const dateCell = document.createElement('td');
|
|
||||||
dateCell.className = 'table-cell date-cell';
|
|
||||||
dateCell.dataset.label = LanguageManager.t('absences.date');
|
|
||||||
dateCell.textContent = absence.date;
|
|
||||||
row.appendChild(dateCell);
|
|
||||||
|
|
||||||
const lessonCell = document.createElement('td');
|
|
||||||
lessonCell.className = 'table-cell lesson-cell';
|
|
||||||
lessonCell.dataset.label = LanguageManager.t('absences.lesson');
|
|
||||||
lessonCell.textContent = absence.lesson + '.';
|
|
||||||
row.appendChild(lessonCell);
|
|
||||||
|
|
||||||
const subjectCell = document.createElement('td');
|
|
||||||
subjectCell.className = 'table-cell subject-cell';
|
|
||||||
subjectCell.dataset.label = LanguageManager.t('absences.subject');
|
|
||||||
subjectCell.textContent = absence.subject;
|
|
||||||
row.appendChild(subjectCell);
|
|
||||||
|
|
||||||
const topicCell = document.createElement('td');
|
|
||||||
topicCell.className = 'table-cell topic-cell';
|
|
||||||
topicCell.dataset.label = LanguageManager.t('absences.topic');
|
|
||||||
topicCell.title = absence.topic;
|
|
||||||
topicCell.textContent = absence.topic;
|
|
||||||
row.appendChild(topicCell);
|
|
||||||
|
|
||||||
const statusCell = document.createElement('td');
|
|
||||||
statusCell.className = 'table-cell status-cell';
|
|
||||||
statusCell.dataset.label = LanguageManager.t('absences.status');
|
|
||||||
|
|
||||||
const statusBadge = document.createElement('span');
|
|
||||||
statusBadge.className = `status-badge ${absence.justificationStatus}`;
|
|
||||||
|
|
||||||
if (absence.justificationStatus === 'justified') {
|
|
||||||
const img = document.createElement('img');
|
|
||||||
img.src = chrome.runtime.getURL('icons/BadgeCheck.svg');
|
|
||||||
img.alt = 'Igazolt';
|
|
||||||
img.style.width = '16px';
|
|
||||||
img.style.height = '16px';
|
|
||||||
statusBadge.appendChild(img);
|
|
||||||
statusBadge.appendChild(document.createTextNode(' ' + LanguageManager.t('absences.justified')));
|
|
||||||
} else if (absence.justificationStatus === 'unjustified') {
|
|
||||||
const span = document.createElement('span');
|
|
||||||
span.className = 'material-icons-round';
|
|
||||||
span.textContent = 'cancel';
|
|
||||||
statusBadge.appendChild(span);
|
|
||||||
statusBadge.appendChild(document.createTextNode(' ' + LanguageManager.t('absences.unjustified')));
|
|
||||||
} else {
|
|
||||||
const span = document.createElement('span');
|
|
||||||
span.className = 'material-icons-round';
|
|
||||||
span.textContent = 'pending';
|
|
||||||
statusBadge.appendChild(span);
|
|
||||||
statusBadge.appendChild(document.createTextNode(' ' + LanguageManager.t('absences.pending')));
|
|
||||||
}
|
|
||||||
|
|
||||||
statusCell.appendChild(statusBadge);
|
|
||||||
row.appendChild(statusCell);
|
|
||||||
|
|
||||||
tbody.appendChild(row);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
function setupEventListeners() {
|
|
||||||
function setupMobileGrouping() {
|
|
||||||
if (window.innerWidth <= 480) {
|
|
||||||
createMobileGroups();
|
|
||||||
} else {
|
|
||||||
removeMobileGroups();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
window.addEventListener("resize", setupMobileGrouping);
|
|
||||||
|
|
||||||
setupMobileGrouping();
|
|
||||||
}
|
|
||||||
|
|
||||||
function createMobileGroups() {
|
|
||||||
const tbody = document.querySelector(".absences-table tbody");
|
|
||||||
if (!tbody) return;
|
|
||||||
|
|
||||||
removeMobileGroups();
|
|
||||||
|
|
||||||
const rows = Array.from(tbody.querySelectorAll(".table-row"));
|
|
||||||
const groupedRows = {};
|
|
||||||
|
|
||||||
rows.forEach((row) => {
|
|
||||||
const date = row.dataset.date;
|
|
||||||
if (!groupedRows[date]) {
|
|
||||||
groupedRows[date] = [];
|
|
||||||
}
|
|
||||||
groupedRows[date].push(row);
|
|
||||||
});
|
|
||||||
|
|
||||||
const sortedDates = Object.keys(groupedRows).sort(
|
|
||||||
(a, b) => new Date(b) - new Date(a),
|
|
||||||
);
|
|
||||||
|
|
||||||
while (tbody.firstChild) {
|
|
||||||
tbody.removeChild(tbody.firstChild);
|
|
||||||
}
|
|
||||||
|
|
||||||
sortedDates.forEach((date) => {
|
|
||||||
const dateRows = groupedRows[date];
|
|
||||||
|
|
||||||
const dateGroup = document.createElement("div");
|
|
||||||
dateGroup.className = "date-group";
|
|
||||||
|
|
||||||
const dateHeader = document.createElement("div");
|
|
||||||
dateHeader.className = "date-group-header";
|
|
||||||
dateHeader.textContent = date;
|
|
||||||
|
|
||||||
const dateContent = document.createElement("div");
|
|
||||||
dateContent.className = "date-group-content";
|
|
||||||
|
|
||||||
dateRows.forEach((row) => {
|
|
||||||
dateContent.appendChild(row);
|
|
||||||
});
|
|
||||||
|
|
||||||
dateGroup.appendChild(dateHeader);
|
|
||||||
dateGroup.appendChild(dateContent);
|
|
||||||
tbody.appendChild(dateGroup);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
function removeMobileGroups() {
|
|
||||||
const tbody = document.querySelector(".absences-table tbody");
|
|
||||||
if (!tbody) return;
|
|
||||||
|
|
||||||
const dateGroups = tbody.querySelectorAll(".date-group");
|
|
||||||
if (dateGroups.length === 0) return;
|
|
||||||
|
|
||||||
const allRows = [];
|
|
||||||
dateGroups.forEach((group) => {
|
|
||||||
const rows = group.querySelectorAll(".table-row");
|
|
||||||
rows.forEach((row) => allRows.push(row));
|
|
||||||
});
|
|
||||||
|
|
||||||
while (tbody.firstChild) {
|
|
||||||
tbody.removeChild(tbody.firstChild);
|
|
||||||
}
|
|
||||||
allRows.forEach((row) => tbody.appendChild(row));
|
|
||||||
}
|
|
||||||
|
|
||||||
function updateDateGroupsVisibility() {
|
|
||||||
if (window.innerWidth > 480) return;
|
|
||||||
|
|
||||||
const dateGroups = document.querySelectorAll(".date-group");
|
|
||||||
|
|
||||||
dateGroups.forEach((group) => {
|
|
||||||
const visibleRows = group.querySelectorAll(
|
|
||||||
'.table-row[style=""], .table-row:not([style])',
|
|
||||||
);
|
|
||||||
|
|
||||||
if (visibleRows.length > 0) {
|
|
||||||
group.style.display = "";
|
|
||||||
} else {
|
|
||||||
group.style.display = "none";
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
function setupFilters() {
|
|
||||||
try {
|
|
||||||
const filters = {
|
|
||||||
dateFilter: document.getElementById("dateFilter"),
|
|
||||||
subject: document.getElementById("subjectFilter"),
|
|
||||||
justified: document.getElementById("justificationFilter"),
|
|
||||||
};
|
|
||||||
|
|
||||||
if (!filters.dateFilter || !filters.subject || !filters.justified) {
|
|
||||||
console.warn("Some filter elements were not found in the DOM");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const filterAbsences = () => {
|
|
||||||
try {
|
|
||||||
const dateFilterValue = filters.dateFilter.value;
|
|
||||||
const subject = filters.subject.value;
|
|
||||||
const justified = filters.justified.value;
|
|
||||||
const selectedDate = dateFilterValue ? new Date(dateFilterValue) : null;
|
|
||||||
|
|
||||||
document.querySelectorAll(".table-row").forEach((row) => {
|
|
||||||
const dateStr = row.dataset.date;
|
|
||||||
const dateParts = dateStr.split(".");
|
|
||||||
|
|
||||||
if (dateParts.length < 3) {
|
|
||||||
console.error(`Invalid date format: ${dateStr}`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const parsedYear = parseInt(dateParts[0].trim(), 10);
|
|
||||||
const parsedMonth = parseInt(dateParts[1].trim(), 10) - 1;
|
|
||||||
const parsedDay = parseInt(dateParts[2].trim(), 10);
|
|
||||||
|
|
||||||
if (isNaN(parsedDay) || isNaN(parsedMonth) || isNaN(parsedYear)) {
|
|
||||||
console.error(`Invalid date components: ${dateStr}`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const rowDate = new Date(parsedYear, parsedMonth, parsedDay);
|
|
||||||
|
|
||||||
let showRow = true;
|
|
||||||
|
|
||||||
if (selectedDate) {
|
|
||||||
if (
|
|
||||||
rowDate.getFullYear() !== selectedDate.getFullYear() ||
|
|
||||||
rowDate.getMonth() !== selectedDate.getMonth() ||
|
|
||||||
rowDate.getDate() !== selectedDate.getDate()
|
|
||||||
) {
|
|
||||||
showRow = false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (subject && row.dataset.subject !== subject) {
|
|
||||||
showRow = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (justified) {
|
|
||||||
const statusElement = row.querySelector(".status-badge");
|
|
||||||
const hasStatus = statusElement.classList.contains(justified);
|
|
||||||
if (!hasStatus) showRow = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
row.style.display = showRow ? "" : "none";
|
|
||||||
});
|
|
||||||
|
|
||||||
updateDateGroupsVisibility();
|
|
||||||
updateStatistics();
|
|
||||||
} catch (err) {
|
|
||||||
console.error("Error during filtering absences:", err);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
Object.values(filters).forEach((filter) => {
|
|
||||||
try {
|
|
||||||
if (filter) {
|
|
||||||
filter.addEventListener("change", filterAbsences);
|
|
||||||
}
|
|
||||||
} catch (err) {
|
|
||||||
if (
|
|
||||||
err.message &&
|
|
||||||
err.message.includes("Extension context invalidated")
|
|
||||||
) {
|
|
||||||
console.warn(
|
|
||||||
"Extension context invalidated during event listener setup",
|
|
||||||
);
|
|
||||||
} else {
|
|
||||||
console.error("Error setting up filter event listener:", err);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
filterAbsences();
|
|
||||||
} catch (err) {
|
|
||||||
if (err.message && err.message.includes("Extension context invalidated")) {
|
|
||||||
console.warn("Extension context invalidated during filter setup");
|
|
||||||
} else {
|
|
||||||
console.error("Error setting up filters:", err);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function updateStatistics() {
|
|
||||||
try {
|
|
||||||
const visibleRows = document.querySelectorAll(
|
|
||||||
'.table-row:not([style*="display: none"])',
|
|
||||||
);
|
|
||||||
const totalVisible = visibleRows.length;
|
|
||||||
const justifiedVisible = Array.from(visibleRows).filter((row) =>
|
|
||||||
row.querySelector(".status-badge.justified"),
|
|
||||||
).length;
|
|
||||||
const unjustifiedVisible = Array.from(visibleRows).filter((row) =>
|
|
||||||
row.querySelector(".status-badge.unjustified"),
|
|
||||||
).length;
|
|
||||||
const pendingVisible = Array.from(visibleRows).filter((row) =>
|
|
||||||
row.querySelector(".status-badge.pending"),
|
|
||||||
).length;
|
|
||||||
|
|
||||||
const statCards = document.querySelectorAll(".stat-card");
|
|
||||||
if (statCards[0])
|
|
||||||
statCards[0].querySelector(".stat-number").textContent = totalVisible;
|
|
||||||
if (statCards[1])
|
|
||||||
statCards[1].querySelector(".stat-number").textContent = justifiedVisible;
|
|
||||||
if (statCards[2])
|
|
||||||
statCards[2].querySelector(".stat-number").textContent =
|
|
||||||
unjustifiedVisible;
|
|
||||||
if (statCards[3])
|
|
||||||
statCards[3].querySelector(".stat-number").textContent = pendingVisible;
|
|
||||||
} catch (err) {
|
|
||||||
console.error("Error updating statistics:", err);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (window.location.href.includes("/Hianyzas/Hianyzasok")) {
|
if (window.location.href.includes("/Hianyzas/Hianyzasok")) {
|
||||||
transformAbsencesPage().catch((error) => {
|
transformAbsencesPage().catch((error) => {
|
||||||
console.error(LanguageManager.t("absences.page_transform_error"), error);
|
console.error(LanguageManager.t("absences.page_transform_error"), error);
|
||||||
|
|||||||
@@ -37,6 +37,8 @@ h2 {
|
|||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
|
grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
|
||||||
gap: 20px;
|
gap: 20px;
|
||||||
|
justify-content: center;
|
||||||
|
justify-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.widget-card {
|
.widget-card {
|
||||||
@@ -50,6 +52,7 @@ h2 {
|
|||||||
height: 100%;
|
height: 100%;
|
||||||
border: none;
|
border: none;
|
||||||
min-height: 400px;
|
min-height: 400px;
|
||||||
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.widget-header {
|
.widget-header {
|
||||||
@@ -222,7 +225,6 @@ h2 {
|
|||||||
max-width: 200px;
|
max-width: 200px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Mobile view: author below content */
|
|
||||||
@media (max-width: 768px) {
|
@media (max-width: 768px) {
|
||||||
.news-item .widget-row {
|
.news-item .widget-row {
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
@@ -257,7 +259,6 @@ h2 {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Desktop view: limit author width and wrap text */
|
|
||||||
@media (min-width: 769px) {
|
@media (min-width: 769px) {
|
||||||
.news-author {
|
.news-author {
|
||||||
max-width: 180px;
|
max-width: 180px;
|
||||||
@@ -354,13 +355,15 @@ h2 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.user-dropdown-btn {
|
.user-dropdown-btn {
|
||||||
background: none;
|
background: var(--button-secondaryFill);
|
||||||
border: none;
|
border: none;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
padding: 8px;
|
padding: 8px 12px;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
|
border-radius: 12px;
|
||||||
|
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-dropdown {
|
.user-dropdown {
|
||||||
|
|||||||
@@ -291,8 +291,9 @@ class DashboardDataManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class DashboardRenderer {
|
class DashboardRenderer {
|
||||||
constructor(data) {
|
constructor(data, settings = {}) {
|
||||||
this.baseData = data;
|
this.baseData = data;
|
||||||
|
this.settings = settings;
|
||||||
}
|
}
|
||||||
|
|
||||||
async init() {
|
async init() {
|
||||||
@@ -315,14 +316,31 @@ class DashboardRenderer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
generateMainContent() {
|
generateMainContent() {
|
||||||
|
const cards = [];
|
||||||
|
|
||||||
|
if (!this.settings.hideGrades) {
|
||||||
|
cards.push(this.createGradeCard());
|
||||||
|
}
|
||||||
|
if (!this.settings.hideAbsences) {
|
||||||
|
cards.push(this.createAbsenceCard());
|
||||||
|
}
|
||||||
|
if (!this.settings.hideNotes) {
|
||||||
|
cards.push(this.createNoteCard());
|
||||||
|
}
|
||||||
|
if (!this.settings.hideExams) {
|
||||||
|
cards.push(this.createExamCard());
|
||||||
|
}
|
||||||
|
|
||||||
|
cards.push(this.createNewsCard());
|
||||||
|
|
||||||
|
if (cards.length === 1) {
|
||||||
|
cards.unshift(this.createGradeCard());
|
||||||
|
}
|
||||||
|
|
||||||
return `
|
return `
|
||||||
<main class="kreta-main">
|
<main class="kreta-main">
|
||||||
<div class="grid-container">
|
<div class="grid-container">
|
||||||
${this.createGradeCard()}
|
${cards.join('')}
|
||||||
${this.createAbsenceCard()}
|
|
||||||
${this.createNoteCard()}
|
|
||||||
${this.createExamCard()}
|
|
||||||
${this.createNewsCard()}
|
|
||||||
</div>
|
</div>
|
||||||
</main>
|
</main>
|
||||||
`;
|
`;
|
||||||
@@ -481,22 +499,22 @@ class DashboardRenderer {
|
|||||||
|
|
||||||
async render() {
|
async render() {
|
||||||
await this.init();
|
await this.init();
|
||||||
document.body.innerHTML = '';
|
helper.clearElement(document.body);
|
||||||
|
|
||||||
const kretaContainer = document.createElement('div');
|
const kretaContainer = document.createElement('div');
|
||||||
kretaContainer.className = 'kreta-container';
|
kretaContainer.className = 'kreta-container';
|
||||||
const headerDiv = document.createElement('div');
|
const headerDiv = document.createElement('div');
|
||||||
const parser = new DOMParser();
|
const template = document.createElement('template');
|
||||||
const headerDoc = parser.parseFromString(await createTemplate.header(), 'text/html');
|
template.innerHTML = await createTemplate.header();
|
||||||
const headerContent = headerDoc.body;
|
const headerContent = template.content;
|
||||||
while (headerContent.firstChild) {
|
while (headerContent.firstChild) {
|
||||||
headerDiv.appendChild(headerContent.firstChild);
|
headerDiv.appendChild(headerContent.firstChild);
|
||||||
}
|
}
|
||||||
kretaContainer.appendChild(headerDiv);
|
kretaContainer.appendChild(headerDiv);
|
||||||
const mainContentDiv = document.createElement('div');
|
const mainContentDiv = document.createElement('div');
|
||||||
const parser2 = new DOMParser();
|
const template2 = document.createElement('template');
|
||||||
const mainDoc = parser2.parseFromString(this.generateMainContent(), 'text/html');
|
template2.innerHTML = this.generateMainContent();
|
||||||
const mainContent = mainDoc.body;
|
const mainContent = template2.content;
|
||||||
while (mainContent.firstChild) {
|
while (mainContent.firstChild) {
|
||||||
mainContentDiv.appendChild(mainContent.firstChild);
|
mainContentDiv.appendChild(mainContent.firstChild);
|
||||||
}
|
}
|
||||||
@@ -505,7 +523,6 @@ class DashboardRenderer {
|
|||||||
document.body.appendChild(kretaContainer);
|
document.body.appendChild(kretaContainer);
|
||||||
|
|
||||||
setupUserDropdown();
|
setupUserDropdown();
|
||||||
setupMobileNavigation();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -514,6 +531,26 @@ class DashboardApplication {
|
|||||||
this.init();
|
this.init();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async loadBulletinSettings() {
|
||||||
|
try {
|
||||||
|
const settings = await storageManager.get("pageSettings_bulletin", {});
|
||||||
|
return {
|
||||||
|
hideGrades: settings.hideGrades || false,
|
||||||
|
hideAbsences: settings.hideAbsences || false,
|
||||||
|
hideNotes: settings.hideNotes || false,
|
||||||
|
hideExams: settings.hideExams || false
|
||||||
|
};
|
||||||
|
} catch (error) {
|
||||||
|
console.error("Error loading bulletin settings:", error);
|
||||||
|
return {
|
||||||
|
hideGrades: false,
|
||||||
|
hideAbsences: false,
|
||||||
|
hideNotes: false,
|
||||||
|
hideExams: false
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
async init() {
|
async init() {
|
||||||
if (!window.location.href.includes("/Intezmeny/Faliujsag")) {
|
if (!window.location.href.includes("/Intezmeny/Faliujsag")) {
|
||||||
return;
|
return;
|
||||||
@@ -576,8 +613,9 @@ class DashboardApplication {
|
|||||||
try {
|
try {
|
||||||
const dataManager = new DashboardDataManager();
|
const dataManager = new DashboardDataManager();
|
||||||
const dashboardData = await dataManager.extractAllData();
|
const dashboardData = await dataManager.extractAllData();
|
||||||
|
const bulletinSettings = await this.loadBulletinSettings();
|
||||||
|
|
||||||
const renderer = new DashboardRenderer(dashboardData);
|
const renderer = new DashboardRenderer(dashboardData, bulletinSettings);
|
||||||
await renderer.render();
|
await renderer.render();
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error("Error initializing dashboard:", error);
|
console.error("Error initializing dashboard:", error);
|
||||||
|
|||||||
@@ -1,57 +0,0 @@
|
|||||||
body.maintenance-mode {
|
|
||||||
margin:0;
|
|
||||||
padding:0;
|
|
||||||
height:100vh;
|
|
||||||
display:flex;
|
|
||||||
align-items:center;
|
|
||||||
justify-content:center;
|
|
||||||
background-color:var(--background);
|
|
||||||
color:var(--text-primary);
|
|
||||||
font-family:'Figtree',sans-serif;
|
|
||||||
}
|
|
||||||
body {
|
|
||||||
background-color:var(--background) !important;
|
|
||||||
}
|
|
||||||
.maintenance-container {
|
|
||||||
text-align:center;
|
|
||||||
padding:2rem;
|
|
||||||
border-radius:8px;
|
|
||||||
background-color:var(--card-card);
|
|
||||||
box-shadow:0 var(--shadow-blur) 6px var(--accent-shadow);
|
|
||||||
max-width:600px;
|
|
||||||
width:90%;
|
|
||||||
}
|
|
||||||
.maintenance-logo {
|
|
||||||
width:128px;
|
|
||||||
height:128px;
|
|
||||||
margin:0 auto 2rem;
|
|
||||||
}
|
|
||||||
.maintenance-title {
|
|
||||||
font-size:1.5rem;
|
|
||||||
font-weight:600;
|
|
||||||
margin-bottom:1rem;
|
|
||||||
color:var(--accent-accent);
|
|
||||||
font-family:'Montserrat',sans-serif;
|
|
||||||
}
|
|
||||||
.maintenance-message {
|
|
||||||
font-size:1rem;
|
|
||||||
line-height:1.5;
|
|
||||||
margin-bottom:1.5rem;
|
|
||||||
color:var(--text-primary);
|
|
||||||
font-family:'Figtree',sans-serif;
|
|
||||||
}
|
|
||||||
.maintenance-footer {
|
|
||||||
font-size:0.875rem;
|
|
||||||
color:var(--text-secondary);
|
|
||||||
margin-top:2rem;
|
|
||||||
font-family:'Figtree',sans-serif;
|
|
||||||
}
|
|
||||||
.maintenance-cactus {
|
|
||||||
position:fixed;
|
|
||||||
bottom:0px;
|
|
||||||
right:20px;
|
|
||||||
width:120px;
|
|
||||||
height:120px;
|
|
||||||
opacity:1;
|
|
||||||
z-index:1000;
|
|
||||||
}
|
|
||||||
@@ -1,290 +0,0 @@
|
|||||||
(() => {
|
|
||||||
// reCAPTCHA functionality removed for security compliance
|
|
||||||
|
|
||||||
const loadDependencies = async () => {
|
|
||||||
// reCAPTCHA functionality removed for security compliance
|
|
||||||
// Extension now works without external script dependencies
|
|
||||||
};
|
|
||||||
|
|
||||||
const createPageStructure = () => {
|
|
||||||
// Biztonságos DOM létrehozás innerHTML helyett
|
|
||||||
document.body.innerHTML = '';
|
|
||||||
// Biztonságos HTML parsing DOMParser használatával
|
|
||||||
const parser = new DOMParser();
|
|
||||||
const doc = parser.parseFromString(`
|
|
||||||
<div class="forgot-container">
|
|
||||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
||||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
||||||
<link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap" rel="stylesheet">
|
|
||||||
<link href="https://fonts.googleapis.com/icon?family=Material+Icons+Round" rel="stylesheet">
|
|
||||||
<style>
|
|
||||||
.g-recaptcha {
|
|
||||||
margin-top: 5px;
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
<div class="forgot-card">
|
|
||||||
<header class="forgot-header">
|
|
||||||
<p class="logo-text">
|
|
||||||
<img src="${chrome.runtime.getURL("images/firka_logo.png")}" alt="Firka" class="logo">
|
|
||||||
Firka
|
|
||||||
</p>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
<h1 class="forgot-title" data-i18n="forgotpassword.title">Elfelejtett jelszó</h1>
|
|
||||||
|
|
||||||
<form id="forgotForm" novalidate>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="form-label" for="BejelentkezesiNev" data-i18n="forgotpassword.om_id_label">OM azonosító</label>
|
|
||||||
<input type="text" id="BejelentkezesiNev" name="BejelentkezesiNev" class="form-control"
|
|
||||||
data-i18n-attr="placeholder" data-i18n="forgotpassword.om_id_placeholder"
|
|
||||||
placeholder="Adja meg az OM azonosítóját" required>
|
|
||||||
<div class="error-message" data-i18n="forgotpassword.om_id_required">Az OM azonosító megadása kötelező</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="form-label" for="EmailCim" data-i18n="forgotpassword.email_label">E-mail cím</label>
|
|
||||||
<input type="email" id="EmailCim" name="EmailCim" class="form-control"
|
|
||||||
data-i18n-attr="placeholder" data-i18n="forgotpassword.email_placeholder"
|
|
||||||
placeholder="Adja meg az e-mail címét" required>
|
|
||||||
<div class="error-message" data-i18n="forgotpassword.email_required">Az e-mail cím megadása kötelező</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- reCAPTCHA container removed for security compliance -->
|
|
||||||
|
|
||||||
<div class="form-actions">
|
|
||||||
<a href="/Adminisztracio/Login" class="help-link" data-i18n="forgotpassword.back_to_login">
|
|
||||||
Vissza a bejelentkezéshez
|
|
||||||
</a>
|
|
||||||
<button type="submit" class="btn-submit" data-i18n="forgotpassword.reset_button">
|
|
||||||
Jelszó visszaállítása
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
`, 'text/html');
|
|
||||||
const tempDiv = doc.body;
|
|
||||||
|
|
||||||
// Biztonságos DOM hozzáadás
|
|
||||||
while (tempDiv.firstChild) {
|
|
||||||
document.body.appendChild(tempDiv.firstChild);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
const transformForgotPasswordPage = async () => {
|
|
||||||
await loadDependencies();
|
|
||||||
|
|
||||||
const isDarkMode = localStorage.getItem("darkMode") === "true";
|
|
||||||
document.documentElement.setAttribute(
|
|
||||||
"data-theme",
|
|
||||||
isDarkMode ? "dark" : "light",
|
|
||||||
);
|
|
||||||
|
|
||||||
chrome.runtime.onMessage.addListener((message) => {
|
|
||||||
if (message.action === "toggleTheme") {
|
|
||||||
document.documentElement.setAttribute(
|
|
||||||
"data-theme",
|
|
||||||
message.darkMode ? "dark" : "light",
|
|
||||||
);
|
|
||||||
localStorage.setItem("darkMode", message.darkMode);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
createPageStructure();
|
|
||||||
|
|
||||||
let attempts = 0;
|
|
||||||
const maxAttempts = 50;
|
|
||||||
|
|
||||||
const waitForLanguageManager = () => {
|
|
||||||
return new Promise((resolve) => {
|
|
||||||
const checkLanguageManager = () => {
|
|
||||||
attempts++;
|
|
||||||
if (typeof LanguageManager !== "undefined" && LanguageManager.t) {
|
|
||||||
setTimeout(resolve, 200);
|
|
||||||
} else if (attempts < maxAttempts) {
|
|
||||||
setTimeout(checkLanguageManager, 100);
|
|
||||||
} else {
|
|
||||||
console.warn("LanguageManager not available, using fallback texts");
|
|
||||||
resolve();
|
|
||||||
}
|
|
||||||
};
|
|
||||||
checkLanguageManager();
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
await waitForLanguageManager();
|
|
||||||
|
|
||||||
if (typeof LanguageManager !== "undefined" && LanguageManager.t) {
|
|
||||||
const elements = document.querySelectorAll("[data-i18n]");
|
|
||||||
elements.forEach((element) => {
|
|
||||||
const key = element.getAttribute("data-i18n");
|
|
||||||
const translation = LanguageManager.t(key);
|
|
||||||
|
|
||||||
if (translation && translation !== key) {
|
|
||||||
const attr = element.getAttribute("data-i18n-attr");
|
|
||||||
if (attr) {
|
|
||||||
element.setAttribute(attr, translation);
|
|
||||||
} else {
|
|
||||||
element.textContent = translation;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// reCAPTCHA rendering removed for security compliance
|
|
||||||
|
|
||||||
setupFormValidation();
|
|
||||||
};
|
|
||||||
|
|
||||||
const setupFormValidation = () => {
|
|
||||||
const form = document.getElementById("forgotForm");
|
|
||||||
const inputs = form.querySelectorAll(".form-control");
|
|
||||||
|
|
||||||
inputs.forEach((input) => {
|
|
||||||
input.addEventListener("input", () => {
|
|
||||||
validateInput(input);
|
|
||||||
});
|
|
||||||
|
|
||||||
input.addEventListener("blur", () => {
|
|
||||||
validateInput(input, true);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
form.addEventListener("submit", handleSubmit);
|
|
||||||
};
|
|
||||||
|
|
||||||
const validateInput = (input, showError = false) => {
|
|
||||||
const isValid = input.value.trim().length > 0;
|
|
||||||
const errorElement = input.nextElementSibling;
|
|
||||||
|
|
||||||
if (!isValid && showError) {
|
|
||||||
input.classList.add("error");
|
|
||||||
errorElement?.classList.add("show");
|
|
||||||
} else {
|
|
||||||
input.classList.remove("error");
|
|
||||||
errorElement?.classList.remove("show");
|
|
||||||
}
|
|
||||||
|
|
||||||
return isValid;
|
|
||||||
};
|
|
||||||
|
|
||||||
const showMessage = (message, isError = false) => {
|
|
||||||
const existingMessage = document.querySelector(".message");
|
|
||||||
if (existingMessage) {
|
|
||||||
existingMessage.remove();
|
|
||||||
}
|
|
||||||
|
|
||||||
const messageDiv = document.createElement("div");
|
|
||||||
messageDiv.className = `message ${isError ? "error" : "success"}`;
|
|
||||||
messageDiv.textContent = message;
|
|
||||||
|
|
||||||
const form = document.getElementById("forgotForm");
|
|
||||||
form.insertBefore(messageDiv, form.firstChild);
|
|
||||||
|
|
||||||
setTimeout(() => {
|
|
||||||
if (messageDiv.parentNode) {
|
|
||||||
messageDiv.remove();
|
|
||||||
}
|
|
||||||
}, 5000);
|
|
||||||
};
|
|
||||||
|
|
||||||
const validateEmail = (email) => {
|
|
||||||
const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
|
|
||||||
return emailRegex.test(email);
|
|
||||||
};
|
|
||||||
|
|
||||||
const handleSubmit = async (event) => {
|
|
||||||
event.preventDefault();
|
|
||||||
|
|
||||||
const form = event.target;
|
|
||||||
const inputs = form.querySelectorAll(".form-control[required]");
|
|
||||||
let isValid = true;
|
|
||||||
|
|
||||||
inputs.forEach((input) => {
|
|
||||||
if (!validateInput(input, true)) {
|
|
||||||
isValid = false;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const emailInput = form.querySelector("#EmailCim");
|
|
||||||
if (emailInput.value && !validateEmail(emailInput.value)) {
|
|
||||||
emailInput.classList.add("error");
|
|
||||||
const errorElement = emailInput.nextElementSibling;
|
|
||||||
if (errorElement) {
|
|
||||||
errorElement.textContent = LanguageManager.t(
|
|
||||||
"forgotpassword.invalid_email",
|
|
||||||
);
|
|
||||||
errorElement.classList.add("show");
|
|
||||||
}
|
|
||||||
isValid = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// reCAPTCHA validation removed for security compliance
|
|
||||||
|
|
||||||
if (!isValid) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const submitButton = form.querySelector(".btn-submit");
|
|
||||||
const originalText = submitButton.textContent;
|
|
||||||
submitButton.disabled = true;
|
|
||||||
submitButton.textContent = LanguageManager.t("loading.text") || "Küldés...";
|
|
||||||
|
|
||||||
try {
|
|
||||||
const formData = new FormData(form);
|
|
||||||
|
|
||||||
// reCAPTCHA data removed for security compliance
|
|
||||||
|
|
||||||
const response = await fetch(
|
|
||||||
"/Adminisztracio/ElfelejtettJelszo/LinkKuldes",
|
|
||||||
{
|
|
||||||
method: "POST",
|
|
||||||
body: formData,
|
|
||||||
headers: {
|
|
||||||
"X-Requested-With": "XMLHttpRequest",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
);
|
|
||||||
|
|
||||||
if (!response.ok) {
|
|
||||||
throw new Error(`HTTP error! status: ${response.status}`);
|
|
||||||
}
|
|
||||||
|
|
||||||
const result = await response.json();
|
|
||||||
|
|
||||||
if (result.Success) {
|
|
||||||
showMessage(LanguageManager.t("forgotpassword.success_message"));
|
|
||||||
|
|
||||||
form.reset();
|
|
||||||
|
|
||||||
// reCAPTCHA reset removed
|
|
||||||
|
|
||||||
setTimeout(() => {
|
|
||||||
window.location.href = "/Adminisztracio/Login";
|
|
||||||
}, 3000);
|
|
||||||
} else {
|
|
||||||
showMessage(
|
|
||||||
result.Message || LanguageManager.t("forgotpassword.error_message"),
|
|
||||||
true,
|
|
||||||
);
|
|
||||||
|
|
||||||
// reCAPTCHA reset removed
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
console.error("Password reset error:", error);
|
|
||||||
showMessage(LanguageManager.t("forgotpassword.error_message"), true);
|
|
||||||
|
|
||||||
// reCAPTCHA reset removed
|
|
||||||
} finally {
|
|
||||||
submitButton.disabled = false;
|
|
||||||
submitButton.textContent = originalText;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
if (window.location.href.includes("/Adminisztracio/ElfelejtettJelszo")) {
|
|
||||||
transformForgotPasswordPage().catch(console.error);
|
|
||||||
}
|
|
||||||
})();
|
|
||||||
@@ -184,6 +184,8 @@
|
|||||||
getAvailableLanguages: () => [
|
getAvailableLanguages: () => [
|
||||||
{ code: "hu", name: "Magyar" },
|
{ code: "hu", name: "Magyar" },
|
||||||
{ code: "en", name: "English" },
|
{ code: "en", name: "English" },
|
||||||
|
{ code: "de", name: "Deutsch" },
|
||||||
],
|
],
|
||||||
|
init: initializeLanguage,
|
||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ function checkMaintenancePage() {
|
|||||||
);
|
);
|
||||||
existingStyles.forEach((style) => style.remove());
|
existingStyles.forEach((style) => style.remove());
|
||||||
|
|
||||||
body.innerHTML = "";
|
helper.clearElement(body);
|
||||||
body.classList.add("maintenance-mode");
|
body.classList.add("maintenance-mode");
|
||||||
body.classList.add("theme-enabled");
|
body.classList.add("theme-enabled");
|
||||||
body.classList.add("loaded");
|
body.classList.add("loaded");
|
||||||
|
|||||||
@@ -1,334 +1,491 @@
|
|||||||
.kreta-header {
|
.kreta-header {
|
||||||
padding:clamp(1rem,3vw,2rem);
|
padding: 1rem 2rem;
|
||||||
display:grid;
|
display: flex;
|
||||||
grid-template-columns:minmax(300px,400px) 1fr minmax(200px,300px);
|
align-items: center;
|
||||||
align-items:center;
|
justify-content: space-between;
|
||||||
gap:1rem;
|
background-color: var(--background);
|
||||||
background-color:var(--background);
|
gap: 1.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.school-info {
|
.school-info {
|
||||||
margin:0;
|
display: flex;
|
||||||
display:flex;
|
flex-direction: column;
|
||||||
flex-direction:column;
|
min-width: 200px;
|
||||||
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.logo-text {
|
.logo-text {
|
||||||
color:var(--text-primary);
|
color: var(--text-primary);
|
||||||
font-size:24px;
|
font-size: 22px;
|
||||||
font-weight:600;
|
font-weight: 600;
|
||||||
margin:0 0 0.5rem;
|
margin: 0;
|
||||||
display:flex;
|
display: flex;
|
||||||
align-items:center;
|
align-items: center;
|
||||||
|
gap: 0.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.logo {
|
.logo {
|
||||||
width:24px;
|
width: 24px;
|
||||||
height:24px;
|
height: 24px;
|
||||||
border-radius:8px;
|
border-radius: 8px;
|
||||||
margin-right:0.5rem;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.school-details {
|
.school-details {
|
||||||
color:var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
font-size:14px;
|
font-size: 13px;
|
||||||
white-space:nowrap;
|
white-space: nowrap;
|
||||||
overflow:hidden;
|
overflow: hidden;
|
||||||
text-overflow:ellipsis;
|
text-overflow: ellipsis;
|
||||||
|
max-width: 300px;
|
||||||
|
margin-top: 0.25rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.kreta-nav {
|
.kreta-nav {
|
||||||
padding:0 clamp(0.5rem,3vw,1.5rem);
|
display: flex;
|
||||||
position:sticky;
|
justify-content: center;
|
||||||
top:0;
|
flex: 1;
|
||||||
z-index:100;
|
|
||||||
display:flex;
|
|
||||||
justify-content:center;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-links {
|
.nav-links {
|
||||||
display:flex;
|
display: flex;
|
||||||
gap:clamp(0.5rem,2vw,1rem);
|
gap: 0.5rem;
|
||||||
padding:0.25rem;
|
align-items: center;
|
||||||
align-items:center;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-item {
|
.nav-item {
|
||||||
display:flex;
|
display: flex;
|
||||||
align-items:center;
|
align-items: center;
|
||||||
padding:8px 14px 8px 12px;
|
padding: 10px 16px;
|
||||||
color:var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
text-decoration:none;
|
text-decoration: none;
|
||||||
font-weight:500;
|
font-weight: 500;
|
||||||
white-space:nowrap;
|
font-size: 14px;
|
||||||
border-radius:20px;
|
white-space: nowrap;
|
||||||
transition:all 0.2s ease;
|
border-radius: 12px;
|
||||||
gap:0.5rem;
|
transition: all 0.2s ease;
|
||||||
text-decoration:none;
|
gap: 0.5rem;
|
||||||
background:var(--button-secondaryFill);
|
background: var(--button-secondaryFill);
|
||||||
box-shadow:0px 1px var(--shadow-blur,2px) 0px var(--accent-shadow);
|
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
||||||
}
|
|
||||||
.nav-item.active {
|
|
||||||
display:flex;
|
|
||||||
padding:8px 14px 8px 12px;
|
|
||||||
align-items:center;
|
|
||||||
gap:8px;
|
|
||||||
border-radius:20px;
|
|
||||||
background:var(--button-secondaryFill);
|
|
||||||
box-shadow:0px 1px var(--shadow-blur,2px) 0px var(--accent-shadow);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-item:hover {
|
.nav-item:hover {
|
||||||
color:var(--text-primary);
|
color: var(--text-primary);
|
||||||
background-color:var(--accent-15);
|
background-color: var(--accent-15);
|
||||||
border-radius:8px;
|
text-decoration: none;
|
||||||
text-decoration:none;
|
|
||||||
}
|
}
|
||||||
.nav-item.active:hover {
|
|
||||||
color:var(--accent-accent);
|
.nav-item.active {
|
||||||
background-color:var(--accent-15);
|
color: var(--accent-accent);
|
||||||
text-decoration:none;
|
background: var(--accent-15);
|
||||||
}
|
}
|
||||||
.nav-item img,.nav-item svg {
|
|
||||||
width:24px;
|
.nav-item img,
|
||||||
height:24px;
|
.nav-item svg {
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
}
|
}
|
||||||
.nav-item.active svg path {
|
|
||||||
fill:var(--accent-accent);
|
.nav-item.active img {
|
||||||
|
filter: var(--icon-filter) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-profile {
|
.user-profile {
|
||||||
position:relative;
|
position: relative;
|
||||||
justify-self:flex-end;
|
flex-shrink: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-dropdown-btn {
|
.user-dropdown-btn {
|
||||||
display:flex;
|
display: flex;
|
||||||
align-items:center;
|
align-items: center;
|
||||||
gap:1rem;
|
gap: 0.75rem;
|
||||||
background:none;
|
background: var(--button-secondaryFill);
|
||||||
border:none;
|
border: none;
|
||||||
cursor:pointer;
|
cursor: pointer;
|
||||||
padding:0.5rem;
|
padding: 8px 12px;
|
||||||
border-radius:8px;
|
border-radius: 12px;
|
||||||
transition:background-color 0.2s;
|
transition: all 0.2s ease;
|
||||||
|
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-dropdown-btn:hover {
|
.user-dropdown-btn:hover {
|
||||||
background:var(--hover);
|
background: var(--accent-15);
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-info {
|
.user-info {
|
||||||
text-align:right;
|
text-align: right;
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-name {
|
.user-name {
|
||||||
display:block;
|
display: block;
|
||||||
color:var(--text-primary);
|
color: var(--text-primary);
|
||||||
font-size:16px;
|
font-size: 14px;
|
||||||
|
font-weight: 500;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-logout-timer {
|
.nav-logout-timer {
|
||||||
display:block;
|
display: block;
|
||||||
color:var(--text-secondary);
|
color: var(--text-secondary);
|
||||||
font-size:14px;
|
font-size: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.user-avatar-icon {
|
||||||
|
width: 32px;
|
||||||
|
height: 32px;
|
||||||
|
border-radius: 50%;
|
||||||
|
background: var(--accent-15);
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-avatar-icon svg {
|
||||||
|
width: 18px;
|
||||||
|
height: 18px;
|
||||||
|
fill: var(--accent-accent);
|
||||||
|
}
|
||||||
|
|
||||||
|
.dropdown-arrow {
|
||||||
|
width: 16px;
|
||||||
|
height: 16px;
|
||||||
|
fill: var(--text-secondary);
|
||||||
|
transition: transform 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-dropdown-btn.open .dropdown-arrow {
|
||||||
|
transform: rotate(180deg);
|
||||||
|
}
|
||||||
|
|
||||||
.user-dropdown {
|
.user-dropdown {
|
||||||
position:absolute;
|
position: absolute;
|
||||||
top:100%;
|
top: calc(100% + 8px);
|
||||||
right:0;
|
right: 0;
|
||||||
margin-top:0.5rem;
|
background: var(--card-card);
|
||||||
background:var(--card-card);
|
border-radius: 12px;
|
||||||
border-radius:12px;
|
box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
|
||||||
box-shadow:0 4px 6px -1px rgba(0,0,0,0.1);
|
min-width: 180px;
|
||||||
width:200px;
|
display: none;
|
||||||
display:none;
|
z-index: 1000;
|
||||||
z-index:1000;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-dropdown.show {
|
.user-dropdown.show {
|
||||||
display:block;
|
display: block;
|
||||||
animation:dropdownShow 0.2s ease;
|
animation: dropdownShow 0.2s ease;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dropdown-item {
|
.dropdown-item {
|
||||||
display:flex;
|
display: flex;
|
||||||
align-items:center;
|
align-items: center;
|
||||||
gap:0.75rem;
|
gap: 0.75rem;
|
||||||
padding:0.75rem 1rem;
|
padding: 12px 16px;
|
||||||
color:var(--text-primary);
|
color: var(--text-primary);
|
||||||
text-decoration:none;
|
text-decoration: none;
|
||||||
transition:background-color 0.2s;
|
transition: background-color 0.2s;
|
||||||
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.dropdown-item:hover {
|
.dropdown-item:hover {
|
||||||
background:var(--hover);
|
background: var(--hover);
|
||||||
color:var(--accent-accent);
|
color: var(--accent-accent);
|
||||||
border-radius:8px;
|
text-decoration: none;
|
||||||
text-decoration:none;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.dropdown-item img {
|
||||||
|
width: 18px;
|
||||||
|
height: 18px;
|
||||||
|
filter: var(--icon-filter);
|
||||||
|
}
|
||||||
|
|
||||||
|
.dropdown-item:hover img {
|
||||||
|
filter: brightness(0) saturate(100%) invert(25%) sepia(50%) saturate(2000%) hue-rotate(90deg) brightness(90%) contrast(95%);
|
||||||
|
}
|
||||||
|
|
||||||
@keyframes dropdownShow {
|
@keyframes dropdownShow {
|
||||||
from {
|
from {
|
||||||
opacity:0;
|
opacity: 0;
|
||||||
transform:translateY(-10px);
|
transform: translateY(-8px);
|
||||||
}
|
|
||||||
to {
|
|
||||||
opacity:1;
|
|
||||||
transform:translateY(0);
|
|
||||||
}
|
|
||||||
}@media (max-width:1200px) {
|
|
||||||
.kreta-header {
|
|
||||||
grid-template-columns:minmax(250px,350px) 1fr minmax(180px,250px);
|
|
||||||
}
|
|
||||||
}/* Hamburger menu styles */
|
|
||||||
.nav-toggle {
|
|
||||||
display:none;
|
|
||||||
background:none;
|
|
||||||
border:none;
|
|
||||||
cursor:pointer;
|
|
||||||
padding:0.5rem;
|
|
||||||
border-radius:8px;
|
|
||||||
transition:background-color 0.2s;
|
|
||||||
}
|
|
||||||
.nav-toggle:hover {
|
|
||||||
background:var(--hover);
|
|
||||||
}
|
|
||||||
.nav-toggle svg {
|
|
||||||
width:24px;
|
|
||||||
height:24px;
|
|
||||||
fill:var(--text-primary);
|
|
||||||
}
|
|
||||||
@media (max-width:768px) {
|
|
||||||
.kreta-header {
|
|
||||||
grid-template-columns:1fr auto auto;
|
|
||||||
grid-template-areas:"school toggle user"
|
|
||||||
"nav nav nav";
|
|
||||||
padding:1rem;
|
|
||||||
gap:0.5rem;
|
|
||||||
}
|
|
||||||
.nav-toggle {
|
|
||||||
display:block;
|
|
||||||
grid-area:toggle;
|
|
||||||
}
|
|
||||||
.school-info {
|
|
||||||
grid-area:school;
|
|
||||||
max-width:none;
|
|
||||||
display:flex;
|
|
||||||
align-items:center;
|
|
||||||
gap:0.5rem;
|
|
||||||
}
|
|
||||||
.logo-text {
|
|
||||||
margin:0;
|
|
||||||
font-size:18px;
|
|
||||||
}
|
|
||||||
.school-details {
|
|
||||||
font-size:11px;
|
|
||||||
max-width:200px;
|
|
||||||
}
|
|
||||||
.kreta-nav {
|
|
||||||
grid-area:nav;
|
|
||||||
padding:0;
|
|
||||||
margin-top:0.5rem;
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
.kreta-nav.show {
|
|
||||||
display:flex;
|
|
||||||
animation:slideDown 0.3s ease;
|
|
||||||
}
|
|
||||||
.kreta-nav::-webkit-scrollbar {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
.nav-links {
|
|
||||||
flex-direction:column;
|
|
||||||
width:100%;
|
|
||||||
gap:0.5rem;
|
|
||||||
background:var(--card-card);
|
|
||||||
border-radius:12px;
|
|
||||||
padding:1rem;
|
|
||||||
box-shadow:0px 1px var(--shadow-blur) 0px var(--accent-shadow);
|
|
||||||
}
|
|
||||||
.nav-item {
|
|
||||||
width:100%;
|
|
||||||
justify-content:flex-start;
|
|
||||||
padding:0.75rem;
|
|
||||||
font-size:14px;
|
|
||||||
}
|
|
||||||
.user-profile {
|
|
||||||
grid-area:user;
|
|
||||||
}
|
|
||||||
.user-info {
|
|
||||||
text-align:right;
|
|
||||||
max-width:120px;
|
|
||||||
}
|
|
||||||
.user-name {
|
|
||||||
font-size:13px;
|
|
||||||
white-space:nowrap;
|
|
||||||
overflow:hidden;
|
|
||||||
text-overflow:ellipsis;
|
|
||||||
}
|
|
||||||
.nav-logout-timer {
|
|
||||||
font-size:11px;
|
|
||||||
}
|
|
||||||
}@media (max-width:480px) {
|
|
||||||
.kreta-header {
|
|
||||||
grid-template-columns:1fr auto auto;
|
|
||||||
grid-template-areas:"school toggle user"
|
|
||||||
"nav nav nav";
|
|
||||||
padding:0.75rem;
|
|
||||||
gap:0.25rem;
|
|
||||||
}
|
|
||||||
.school-info {
|
|
||||||
min-width:0;
|
|
||||||
flex:1;
|
|
||||||
}
|
|
||||||
.logo-text {
|
|
||||||
font-size:16px;
|
|
||||||
}
|
|
||||||
.school-details {
|
|
||||||
font-size:10px;
|
|
||||||
max-width:150px;
|
|
||||||
}
|
|
||||||
.kreta-nav {
|
|
||||||
display:none;
|
|
||||||
}
|
|
||||||
.kreta-nav.show {
|
|
||||||
display:flex;
|
|
||||||
animation:slideDown 0.3s ease;
|
|
||||||
}
|
|
||||||
.nav-links {
|
|
||||||
flex-direction:column;
|
|
||||||
width:100%;
|
|
||||||
gap:0.5rem;
|
|
||||||
background:var(--card-card);
|
|
||||||
border-radius:12px;
|
|
||||||
padding:1rem;
|
|
||||||
box-shadow:0px 1px var(--shadow-blur) 0px var(--accent-shadow);
|
|
||||||
}
|
|
||||||
.nav-item {
|
|
||||||
width:100%;
|
|
||||||
justify-content:flex-start;
|
|
||||||
padding:0.75rem;
|
|
||||||
font-size:14px;
|
|
||||||
}
|
|
||||||
.user-info {
|
|
||||||
max-width:100px;
|
|
||||||
}
|
|
||||||
.user-name {
|
|
||||||
font-size:12px;
|
|
||||||
}
|
|
||||||
.nav-logout-timer {
|
|
||||||
font-size:10px;
|
|
||||||
}
|
|
||||||
}@media (max-width:360px) {
|
|
||||||
.kreta-header {
|
|
||||||
padding:0.5rem;
|
|
||||||
}
|
}
|
||||||
.logo-text {
|
to {
|
||||||
font-size:14px;
|
opacity: 1;
|
||||||
|
transform: translateY(0);
|
||||||
}
|
}
|
||||||
.school-details {
|
|
||||||
font-size:9px;
|
|
||||||
max-width:120px;
|
|
||||||
}
|
|
||||||
.user-info {
|
|
||||||
max-width:80px;
|
|
||||||
}
|
|
||||||
.user-name {
|
|
||||||
font-size:11px;
|
|
||||||
}
|
|
||||||
.nav-logout-timer {
|
|
||||||
font-size:9px;
|
|
||||||
}
|
}
|
||||||
}@keyframes slideDown {
|
|
||||||
|
@keyframes dropdownShowUp {
|
||||||
from {
|
from {
|
||||||
opacity:0;
|
opacity: 0;
|
||||||
transform:translateY(-10px);
|
transform: translateY(8px);
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
transform: translateY(0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
to {
|
|
||||||
opacity:1;
|
.mobile-header,
|
||||||
transform:translateY(0);
|
.mobile-bottom-nav,
|
||||||
|
.mobile-user-dropdown {
|
||||||
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media (max-width: 900px) {
|
||||||
|
.kreta-header {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-header {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
padding: 1rem;
|
||||||
|
background-color: var(--background);
|
||||||
|
gap: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-header .school-info {
|
||||||
|
align-items: center;
|
||||||
|
text-align: center;
|
||||||
|
min-width: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-header .logo-text {
|
||||||
|
font-size: 20px;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-header .school-details {
|
||||||
|
max-width: 280px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-bottom-nav {
|
||||||
|
display: flex;
|
||||||
|
position: fixed;
|
||||||
|
bottom: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
background: var(--background);
|
||||||
|
padding: 8px 16px;
|
||||||
|
padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
|
||||||
|
z-index: 1000;
|
||||||
|
box-shadow: 0 -2px 16px rgba(0, 0, 0, 0.1);
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
gap: 8px;
|
||||||
|
border-radius: 20px 20px 0 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
flex: 1;
|
||||||
|
padding: 8px 4px;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
text-decoration: none;
|
||||||
|
font-size: 10px;
|
||||||
|
font-weight: 500;
|
||||||
|
border-radius: 12px;
|
||||||
|
transition: all 0.2s ease;
|
||||||
|
gap: 4px;
|
||||||
|
background: var(--card-card);
|
||||||
|
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item:hover {
|
||||||
|
color: var(--text-primary);
|
||||||
|
background: var(--accent-15);
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item.active {
|
||||||
|
color: var(--accent-accent);
|
||||||
|
background: var(--accent-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item img {
|
||||||
|
width: 22px;
|
||||||
|
height: 22px;
|
||||||
|
transition: filter 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item.active img {
|
||||||
|
filter: var(--icon-filter) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item.active {
|
||||||
|
color: var(--accent-accent) !important;
|
||||||
|
background: var(--accent-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
flex: 1;
|
||||||
|
padding: 8px 4px;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
background: var(--card-card);
|
||||||
|
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
||||||
|
border: none;
|
||||||
|
font-size: 10px;
|
||||||
|
font-weight: 500;
|
||||||
|
border-radius: 12px;
|
||||||
|
transition: all 0.2s ease;
|
||||||
|
gap: 4px;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn:hover {
|
||||||
|
color: var(--text-primary);
|
||||||
|
background: var(--accent-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn.active {
|
||||||
|
color: var(--accent-accent);
|
||||||
|
background: var(--accent-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn .user-avatar-icon {
|
||||||
|
width: 22px;
|
||||||
|
height: 22px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn .user-avatar-icon svg {
|
||||||
|
width: 14px;
|
||||||
|
height: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-dropdown {
|
||||||
|
position: fixed;
|
||||||
|
bottom: calc(70px + env(safe-area-inset-bottom, 0px));
|
||||||
|
right: 12px;
|
||||||
|
background: var(--card-card);
|
||||||
|
border-radius: 12px;
|
||||||
|
box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.15);
|
||||||
|
min-width: 200px;
|
||||||
|
display: none;
|
||||||
|
z-index: 1001;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-dropdown.show {
|
||||||
|
display: block;
|
||||||
|
animation: dropdownShowUp 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-dropdown-header {
|
||||||
|
padding: 12px 16px;
|
||||||
|
border-bottom: 1px solid var(--hover);
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-dropdown-header .user-name {
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-dropdown-header .nav-logout-timer {
|
||||||
|
font-size: 12px;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
margin-top: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-dropdown-item {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.75rem;
|
||||||
|
padding: 12px 16px;
|
||||||
|
color: var(--text-primary);
|
||||||
|
text-decoration: none;
|
||||||
|
transition: background-color 0.2s;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-dropdown-item:hover {
|
||||||
|
background: var(--hover);
|
||||||
|
color: var(--accent-accent);
|
||||||
|
text-decoration: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-dropdown-item img {
|
||||||
|
width: 18px;
|
||||||
|
height: 18px;
|
||||||
|
filter: var(--icon-filter);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-dropdown-item:hover img {
|
||||||
|
filter: brightness(0) saturate(100%) invert(25%) sepia(50%) saturate(2000%) hue-rotate(90deg) brightness(90%) contrast(95%);
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 480px) {
|
||||||
|
.mobile-header {
|
||||||
|
padding: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-header .logo-text {
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-header .school-details {
|
||||||
|
font-size: 11px;
|
||||||
|
max-width: 220px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item {
|
||||||
|
padding: 6px 4px;
|
||||||
|
font-size: 9px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item img {
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn {
|
||||||
|
padding: 6px 4px;
|
||||||
|
font-size: 9px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn .user-avatar-icon {
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 360px) {
|
||||||
|
.mobile-header .logo-text {
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-header .school-details {
|
||||||
|
font-size: 10px;
|
||||||
|
max-width: 180px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item span {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn span {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-nav-item img {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mobile-user-btn .user-avatar-icon {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -42,12 +42,17 @@ async function updateHeaderInfo() {
|
|||||||
function startLogoutTimer(timeString) {
|
function startLogoutTimer(timeString) {
|
||||||
const startTime = parseInt(timeString?.match(/\d+/)?.[0] || "45");
|
const startTime = parseInt(timeString?.match(/\d+/)?.[0] || "45");
|
||||||
let timeLeft = startTime * 60;
|
let timeLeft = startTime * 60;
|
||||||
const timerElement = document.querySelector(".nav-logout-timer");
|
|
||||||
|
|
||||||
const updateTimer = () => {
|
const updateTimer = () => {
|
||||||
const minutes = Math.floor(timeLeft / 60);
|
const minutes = Math.floor(timeLeft / 60);
|
||||||
const seconds = timeLeft % 60;
|
const seconds = timeLeft % 60;
|
||||||
timerElement.textContent = `${minutes}:${seconds.toString().padStart(2, "0")}`;
|
const timeText = `${minutes}:${seconds.toString().padStart(2, "0")}`;
|
||||||
|
|
||||||
|
const desktopTimer = document.querySelector("#logoutTimer");
|
||||||
|
const mobileTimer = document.querySelector("#mobileLogoutTimer");
|
||||||
|
|
||||||
|
if (desktopTimer) desktopTimer.textContent = timeText;
|
||||||
|
if (mobileTimer) mobileTimer.textContent = timeText;
|
||||||
|
|
||||||
if (timeLeft <= 0) {
|
if (timeLeft <= 0) {
|
||||||
window.location.href = "/Home/Logout";
|
window.location.href = "/Home/Logout";
|
||||||
@@ -59,10 +64,6 @@ function startLogoutTimer(timeString) {
|
|||||||
setInterval(updateTimer, 1000);
|
setInterval(updateTimer, 1000);
|
||||||
}
|
}
|
||||||
|
|
||||||
document.addEventListener("DOMContentLoaded", async () => {
|
|
||||||
await updateHeaderInfo();
|
|
||||||
});
|
|
||||||
|
|
||||||
function setupUserDropdown() {
|
function setupUserDropdown() {
|
||||||
const userBtn = document.querySelector(".user-dropdown-btn");
|
const userBtn = document.querySelector(".user-dropdown-btn");
|
||||||
const userDropdown = document.querySelector(".user-dropdown");
|
const userDropdown = document.querySelector(".user-dropdown");
|
||||||
@@ -70,10 +71,36 @@ function setupUserDropdown() {
|
|||||||
userBtn?.addEventListener("click", (e) => {
|
userBtn?.addEventListener("click", (e) => {
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
userDropdown?.classList.toggle("show");
|
userDropdown?.classList.toggle("show");
|
||||||
|
userBtn?.classList.toggle("open");
|
||||||
});
|
});
|
||||||
|
|
||||||
document.addEventListener("click", () => {
|
const mobileUserBtn = document.querySelector("#mobileUserBtn");
|
||||||
userDropdown?.classList.remove("show");
|
const mobileUserDropdown = document.querySelector("#mobileUserDropdown");
|
||||||
|
|
||||||
|
mobileUserBtn?.addEventListener("click", (e) => {
|
||||||
|
e.stopPropagation();
|
||||||
|
mobileUserDropdown?.classList.toggle("show");
|
||||||
|
mobileUserBtn?.classList.toggle("active");
|
||||||
|
});
|
||||||
|
|
||||||
|
document.addEventListener("click", (e) => {
|
||||||
|
if (!userBtn?.contains(e.target) && !userDropdown?.contains(e.target)) {
|
||||||
|
userDropdown?.classList.remove("show");
|
||||||
|
userBtn?.classList.remove("open");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!mobileUserBtn?.contains(e.target) && !mobileUserDropdown?.contains(e.target)) {
|
||||||
|
mobileUserDropdown?.classList.remove("show");
|
||||||
|
mobileUserBtn?.classList.remove("active");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const mobileDropdownItems = document.querySelectorAll(".mobile-dropdown-item");
|
||||||
|
mobileDropdownItems.forEach(item => {
|
||||||
|
item.addEventListener("click", () => {
|
||||||
|
mobileUserDropdown?.classList.remove("show");
|
||||||
|
mobileUserBtn?.classList.remove("active");
|
||||||
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -84,94 +111,17 @@ function setupSettingsButton() {
|
|||||||
const url = chrome.runtime.getURL("settings/index.html");
|
const url = chrome.runtime.getURL("settings/index.html");
|
||||||
window.open(url, "_blank", "width=400,height=600");
|
window.open(url, "_blank", "width=400,height=600");
|
||||||
});
|
});
|
||||||
}
|
|
||||||
|
|
||||||
function setupMobileNavigation() {
|
document.getElementById("mobileSettingsBtn")?.addEventListener("click", (e) => {
|
||||||
setTimeout(() => {
|
e.preventDefault();
|
||||||
const navToggle = document.querySelector(".nav-toggle");
|
e.stopPropagation();
|
||||||
const nav = document.querySelector(".kreta-nav");
|
const url = chrome.runtime.getURL("settings/index.html");
|
||||||
|
window.open(url, "_blank", "width=400,height=600");
|
||||||
if (!navToggle || !nav) {
|
});
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const isFirefox = navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
|
|
||||||
|
|
||||||
if (isFirefox) {
|
|
||||||
let isNavOpen = false;
|
|
||||||
|
|
||||||
navToggle.addEventListener("click", (e) => {
|
|
||||||
e.preventDefault();
|
|
||||||
e.stopPropagation();
|
|
||||||
|
|
||||||
if (isNavOpen) {
|
|
||||||
nav.style.display = "none";
|
|
||||||
nav.classList.remove("show");
|
|
||||||
isNavOpen = false;
|
|
||||||
} else {
|
|
||||||
nav.style.display = "flex";
|
|
||||||
nav.classList.add("show");
|
|
||||||
isNavOpen = true;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
navToggle.addEventListener("touchend", (e) => {
|
|
||||||
e.preventDefault();
|
|
||||||
e.stopPropagation();
|
|
||||||
|
|
||||||
if (isNavOpen) {
|
|
||||||
nav.style.display = "none";
|
|
||||||
nav.classList.remove("show");
|
|
||||||
isNavOpen = false;
|
|
||||||
} else {
|
|
||||||
nav.style.display = "flex";
|
|
||||||
nav.classList.add("show");
|
|
||||||
isNavOpen = true;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
document.addEventListener("click", (e) => {
|
|
||||||
if (!nav.contains(e.target) && !navToggle.contains(e.target) && isNavOpen) {
|
|
||||||
nav.style.display = "none";
|
|
||||||
nav.classList.remove("show");
|
|
||||||
isNavOpen = false;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const navItems = document.querySelectorAll(".nav-item");
|
|
||||||
navItems.forEach((item) => {
|
|
||||||
item.addEventListener("click", () => {
|
|
||||||
nav.style.display = "none";
|
|
||||||
nav.classList.remove("show");
|
|
||||||
isNavOpen = false;
|
|
||||||
});
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
navToggle.addEventListener("click", (e) => {
|
|
||||||
e.preventDefault();
|
|
||||||
e.stopPropagation();
|
|
||||||
nav.classList.toggle("show");
|
|
||||||
});
|
|
||||||
|
|
||||||
document.addEventListener("click", (e) => {
|
|
||||||
if (!nav.contains(e.target) && !navToggle.contains(e.target)) {
|
|
||||||
nav.classList.remove("show");
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const navItems = document.querySelectorAll(".nav-item");
|
|
||||||
navItems.forEach((item) => {
|
|
||||||
item.addEventListener("click", () => {
|
|
||||||
nav.classList.remove("show");
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}, 100);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
document.addEventListener("DOMContentLoaded", async () => {
|
document.addEventListener("DOMContentLoaded", async () => {
|
||||||
await updateHeaderInfo();
|
await updateHeaderInfo();
|
||||||
setupUserDropdown();
|
setupUserDropdown();
|
||||||
setupSettingsButton();
|
setupSettingsButton();
|
||||||
setupMobileNavigation();
|
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
--accent-secondary:#6E8F1B;
|
--accent-secondary:#6E8F1B;
|
||||||
--accent-shadow:#647e2226;
|
--accent-shadow:#647e2226;
|
||||||
--accent-15:#a7dc2226;
|
--accent-15:#a7dc2226;
|
||||||
|
--icon-filter:brightness(0) saturate(100%) invert(76%) sepia(65%) saturate(482%) hue-rotate(35deg) brightness(98%) contrast(89%);
|
||||||
--warning-accent:var(--grades-2);
|
--warning-accent:var(--grades-2);
|
||||||
--warning-text:#8F531B;
|
--warning-text:#8F531B;
|
||||||
--warning-15:#ffa04626;
|
--warning-15:#ffa04626;
|
||||||
@@ -47,6 +48,7 @@
|
|||||||
--accent-secondary:#6E8F1B;
|
--accent-secondary:#6E8F1B;
|
||||||
--accent-shadow:#647e2226;
|
--accent-shadow:#647e2226;
|
||||||
--accent-15:#a7dc2226;
|
--accent-15:#a7dc2226;
|
||||||
|
--icon-filter:brightness(0) saturate(100%) invert(76%) sepia(65%) saturate(482%) hue-rotate(35deg) brightness(98%) contrast(89%);
|
||||||
--warning-accent:var(--grades-2);
|
--warning-accent:var(--grades-2);
|
||||||
--warning-text:#8F531B;
|
--warning-text:#8F531B;
|
||||||
--warning-15:#ffa04626;
|
--warning-15:#ffa04626;
|
||||||
@@ -81,6 +83,7 @@
|
|||||||
--accent-secondary:#CBEE71;
|
--accent-secondary:#CBEE71;
|
||||||
--accent-shadow:#0000;
|
--accent-shadow:#0000;
|
||||||
--accent-15:#a7dc2226;
|
--accent-15:#a7dc2226;
|
||||||
|
--icon-filter:brightness(0) saturate(100%) invert(76%) sepia(65%) saturate(482%) hue-rotate(35deg) brightness(98%) contrast(89%);
|
||||||
--warning-accent:var(--grades-2);
|
--warning-accent:var(--grades-2);
|
||||||
--warning-text:#f0b37a;
|
--warning-text:#f0b37a;
|
||||||
--warning-15:#ffa04626;
|
--warning-15:#ffa04626;
|
||||||
@@ -127,3 +130,41 @@ body {
|
|||||||
::-webkit-scrollbar-thumb:hover {
|
::-webkit-scrollbar-thumb:hover {
|
||||||
background:var(--text-primary);
|
background:var(--text-primary);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* SVG ikonok színezése a kiemelő színnel */
|
||||||
|
.icon-accent,
|
||||||
|
svg.icon-accent,
|
||||||
|
img.icon-accent {
|
||||||
|
filter: var(--icon-filter);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Minden SVG-re alkalmazható osztály */
|
||||||
|
.themed-icon {
|
||||||
|
filter: var(--icon-filter);
|
||||||
|
transition: filter 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Automatikus ikon színezés - minden icons/ mappából származó kép */
|
||||||
|
img[src*="icons/"],
|
||||||
|
img[src*="icons%2F"],
|
||||||
|
img[src$=".svg"] {
|
||||||
|
filter: var(--icon-filter);
|
||||||
|
transition: filter 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Warning színű ikonok (narancssárga) */
|
||||||
|
img[src*="icons/dkt.svg"],
|
||||||
|
img[src*="icons%2Fdkt.svg"],
|
||||||
|
img[src*="icons/assigment.svg"],
|
||||||
|
img[src*="icons%2Fassigment.svg"],
|
||||||
|
img[src$="dkt.svg"],
|
||||||
|
img[src$="assigment.svg"] {
|
||||||
|
filter: brightness(0) saturate(100%) invert(67%) sepia(44%) saturate(1057%) hue-rotate(349deg) brightness(101%) contrast(101%) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Error színű ikonok (piros/rózsaszín) */
|
||||||
|
img[src*="icons/logout.svg"],
|
||||||
|
img[src*="icons%2Flogout.svg"],
|
||||||
|
img[src$="logout.svg"] {
|
||||||
|
filter: brightness(0) saturate(100%) invert(52%) sepia(75%) saturate(1637%) hue-rotate(306deg) brightness(101%) contrast(101%) !important;
|
||||||
|
}
|
||||||
|
|||||||
121
global/theme.js
@@ -1,8 +1,125 @@
|
|||||||
(() => {
|
(() => {
|
||||||
|
let customThemes = [];
|
||||||
|
|
||||||
|
async function loadCustomThemes() {
|
||||||
|
try {
|
||||||
|
const saved = await storageManager.get("customThemes", []);
|
||||||
|
customThemes = Array.isArray(saved) ? saved : [];
|
||||||
|
} catch (error) {
|
||||||
|
console.error("Error loading custom themes:", error);
|
||||||
|
customThemes = [];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function applyCustomThemeColors(theme) {
|
||||||
|
const root = document.documentElement;
|
||||||
|
const isDark = theme.mode === "dark";
|
||||||
|
|
||||||
|
root.style.setProperty("--background", theme.colors.background);
|
||||||
|
root.style.setProperty("--background-0", theme.colors.background + "00");
|
||||||
|
root.style.setProperty("--card-card", theme.colors.card);
|
||||||
|
root.style.setProperty("--card-translucent", theme.colors.card + "80");
|
||||||
|
root.style.setProperty("--accent-accent", theme.colors.accent);
|
||||||
|
root.style.setProperty("--text-primary", theme.colors.text);
|
||||||
|
root.style.setProperty("--text-secondary", theme.colors.text + "cc");
|
||||||
|
root.style.setProperty("--text-teritary", theme.colors.text + "80");
|
||||||
|
root.style.setProperty("--accent-15", theme.colors.accent + "26");
|
||||||
|
root.style.setProperty("--button-secondaryFill", isDark ? lightenColor(theme.colors.card, 10) : darkenColor(theme.colors.card, 5));
|
||||||
|
root.style.setProperty("--accent-secondary", isDark ? lightenColor(theme.colors.accent, 20) : darkenColor(theme.colors.accent, 20));
|
||||||
|
root.style.setProperty("--shadow-blur", isDark ? "0" : "2px");
|
||||||
|
root.style.setProperty("--accent-shadow", isDark ? "#0000" : theme.colors.accent + "26");
|
||||||
|
root.style.setProperty("--warning-accent", "#FFA046");
|
||||||
|
root.style.setProperty("--warning-text", isDark ? "#f0b37a" : "#8F531B");
|
||||||
|
root.style.setProperty("--warning-15", "#ffa04626");
|
||||||
|
root.style.setProperty("--warning-card", isDark ? "#201203" : "#FAEBDC");
|
||||||
|
root.style.setProperty("--error-accent", "#FF54A1");
|
||||||
|
root.style.setProperty("--error-text", isDark ? "#f59ec5" : "#8F1B4F");
|
||||||
|
root.style.setProperty("--error-15", "#FF54A126");
|
||||||
|
root.style.setProperty("--error-card", isDark ? "#1e030f" : "#FADCE9");
|
||||||
|
root.style.setProperty("--icon-filter", hexToFilter(theme.colors.accent));
|
||||||
|
}
|
||||||
|
|
||||||
|
function hexToFilter(hex) {
|
||||||
|
const r = parseInt(hex.slice(1, 3), 16);
|
||||||
|
const g = parseInt(hex.slice(3, 5), 16);
|
||||||
|
const b = parseInt(hex.slice(5, 7), 16);
|
||||||
|
|
||||||
|
const rNorm = r / 255;
|
||||||
|
const gNorm = g / 255;
|
||||||
|
const bNorm = b / 255;
|
||||||
|
|
||||||
|
const max = Math.max(rNorm, gNorm, bNorm);
|
||||||
|
const min = Math.min(rNorm, gNorm, bNorm);
|
||||||
|
let h, s, l = (max + min) / 2;
|
||||||
|
|
||||||
|
if (max === min) {
|
||||||
|
h = s = 0;
|
||||||
|
} else {
|
||||||
|
const d = max - min;
|
||||||
|
s = l > 0.5 ? d / (2 - max - min) : d / (max + min);
|
||||||
|
switch (max) {
|
||||||
|
case rNorm: h = ((gNorm - bNorm) / d + (gNorm < bNorm ? 6 : 0)) / 6; break;
|
||||||
|
case gNorm: h = ((bNorm - rNorm) / d + 2) / 6; break;
|
||||||
|
case bNorm: h = ((rNorm - gNorm) / d + 4) / 6; break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
const hue = Math.round(h * 360);
|
||||||
|
const saturation = Math.round(s * 100);
|
||||||
|
const lightness = Math.round(l * 100);
|
||||||
|
const brightnessVal = lightness > 50 ? 1 + (lightness - 50) / 100 : 0.5 + lightness / 100;
|
||||||
|
const saturateVal = saturation > 0 ? 1 + saturation / 100 : 0;
|
||||||
|
|
||||||
|
return `brightness(0) saturate(100%) invert(${lightness}%) sepia(${saturation}%) saturate(${Math.min(500, saturation * 5)}%) hue-rotate(${hue}deg) brightness(${brightnessVal}) contrast(${90 + saturation / 10}%)`;
|
||||||
|
}
|
||||||
|
|
||||||
|
function lightenColor(color, percent) {
|
||||||
|
const num = parseInt(color.replace("#", ""), 16);
|
||||||
|
const amt = Math.round(2.55 * percent);
|
||||||
|
const R = Math.min(255, (num >> 16) + amt);
|
||||||
|
const G = Math.min(255, ((num >> 8) & 0x00ff) + amt);
|
||||||
|
const B = Math.min(255, (num & 0x0000ff) + amt);
|
||||||
|
return "#" + (0x1000000 + R * 0x10000 + G * 0x100 + B).toString(16).slice(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
function darkenColor(color, percent) {
|
||||||
|
const num = parseInt(color.replace("#", ""), 16);
|
||||||
|
const amt = Math.round(2.55 * percent);
|
||||||
|
const R = Math.max(0, (num >> 16) - amt);
|
||||||
|
const G = Math.max(0, ((num >> 8) & 0x00ff) - amt);
|
||||||
|
const B = Math.max(0, (num & 0x0000ff) - amt);
|
||||||
|
return "#" + (0x1000000 + R * 0x10000 + G * 0x100 + B).toString(16).slice(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
function clearCustomThemeStyles() {
|
||||||
|
const root = document.documentElement;
|
||||||
|
const customProps = [
|
||||||
|
"--background", "--background-0", "--card-card", "--card-translucent",
|
||||||
|
"--accent-accent", "--text-primary", "--text-secondary", "--text-teritary",
|
||||||
|
"--accent-15", "--button-secondaryFill", "--accent-secondary",
|
||||||
|
"--shadow-blur", "--accent-shadow", "--icon-filter",
|
||||||
|
"--warning-accent", "--warning-text", "--warning-15", "--warning-card",
|
||||||
|
"--error-accent", "--error-text", "--error-15", "--error-card"
|
||||||
|
];
|
||||||
|
customProps.forEach(prop => root.style.removeProperty(prop));
|
||||||
|
}
|
||||||
|
|
||||||
async function setTheme(theme) {
|
async function setTheme(theme) {
|
||||||
try {
|
try {
|
||||||
|
clearCustomThemeStyles();
|
||||||
|
|
||||||
document.documentElement.setAttribute("data-theme", theme);
|
document.documentElement.setAttribute("data-theme", theme);
|
||||||
await storageManager.set("themePreference", theme);
|
await storageManager.set("themePreference", theme);
|
||||||
|
|
||||||
|
if (theme.startsWith("custom-")) {
|
||||||
|
await loadCustomThemes();
|
||||||
|
const themeId = theme.replace("custom-", "");
|
||||||
|
const customTheme = customThemes.find(t => t.id === themeId);
|
||||||
|
if (customTheme) {
|
||||||
|
applyCustomThemeColors(customTheme);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
chrome.runtime
|
chrome.runtime
|
||||||
.sendMessage({
|
.sendMessage({
|
||||||
action: "themeChanged",
|
action: "themeChanged",
|
||||||
@@ -103,6 +220,7 @@
|
|||||||
async function initializeTheme() {
|
async function initializeTheme() {
|
||||||
try {
|
try {
|
||||||
const theme = await storageManager.get("themePreference", "light-green");
|
const theme = await storageManager.get("themePreference", "light-green");
|
||||||
|
await loadCustomThemes();
|
||||||
|
|
||||||
await setTheme(theme);
|
await setTheme(theme);
|
||||||
setPageTitleAndFavicon();
|
setPageTitleAndFavicon();
|
||||||
@@ -123,6 +241,9 @@
|
|||||||
|
|
||||||
chrome.runtime.onMessage.addListener((message, sender, sendResponse) => {
|
chrome.runtime.onMessage.addListener((message, sender, sendResponse) => {
|
||||||
if (message.action === "changeTheme") {
|
if (message.action === "changeTheme") {
|
||||||
|
if (message.customThemes) {
|
||||||
|
customThemes = message.customThemes;
|
||||||
|
}
|
||||||
setTheme(message.theme);
|
setTheme(message.theme);
|
||||||
sendResponse({ success: true });
|
sendResponse({ success: true });
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -276,16 +276,17 @@ body {
|
|||||||
.user-dropdown-btn {
|
.user-dropdown-btn {
|
||||||
display:flex;
|
display:flex;
|
||||||
align-items:center;
|
align-items:center;
|
||||||
gap:1rem;
|
gap:0.75rem;
|
||||||
background:none;
|
background:var(--button-secondaryFill);
|
||||||
border:none;
|
border:none;
|
||||||
cursor:pointer;
|
cursor:pointer;
|
||||||
padding:0.5rem;
|
padding:8px 12px;
|
||||||
border-radius:8px;
|
border-radius:12px;
|
||||||
transition:background-color 0.2s;
|
transition:all 0.2s ease;
|
||||||
|
box-shadow:0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
||||||
}
|
}
|
||||||
.user-dropdown-btn:hover {
|
.user-dropdown-btn:hover {
|
||||||
background:var(--card-card);
|
background:var(--accent-15);
|
||||||
}
|
}
|
||||||
.user-info {
|
.user-info {
|
||||||
text-align:right;
|
text-align:right;
|
||||||
@@ -457,6 +458,9 @@ to {
|
|||||||
gap:1rem;
|
gap:1rem;
|
||||||
padding:1rem;
|
padding:1rem;
|
||||||
}
|
}
|
||||||
|
.grade-distribution.centered {
|
||||||
|
justify-content:center;
|
||||||
|
}
|
||||||
.grade-count {
|
.grade-count {
|
||||||
display:flex;
|
display:flex;
|
||||||
align-items:center;
|
align-items:center;
|
||||||
|
|||||||
203
grades/grades.js
@@ -1,6 +1,25 @@
|
|||||||
(() => {
|
(() => {
|
||||||
|
let gradesSettings = {
|
||||||
|
hideChart: false,
|
||||||
|
hideClassAverage: false
|
||||||
|
};
|
||||||
|
|
||||||
|
async function loadGradesSettings() {
|
||||||
|
try {
|
||||||
|
const settings = await storageManager.get("pageSettings_grades", {});
|
||||||
|
gradesSettings = {
|
||||||
|
hideChart: settings.hideChart || false,
|
||||||
|
hideClassAverage: settings.hideClassAverage || false
|
||||||
|
};
|
||||||
|
} catch (error) {
|
||||||
|
console.error("Error loading grades settings:", error);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
async function transformGradesPage() {
|
async function transformGradesPage() {
|
||||||
try {
|
try {
|
||||||
|
await loadGradesSettings();
|
||||||
|
|
||||||
const tanuloIdElement = document.querySelector("#TanuloId");
|
const tanuloIdElement = document.querySelector("#TanuloId");
|
||||||
const tanuloId = tanuloIdElement ? tanuloIdElement.value : "772481";
|
const tanuloId = tanuloIdElement ? tanuloIdElement.value : "772481";
|
||||||
|
|
||||||
@@ -9,29 +28,31 @@
|
|||||||
const classAverage = calculateOverallClassAverage(gradesData.subjects);
|
const classAverage = calculateOverallClassAverage(gradesData.subjects);
|
||||||
|
|
||||||
window.currentGradesData = gradesData;
|
window.currentGradesData = gradesData;
|
||||||
document.body.innerHTML = '';
|
|
||||||
const parser = new DOMParser();
|
const htmlString = await generatePageHTML(
|
||||||
const doc = parser.parseFromString(await generatePageHTML(
|
|
||||||
gradesData,
|
gradesData,
|
||||||
studentAverage,
|
studentAverage,
|
||||||
classAverage,
|
classAverage,
|
||||||
), 'text/html');
|
);
|
||||||
const tempDiv = doc.body;
|
|
||||||
while (tempDiv.firstChild) {
|
const template = document.createElement('template');
|
||||||
document.body.appendChild(tempDiv.firstChild);
|
template.innerHTML = htmlString;
|
||||||
}
|
|
||||||
|
helper.clearElement(document.body);
|
||||||
|
document.body.appendChild(template.content);
|
||||||
|
|
||||||
|
|
||||||
setupUserDropdown();
|
setupUserDropdown();
|
||||||
setupMobileNavigation();
|
|
||||||
|
|
||||||
const script = document.createElement("script");
|
if (!gradesSettings.hideChart) {
|
||||||
script.src = chrome.runtime.getURL("grades/chart.js");
|
const script = document.createElement("script");
|
||||||
document.head.appendChild(script);
|
script.src = chrome.runtime.getURL("grades/chart.js");
|
||||||
|
document.head.appendChild(script);
|
||||||
|
|
||||||
script.onload = () => {
|
script.onload = () => {
|
||||||
setupGradesChart(gradesData.subjects);
|
setupGradesChart(gradesData.subjects);
|
||||||
};
|
};
|
||||||
|
}
|
||||||
|
|
||||||
setupEventListeners();
|
setupEventListeners();
|
||||||
setupGradesListScrolling();
|
setupGradesListScrolling();
|
||||||
@@ -45,9 +66,9 @@
|
|||||||
async function fetchGradesFromAPI(tanuloId) {
|
async function fetchGradesFromAPI(tanuloId) {
|
||||||
try {
|
try {
|
||||||
const currentDomain = window.location.origin;
|
const currentDomain = window.location.origin;
|
||||||
const apiUrl = `${currentDomain}/api/TanuloErtekelesByTanuloApi/GetTanuloErtekelesByTanuloGridTanuloView?sort=&group=&filter=&data=%7B%22tanuloId%22%3A%22${tanuloId}%22%2C%22oktatasiNevelesiFeladatId%22%3A%227895%22%2C%22isOsztalyAtlagMegjelenik%22%3A%22True%22%7D&_=${Date.now()}`;
|
let apiUrl = `${currentDomain}/api/TanuloErtekelesByTanuloApi/GetTanuloErtekelesByTanuloGridTanuloView?sort=&group=&filter=&data=%7B%22tanuloId%22%3A%22${tanuloId}%22%2C%22oktatasiNevelesiFeladatId%22%3A%227895%22%2C%22isOsztalyAtlagMegjelenik%22%3A%22True%22%7D&_=${Date.now()}`;
|
||||||
|
|
||||||
const response = await fetch(apiUrl, {
|
let response = await fetch(apiUrl, {
|
||||||
method: "GET",
|
method: "GET",
|
||||||
credentials: "include",
|
credentials: "include",
|
||||||
headers: {
|
headers: {
|
||||||
@@ -60,7 +81,28 @@
|
|||||||
throw new Error(`HTTP error! status: ${response.status}`);
|
throw new Error(`HTTP error! status: ${response.status}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
const data = await response.json();
|
let data = await response.json();
|
||||||
|
|
||||||
|
if (data.Data && Array.isArray(data.Data) && data.Data.length === 1 && data.Data[0].ID === 0) {
|
||||||
|
console.log("Received only ID: 0, retrying with alternative endpoint...");
|
||||||
|
apiUrl = `${currentDomain}/api/TanuloErtekelesByTanuloApi/GetTanuloErtekelesByTanuloGridTanuloView?sort=&group=&filter=&data=%7B%22tanuloId%22%3A%22${tanuloId}%22%2C%22oktatasiNevelesiFeladatId%22%3A%221160%22%2C%22isOsztalyAtlagMegjelenik%22%3A%22True%22%7D&_=${Date.now()}`;
|
||||||
|
|
||||||
|
response = await fetch(apiUrl, {
|
||||||
|
method: "GET",
|
||||||
|
credentials: "include",
|
||||||
|
headers: {
|
||||||
|
Accept: "application/json, text/javascript, */*; q=0.01",
|
||||||
|
"X-Requested-With": "XMLHttpRequest",
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
|
if (!response.ok) {
|
||||||
|
throw new Error(`HTTP error on retry! status: ${response.status}`);
|
||||||
|
}
|
||||||
|
|
||||||
|
data = await response.json();
|
||||||
|
}
|
||||||
|
|
||||||
return await processAPIGradesData(data);
|
return await processAPIGradesData(data);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error("Error fetching grades from API:", error);
|
console.error("Error fetching grades from API:", error);
|
||||||
@@ -391,12 +433,16 @@
|
|||||||
schoolNameFull = `${data.schoolInfo.id} - ${data.schoolInfo.name}`;
|
schoolNameFull = `${data.schoolInfo.id} - ${data.schoolInfo.name}`;
|
||||||
shortenedSchoolName = helper.shortenSchoolName(schoolNameFull);
|
shortenedSchoolName = helper.shortenSchoolName(schoolNameFull);
|
||||||
|
|
||||||
|
const showClassAverage = !gradesSettings.hideClassAverage && classAverage > 0;
|
||||||
|
const showChart = !gradesSettings.hideChart;
|
||||||
|
|
||||||
return `
|
return `
|
||||||
<div class="kreta-container">
|
<div class="kreta-container">
|
||||||
${await createTemplate.header()}
|
${await createTemplate.header()}
|
||||||
|
|
||||||
<main class="kreta-main">
|
<main class="kreta-main">
|
||||||
<div class="grades-overview">
|
<div class="grades-overview">
|
||||||
|
${showChart ? `
|
||||||
<div class="overall-averages card">
|
<div class="overall-averages card">
|
||||||
<div class="chart-header">
|
<div class="chart-header">
|
||||||
<div class="chart-title">${LanguageManager.t("grades.chart_title")} (${totalGrades}db)</div>
|
<div class="chart-title">${LanguageManager.t("grades.chart_title")} (${totalGrades}db)</div>
|
||||||
@@ -405,7 +451,7 @@
|
|||||||
<span class="average-value ${studentAverage < 2 && studentAverage > 0 ? "warning" : ""}">${studentAverage > 0 ? studentAverage.toFixed(2) : "-"}</span>
|
<span class="average-value ${studentAverage < 2 && studentAverage > 0 ? "warning" : ""}">${studentAverage > 0 ? studentAverage.toFixed(2) : "-"}</span>
|
||||||
</div>
|
</div>
|
||||||
${
|
${
|
||||||
classAverage > 0
|
showClassAverage
|
||||||
? `
|
? `
|
||||||
<div class="average-circle class-average" data-grade="${classGradeLevel}">
|
<div class="average-circle class-average" data-grade="${classGradeLevel}">
|
||||||
<span class="average-value">${classAverage.toFixed(2)}</span>
|
<span class="average-value">${classAverage.toFixed(2)}</span>
|
||||||
@@ -431,6 +477,39 @@
|
|||||||
.join("")}
|
.join("")}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
` : `
|
||||||
|
<div class="overall-averages card">
|
||||||
|
<div class="chart-header">
|
||||||
|
<div class="chart-title">${LanguageManager.t("grades.chart_title")} (${totalGrades}db)</div>
|
||||||
|
<div class="chart-averages">
|
||||||
|
<div class="average-circle my-average" data-grade="${studentGradeLevel}">
|
||||||
|
<span class="average-value ${studentAverage < 2 && studentAverage > 0 ? "warning" : ""}">${studentAverage > 0 ? studentAverage.toFixed(2) : "-"}</span>
|
||||||
|
</div>
|
||||||
|
${
|
||||||
|
showClassAverage
|
||||||
|
? `
|
||||||
|
<div class="average-circle class-average" data-grade="${classGradeLevel}">
|
||||||
|
<span class="average-value">${classAverage.toFixed(2)}</span>
|
||||||
|
</div>
|
||||||
|
`
|
||||||
|
: ""
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="grade-distribution centered">
|
||||||
|
${Object.entries(gradeDistribution)
|
||||||
|
.map(
|
||||||
|
([grade, count]) => `
|
||||||
|
<div class="grade-count grade-${grade}">
|
||||||
|
<span class="grade-value">${grade}</span>
|
||||||
|
<span class="grade-amount">${count}</span>
|
||||||
|
</div>
|
||||||
|
`,
|
||||||
|
)
|
||||||
|
.join("")}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
`}
|
||||||
${
|
${
|
||||||
yearEndGrades.length > 0
|
yearEndGrades.length > 0
|
||||||
? `
|
? `
|
||||||
@@ -533,6 +612,9 @@
|
|||||||
if (!ctx) return;
|
if (!ctx) return;
|
||||||
|
|
||||||
const gradePoints = calculateGradePoints(subjects);
|
const gradePoints = calculateGradePoints(subjects);
|
||||||
|
const accentColor = getComputedStyle(document.documentElement)
|
||||||
|
.getPropertyValue("--accent-accent")
|
||||||
|
.trim();
|
||||||
|
|
||||||
new Chart(ctx, {
|
new Chart(ctx, {
|
||||||
type: "line",
|
type: "line",
|
||||||
@@ -543,28 +625,8 @@
|
|||||||
label: "Átlag",
|
label: "Átlag",
|
||||||
data: gradePoints.map((p) => p.average),
|
data: gradePoints.map((p) => p.average),
|
||||||
borderWidth: 5,
|
borderWidth: 5,
|
||||||
|
borderColor: accentColor,
|
||||||
tension: 0.5,
|
tension: 0.5,
|
||||||
segment: {
|
|
||||||
borderColor: (ctx) => {
|
|
||||||
const curr = ctx.p1.parsed.y;
|
|
||||||
if (!curr) return "transparent";
|
|
||||||
const color =
|
|
||||||
getComputedStyle(document.documentElement)
|
|
||||||
.getPropertyValue(
|
|
||||||
curr < 2
|
|
||||||
? "--grades-1"
|
|
||||||
: curr < 2.5
|
|
||||||
? "--grades-2"
|
|
||||||
: curr < 3.5
|
|
||||||
? "--grades-3"
|
|
||||||
: curr < 4.5
|
|
||||||
? "--grades-4"
|
|
||||||
: "--grades-5",
|
|
||||||
)
|
|
||||||
.trim() + "80";
|
|
||||||
return color;
|
|
||||||
},
|
|
||||||
},
|
|
||||||
fill: true,
|
fill: true,
|
||||||
backgroundColor: function (context) {
|
backgroundColor: function (context) {
|
||||||
const chart = context.chart;
|
const chart = context.chart;
|
||||||
@@ -578,55 +640,12 @@
|
|||||||
chartArea.top,
|
chartArea.top,
|
||||||
);
|
);
|
||||||
|
|
||||||
gradientBg.addColorStop(
|
gradientBg.addColorStop(0, accentColor + "30");
|
||||||
0,
|
gradientBg.addColorStop(1, accentColor + "10");
|
||||||
getComputedStyle(document.documentElement)
|
|
||||||
.getPropertyValue("--grades-1")
|
|
||||||
.trim() + "30",
|
|
||||||
);
|
|
||||||
gradientBg.addColorStop(
|
|
||||||
0.2,
|
|
||||||
getComputedStyle(document.documentElement)
|
|
||||||
.getPropertyValue("--grades-2")
|
|
||||||
.trim() + "30",
|
|
||||||
);
|
|
||||||
gradientBg.addColorStop(
|
|
||||||
0.4,
|
|
||||||
getComputedStyle(document.documentElement)
|
|
||||||
.getPropertyValue("--grades-3")
|
|
||||||
.trim() + "30",
|
|
||||||
);
|
|
||||||
gradientBg.addColorStop(
|
|
||||||
0.6,
|
|
||||||
getComputedStyle(document.documentElement)
|
|
||||||
.getPropertyValue("--grades-4")
|
|
||||||
.trim() + "30",
|
|
||||||
);
|
|
||||||
gradientBg.addColorStop(
|
|
||||||
0.8,
|
|
||||||
getComputedStyle(document.documentElement)
|
|
||||||
.getPropertyValue("--grades-5")
|
|
||||||
.trim() + "30",
|
|
||||||
);
|
|
||||||
|
|
||||||
return gradientBg;
|
return gradientBg;
|
||||||
},
|
},
|
||||||
pointBackgroundColor: (context) => {
|
pointBackgroundColor: accentColor,
|
||||||
const value = context.raw;
|
|
||||||
return getComputedStyle(document.documentElement)
|
|
||||||
.getPropertyValue(
|
|
||||||
value < 2
|
|
||||||
? "--grades-1"
|
|
||||||
: value < 2.5
|
|
||||||
? "--grades-2"
|
|
||||||
: value < 3.5
|
|
||||||
? "--grades-3"
|
|
||||||
: value < 4.5
|
|
||||||
? "--grades-4"
|
|
||||||
: "--grades-5",
|
|
||||||
)
|
|
||||||
.trim();
|
|
||||||
},
|
|
||||||
pointRadius: 0,
|
pointRadius: 0,
|
||||||
pointHoverRadius: 0,
|
pointHoverRadius: 0,
|
||||||
},
|
},
|
||||||
@@ -641,15 +660,10 @@
|
|||||||
max: 5,
|
max: 5,
|
||||||
ticks: {
|
ticks: {
|
||||||
stepSize: 1,
|
stepSize: 1,
|
||||||
color: getComputedStyle(
|
color: accentColor,
|
||||||
document.documentElement,
|
|
||||||
).getPropertyValue("--text-secondary"),
|
|
||||||
},
|
},
|
||||||
grid: {
|
grid: {
|
||||||
color:
|
color: accentColor + "20",
|
||||||
getComputedStyle(document.documentElement).getPropertyValue(
|
|
||||||
"--text-teritary",
|
|
||||||
) + "20",
|
|
||||||
lineWidth: 1,
|
lineWidth: 1,
|
||||||
borderDash: [5, 5],
|
borderDash: [5, 5],
|
||||||
},
|
},
|
||||||
@@ -701,6 +715,7 @@
|
|||||||
.reverse();
|
.reverse();
|
||||||
const myGrade = Math.floor(subject.average) || 0;
|
const myGrade = Math.floor(subject.average) || 0;
|
||||||
const classGrade = Math.floor(subject.classAverage) || 0;
|
const classGrade = Math.floor(subject.classAverage) || 0;
|
||||||
|
const showClassAvg = !gradesSettings.hideClassAverage && subject.classAverage > 0;
|
||||||
|
|
||||||
return `
|
return `
|
||||||
<div class="subject-card card">
|
<div class="subject-card card">
|
||||||
@@ -713,7 +728,7 @@
|
|||||||
<span class="average-value">${subject.average > 0 ? subject.average.toFixed(2) : "-"}</span>
|
<span class="average-value">${subject.average > 0 ? subject.average.toFixed(2) : "-"}</span>
|
||||||
</div>
|
</div>
|
||||||
${
|
${
|
||||||
subject.classAverage > 0
|
showClassAvg
|
||||||
? `
|
? `
|
||||||
<div class="average-circle class-average" data-grade="${classGrade}">
|
<div class="average-circle class-average" data-grade="${classGrade}">
|
||||||
<span class="average-value">${subject.classAverage.toFixed(2)}</span>
|
<span class="average-value">${subject.classAverage.toFixed(2)}</span>
|
||||||
|
|||||||
596
i18n/de.json
Normal file
@@ -0,0 +1,596 @@
|
|||||||
|
{
|
||||||
|
"loading": {
|
||||||
|
"text": "Laden...",
|
||||||
|
"subtext": "Bitte warten!"
|
||||||
|
},
|
||||||
|
"settings": {
|
||||||
|
"title": "Einstellungen",
|
||||||
|
"appearance": "Erscheinungsbild",
|
||||||
|
"theme": "Design",
|
||||||
|
"language": "Sprache",
|
||||||
|
"tabs": {
|
||||||
|
"home": "Startseite",
|
||||||
|
"appearance": "Erscheinungsbild",
|
||||||
|
"settings": "Einstellungen",
|
||||||
|
"about": "Über"
|
||||||
|
},
|
||||||
|
"page_settings": {
|
||||||
|
"title": "Seiteneinstellungen",
|
||||||
|
"current_page": "Aktuelle Seite",
|
||||||
|
"no_settings": "Keine benutzerdefinierten Einstellungen für diese Seite verfügbar.",
|
||||||
|
"login": {
|
||||||
|
"hide_system_message": "Systemmeldung ausblenden",
|
||||||
|
"hide_system_message_desc": "Systemmeldung auf der Anmeldeseite ausblenden",
|
||||||
|
"hide_school_info": "Schulname und ID ausblenden",
|
||||||
|
"hide_school_info_desc": "Der Schulname und die KRÉTA-ID werden nicht angezeigt"
|
||||||
|
},
|
||||||
|
"roleselect": {
|
||||||
|
"auto_redirect": "Automatische Weiterleitung",
|
||||||
|
"auto_redirect_desc": "Automatische Weiterleitung zum Notenbuch",
|
||||||
|
"hide_school_info": "Schule und Name ausblenden",
|
||||||
|
"hide_school_info_desc": "Der Schulname und Benutzername werden nicht angezeigt"
|
||||||
|
},
|
||||||
|
"bulletin": {
|
||||||
|
"hide_grades": "Noten ausblenden",
|
||||||
|
"hide_grades_desc": "Die Notenkarte ausblenden",
|
||||||
|
"hide_absences": "Fehlzeiten ausblenden",
|
||||||
|
"hide_absences_desc": "Die Fehlzeitenkarte ausblenden",
|
||||||
|
"hide_notes": "Notizen ausblenden",
|
||||||
|
"hide_notes_desc": "Die Notizenkarte ausblenden",
|
||||||
|
"hide_exams": "Angekündigte Prüfungen ausblenden",
|
||||||
|
"hide_exams_desc": "Die Karte für angekündigte Prüfungen ausblenden"
|
||||||
|
},
|
||||||
|
"grades": {
|
||||||
|
"hide_chart": "Diagramm ausblenden",
|
||||||
|
"hide_chart_desc": "Das Notendiagramm ausblenden",
|
||||||
|
"hide_class_average": "Klassendurchschnitt ausblenden",
|
||||||
|
"hide_class_average_desc": "Klassendurchschnittswerte ausblenden"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"themes": {
|
||||||
|
"light_green": "Hellgrün",
|
||||||
|
"dark_green": "Dunkelgrün",
|
||||||
|
"dark_red": "Dunkelrot",
|
||||||
|
"dark_purple": "Dunkellila",
|
||||||
|
"dark_orange": "Dunkelorange",
|
||||||
|
"dark_pink": "Dunkelrosa",
|
||||||
|
"dark_yellow": "Dunkelgelb",
|
||||||
|
"dark_cyan": "Dunkelcyan",
|
||||||
|
"dark_lime": "Dunkellime",
|
||||||
|
"dark_indigo": "Dunkelindigo"
|
||||||
|
},
|
||||||
|
"custom_themes": {
|
||||||
|
"title": "Benutzerdefinierte Designs",
|
||||||
|
"no_themes": "Noch keine benutzerdefinierten Designs",
|
||||||
|
"create": "Neues Design erstellen",
|
||||||
|
"edit": "Design bearbeiten",
|
||||||
|
"name": "Designname",
|
||||||
|
"mode": "Modus",
|
||||||
|
"dark_mode": "Dunkel",
|
||||||
|
"light_mode": "Hell",
|
||||||
|
"colors": "Farben",
|
||||||
|
"accent_color": "Akzentfarbe",
|
||||||
|
"background_color": "Hintergrundfarbe",
|
||||||
|
"card_color": "Kartenfarbe",
|
||||||
|
"text_color": "Textfarbe",
|
||||||
|
"preview": "Vorschau",
|
||||||
|
"share": "Design teilen",
|
||||||
|
"share_description": "Kopieren Sie den Code und teilen Sie ihn mit anderen:",
|
||||||
|
"import": "Design importieren",
|
||||||
|
"import_description": "Fügen Sie den Design-Code ein:",
|
||||||
|
"import_error_empty": "Bitte fügen Sie den Design-Code ein!",
|
||||||
|
"import_error_invalid": "Ungültiger Design-Code!",
|
||||||
|
"delete_confirm": "Möchten Sie dieses Design wirklich löschen?",
|
||||||
|
"manage": "Verwalten"
|
||||||
|
},
|
||||||
|
"languages": {
|
||||||
|
"hu": "Magyar",
|
||||||
|
"en": "English",
|
||||||
|
"de": "Deutsch"
|
||||||
|
},
|
||||||
|
"about": {
|
||||||
|
"title": "Über",
|
||||||
|
"description": "Firka ist ein Open-Source-Projekt, das eine benutzerdefinierte Benutzeroberfläche für das KRÉTA-System erstellt.",
|
||||||
|
"github": "GitHub"
|
||||||
|
},
|
||||||
|
"support": {
|
||||||
|
"title": "Unterstützung",
|
||||||
|
"description": "Wenn Ihnen unsere Arbeit gefällt und Sie die Entwicklung unterstützen möchten, können Sie dies folgendermaßen tun:",
|
||||||
|
"kofi": "Ko-Fi"
|
||||||
|
},
|
||||||
|
"error_reporting": {
|
||||||
|
"title": "Fehlerberichterstattung",
|
||||||
|
"enable": "Fehlerberichterstattung aktivieren",
|
||||||
|
"enable_desc": "Automatische Fehlerberichte an Entwickler senden, um die Erweiterung zu verbessern",
|
||||||
|
"report_issue": "Fehler oder Idee melden",
|
||||||
|
"report_issue_desc": "Öffnen Sie ein GitHub-Issue"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"navigation": {
|
||||||
|
"dashboard": "Dashboard",
|
||||||
|
"timetable": "Stundenplan",
|
||||||
|
"grades": "Noten",
|
||||||
|
"homework": "Hausaufgaben",
|
||||||
|
"absences": "Fehlzeiten",
|
||||||
|
"messages": "Nachrichten",
|
||||||
|
"profile": "Profil",
|
||||||
|
"settings": "Einstellungen",
|
||||||
|
"logout": "Abmelden",
|
||||||
|
"nav_toggle": "Navigation öffnen"
|
||||||
|
},
|
||||||
|
"dashboard": {
|
||||||
|
"welcome": "Willkommen",
|
||||||
|
"recent_grades": "Letzte Noten",
|
||||||
|
"upcoming_lessons": "Kommende Stunden",
|
||||||
|
"homework_due": "Fällige Hausaufgaben",
|
||||||
|
"news": "Nachrichten",
|
||||||
|
"grades": "Ihre Bewertungen",
|
||||||
|
"absences": "Fehlzeiten",
|
||||||
|
"notes": "Notizen",
|
||||||
|
"exams": "Angekündigte Prüfungen",
|
||||||
|
"all_news": "Alle Nachrichten",
|
||||||
|
"all_grades": "Alle Noten",
|
||||||
|
"all_absences": "Alle Fehlzeiten",
|
||||||
|
"all_messages": "Alle Nachrichten",
|
||||||
|
"all_exams": "Alle Prüfungen",
|
||||||
|
"not_supported": "Derzeit sind keine Daten zum Laden verfügbar",
|
||||||
|
"evaluation": "Bewertung"
|
||||||
|
},
|
||||||
|
"grades": {
|
||||||
|
"title": "Noten",
|
||||||
|
"subject": "Fach",
|
||||||
|
"grade": "Note",
|
||||||
|
"date": "Datum",
|
||||||
|
"teacher": "Lehrer",
|
||||||
|
"average": "Durchschnitt",
|
||||||
|
"chart_title": "Noten",
|
||||||
|
"semester_evaluation": "Semesterbewertung",
|
||||||
|
"semester_evaluations": "Semesterbewertungen",
|
||||||
|
"year_end_evaluations": "Jahresabschlussbewertungen",
|
||||||
|
"semester_average": "Semesterdurchschnitt",
|
||||||
|
"no_grades": "Keine Noten",
|
||||||
|
"september": "September",
|
||||||
|
"october": "Oktober",
|
||||||
|
"november": "November",
|
||||||
|
"december": "Dezember",
|
||||||
|
"january_1": "JanuarI",
|
||||||
|
"january_2": "JanuarII",
|
||||||
|
"february": "Februar",
|
||||||
|
"march": "März",
|
||||||
|
"april": "April",
|
||||||
|
"may": "Mai",
|
||||||
|
"june_1": "JuniI",
|
||||||
|
"june_2": "JuniII"
|
||||||
|
},
|
||||||
|
"timetable": {
|
||||||
|
"title": "Stundenplan",
|
||||||
|
"lesson": "Stunde",
|
||||||
|
"time": "Zeit",
|
||||||
|
"subject": "Fach",
|
||||||
|
"teacher": "Lehrer",
|
||||||
|
"classroom": "Klassenzimmer",
|
||||||
|
"homework_indicator": "Hausaufgaben",
|
||||||
|
"test_indicator": "Prüfung",
|
||||||
|
"teacher_label": "Lehrer:",
|
||||||
|
"substitute_teacher_label": "Vertretungslehrer:",
|
||||||
|
"classroom_label": "Raum:",
|
||||||
|
"time_label": "Zeit:",
|
||||||
|
"status_label": "Status:",
|
||||||
|
"substitution": "Vertretung",
|
||||||
|
"cancelled": "Abgesagt",
|
||||||
|
"has_homework": "Hat Hausaufgaben",
|
||||||
|
"no_lessons_this_week": "Keine Stunden in dieser Woche oder Zeitüberschreitung",
|
||||||
|
"monday": "Montag",
|
||||||
|
"tuesday": "Dienstag",
|
||||||
|
"wednesday": "Mittwoch",
|
||||||
|
"thursday": "Donnerstag",
|
||||||
|
"friday": "Freitag",
|
||||||
|
"found_current_week": "Aktuelle Woche gefunden",
|
||||||
|
"open_homework": "Zu den Hausaufgaben gehen",
|
||||||
|
"all_day": "Ganztägig",
|
||||||
|
"special_day": "Besonderer Tag",
|
||||||
|
"unknown_subject": "Unbekanntes Fach",
|
||||||
|
"lesson_topic": "Stundenthema",
|
||||||
|
"homework_completed": "Hausaufgabe erledigt",
|
||||||
|
"homework_mark_completed": "Als erledigt markieren",
|
||||||
|
"homework_mark_uncompleted": "Erledigt - Klicken zum Rückgängigmachen",
|
||||||
|
"custom_homework": "Eigene Hausaufgaben",
|
||||||
|
"custom_test": "Eigene Prüfung",
|
||||||
|
"add_homework_test": "Hausaufgaben oder Prüfung hinzufügen",
|
||||||
|
"close": "Schließen",
|
||||||
|
"add": "Hinzufügen",
|
||||||
|
"homework_details_loading": "Hausaufgabendetails werden geladen...",
|
||||||
|
"homework_details_error": "Fehler beim Laden der Hausaufgabendetails.",
|
||||||
|
"test_details_loading": "Details werden geladen...",
|
||||||
|
"test_details_error": "Prüfungsdetails konnten nicht geladen werden.",
|
||||||
|
"test_details_error_general": "Fehler beim Laden der Prüfungsdetails.",
|
||||||
|
"custom_homework_title": "Eigene Hausaufgaben:",
|
||||||
|
"custom_tests_title": "Eigene Prüfungen:",
|
||||||
|
"delete_homework_confirm": "Möchten Sie diese Hausaufgabe wirklich löschen?",
|
||||||
|
"delete_test_confirm": "Möchten Sie diese Prüfung wirklich löschen?",
|
||||||
|
"task_label": "Aufgabe:",
|
||||||
|
"deadline_label": "Frist:",
|
||||||
|
"name_label": "Name:",
|
||||||
|
"type_label": "Typ:",
|
||||||
|
"announce_date_label": "Ankündigungsdatum:",
|
||||||
|
"no_name": "Kein Name",
|
||||||
|
"no_type": "Kein Typ angegeben",
|
||||||
|
"no_date": "Kein Datum"
|
||||||
|
},
|
||||||
|
"homework": {
|
||||||
|
"title": "Hausaufgaben",
|
||||||
|
"due_date": "Fälligkeitsdatum",
|
||||||
|
"subject": "Fach",
|
||||||
|
"description": "Beschreibung",
|
||||||
|
"filter_title": "Filter",
|
||||||
|
"all_subjects": "Alle Fächer",
|
||||||
|
"all_teachers": "Alle Lehrer",
|
||||||
|
"all_deadlines": "Alle Fristen",
|
||||||
|
"tomorrow_deadline": "Frist morgen",
|
||||||
|
"this_week": "Diese Woche",
|
||||||
|
"next_week": "Nächste Woche",
|
||||||
|
"no_homework": "Keine anzeigbaren Hausaufgaben.",
|
||||||
|
"no_filtered_homework": "Keine Hausaufgaben, die den Filterkriterien entsprechen.",
|
||||||
|
"teacher": "Lehrer",
|
||||||
|
"no_matching_homework": "Keine Hausaufgaben, die den Filterkriterien entsprechen.",
|
||||||
|
"items": "Element",
|
||||||
|
"status": "Status",
|
||||||
|
"total_homework": "Alle Aufgaben",
|
||||||
|
"urgent_homework": "Dringende Aufgaben",
|
||||||
|
"completed_homework": "Erledigte Aufgaben",
|
||||||
|
"pending_homework": "Ausstehende Aufgaben",
|
||||||
|
"completed": "Abgeschlossen",
|
||||||
|
"urgent": "Dringend",
|
||||||
|
"pending": "Ausstehend"
|
||||||
|
},
|
||||||
|
"absences": {
|
||||||
|
"title": "Fehlzeiten",
|
||||||
|
"date": "Datum",
|
||||||
|
"lesson": "Stunde",
|
||||||
|
"type": "Typ",
|
||||||
|
"justified": "Entschuldigt",
|
||||||
|
"unjustified": "Unentschuldigt",
|
||||||
|
"filter_title": "Filter",
|
||||||
|
"all_subjects": "Alle Fächer",
|
||||||
|
"all_types": "Alle",
|
||||||
|
"pending": "Wartet auf Entschuldigung",
|
||||||
|
"subject": "Fach",
|
||||||
|
"justification": "Entschuldigung",
|
||||||
|
"hours": "Stunden",
|
||||||
|
"page_transform_error": "Fehler bei der Seitentransformation",
|
||||||
|
"time_period": "Zeitraum",
|
||||||
|
"all_periods": "Alle Zeiträume",
|
||||||
|
"current_month": "Aktueller Monat",
|
||||||
|
"last_month": "Letzter Monat",
|
||||||
|
"current_semester": "Aktuelles Semester",
|
||||||
|
"last_30_days": "Letzte 30 Tage",
|
||||||
|
"total_absences": "Alle Fehlzeiten",
|
||||||
|
"topic": "Thema",
|
||||||
|
"status": "Status",
|
||||||
|
"absence_type": "Abwesenheit",
|
||||||
|
"late_type": "Verspätung",
|
||||||
|
"minutes": "Minuten"
|
||||||
|
},
|
||||||
|
"profile": {
|
||||||
|
"title": "Profil",
|
||||||
|
"name": "Name",
|
||||||
|
"class": "Klasse",
|
||||||
|
"school": "Schule",
|
||||||
|
"student_id": "Schüler-ID",
|
||||||
|
"settings_title": "Profileinstellungen",
|
||||||
|
"tab_my_data": "Meine Daten",
|
||||||
|
"tab_settings": "Einstellungen",
|
||||||
|
"tab_password": "Passwort ändern",
|
||||||
|
"tab_security": "Sicherheitseinstellungen",
|
||||||
|
"tab_contacts": "Kontakte",
|
||||||
|
"loading_data": "Daten werden geladen...",
|
||||||
|
"loading_error": "Fehler beim Laden der Daten.",
|
||||||
|
"my_data_title": "Meine persönlichen Daten",
|
||||||
|
"personal_data": "Persönliche Daten",
|
||||||
|
"contact_data": "Kontaktdaten",
|
||||||
|
"address_data": "Adressdaten",
|
||||||
|
"bank_account_data": "Bankverbindung",
|
||||||
|
"student_card_data": "Schülerausweis Daten",
|
||||||
|
"default_address": "Standard",
|
||||||
|
"password_change_unavailable": "Die Passwortänderungsfunktion ist derzeit nicht verfügbar.",
|
||||||
|
"security_settings_info": "Um Sicherheitseinstellungen zu verwalten, klicken Sie auf die Schaltfläche unten:",
|
||||||
|
"open_security_settings": "Sicherheitseinstellungen öffnen",
|
||||||
|
"two_factor_description": "Um die Zwei-Faktor-Authentifizierung zu verwenden, installieren Sie eine zeitbasierte Einmalpasswort-App (TOTP):",
|
||||||
|
"android": "Android",
|
||||||
|
"iphone": "iPhone",
|
||||||
|
"enable_2fa": "Zwei-Faktor-Authentifizierung aktivieren",
|
||||||
|
"security_key": "Sicherheitsschlüssel:",
|
||||||
|
"verification_code_label": "Bestätigungscode",
|
||||||
|
"verification_code_help": "Geben Sie den 6-stelligen Code aus der Authentifizierungs-App ein.",
|
||||||
|
"verification_code_placeholder": "123456",
|
||||||
|
"verify_and_activate": "Überprüfen und aktivieren",
|
||||||
|
"backup_codes_description": "Sie können die folgenden Sicherheitscodes zum Anmelden verwenden, wenn Sie keinen Zugriff auf Ihre Authentifizierungs-App haben. Jeder Code kann nur einmal verwendet werden.",
|
||||||
|
"email_label": "E-Mail-Adresse",
|
||||||
|
"email_help": "Die E-Mail-Adresse ist für die Passwort-Erinnerung erforderlich.",
|
||||||
|
"phone_label": "Telefonnummer",
|
||||||
|
"phone_help": "Die Angabe einer Telefonnummer ist optional.",
|
||||||
|
"phone_placeholder": "+49 xxx xxxxxx",
|
||||||
|
"current_password": "Aktuelles Passwort",
|
||||||
|
"new_password": "Neues Passwort",
|
||||||
|
"new_password_help": "Das Passwort muss mindestens 8 Zeichen lang sein.",
|
||||||
|
"confirm_password": "Neues Passwort bestätigen",
|
||||||
|
"change_password": "Passwort ändern",
|
||||||
|
"show_tips": "Tipps anzeigen",
|
||||||
|
"show_tips_help": "Tipps ein-/ausblenden.",
|
||||||
|
"email_required": "Die E-Mail-Adresse ist erforderlich!",
|
||||||
|
"email_invalid": "Bitte geben Sie eine gültige E-Mail-Adresse ein!",
|
||||||
|
"phone_invalid": "Bitte geben Sie eine gültige Telefonnummer ein!",
|
||||||
|
"contacts_saved": "Kontakte erfolgreich gespeichert!",
|
||||||
|
"contacts_save_error": "Fehler beim Speichern. Bitte versuchen Sie es später erneut.",
|
||||||
|
"settings_saved": "Einstellungen erfolgreich gespeichert! Bitte melden Sie sich erneut an, um die Änderungen zu übernehmen.",
|
||||||
|
"settings_save_error": "Fehler beim Speichern. Bitte versuchen Sie es später erneut.",
|
||||||
|
"password_fields_required": "Bitte füllen Sie alle Felder aus!",
|
||||||
|
"passwords_not_match": "Die neuen Passwörter stimmen nicht überein!",
|
||||||
|
"password_too_short": "Das neue Passwort muss mindestens 8 Zeichen lang sein!",
|
||||||
|
"password_changed": "Passwort erfolgreich geändert!",
|
||||||
|
"password_change_error": "Fehler beim Ändern des Passworts. Bitte versuchen Sie es später erneut.",
|
||||||
|
"field_familyName": "Familienname",
|
||||||
|
"field_firstName": "Vorname",
|
||||||
|
"field_birthFamilyName": "Geburts-Familienname",
|
||||||
|
"field_birthFirstName": "Geburts-Vorname",
|
||||||
|
"field_motherFamilyName": "Geburts-Familienname der Mutter",
|
||||||
|
"field_motherFirstName": "Geburts-Vorname der Mutter",
|
||||||
|
"field_birthDate": "Geburtsdatum",
|
||||||
|
"field_birthPlace": "Geburtsort",
|
||||||
|
"field_birthCountry": "Geburtsland",
|
||||||
|
"field_motherTongue": "Muttersprache",
|
||||||
|
"field_citizenship": "Staatsangehörigkeit",
|
||||||
|
"field_classTeacher": "Klassenlehrer",
|
||||||
|
"field_className": "Klasse",
|
||||||
|
"field_classroom": "Klassenzimmer",
|
||||||
|
"field_username": "Benutzername",
|
||||||
|
"field_phone": "Telefonnummer",
|
||||||
|
"field_email": "Benachrichtigungs-E-Mail-Adresse",
|
||||||
|
"field_accountNumber": "Bankkontonummer",
|
||||||
|
"field_bankName": "Bankname",
|
||||||
|
"field_accountOwner": "Kontoinhaber",
|
||||||
|
"field_cardNumber": "Kartennummer",
|
||||||
|
"field_taxId": "Steuer-ID",
|
||||||
|
"field_studentCardNumber": "Studentenausweisnummer",
|
||||||
|
"field_socialSecurityNumber": "Sozialversicherungsnummer"
|
||||||
|
},
|
||||||
|
"login": {
|
||||||
|
"title": "Anmelden",
|
||||||
|
"username": "Benutzername",
|
||||||
|
"password": "Passwort",
|
||||||
|
"login_button": "Anmelden",
|
||||||
|
"forgot_password": "Passwort vergessen",
|
||||||
|
"two_factor_title": "Zwei-Faktor-Authentifizierung",
|
||||||
|
"verification_code": "Bestätigungscode",
|
||||||
|
"username_placeholder": "Benutzername",
|
||||||
|
"password_placeholder": "Passwort",
|
||||||
|
"username_required": "Bitte geben Sie Ihren Benutzernamen ein.",
|
||||||
|
"password_required": "Bitte geben Sie Ihr Passwort ein.",
|
||||||
|
"help_login": "Anmeldeprobleme?",
|
||||||
|
"help_link": "Hilfe",
|
||||||
|
"system_message": "Systemmeldung",
|
||||||
|
"privacy_policy": "Datenschutzerklärung",
|
||||||
|
"kreta_id": "KRÉTA-ID",
|
||||||
|
"system_notification": "Systembenachrichtigung"
|
||||||
|
},
|
||||||
|
"forgot_password": {
|
||||||
|
"title": "Passwort vergessen",
|
||||||
|
"om_id": "Ihre OM-ID",
|
||||||
|
"email": "E-Mail-Adresse",
|
||||||
|
"om_id_placeholder": "Geben Sie Ihre OM-ID ein",
|
||||||
|
"email_placeholder": "Geben Sie Ihre E-Mail-Adresse ein",
|
||||||
|
"om_id_required": "Bitte geben Sie Ihre OM-ID ein.",
|
||||||
|
"email_required": "Bitte geben Sie Ihre E-Mail-Adresse ein."
|
||||||
|
},
|
||||||
|
"two_factor": {
|
||||||
|
"title": "Zwei-Faktor-Authentifizierung",
|
||||||
|
"code_placeholder": "Einmalpasswort",
|
||||||
|
"code_required": "Bitte geben Sie das Einmalpasswort ein.",
|
||||||
|
"verify_button": "Code überprüfen",
|
||||||
|
"verifying": "Überprüfung...",
|
||||||
|
"trust_device": "Diesem Gerät vertrauen"
|
||||||
|
},
|
||||||
|
"logout": {
|
||||||
|
"title": "Abmelden",
|
||||||
|
"message": "Möchten Sie sich wirklich abmelden?",
|
||||||
|
"confirm": "Ja",
|
||||||
|
"cancel": "Abbrechen",
|
||||||
|
"success": "Erfolgreich abgemeldet!",
|
||||||
|
"continue": "Weiter"
|
||||||
|
},
|
||||||
|
"setup": {
|
||||||
|
"welcome": "Richten Sie die Erweiterung in wenigen einfachen Schritten ein",
|
||||||
|
"steps": {
|
||||||
|
"theme": "Design",
|
||||||
|
"language": "Sprache",
|
||||||
|
"finish": "Fertig"
|
||||||
|
},
|
||||||
|
"theme": {
|
||||||
|
"title": "Design wählen",
|
||||||
|
"description": "Wählen Sie das für Sie am besten geeignete Erscheinungsbild"
|
||||||
|
},
|
||||||
|
"language": {
|
||||||
|
"title": "Sprache wählen",
|
||||||
|
"description": "Wählen Sie die Sprache, die Sie verwenden möchten"
|
||||||
|
},
|
||||||
|
"finish": {
|
||||||
|
"title": "Alles erledigt!",
|
||||||
|
"description": "Die Einstellungen wurden erfolgreich gespeichert. Viel Erfolg beim Lernen!",
|
||||||
|
"about": "Über uns",
|
||||||
|
"about_desc": "Erfahren Sie mehr über das Projekt",
|
||||||
|
"support": "Unterstützung",
|
||||||
|
"support_desc": "Unterstützen Sie die Entwicklung",
|
||||||
|
"github": "GitHub",
|
||||||
|
"github_desc": "Sehen Sie sich den Quellcode an",
|
||||||
|
"discord": "Discord",
|
||||||
|
"discord_desc": "Treten Sie der Community bei",
|
||||||
|
"start": "Start"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"common": {
|
||||||
|
"save": "Speichern",
|
||||||
|
"cancel": "Abbrechen",
|
||||||
|
"close": "Schließen",
|
||||||
|
"loading": "Laden...",
|
||||||
|
"error": "Fehler",
|
||||||
|
"success": "Erfolgreich",
|
||||||
|
"warning": "Warnung",
|
||||||
|
"info": "Information",
|
||||||
|
"yes": "Ja",
|
||||||
|
"no": "Nein",
|
||||||
|
"continue": "Weiter",
|
||||||
|
"back": "Zurück",
|
||||||
|
"next": "Weiter",
|
||||||
|
"previous": "Zurück",
|
||||||
|
"all": "Alle",
|
||||||
|
"none": "Keine",
|
||||||
|
"filter": "Filter",
|
||||||
|
"search": "Suchen",
|
||||||
|
"select": "Wählen",
|
||||||
|
"required": "Erforderlich",
|
||||||
|
"optional": "Optional",
|
||||||
|
"api_error": "API-Fehler",
|
||||||
|
"api_load_error": "API-Ladefehler",
|
||||||
|
"monday": "Montag",
|
||||||
|
"tuesday": "Dienstag",
|
||||||
|
"wednesday": "Mittwoch",
|
||||||
|
"thursday": "Donnerstag",
|
||||||
|
"friday": "Freitag",
|
||||||
|
"saturday": "Samstag",
|
||||||
|
"sunday": "Sonntag",
|
||||||
|
"mon": "M",
|
||||||
|
"tue": "D",
|
||||||
|
"wed": "M",
|
||||||
|
"thu": "D",
|
||||||
|
"fri": "F",
|
||||||
|
"sat": "S",
|
||||||
|
"sun": "S",
|
||||||
|
"today": "Heute",
|
||||||
|
"tomorrow": "Morgen",
|
||||||
|
"january": "Januar",
|
||||||
|
"february": "Februar",
|
||||||
|
"march": "März",
|
||||||
|
"april": "April",
|
||||||
|
"may": "Mai",
|
||||||
|
"june": "Juni",
|
||||||
|
"july": "Juli",
|
||||||
|
"august": "August",
|
||||||
|
"september": "September",
|
||||||
|
"october": "Oktober",
|
||||||
|
"november": "November",
|
||||||
|
"december": "Dezember"
|
||||||
|
},
|
||||||
|
"months": {
|
||||||
|
"january": "Januar",
|
||||||
|
"february": "Februar",
|
||||||
|
"march": "März",
|
||||||
|
"april": "April",
|
||||||
|
"may": "Mai",
|
||||||
|
"june": "Juni",
|
||||||
|
"july": "Juli",
|
||||||
|
"august": "August",
|
||||||
|
"september": "September",
|
||||||
|
"october": "Oktober",
|
||||||
|
"november": "November",
|
||||||
|
"december": "Dezember"
|
||||||
|
},
|
||||||
|
"roleselect": {
|
||||||
|
"student_book": "Notenbuch",
|
||||||
|
"student_description": "Noten, Fehlzeiten, Stundenplan und andere Informationen anzeigen.",
|
||||||
|
"dkt_title": "Digitaler Kollaborationsraum (DKT)",
|
||||||
|
"dkt_description": "Klassenzimmerkommunikation und Aufgaben.",
|
||||||
|
"logout_title": "Abmelden",
|
||||||
|
"logout_description": "Vom System abmelden",
|
||||||
|
"role_change_error": "Fehler beim Wechseln der Rolle."
|
||||||
|
},
|
||||||
|
"maintenance": {
|
||||||
|
"title": "Wartung",
|
||||||
|
"message1": "Das KRÉTA-System wird derzeit aktualisiert und wird bald wieder verfügbar sein.",
|
||||||
|
"message2": "Vielen Dank für Ihre Geduld und Ihr Verständnis!",
|
||||||
|
"team": "KRÉTA-Team"
|
||||||
|
},
|
||||||
|
"about": {
|
||||||
|
"title": "Über",
|
||||||
|
"description": "Firka ist ein Open-Source-Projekt, das eine benutzerdefinierte Benutzeroberfläche für das KRÉTA-System erstellt.",
|
||||||
|
"support_title": "Unterstützung",
|
||||||
|
"support_description": "Wenn Ihnen unsere Arbeit gefällt und Sie die Entwicklung unterstützen möchten, können Sie dies folgendermaßen tun:",
|
||||||
|
"version": "v1.3.0"
|
||||||
|
},
|
||||||
|
"app": {
|
||||||
|
"title": "Firka - KRÉTA",
|
||||||
|
"settings_title": "Firxa - Einstellungen"
|
||||||
|
},
|
||||||
|
"forgotpassword": {
|
||||||
|
"title": "Passwort vergessen",
|
||||||
|
"om_id_label": "OM-ID",
|
||||||
|
"om_id_placeholder": "Geben Sie Ihre OM-ID ein",
|
||||||
|
"om_id_required": "Die OM-ID ist erforderlich",
|
||||||
|
"email_label": "E-Mail-Adresse",
|
||||||
|
"email_placeholder": "Geben Sie Ihre E-Mail-Adresse ein",
|
||||||
|
"email_required": "Die E-Mail-Adresse ist erforderlich",
|
||||||
|
"back_to_login": "Zurück zur Anmeldung",
|
||||||
|
"reset_button": "Passwort zurücksetzen",
|
||||||
|
"error_message": "Fehler beim Zurücksetzen des Passworts",
|
||||||
|
"success_message": "Link zum Zurücksetzen des Passworts an Ihre E-Mail-Adresse gesendet",
|
||||||
|
"invalid_data": "Ungültige Daten",
|
||||||
|
"invalid_email": "Ungültiges E-Mail-Format",
|
||||||
|
"recaptcha_required": "Bitte füllen Sie das reCAPTCHA aus"
|
||||||
|
},
|
||||||
|
"modal": {
|
||||||
|
"add_item_title": "Neues Element hinzufügen",
|
||||||
|
"type_label": "Typ:",
|
||||||
|
"homework_option": "Hausaufgaben",
|
||||||
|
"test_option": "Prüfung",
|
||||||
|
"description_label": "Beschreibung:",
|
||||||
|
"cancel": "Abbrechen",
|
||||||
|
"save": "Speichern"
|
||||||
|
},
|
||||||
|
"search": {
|
||||||
|
"choose_school": "Schule wählen",
|
||||||
|
"privacy_policy": "Datenschutzrichtlinie",
|
||||||
|
"title": "Schule wählen",
|
||||||
|
"select_institution": "Bitte wählen Sie eine Einrichtung aus, um fortzufahren!"
|
||||||
|
},
|
||||||
|
"icons": {
|
||||||
|
"cancel": "cancel",
|
||||||
|
"pending": "pending"
|
||||||
|
},
|
||||||
|
"messages": {
|
||||||
|
"title": "Nachrichten",
|
||||||
|
"back": "Zurück",
|
||||||
|
"surveys": "Umfragen",
|
||||||
|
"loading": "Nachrichten werden geladen...",
|
||||||
|
"error": {
|
||||||
|
"title": "Fehler aufgetreten",
|
||||||
|
"description": "Nachrichten konnten nicht geladen werden.",
|
||||||
|
"retry": "Erneut versuchen"
|
||||||
|
},
|
||||||
|
"empty": {
|
||||||
|
"title": "Keine Nachrichten",
|
||||||
|
"description": "Derzeit sind keine eingegangenen Nachrichten vorhanden."
|
||||||
|
},
|
||||||
|
"sender": "Absender",
|
||||||
|
"subject": "Betreff",
|
||||||
|
"date": "Datum",
|
||||||
|
"unread": "Ungelesen",
|
||||||
|
"read": "Gelesen",
|
||||||
|
"message_detail": {
|
||||||
|
"title": "Nachrichtendetails",
|
||||||
|
"loading": "Nachricht wird geladen...",
|
||||||
|
"error": "Fehler beim Laden der Nachricht.",
|
||||||
|
"from": "Von",
|
||||||
|
"to": "An",
|
||||||
|
"subject": "Betreff",
|
||||||
|
"date": "Datum",
|
||||||
|
"content": "Inhalt",
|
||||||
|
"attachments": "Anhänge",
|
||||||
|
"no_attachments": "Keine Anhänge",
|
||||||
|
"reply": "Antworten",
|
||||||
|
"forward": "Weiterleiten",
|
||||||
|
"delete": "Löschen",
|
||||||
|
"mark_read": "Als gelesen markieren",
|
||||||
|
"mark_unread": "Als ungelesen markieren",
|
||||||
|
"back_to_messages": "Zurück zu den Nachrichten"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
193
i18n/en.json
@@ -5,8 +5,47 @@
|
|||||||
},
|
},
|
||||||
"settings": {
|
"settings": {
|
||||||
"title": "Settings",
|
"title": "Settings",
|
||||||
|
"appearance": "Appearance",
|
||||||
"theme": "Theme",
|
"theme": "Theme",
|
||||||
"language": "Language",
|
"language": "Language",
|
||||||
|
"tabs": {
|
||||||
|
"appearance": "Appearance",
|
||||||
|
"settings": "Settings",
|
||||||
|
"about": "About"
|
||||||
|
},
|
||||||
|
"page_settings": {
|
||||||
|
"title": "Page Settings",
|
||||||
|
"current_page": "Current page",
|
||||||
|
"no_settings": "No custom settings available for this page.",
|
||||||
|
"login": {
|
||||||
|
"hide_system_message": "Hide system message",
|
||||||
|
"hide_system_message_desc": "Hide the system message shown on the login page",
|
||||||
|
"hide_school_info": "Hide school name and ID",
|
||||||
|
"hide_school_info_desc": "The school name and KRÉTA ID will not be displayed"
|
||||||
|
},
|
||||||
|
"roleselect": {
|
||||||
|
"auto_redirect": "Auto redirect",
|
||||||
|
"auto_redirect_desc": "Automatically redirect to the gradebook",
|
||||||
|
"hide_school_info": "Hide school and name",
|
||||||
|
"hide_school_info_desc": "The school name and user name will not be displayed"
|
||||||
|
},
|
||||||
|
"bulletin": {
|
||||||
|
"hide_grades": "Hide grades",
|
||||||
|
"hide_grades_desc": "Hide the grades card",
|
||||||
|
"hide_absences": "Hide absences",
|
||||||
|
"hide_absences_desc": "Hide the absences card",
|
||||||
|
"hide_notes": "Hide notes",
|
||||||
|
"hide_notes_desc": "Hide the notes card",
|
||||||
|
"hide_exams": "Hide announced exams",
|
||||||
|
"hide_exams_desc": "Hide the announced exams card"
|
||||||
|
},
|
||||||
|
"grades": {
|
||||||
|
"hide_chart": "Hide chart",
|
||||||
|
"hide_chart_desc": "Hide the grades chart",
|
||||||
|
"hide_class_average": "Hide class average",
|
||||||
|
"hide_class_average_desc": "Hide class average values"
|
||||||
|
}
|
||||||
|
},
|
||||||
"themes": {
|
"themes": {
|
||||||
"light_green": "Light Green",
|
"light_green": "Light Green",
|
||||||
"dark_green": "Dark Green",
|
"dark_green": "Dark Green",
|
||||||
@@ -19,9 +58,35 @@
|
|||||||
"dark_lime": "Dark Lime",
|
"dark_lime": "Dark Lime",
|
||||||
"dark_indigo": "Dark Indigo"
|
"dark_indigo": "Dark Indigo"
|
||||||
},
|
},
|
||||||
|
"custom_themes": {
|
||||||
|
"title": "Custom themes",
|
||||||
|
"no_themes": "No custom themes yet",
|
||||||
|
"create": "Create new theme",
|
||||||
|
"edit": "Edit theme",
|
||||||
|
"name": "Theme name",
|
||||||
|
"mode": "Mode",
|
||||||
|
"dark_mode": "Dark",
|
||||||
|
"light_mode": "Light",
|
||||||
|
"colors": "Colors",
|
||||||
|
"accent_color": "Accent color",
|
||||||
|
"background_color": "Background color",
|
||||||
|
"card_color": "Card color",
|
||||||
|
"text_color": "Text color",
|
||||||
|
"preview": "Preview",
|
||||||
|
"share": "Share",
|
||||||
|
"share_description": "Copy the code and share it with others:",
|
||||||
|
"import": "Import",
|
||||||
|
"import_description": "Paste the theme code:",
|
||||||
|
"import_error_empty": "Please paste the theme code!",
|
||||||
|
"import_error_invalid": "Invalid theme code!",
|
||||||
|
"delete_confirm": "Are you sure you want to delete this theme?",
|
||||||
|
"delete": "Delete",
|
||||||
|
"manage": "Manage"
|
||||||
|
},
|
||||||
"languages": {
|
"languages": {
|
||||||
"hu": "Magyar",
|
"hu": "Magyar",
|
||||||
"en": "English"
|
"en": "English",
|
||||||
|
"de": "Deutsch"
|
||||||
},
|
},
|
||||||
"about": {
|
"about": {
|
||||||
"title": "About",
|
"title": "About",
|
||||||
@@ -33,32 +98,12 @@
|
|||||||
"description": "If you like our work and would like to support the development, you can do so in the following way:",
|
"description": "If you like our work and would like to support the development, you can do so in the following way:",
|
||||||
"kofi": "Ko-Fi"
|
"kofi": "Ko-Fi"
|
||||||
},
|
},
|
||||||
"custom_theme": {
|
"error_reporting": {
|
||||||
"title": "Custom Theme",
|
"title": "Error Reporting",
|
||||||
"create": "Create New Theme",
|
"enable": "Enable error reporting",
|
||||||
"import": "Import Theme",
|
"enable_desc": "Send automatic error reports to developers to help fix the extension",
|
||||||
"editor_title": "Theme Editor",
|
"report_issue": "Report bug or idea",
|
||||||
"import_title": "Import Theme",
|
"report_issue_desc": "Open a GitHub issue"
|
||||||
"name": "Theme name",
|
|
||||||
"background": "Background",
|
|
||||||
"text": "Text",
|
|
||||||
"accent": "Accent colors",
|
|
||||||
"main_background": "Main background",
|
|
||||||
"card_background": "Card background",
|
|
||||||
"primary_text": "Primary text",
|
|
||||||
"secondary_text": "Secondary text",
|
|
||||||
"primary_accent": "Primary accent",
|
|
||||||
"secondary_accent": "Secondary accent",
|
|
||||||
"preview": "Preview",
|
|
||||||
"save": "Save",
|
|
||||||
"cancel": "Cancel",
|
|
||||||
"import_string": "Theme ID",
|
|
||||||
"apply": "Apply",
|
|
||||||
"edit": "Edit",
|
|
||||||
"export": "Export",
|
|
||||||
"delete": "Delete",
|
|
||||||
"no_themes": "No custom themes yet",
|
|
||||||
"delete_confirm": "Are you sure you want to delete the \"{name}\" theme?"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"navigation": {
|
"navigation": {
|
||||||
@@ -221,7 +266,10 @@
|
|||||||
"last_30_days": "Last 30 days",
|
"last_30_days": "Last 30 days",
|
||||||
"total_absences": "Total absences",
|
"total_absences": "Total absences",
|
||||||
"topic": "Topic",
|
"topic": "Topic",
|
||||||
"status": "Status"
|
"status": "Status",
|
||||||
|
"absence_type": "Absence",
|
||||||
|
"late_type": "Late",
|
||||||
|
"minutes": "minutes"
|
||||||
},
|
},
|
||||||
"profile": {
|
"profile": {
|
||||||
"title": "Profile",
|
"title": "Profile",
|
||||||
@@ -230,10 +278,23 @@
|
|||||||
"school": "School",
|
"school": "School",
|
||||||
"student_id": "Student ID",
|
"student_id": "Student ID",
|
||||||
"settings_title": "Profile settings",
|
"settings_title": "Profile settings",
|
||||||
|
"tab_my_data": "My Data",
|
||||||
"tab_settings": "Settings",
|
"tab_settings": "Settings",
|
||||||
"tab_password": "Change password",
|
"tab_password": "Change password",
|
||||||
"tab_security": "Security settings",
|
"tab_security": "Security settings",
|
||||||
"tab_contacts": "Contact information",
|
"tab_contacts": "Contact information",
|
||||||
|
"loading_data": "Loading data...",
|
||||||
|
"loading_error": "An error occurred while loading the data.",
|
||||||
|
"my_data_title": "My Personal Data",
|
||||||
|
"personal_data": "Personal Information",
|
||||||
|
"contact_data": "Contact Information",
|
||||||
|
"address_data": "Address Data",
|
||||||
|
"bank_account_data": "Bank Account Data",
|
||||||
|
"student_card_data": "Student Card Data",
|
||||||
|
"default_address": "Default",
|
||||||
|
"password_change_unavailable": "The password change function is currently unavailable.",
|
||||||
|
"security_settings_info": "To manage security settings, click the button below:",
|
||||||
|
"open_security_settings": "Open Security Settings",
|
||||||
"two_factor_description": "To use two-factor authentication, install a time-based one-time password (TOTP) application:",
|
"two_factor_description": "To use two-factor authentication, install a time-based one-time password (TOTP) application:",
|
||||||
"android": "Android",
|
"android": "Android",
|
||||||
"iphone": "iPhone",
|
"iphone": "iPhone",
|
||||||
@@ -267,7 +328,31 @@
|
|||||||
"passwords_not_match": "New passwords do not match!",
|
"passwords_not_match": "New passwords do not match!",
|
||||||
"password_too_short": "New password must be at least 8 characters long!",
|
"password_too_short": "New password must be at least 8 characters long!",
|
||||||
"password_changed": "Password changed successfully!",
|
"password_changed": "Password changed successfully!",
|
||||||
"password_change_error": "An error occurred while changing password. Please try again later."
|
"password_change_error": "An error occurred while changing password. Please try again later.",
|
||||||
|
"field_familyName": "Family name",
|
||||||
|
"field_firstName": "First name",
|
||||||
|
"field_birthFamilyName": "Birth family name",
|
||||||
|
"field_birthFirstName": "Birth first name",
|
||||||
|
"field_motherFamilyName": "Mother's birth family name",
|
||||||
|
"field_motherFirstName": "Mother's birth first name",
|
||||||
|
"field_birthDate": "Date of birth",
|
||||||
|
"field_birthPlace": "Place of birth",
|
||||||
|
"field_birthCountry": "Country of birth",
|
||||||
|
"field_motherTongue": "Mother tongue",
|
||||||
|
"field_citizenship": "Citizenship",
|
||||||
|
"field_classTeacher": "Class teacher",
|
||||||
|
"field_className": "Class",
|
||||||
|
"field_classroom": "Classroom",
|
||||||
|
"field_username": "Username",
|
||||||
|
"field_phone": "Phone number",
|
||||||
|
"field_email": "Notification email address",
|
||||||
|
"field_accountNumber": "Bank account number",
|
||||||
|
"field_bankName": "Bank name",
|
||||||
|
"field_accountOwner": "Account owner's name",
|
||||||
|
"field_cardNumber": "Card number",
|
||||||
|
"field_taxId": "Tax ID",
|
||||||
|
"field_studentCardNumber": "Student card number",
|
||||||
|
"field_socialSecurityNumber": "Social security number"
|
||||||
},
|
},
|
||||||
"login": {
|
"login": {
|
||||||
"title": "Login",
|
"title": "Login",
|
||||||
@@ -313,6 +398,35 @@
|
|||||||
"success": "Successfully logged out!",
|
"success": "Successfully logged out!",
|
||||||
"continue": "Continue"
|
"continue": "Continue"
|
||||||
},
|
},
|
||||||
|
"setup": {
|
||||||
|
"welcome": "Set up the extension in a few simple steps",
|
||||||
|
"steps": {
|
||||||
|
"theme": "Theme",
|
||||||
|
"language": "Language",
|
||||||
|
"finish": "Done"
|
||||||
|
},
|
||||||
|
"theme": {
|
||||||
|
"title": "Choose a theme",
|
||||||
|
"description": "Select the appearance that suits you best"
|
||||||
|
},
|
||||||
|
"language": {
|
||||||
|
"title": "Choose a language",
|
||||||
|
"description": "Select the language you want to use"
|
||||||
|
},
|
||||||
|
"finish": {
|
||||||
|
"title": "All set!",
|
||||||
|
"description": "Settings saved successfully. Let's start learning!",
|
||||||
|
"about": "About",
|
||||||
|
"about_desc": "Learn more about the project",
|
||||||
|
"support": "Support",
|
||||||
|
"support_desc": "Support the development",
|
||||||
|
"github": "GitHub",
|
||||||
|
"github_desc": "View the source code",
|
||||||
|
"discord": "Discord",
|
||||||
|
"discord_desc": "Join the community",
|
||||||
|
"start": "Get Started"
|
||||||
|
}
|
||||||
|
},
|
||||||
"common": {
|
"common": {
|
||||||
"save": "Save",
|
"save": "Save",
|
||||||
"cancel": "Cancel",
|
"cancel": "Cancel",
|
||||||
@@ -344,8 +458,27 @@
|
|||||||
"friday": "Friday",
|
"friday": "Friday",
|
||||||
"saturday": "Saturday",
|
"saturday": "Saturday",
|
||||||
"sunday": "Sunday",
|
"sunday": "Sunday",
|
||||||
|
"mon": "M",
|
||||||
|
"tue": "T",
|
||||||
|
"wed": "W",
|
||||||
|
"thu": "T",
|
||||||
|
"fri": "F",
|
||||||
|
"sat": "S",
|
||||||
|
"sun": "S",
|
||||||
"today": "Today",
|
"today": "Today",
|
||||||
"tomorrow": "Tomorrow"
|
"tomorrow": "Tomorrow",
|
||||||
|
"january": "January",
|
||||||
|
"february": "February",
|
||||||
|
"march": "March",
|
||||||
|
"april": "April",
|
||||||
|
"may": "May",
|
||||||
|
"june": "June",
|
||||||
|
"july": "July",
|
||||||
|
"august": "August",
|
||||||
|
"september": "September",
|
||||||
|
"october": "October",
|
||||||
|
"november": "November",
|
||||||
|
"december": "December"
|
||||||
},
|
},
|
||||||
"months": {
|
"months": {
|
||||||
"january": "January",
|
"january": "January",
|
||||||
|
|||||||
195
i18n/hu.json
@@ -5,8 +5,47 @@
|
|||||||
},
|
},
|
||||||
"settings": {
|
"settings": {
|
||||||
"title": "Beállítások",
|
"title": "Beállítások",
|
||||||
|
"appearance": "Megjelenés",
|
||||||
"theme": "Téma",
|
"theme": "Téma",
|
||||||
"language": "Nyelv",
|
"language": "Nyelv",
|
||||||
|
"tabs": {
|
||||||
|
"appearance": "Megjelenés",
|
||||||
|
"settings": "Beállítások",
|
||||||
|
"about": "Névjegy"
|
||||||
|
},
|
||||||
|
"page_settings": {
|
||||||
|
"title": "Oldal beállítások",
|
||||||
|
"current_page": "Aktuális oldal",
|
||||||
|
"no_settings": "Ehhez az oldalhoz nincsenek egyéni beállítások.",
|
||||||
|
"login": {
|
||||||
|
"hide_system_message": "Rendszerüzenet elrejtése",
|
||||||
|
"hide_system_message_desc": "A bejelentkezési oldalon megjelenő rendszerüzenet elrejtése",
|
||||||
|
"hide_school_info": "Iskola nevének és azonosítójának elrejtése",
|
||||||
|
"hide_school_info_desc": "Az iskola neve és KRÉTA azonosítója nem jelenik meg"
|
||||||
|
},
|
||||||
|
"roleselect": {
|
||||||
|
"auto_redirect": "Automatikus továbblépés",
|
||||||
|
"auto_redirect_desc": "Automatikusan átirányít az ellenőrzőkönyvre",
|
||||||
|
"hide_school_info": "Iskola és név elrejtése",
|
||||||
|
"hide_school_info_desc": "Az iskola neve és a felhasználó neve nem jelenik meg"
|
||||||
|
},
|
||||||
|
"bulletin": {
|
||||||
|
"hide_grades": "Értékelések elrejtése",
|
||||||
|
"hide_grades_desc": "Az értékeléseid kártya elrejtése",
|
||||||
|
"hide_absences": "Mulasztások elrejtése",
|
||||||
|
"hide_absences_desc": "A mulasztások kártya elrejtése",
|
||||||
|
"hide_notes": "Feljegyzések elrejtése",
|
||||||
|
"hide_notes_desc": "A feljegyzések kártya elrejtése",
|
||||||
|
"hide_exams": "Bejelentett dolgozatok elrejtése",
|
||||||
|
"hide_exams_desc": "A bejelentett dolgozatok kártya elrejtése"
|
||||||
|
},
|
||||||
|
"grades": {
|
||||||
|
"hide_chart": "Grafikon elrejtése",
|
||||||
|
"hide_chart_desc": "A jegyek grafikonjának elrejtése",
|
||||||
|
"hide_class_average": "Osztályátlag elrejtése",
|
||||||
|
"hide_class_average_desc": "Az osztályátlag értékek elrejtése"
|
||||||
|
}
|
||||||
|
},
|
||||||
"themes": {
|
"themes": {
|
||||||
"light_blue": "Világos Kék",
|
"light_blue": "Világos Kék",
|
||||||
"light_green": "Világos Zöld",
|
"light_green": "Világos Zöld",
|
||||||
@@ -21,9 +60,35 @@
|
|||||||
"dark_lime": "Sötét Lime",
|
"dark_lime": "Sötét Lime",
|
||||||
"dark_indigo": "Sötét Indigó"
|
"dark_indigo": "Sötét Indigó"
|
||||||
},
|
},
|
||||||
|
"custom_themes": {
|
||||||
|
"title": "Egyéni témák",
|
||||||
|
"no_themes": "Még nincsenek egyéni témák",
|
||||||
|
"create": "Új téma",
|
||||||
|
"edit": "Téma szerkesztése",
|
||||||
|
"name": "Téma neve",
|
||||||
|
"mode": "Mód",
|
||||||
|
"dark_mode": "Sötét",
|
||||||
|
"light_mode": "Világos",
|
||||||
|
"colors": "Színek",
|
||||||
|
"accent_color": "Kiemelő szín",
|
||||||
|
"background_color": "Háttér szín",
|
||||||
|
"card_color": "Kártya szín",
|
||||||
|
"text_color": "Szöveg szín",
|
||||||
|
"preview": "Előnézet",
|
||||||
|
"share": "Megosztás",
|
||||||
|
"share_description": "Másold ki a kódot és oszd meg másokkal:",
|
||||||
|
"import": "Importálás",
|
||||||
|
"import_description": "Illeszd be a téma kódot:",
|
||||||
|
"import_error_empty": "Kérlek illeszd be a téma kódot!",
|
||||||
|
"import_error_invalid": "Érvénytelen téma kód!",
|
||||||
|
"delete_confirm": "Biztosan törölni szeretnéd ezt a témát?",
|
||||||
|
"delete": "Törlés",
|
||||||
|
"manage": "Kezelés"
|
||||||
|
},
|
||||||
"languages": {
|
"languages": {
|
||||||
"hu": "Magyar",
|
"hu": "Magyar",
|
||||||
"en": "English"
|
"en": "English",
|
||||||
|
"de": "Deutsch"
|
||||||
},
|
},
|
||||||
"about": {
|
"about": {
|
||||||
"title": "Névjegy",
|
"title": "Névjegy",
|
||||||
@@ -35,32 +100,12 @@
|
|||||||
"description": "Ha tetszik a munkánk és szeretnéd támogatni a fejlesztést, az alábbi módon teheted meg:",
|
"description": "Ha tetszik a munkánk és szeretnéd támogatni a fejlesztést, az alábbi módon teheted meg:",
|
||||||
"kofi": "Ko-Fi"
|
"kofi": "Ko-Fi"
|
||||||
},
|
},
|
||||||
"custom_theme": {
|
"error_reporting": {
|
||||||
"title": "Egyéni Téma",
|
"title": "Hibajelentés",
|
||||||
"create": "Új Téma Létrehozása",
|
"enable": "Hibajelentés engedélyezése",
|
||||||
"import": "Téma Importálása",
|
"enable_desc": "Automatikus hibajelentés küldése a fejlesztőknek a bővítmény javításához",
|
||||||
"editor_title": "Téma Szerkesztő",
|
"report_issue": "Hiba vagy ötlet jelentése",
|
||||||
"import_title": "Téma Importálása",
|
"report_issue_desc": "Nyiss egy GitHub issue-t"
|
||||||
"name": "Téma neve",
|
|
||||||
"background": "Háttér",
|
|
||||||
"text": "Szöveg",
|
|
||||||
"accent": "Kiemelő színek",
|
|
||||||
"main_background": "Fő háttér",
|
|
||||||
"card_background": "Kártya háttér",
|
|
||||||
"primary_text": "Elsődleges szöveg",
|
|
||||||
"secondary_text": "Másodlagos szöveg",
|
|
||||||
"primary_accent": "Elsődleges kiemelő",
|
|
||||||
"secondary_accent": "Másodlagos kiemelő",
|
|
||||||
"preview": "Előnézet",
|
|
||||||
"save": "Mentés",
|
|
||||||
"cancel": "Mégse",
|
|
||||||
"import_string": "Téma azonosító",
|
|
||||||
"apply": "Alkalmaz",
|
|
||||||
"edit": "Szerkeszt",
|
|
||||||
"export": "Export",
|
|
||||||
"delete": "Töröl",
|
|
||||||
"no_themes": "Még nincsenek egyéni témák",
|
|
||||||
"delete_confirm": "Biztosan törölni szeretnéd a \"{name}\" témát?"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"navigation": {
|
"navigation": {
|
||||||
@@ -221,9 +266,12 @@
|
|||||||
"last_month": "Előző hónap",
|
"last_month": "Előző hónap",
|
||||||
"current_semester": "Aktuális félév",
|
"current_semester": "Aktuális félév",
|
||||||
"last_30_days": "Utolsó 30 nap",
|
"last_30_days": "Utolsó 30 nap",
|
||||||
"total_absences": "Összes hiányzás",
|
"total_absences": "Összes mulasztás",
|
||||||
"topic": "Téma",
|
"topic": "Téma",
|
||||||
"status": "Állapot"
|
"status": "Állapot",
|
||||||
|
"absence_type": "Hiányzás",
|
||||||
|
"late_type": "Késés",
|
||||||
|
"minutes": "perc"
|
||||||
},
|
},
|
||||||
"profile": {
|
"profile": {
|
||||||
"title": "Profil",
|
"title": "Profil",
|
||||||
@@ -232,10 +280,23 @@
|
|||||||
"school": "Iskola",
|
"school": "Iskola",
|
||||||
"student_id": "Diák azonosító",
|
"student_id": "Diák azonosító",
|
||||||
"settings_title": "Profil beállítások",
|
"settings_title": "Profil beállítások",
|
||||||
|
"tab_my_data": "Adataim",
|
||||||
"tab_settings": "Beállítások",
|
"tab_settings": "Beállítások",
|
||||||
"tab_password": "Jelszó módosítása",
|
"tab_password": "Jelszó módosítása",
|
||||||
"tab_security": "Biztonsági beállítások",
|
"tab_security": "Biztonsági beállítások",
|
||||||
"tab_contacts": "Elérhetőségek",
|
"tab_contacts": "Elérhetőségek",
|
||||||
|
"loading_data": "Adatok betöltése...",
|
||||||
|
"loading_error": "Hiba történt az adatok betöltése során.",
|
||||||
|
"my_data_title": "Személyes adataim",
|
||||||
|
"personal_data": "Személyes adatok",
|
||||||
|
"contact_data": "Elérhetőségi adatok",
|
||||||
|
"address_data": "Lakcím adatok",
|
||||||
|
"bank_account_data": "Bankszámla adatok",
|
||||||
|
"student_card_data": "Tanulói igazolvány adatok",
|
||||||
|
"default_address": "Alapértelmezett",
|
||||||
|
"password_change_unavailable": "A jelszó módosítás funkció jelenleg nem érhető el.",
|
||||||
|
"security_settings_info": "A biztonsági beállítások kezeléséhez kattints az alábbi gombra:",
|
||||||
|
"open_security_settings": "Biztonsági beállítások megnyitása",
|
||||||
"two_factor_description": "A kétfaktoros hitelesítés használatához telepítsen egy időalapú, egyszer használatos jelszó (TOTP) alkalmazást:",
|
"two_factor_description": "A kétfaktoros hitelesítés használatához telepítsen egy időalapú, egyszer használatos jelszó (TOTP) alkalmazást:",
|
||||||
"android": "Android",
|
"android": "Android",
|
||||||
"iphone": "iPhone",
|
"iphone": "iPhone",
|
||||||
@@ -269,7 +330,31 @@
|
|||||||
"passwords_not_match": "Az új jelszavak nem egyeznek!",
|
"passwords_not_match": "Az új jelszavak nem egyeznek!",
|
||||||
"password_too_short": "Az új jelszónak legalább 8 karakter hosszúnak kell lennie!",
|
"password_too_short": "Az új jelszónak legalább 8 karakter hosszúnak kell lennie!",
|
||||||
"password_changed": "Jelszó sikeresen módosítva!",
|
"password_changed": "Jelszó sikeresen módosítva!",
|
||||||
"password_change_error": "Hiba történt a jelszó módosítása során. Kérjük, próbálja újra később."
|
"password_change_error": "Hiba történt a jelszó módosítása során. Kérjük, próbálja újra később.",
|
||||||
|
"field_familyName": "Családi név",
|
||||||
|
"field_firstName": "Utónév",
|
||||||
|
"field_birthFamilyName": "Születési családi név",
|
||||||
|
"field_birthFirstName": "Születési utónév",
|
||||||
|
"field_motherFamilyName": "Anyja születési családi neve",
|
||||||
|
"field_motherFirstName": "Anyja születési utóneve",
|
||||||
|
"field_birthDate": "Születési idő",
|
||||||
|
"field_birthPlace": "Születési hely",
|
||||||
|
"field_birthCountry": "Születési ország",
|
||||||
|
"field_motherTongue": "Anyanyelv",
|
||||||
|
"field_citizenship": "Állampolgárság",
|
||||||
|
"field_classTeacher": "Osztályfőnök",
|
||||||
|
"field_className": "Osztály",
|
||||||
|
"field_classroom": "Terem",
|
||||||
|
"field_username": "Felhasználónév",
|
||||||
|
"field_phone": "Telefonszám",
|
||||||
|
"field_email": "Értesítési e-mail cím",
|
||||||
|
"field_accountNumber": "Bankszámlaszám",
|
||||||
|
"field_bankName": "Számlavezető bank",
|
||||||
|
"field_accountOwner": "Bankszámla tulajdonos neve",
|
||||||
|
"field_cardNumber": "Igazolvány száma",
|
||||||
|
"field_taxId": "Adóazonosító jel",
|
||||||
|
"field_studentCardNumber": "Diákigazolvány szám",
|
||||||
|
"field_socialSecurityNumber": "TAJ-szám"
|
||||||
},
|
},
|
||||||
"login": {
|
"login": {
|
||||||
"title": "Bejelentkezés",
|
"title": "Bejelentkezés",
|
||||||
@@ -315,6 +400,35 @@
|
|||||||
"success": "Sikeres kijelentkezés!",
|
"success": "Sikeres kijelentkezés!",
|
||||||
"continue": "Tovább"
|
"continue": "Tovább"
|
||||||
},
|
},
|
||||||
|
"setup": {
|
||||||
|
"welcome": "Állítsd be a bővítményt néhány egyszerű lépésben",
|
||||||
|
"steps": {
|
||||||
|
"theme": "Téma",
|
||||||
|
"language": "Nyelv",
|
||||||
|
"finish": "Kész"
|
||||||
|
},
|
||||||
|
"theme": {
|
||||||
|
"title": "Válassz témát",
|
||||||
|
"description": "Válaszd ki a számodra legmegfelelőbb megjelenést"
|
||||||
|
},
|
||||||
|
"language": {
|
||||||
|
"title": "Válassz nyelvet",
|
||||||
|
"description": "Válaszd ki a használni kívánt nyelvet"
|
||||||
|
},
|
||||||
|
"finish": {
|
||||||
|
"title": "Minden kész!",
|
||||||
|
"description": "A beállítások sikeresen mentve. Indulhat a tanulás!",
|
||||||
|
"about": "Rólunk",
|
||||||
|
"about_desc": "Tudj meg többet a projektről",
|
||||||
|
"support": "Támogatás",
|
||||||
|
"support_desc": "Támogasd a fejlesztést",
|
||||||
|
"github": "GitHub",
|
||||||
|
"github_desc": "Nézd meg a forráskódot",
|
||||||
|
"discord": "Discord",
|
||||||
|
"discord_desc": "Csatlakozz a közösséghez",
|
||||||
|
"start": "Kezdés"
|
||||||
|
}
|
||||||
|
},
|
||||||
"common": {
|
"common": {
|
||||||
"save": "Mentés",
|
"save": "Mentés",
|
||||||
"cancel": "Mégse",
|
"cancel": "Mégse",
|
||||||
@@ -346,8 +460,27 @@
|
|||||||
"friday": "péntek",
|
"friday": "péntek",
|
||||||
"saturday": "szombat",
|
"saturday": "szombat",
|
||||||
"sunday": "vasárnap",
|
"sunday": "vasárnap",
|
||||||
|
"mon": "H",
|
||||||
|
"tue": "K",
|
||||||
|
"wed": "Sze",
|
||||||
|
"thu": "Cs",
|
||||||
|
"fri": "P",
|
||||||
|
"sat": "Szo",
|
||||||
|
"sun": "V",
|
||||||
"today": "Ma",
|
"today": "Ma",
|
||||||
"tomorrow": "Holnap"
|
"tomorrow": "Holnap",
|
||||||
|
"january": "Január",
|
||||||
|
"february": "Február",
|
||||||
|
"march": "Március",
|
||||||
|
"april": "Április",
|
||||||
|
"may": "Május",
|
||||||
|
"june": "Június",
|
||||||
|
"july": "Július",
|
||||||
|
"august": "Augusztus",
|
||||||
|
"september": "Szeptember",
|
||||||
|
"october": "Október",
|
||||||
|
"november": "November",
|
||||||
|
"december": "December"
|
||||||
},
|
},
|
||||||
"months": {
|
"months": {
|
||||||
"january": "január",
|
"january": "január",
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="none" stroke="#A7DC22" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19h4m0 0v-4m0 4l-4-4M9 5H5m0 0v4m0-4l4 4m6-4h4m0 0v4m0-4l-4 4M9 19H5m0 0v-4m0 4l4-4"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 19h4m0 0v-4m0 4l-4-4M9 5H5m0 0v4m0-4l4 4m6-4h4m0 0v4m0-4l-4 4M9 19H5m0 0v-4m0 4l4-4"/></svg>
|
||||||
|
Before Width: | Height: | Size: 283 B After Width: | Height: | Size: 288 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M10.054 2.344a3 3 0 0 1 3.892 0l1.271 1.084a1 1 0 0 0 .57.236l1.665.133a3 3 0 0 1 2.751 2.751l.133 1.666a1 1 0 0 0 .236.569l1.084 1.271a3 3 0 0 1 0 3.892l-1.084 1.271a1 1 0 0 0-.236.57l-.133 1.665a3 3 0 0 1-2.751 2.751l-1.666.133a1 1 0 0 0-.569.236l-1.271 1.084a3 3 0 0 1-3.892 0l-1.271-1.084a1 1 0 0 0-.57-.236l-1.665-.133a3 3 0 0 1-2.751-2.751l-.133-1.666a1 1 0 0 0-.236-.569l-1.084-1.271a3 3 0 0 1 0-3.892l1.084-1.271a1 1 0 0 0 .236-.57l.133-1.665a3 3 0 0 1 2.751-2.751l1.666-.133a1 1 0 0 0 .569-.236l1.271-1.084zm5.653 8.363a1 1 0 0 0-1.414-1.414L11 12.586l-1.293-1.293a1 1 0 0 0-1.414 1.414l2 2a1 1 0 0 0 1.414 0l4-4z" fill="#A7DC22"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M10.054 2.344a3 3 0 0 1 3.892 0l1.271 1.084a1 1 0 0 0 .57.236l1.665.133a3 3 0 0 1 2.751 2.751l.133 1.666a1 1 0 0 0 .236.569l1.084 1.271a3 3 0 0 1 0 3.892l-1.084 1.271a1 1 0 0 0-.236.57l-.133 1.665a3 3 0 0 1-2.751 2.751l-1.666.133a1 1 0 0 0-.569.236l-1.271 1.084a3 3 0 0 1-3.892 0l-1.271-1.084a1 1 0 0 0-.57-.236l-1.665-.133a3 3 0 0 1-2.751-2.751l-.133-1.666a1 1 0 0 0-.236-.569l-1.084-1.271a3 3 0 0 1 0-3.892l1.084-1.271a1 1 0 0 0 .236-.57l.133-1.665a3 3 0 0 1 2.751-2.751l1.666-.133a1 1 0 0 0 .569-.236l1.271-1.084zm5.653 8.363a1 1 0 0 0-1.414-1.414L11 12.586l-1.293-1.293a1 1 0 0 0-1.414 1.414l2 2a1 1 0 0 0 1.414 0l4-4z" fill="currentColor"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 799 B After Width: | Height: | Size: 804 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill="#A7DC22" d="M4 7v2h16V7a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2"/><path stroke="#A7DC22" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 5h2a2 2 0 0 1 2 2v2H4V7a2 2 0 0 1 2-2h2m8 0V3m0 2H8m0-2v2M4 9.5V19a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9.5"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill="currentColor" d="M4 7v2h16V7a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M16 5h2a2 2 0 0 1 2 2v2H4V7a2 2 0 0 1 2-2h2m8 0V3m0 2H8m0-2v2M4 9.5V19a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9.5"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 376 B After Width: | Height: | Size: 386 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="#A7DC22" fill-rule="evenodd" d="M12 21a9 9 0 1 0 0-18a9 9 0 0 0 0 18m1.707-11.293a1 1 0 0 0-1.414-1.414l-3 3a1 1 0 0 0 0 1.414l3 3a1 1 0 0 0 1.414-1.414L11.414 12z" clip-rule="evenodd"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="currentColor" fill-rule="evenodd" d="M12 21a9 9 0 1 0 0-18a9 9 0 0 0 0 18m1.707-11.293a1 1 0 0 0-1.414-1.414l-3 3a1 1 0 0 0 0 1.414l3 3a1 1 0 0 0 1.414-1.414L11.414 12z" clip-rule="evenodd"/></svg>
|
||||||
|
Before Width: | Height: | Size: 289 B After Width: | Height: | Size: 294 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="#A7DC22" fill-rule="evenodd" d="M12 21a9 9 0 1 0 0-18a9 9 0 0 0 0 18M10.293 9.707a1 1 0 1 1 1.414-1.414l3 3a1 1 0 0 1 0 1.414l-3 3a1 1 0 0 1-1.414-1.414L12.586 12z" clip-rule="evenodd"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="currentColor" fill-rule="evenodd" d="M12 21a9 9 0 1 0 0-18a9 9 0 0 0 0 18M10.293 9.707a1 1 0 1 1 1.414-1.414l3 3a1 1 0 0 1 0 1.414l-3 3a1 1 0 0 1-1.414-1.414L12.586 12z" clip-rule="evenodd"/></svg>
|
||||||
|
Before Width: | Height: | Size: 289 B After Width: | Height: | Size: 294 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12zm8.207-3.207a1 1 0 0 0-1.414 1.414L10.586 12l-1.793 1.793a1 1 0 1 0 1.414 1.414L12 13.414l1.793 1.793a1 1 0 0 0 1.414-1.414L13.414 12l1.793-1.793a1 1 0 0 0-1.414-1.414L12 10.586l-1.793-1.793z" fill="#A7DC22"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12zm8.207-3.207a1 1 0 0 0-1.414 1.414L10.586 12l-1.793 1.793a1 1 0 1 0 1.414 1.414L12 13.414l1.793 1.793a1 1 0 0 0 1.414-1.414L13.414 12l1.793-1.793a1 1 0 0 0-1.414-1.414L12 10.586l-1.793-1.793z" fill="currentColor"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 440 B After Width: | Height: | Size: 445 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M11.514 3.126a1 1 0 0 1 .972 0l9 5A1 1 0 0 1 22 9v7a1 1 0 1 1-2 0v-5.3l-1 .555v.004l-6.067 3.016a2 2 0 0 1-1.848-.035L2.357 9.479a1 1 0 0 0-.284-.103a1 1 0 0 1 .441-1.25l9-5zM5 13.199V17a1 1 0 0 0 .553.894l6 3a1 1 0 0 0 .894 0l6-3A1 1 0 0 0 19 17v-3.256l-6.083 2.844a2 2 0 0 1-1.805-.056L5 13.2z" fill="#A7DC22"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M11.514 3.126a1 1 0 0 1 .972 0l9 5A1 1 0 0 1 22 9v7a1 1 0 1 1-2 0v-5.3l-1 .555v.004l-6.067 3.016a2 2 0 0 1-1.848-.035L2.357 9.479a1 1 0 0 0-.284-.103a1 1 0 0 1 .441-1.25l9-5zM5 13.199V17a1 1 0 0 0 .553.894l6 3a1 1 0 0 0 .894 0l6-3A1 1 0 0 0 19 17v-3.256l-6.083 2.844a2 2 0 0 1-1.805-.056L5 13.2z" fill="currentColor"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 472 B After Width: | Height: | Size: 477 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="#A7DC22" d="M8 3a1 1 0 0 1 1-1h6a1 1 0 1 1 0 2H9a1 1 0 0 1-1-1M3 14a9 9 0 0 1 14.618-7.032l.675-.675a1 1 0 1 1 1.414 1.414l-.675.675A9 9 0 1 1 3 14m10-4a1 1 0 1 0-2 0v4a1 1 0 1 0 2 0z" clip-rule="evenodd"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="currentColor" d="M8 3a1 1 0 0 1 1-1h6a1 1 0 1 1 0 2H9a1 1 0 0 1-1-1M3 14a9 9 0 0 1 14.618-7.032l.675-.675a1 1 0 1 1 1.414 1.414l-.675.675A9 9 0 1 1 3 14m10-4a1 1 0 1 0-2 0v4a1 1 0 1 0 2 0z" clip-rule="evenodd"/></svg>
|
||||||
|
Before Width: | Height: | Size: 309 B After Width: | Height: | Size: 314 B |
@@ -1,5 +1,5 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
||||||
<g opacity="0.5">
|
<g opacity="0.5">
|
||||||
<path d="M15.8334 5.83333L14.7143 6.9525M14.7143 6.9525C13.464 5.70223 11.7682 4.99983 10.0001 4.99983C8.23193 4.99983 6.5362 5.70223 5.28592 6.9525C4.03565 8.20278 3.33325 9.89851 3.33325 11.6667C3.33325 13.4348 4.03565 15.1306 5.28592 16.3808C6.5362 17.6311 8.23193 18.3335 10.0001 18.3335C11.7682 18.3335 13.464 17.6311 14.7143 16.3808C15.9645 15.1306 16.6669 13.4348 16.6669 11.6667C16.6669 9.89851 15.9645 8.20278 14.7143 6.9525ZM10.0001 8.33333V11.6667M7.50009 2.5H12.5001" stroke="#6E8F1B" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M15.8334 5.83333L14.7143 6.9525M14.7143 6.9525C13.464 5.70223 11.7682 4.99983 10.0001 4.99983C8.23193 4.99983 6.5362 5.70223 5.28592 6.9525C4.03565 8.20278 3.33325 9.89851 3.33325 11.6667C3.33325 13.4348 4.03565 15.1306 5.28592 16.3808C6.5362 17.6311 8.23193 18.3335 10.0001 18.3335C11.7682 18.3335 13.464 17.6311 14.7143 16.3808C15.9645 15.1306 16.6669 13.4348 16.6669 11.6667C16.6669 9.89851 15.9645 8.20278 14.7143 6.9525ZM10.0001 8.33333V11.6667M7.50009 2.5H12.5001" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 696 B After Width: | Height: | Size: 701 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path stroke="#FFA046" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M14 8H9m2 4H9"/><path fill="#FFA046" d="M3 16h8c0 1.333.8 4 4 4a3 3 0 0 0 3-3V4h1a2 2 0 0 1 2 2v2a2 2 0 0 1-2 2h-1v7a3 3 0 0 1-3 3H5a2 2 0 0 1-2-2z"/><path stroke="#FFA046" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 20c-3.2 0-4-2.667-4-4H3v2a2 2 0 0 0 2 2zm0 0a3 3 0 0 0 3-3v-7m0-6H7a2 2 0 0 0-2 2v9.5M18 4h1a2 2 0 0 1 2 2v2a2 2 0 0 1-2 2h-1m0-6v6"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M14 8H9m2 4H9"/><path fill="currentColor" d="M3 16h8c0 1.333.8 4 4 4a3 3 0 0 0 3-3V4h1a2 2 0 0 1 2 2v2a2 2 0 0 1-2 2h-1v7a3 3 0 0 1-3 3H5a2 2 0 0 1-2-2z"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 20c-3.2 0-4-2.667-4-4H3v2a2 2 0 0 0 2 2zm0 0a3 3 0 0 0 3-3v-7m0-6H7a2 2 0 0 0-2 2v9.5M18 4h1a2 2 0 0 1 2 2v2a2 2 0 0 1-2 2h-1m0-6v6"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 578 B After Width: | Height: | Size: 593 B |
1
icons/contact.svg
Normal file
@@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M10 3.223a9.003 9.003 0 0 0-5.605 13.592L3 21l4.185-1.395A9.003 9.003 0 0 0 20.777 14m0-4A9.01 9.01 0 0 0 14 3.223M17 12a5 5 0 0 0-5-5m1 5a1 1 0 0 0-1-1"/></svg>
|
||||||
|
After Width: | Height: | Size: 353 B |
@@ -1,3 +1,3 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
||||||
<path d="M16.6666 15.8333V8.74999C16.6666 8.62062 16.6365 8.49302 16.5786 8.37731C16.5208 8.2616 16.4367 8.16095 16.3333 8.08332L10.4999 3.70832C10.3557 3.60014 10.1802 3.54166 9.99992 3.54166C9.81961 3.54166 9.64417 3.60014 9.49992 3.70832L3.66659 8.08332C3.56309 8.16095 3.47909 8.2616 3.42123 8.37731C3.36337 8.49302 3.33325 8.62062 3.33325 8.74999V15.8333C3.33325 16.0543 3.42105 16.2663 3.57733 16.4226C3.73361 16.5789 3.94557 16.6667 4.16659 16.6667H7.49992C7.72093 16.6667 7.93289 16.5789 8.08917 16.4226C8.24545 16.2663 8.33325 16.0543 8.33325 15.8333V13.3333C8.33325 13.1123 8.42105 12.9003 8.57733 12.7441C8.73361 12.5878 8.94557 12.5 9.16658 12.5H10.8333C11.0543 12.5 11.2662 12.5878 11.4225 12.7441C11.5788 12.9003 11.6666 13.1123 11.6666 13.3333V15.8333C11.6666 16.0543 11.7544 16.2663 11.9107 16.4226C12.0669 16.5789 12.2789 16.6667 12.4999 16.6667H15.8333C16.0543 16.6667 16.2662 16.5789 16.4225 16.4226C16.5788 16.2663 16.6666 16.0543 16.6666 15.8333Z" fill="#A7DC22" stroke="#A7DC22" stroke-width="1.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M16.6666 15.8333V8.74999C16.6666 8.62062 16.6365 8.49302 16.5786 8.37731C16.5208 8.2616 16.4367 8.16095 16.3333 8.08332L10.4999 3.70832C10.3557 3.60014 10.1802 3.54166 9.99992 3.54166C9.81961 3.54166 9.64417 3.60014 9.49992 3.70832L3.66659 8.08332C3.56309 8.16095 3.47909 8.2616 3.42123 8.37731C3.36337 8.49302 3.33325 8.62062 3.33325 8.74999V15.8333C3.33325 16.0543 3.42105 16.2663 3.57733 16.4226C3.73361 16.5789 3.94557 16.6667 4.16659 16.6667H7.49992C7.72093 16.6667 7.93289 16.5789 8.08917 16.4226C8.24545 16.2663 8.33325 16.0543 8.33325 15.8333V13.3333C8.33325 13.1123 8.42105 12.9003 8.57733 12.7441C8.73361 12.5878 8.94557 12.5 9.16658 12.5H10.8333C11.0543 12.5 11.2662 12.5878 11.4225 12.7441C11.5788 12.9003 11.6666 13.1123 11.6666 13.3333V15.8333C11.6666 16.0543 11.7544 16.2663 11.9107 16.4226C12.0669 16.5789 12.2789 16.6667 12.4999 16.6667H15.8333C16.0543 16.6667 16.2662 16.5789 16.4225 16.4226C16.5788 16.2663 16.6666 16.0543 16.6666 15.8333Z" fill="currentColor" stroke="currentColor" stroke-width="1.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.2 KiB |
@@ -1,5 +1,5 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
||||||
<g opacity="0.5">
|
<g opacity="0.5">
|
||||||
<path d="M16.6668 15.8333V8.74999C16.6668 8.62062 16.6367 8.49302 16.5789 8.37731C16.521 8.2616 16.437 8.16095 16.3335 8.08332L10.5002 3.70832C10.3559 3.60014 10.1805 3.54166 10.0002 3.54166C9.81985 3.54166 9.64441 3.60014 9.50016 3.70832L3.66683 8.08332C3.56333 8.16095 3.47933 8.2616 3.42147 8.37731C3.36362 8.49302 3.3335 8.62062 3.3335 8.74999V15.8333C3.3335 16.0543 3.42129 16.2663 3.57757 16.4226C3.73385 16.5789 3.94582 16.6667 4.16683 16.6667H7.50016C7.72118 16.6667 7.93314 16.5789 8.08942 16.4226C8.2457 16.2663 8.3335 16.0543 8.3335 15.8333V13.3333C8.3335 13.1123 8.42129 12.9003 8.57757 12.7441C8.73385 12.5878 8.94582 12.5 9.16683 12.5H10.8335C11.0545 12.5 11.2665 12.5878 11.4228 12.7441C11.579 12.9003 11.6668 13.1123 11.6668 13.3333V15.8333C11.6668 16.0543 11.7546 16.2663 11.9109 16.4226C12.0672 16.5789 12.2791 16.6667 12.5002 16.6667H15.8335C16.0545 16.6667 16.2665 16.5789 16.4228 16.4226C16.579 16.2663 16.6668 16.0543 16.6668 15.8333Z" stroke="#6E8F1B" stroke-width="1.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M16.6668 15.8333V8.74999C16.6668 8.62062 16.6367 8.49302 16.5789 8.37731C16.521 8.2616 16.437 8.16095 16.3335 8.08332L10.5002 3.70832C10.3559 3.60014 10.1805 3.54166 10.0002 3.54166C9.81985 3.54166 9.64441 3.60014 9.50016 3.70832L3.66683 8.08332C3.56333 8.16095 3.47933 8.2616 3.42147 8.37731C3.36362 8.49302 3.3335 8.62062 3.3335 8.74999V15.8333C3.3335 16.0543 3.42129 16.2663 3.57757 16.4226C3.73385 16.5789 3.94582 16.6667 4.16683 16.6667H7.50016C7.72118 16.6667 7.93314 16.5789 8.08942 16.4226C8.2457 16.2663 8.3335 16.0543 8.3335 15.8333V13.3333C8.3335 13.1123 8.42129 12.9003 8.57757 12.7441C8.73385 12.5878 8.94582 12.5 9.16683 12.5H10.8335C11.0545 12.5 11.2665 12.5878 11.4228 12.7441C11.579 12.9003 11.6668 13.1123 11.6668 13.3333V15.8333C11.6668 16.0543 11.7546 16.2663 11.9109 16.4226C12.0672 16.5789 12.2791 16.6667 12.5002 16.6667H15.8335C16.0545 16.6667 16.2665 16.5789 16.4228 16.4226C16.579 16.2663 16.6668 16.0543 16.6668 15.8333Z" stroke="currentColor" stroke-width="1.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill="#A7DC22" d="M9 7h9v11a2 2 0 0 1-2 2H8a2 2 0 0 1-2-2V7z"/><path stroke="#A7DC22" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M20 7h-2M4 7h2m0 0h12M6 7v11a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7m-9-.5A2.5 2.5 0 0 1 11.5 4h1A2.5 2.5 0 0 1 15 6.5v0"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill="currentColor" d="M9 7h9v11a2 2 0 0 1-2 2H8a2 2 0 0 1-2-2V7z"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M20 7h-2M4 7h2m0 0h12M6 7v11a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7m-9-.5A2.5 2.5 0 0 1 11.5 4h1A2.5 2.5 0 0 1 15 6.5v0"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 384 B After Width: | Height: | Size: 394 B |
@@ -1,5 +1,5 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="30" height="23" viewBox="0 0 30 23" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="30" height="23" viewBox="0 0 30 23" fill="none">
|
||||||
<path d="M11 12.8333C13.9455 12.8333 16.3333 10.4455 16.3333 7.49996C16.3333 4.55444 13.9455 2.16663 11 2.16663C8.05444 2.16663 5.66663 4.55444 5.66663 7.49996C5.66663 10.4455 8.05444 12.8333 11 12.8333Z" fill="#FFA046" stroke="#FFA046" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M11 12.8333C13.9455 12.8333 16.3333 10.4455 16.3333 7.49996C16.3333 4.55444 13.9455 2.16663 11 2.16663C8.05444 2.16663 5.66663 4.55444 5.66663 7.49996C5.66663 10.4455 8.05444 12.8333 11 12.8333Z" fill="currentColor" stroke="currentColor" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
<path d="M11 12.8333C5.84529 12.8333 1.66663 16.4146 1.66663 20.8333H20.3333C20.3333 16.4146 16.1546 12.8333 11 12.8333Z" fill="#FFA046" stroke="#FFA046" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M11 12.8333C5.84529 12.8333 1.66663 16.4146 1.66663 20.8333H20.3333C20.3333 16.4146 16.1546 12.8333 11 12.8333Z" fill="currentColor" stroke="currentColor" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
<path d="M19 12.8333C19.8912 12.8332 20.7681 12.6099 21.5508 12.1836C22.3334 11.7573 22.9967 11.1417 23.4801 10.3931C23.9636 9.64441 24.2517 8.78654 24.3182 7.89785C24.3847 7.00915 24.2274 6.11796 23.8607 5.30569C23.4941 4.49343 22.9297 3.786 22.2193 3.24802C21.5088 2.71005 20.6748 2.35869 19.7935 2.22604C18.9123 2.09339 18.0118 2.18369 17.1745 2.48867C16.3371 2.79366 15.5895 3.30362 15 3.97196M19 12.8333C17.924 12.8333 16.196 12.4426 15 11.1866M19 12.8333C24.1547 12.8333 28.3333 16.4146 28.3333 20.8333H20.3333" stroke="#FFA046" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M19 12.8333C19.8912 12.8332 20.7681 12.6099 21.5508 12.1836C22.3334 11.7573 22.9967 11.1417 23.4801 10.3931C23.9636 9.64441 24.2517 8.78654 24.3182 7.89785C24.3847 7.00915 24.2274 6.11796 23.8607 5.30569C23.4941 4.49343 22.9297 3.786 22.2193 3.24802C21.5088 2.71005 20.6748 2.35869 19.7935 2.22604C18.9123 2.09339 18.0118 2.18369 17.1745 2.48867C16.3371 2.79366 15.5895 3.30362 15 3.97196M19 12.8333C17.924 12.8333 16.196 12.4426 15 11.1866M19 12.8333C24.1547 12.8333 28.3333 16.4146 28.3333 20.8333H20.3333" stroke="currentColor" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path stroke="#A7DC22" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m3 3l18 18"/><path fill="#A7DC22" fill-rule="evenodd" d="M5.4 6.23c-.44.33-.843.678-1.21 1.032a15.1 15.1 0 0 0-3.001 4.11a1.44 1.44 0 0 0 0 1.255a15.1 15.1 0 0 0 3 4.111C5.94 18.423 8.518 20 12 20c2.236 0 4.1-.65 5.61-1.562l-3.944-3.943a3 3 0 0 1-4.161-4.161L5.401 6.229zm15.266 9.608a15 15 0 0 0 2.145-3.21a1.44 1.44 0 0 0 0-1.255a15.1 15.1 0 0 0-3-4.111C18.06 5.577 15.483 4 12 4a10.8 10.8 0 0 0-2.808.363z" clip-rule="evenodd"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m3 3l18 18"/><path fill="currentColor" fill-rule="evenodd" d="M5.4 6.23c-.44.33-.843.678-1.21 1.032a15.1 15.1 0 0 0-3.001 4.11a1.44 1.44 0 0 0 0 1.255a15.1 15.1 0 0 0 3 4.111C5.94 18.423 8.518 20 12 20c2.236 0 4.1-.65 5.61-1.562l-3.944-3.943a3 3 0 0 1-4.161-4.161L5.401 6.229zm15.266 9.608a15 15 0 0 0 2.145-3.21a1.44 1.44 0 0 0 0-1.255a15.1 15.1 0 0 0-3-4.111C18.06 5.577 15.483 4 12 4a10.8 10.8 0 0 0-2.808.363z" clip-rule="evenodd"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 631 B After Width: | Height: | Size: 641 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="#A7DC22" fill-rule="evenodd" d="M4.19 7.262C5.94 5.577 8.517 4 12 4s6.06 1.577 7.81 3.262a15.1 15.1 0 0 1 3.001 4.11c.193.399.193.857 0 1.255a15.1 15.1 0 0 1-3 4.111C18.06 18.423 15.483 20 12 20s-6.06-1.577-7.81-3.262a15.1 15.1 0 0 1-3.001-4.11a1.44 1.44 0 0 1 0-1.255a15.1 15.1 0 0 1 3-4.111zM12 15a3 3 0 1 0 0-6a3 3 0 0 0 0 6" clip-rule="evenodd"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="currentColor" fill-rule="evenodd" d="M4.19 7.262C5.94 5.577 8.517 4 12 4s6.06 1.577 7.81 3.262a15.1 15.1 0 0 1 3.001 4.11c.193.399.193.857 0 1.255a15.1 15.1 0 0 1-3 4.111C18.06 18.423 15.483 20 12 20s-6.06-1.577-7.81-3.262a15.1 15.1 0 0 1-3.001-4.11a1.44 1.44 0 0 1 0-1.255a15.1 15.1 0 0 1 3-4.111zM12 15a3 3 0 1 0 0-6a3 3 0 0 0 0 6" clip-rule="evenodd"/></svg>
|
||||||
|
Before Width: | Height: | Size: 453 B After Width: | Height: | Size: 458 B |
@@ -1,3 +1,3 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
||||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.8335 1.66666C5.17045 1.66666 4.53457 1.93005 4.06573 2.39889C3.59689 2.86773 3.3335 3.50362 3.3335 4.16666V16.7817C3.33342 17.0006 3.39087 17.2158 3.50008 17.4056C3.6093 17.5953 3.76645 17.7531 3.95582 17.8631C4.14518 17.973 4.3601 18.0313 4.57906 18.0321C4.79803 18.0329 5.01336 17.9761 5.2035 17.8675L9.58683 15.3625C9.71272 15.2906 9.85519 15.2528 10.0002 15.2528C10.1451 15.2528 10.2876 15.2906 10.4135 15.3625L14.7968 17.8675C14.987 17.9761 15.2023 18.0329 15.4213 18.0321C15.6402 18.0313 15.8552 17.973 16.0445 17.8631C16.2339 17.7531 16.391 17.5953 16.5002 17.4056C16.6095 17.2158 16.6669 17.0006 16.6668 16.7817V4.16666C16.6668 3.50362 16.4034 2.86773 15.9346 2.39889C15.4658 1.93005 14.8299 1.66666 14.1668 1.66666H5.8335Z" fill="#A7DC22"/>
|
<path fill-rule="evenodd" clip-rule="evenodd" d="M5.8335 1.66666C5.17045 1.66666 4.53457 1.93005 4.06573 2.39889C3.59689 2.86773 3.3335 3.50362 3.3335 4.16666V16.7817C3.33342 17.0006 3.39087 17.2158 3.50008 17.4056C3.6093 17.5953 3.76645 17.7531 3.95582 17.8631C4.14518 17.973 4.3601 18.0313 4.57906 18.0321C4.79803 18.0329 5.01336 17.9761 5.2035 17.8675L9.58683 15.3625C9.71272 15.2906 9.85519 15.2528 10.0002 15.2528C10.1451 15.2528 10.2876 15.2906 10.4135 15.3625L14.7968 17.8675C14.987 17.9761 15.2023 18.0329 15.4213 18.0321C15.6402 18.0313 15.8552 17.973 16.0445 17.8631C16.2339 17.7531 16.391 17.5953 16.5002 17.4056C16.6095 17.2158 16.6669 17.0006 16.6668 16.7817V4.16666C16.6668 3.50362 16.4034 2.86773 15.9346 2.39889C15.4658 1.93005 14.8299 1.66666 14.1668 1.66666H5.8335Z" fill="currentColor"/>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 906 B After Width: | Height: | Size: 911 B |
@@ -1,5 +1,5 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
||||||
<g opacity="0.5">
|
<g opacity="0.5">
|
||||||
<path d="M14.1667 2.5H5.83341C5.39139 2.5 4.96746 2.67559 4.6549 2.98816C4.34234 3.30072 4.16675 3.72464 4.16675 4.16667V16.7817C4.16677 16.8546 4.18596 16.9263 4.22238 16.9895C4.25881 17.0528 4.3112 17.1053 4.37431 17.1419C4.43742 17.1785 4.50904 17.198 4.58201 17.1982C4.65497 17.1984 4.72672 17.1795 4.79008 17.1433L9.17342 14.6392C9.42519 14.4953 9.71013 14.4197 10.0001 14.4197C10.29 14.4197 10.575 14.4953 10.8267 14.6392L15.2101 17.1442C15.2735 17.1804 15.3453 17.1993 15.4184 17.199C15.4914 17.1987 15.5631 17.1793 15.6262 17.1426C15.6894 17.1058 15.7417 17.0532 15.7781 16.9898C15.8145 16.9265 15.8335 16.8547 15.8334 16.7817V4.16667C15.8334 3.72464 15.6578 3.30072 15.3453 2.98816C15.0327 2.67559 14.6088 2.5 14.1667 2.5Z" stroke="#6E8F1B" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M14.1667 2.5H5.83341C5.39139 2.5 4.96746 2.67559 4.6549 2.98816C4.34234 3.30072 4.16675 3.72464 4.16675 4.16667V16.7817C4.16677 16.8546 4.18596 16.9263 4.22238 16.9895C4.25881 17.0528 4.3112 17.1053 4.37431 17.1419C4.43742 17.1785 4.50904 17.198 4.58201 17.1982C4.65497 17.1984 4.72672 17.1795 4.79008 17.1433L9.17342 14.6392C9.42519 14.4953 9.71013 14.4197 10.0001 14.4197C10.29 14.4197 10.575 14.4953 10.8267 14.6392L15.2101 17.1442C15.2735 17.1804 15.3453 17.1993 15.4184 17.199C15.4914 17.1987 15.5631 17.1793 15.6262 17.1426C15.6894 17.1058 15.7417 17.0532 15.7781 16.9898C15.8145 16.9265 15.8335 16.8547 15.8334 16.7817V4.16667C15.8334 3.72464 15.6578 3.30072 15.3453 2.98816C15.0327 2.67559 14.6088 2.5 14.1667 2.5Z" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 949 B After Width: | Height: | Size: 954 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M15.586 3a2 2 0 0 1 2.828 0L21 5.586a2 2 0 0 1 0 2.828L19.414 10L14 4.586L15.586 3zm-3 3l-9 9A2 2 0 0 0 3 16.414V19a2 2 0 0 0 2 2h2.586A2 2 0 0 0 9 20.414l9-9L12.586 6z" fill="#A7DC22"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M15.586 3a2 2 0 0 1 2.828 0L21 5.586a2 2 0 0 1 0 2.828L19.414 10L14 4.586L15.586 3zm-3 3l-9 9A2 2 0 0 0 3 16.414V19a2 2 0 0 0 2 2h2.586A2 2 0 0 0 9 20.414l9-9L12.586 6z" fill="currentColor"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 345 B After Width: | Height: | Size: 350 B |
@@ -1,4 +1,4 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" viewBox="0 0 28 28" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" viewBox="0 0 28 28" fill="none">
|
||||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M11.5174 0.419898C12.1146 0.240744 12.7454 0.203682 13.3595 0.311674C13.9736 0.419665 14.5539 0.669717 15.0542 1.04187C15.5544 1.41403 15.9608 1.89798 16.2407 2.45509C16.5207 3.0122 16.6666 3.62706 16.6667 4.25057V23.7492C16.6666 24.3727 16.5207 24.9876 16.2407 25.5447C15.9608 26.1018 15.5544 26.5858 15.0542 26.9579C14.5539 27.3301 13.9736 27.5801 13.3595 27.6881C12.7454 27.7961 12.1146 27.7591 11.5174 27.5799L3.51735 25.1799C2.69349 24.9328 1.97123 24.4266 1.45773 23.7366C0.944226 23.0466 0.666828 22.2094 0.666687 21.3492V6.65057C0.666828 5.79043 0.944226 4.95325 1.45773 4.26321C1.97123 3.57318 2.69349 3.06704 3.51735 2.8199L11.5174 0.419898ZM18 3.33323C18 2.97961 18.1405 2.64047 18.3905 2.39042C18.6406 2.14037 18.9797 1.9999 19.3334 1.9999H23.3334C24.3942 1.9999 25.4116 2.42133 26.1618 3.17147C26.9119 3.92162 27.3334 4.93903 27.3334 5.9999V7.33323C27.3334 7.68685 27.1929 8.02599 26.9428 8.27604C26.6928 8.52609 26.3536 8.66656 26 8.66656C25.6464 8.66656 25.3073 8.52609 25.0572 8.27604C24.8072 8.02599 24.6667 7.68685 24.6667 7.33323V5.9999C24.6667 5.64628 24.5262 5.30714 24.2762 5.05709C24.0261 4.80704 23.687 4.66656 23.3334 4.66656H19.3334C18.9797 4.66656 18.6406 4.52609 18.3905 4.27604C18.1405 4.02599 18 3.68685 18 3.33323ZM26 19.3332C26.3536 19.3332 26.6928 19.4737 26.9428 19.7238C27.1929 19.9738 27.3334 20.3129 27.3334 20.6666V21.9999C27.3334 23.0608 26.9119 24.0782 26.1618 24.8283C25.4116 25.5785 24.3942 25.9999 23.3334 25.9999H19.3334C18.9797 25.9999 18.6406 25.8594 18.3905 25.6094C18.1405 25.3593 18 25.0202 18 24.6666C18 24.3129 18.1405 23.9738 18.3905 23.7238C18.6406 23.4737 18.9797 23.3332 19.3334 23.3332H23.3334C23.687 23.3332 24.0261 23.1928 24.2762 22.9427C24.5262 22.6927 24.6667 22.3535 24.6667 21.9999V20.6666C24.6667 20.3129 24.8072 19.9738 25.0572 19.7238C25.3073 19.4737 25.6464 19.3332 26 19.3332ZM10 12.6666C9.6464 12.6666 9.30726 12.807 9.05721 13.0571C8.80716 13.3071 8.66669 13.6463 8.66669 13.9999C8.66669 14.3535 8.80716 14.6927 9.05721 14.9427C9.30726 15.1928 9.6464 15.3332 10 15.3332H10.0014C10.355 15.3332 10.6941 15.1928 10.9442 14.9427C11.1942 14.6927 11.3347 14.3535 11.3347 13.9999C11.3347 13.6463 11.1942 13.3071 10.9442 13.0571C10.6941 12.807 10.355 12.6666 10.0014 12.6666H10Z" fill="#FF54A1"/>
|
<path fill-rule="evenodd" clip-rule="evenodd" d="M11.5174 0.419898C12.1146 0.240744 12.7454 0.203682 13.3595 0.311674C13.9736 0.419665 14.5539 0.669717 15.0542 1.04187C15.5544 1.41403 15.9608 1.89798 16.2407 2.45509C16.5207 3.0122 16.6666 3.62706 16.6667 4.25057V23.7492C16.6666 24.3727 16.5207 24.9876 16.2407 25.5447C15.9608 26.1018 15.5544 26.5858 15.0542 26.9579C14.5539 27.3301 13.9736 27.5801 13.3595 27.6881C12.7454 27.7961 12.1146 27.7591 11.5174 27.5799L3.51735 25.1799C2.69349 24.9328 1.97123 24.4266 1.45773 23.7366C0.944226 23.0466 0.666828 22.2094 0.666687 21.3492V6.65057C0.666828 5.79043 0.944226 4.95325 1.45773 4.26321C1.97123 3.57318 2.69349 3.06704 3.51735 2.8199L11.5174 0.419898ZM18 3.33323C18 2.97961 18.1405 2.64047 18.3905 2.39042C18.6406 2.14037 18.9797 1.9999 19.3334 1.9999H23.3334C24.3942 1.9999 25.4116 2.42133 26.1618 3.17147C26.9119 3.92162 27.3334 4.93903 27.3334 5.9999V7.33323C27.3334 7.68685 27.1929 8.02599 26.9428 8.27604C26.6928 8.52609 26.3536 8.66656 26 8.66656C25.6464 8.66656 25.3073 8.52609 25.0572 8.27604C24.8072 8.02599 24.6667 7.68685 24.6667 7.33323V5.9999C24.6667 5.64628 24.5262 5.30714 24.2762 5.05709C24.0261 4.80704 23.687 4.66656 23.3334 4.66656H19.3334C18.9797 4.66656 18.6406 4.52609 18.3905 4.27604C18.1405 4.02599 18 3.68685 18 3.33323ZM26 19.3332C26.3536 19.3332 26.6928 19.4737 26.9428 19.7238C27.1929 19.9738 27.3334 20.3129 27.3334 20.6666V21.9999C27.3334 23.0608 26.9119 24.0782 26.1618 24.8283C25.4116 25.5785 24.3942 25.9999 23.3334 25.9999H19.3334C18.9797 25.9999 18.6406 25.8594 18.3905 25.6094C18.1405 25.3593 18 25.0202 18 24.6666C18 24.3129 18.1405 23.9738 18.3905 23.7238C18.6406 23.4737 18.9797 23.3332 19.3334 23.3332H23.3334C23.687 23.3332 24.0261 23.1928 24.2762 22.9427C24.5262 22.6927 24.6667 22.3535 24.6667 21.9999V20.6666C24.6667 20.3129 24.8072 19.9738 25.0572 19.7238C25.3073 19.4737 25.6464 19.3332 26 19.3332ZM10 12.6666C9.6464 12.6666 9.30726 12.807 9.05721 13.0571C8.80716 13.3071 8.66669 13.6463 8.66669 13.9999C8.66669 14.3535 8.80716 14.6927 9.05721 14.9427C9.30726 15.1928 9.6464 15.3332 10 15.3332H10.0014C10.355 15.3332 10.6941 15.1928 10.9442 14.9427C11.1942 14.6927 11.3347 14.3535 11.3347 13.9999C11.3347 13.6463 11.1942 13.3071 10.9442 13.0571C10.6941 12.807 10.355 12.6666 10.0014 12.6666H10Z" fill="currentColor"/>
|
||||||
<path d="M19.3334 13.9999H26M26 13.9999L23.3334 11.3333M26 13.9999L23.3334 16.6666" stroke="#FF54A1" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M19.3334 13.9999H26M26 13.9999L23.3334 11.3333M26 13.9999L23.3334 16.6666" stroke="currentColor" stroke-width="2.66667" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 2.5 KiB After Width: | Height: | Size: 2.5 KiB |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M6 21a3 3 0 0 1-3-3v-3h5a2 2 0 0 0 2 2h4a2 2 0 0 0 2-2h5v3a3 3 0 0 1-3 3H6zm15-8h-5a2 2 0 0 0-2 2h-4a2 2 0 0 0-2-2H3V6a3 3 0 0 1 3-3h12a3 3 0 0 1 3 3v7z" fill="#A7DC22"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M6 21a3 3 0 0 1-3-3v-3h5a2 2 0 0 0 2 2h4a2 2 0 0 0 2-2h5v3a3 3 0 0 1-3 3H6zm15-8h-5a2 2 0 0 0-2 2h-4a2 2 0 0 0-2-2H3V6a3 3 0 0 1 3-3h12a3 3 0 0 1 3 3v7z" fill="currentColor"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 329 B After Width: | Height: | Size: 334 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="#6E8F1B"><path d="M5 13h3a2 2 0 0 1 2 2h4a2 2 0 0 1 2-2h3V6a1 1 0 0 0-1-1H6a1 1 0 0 0-1 1v7zm14 2h-3a2 2 0 0 1-2 2h-4a2 2 0 0 1-2-2H5v3a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-3zM3 6a3 3 0 0 1 3-3h12a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H6a3 3 0 0 1-3-3V6z"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="currentColor"><path d="M5 13h3a2 2 0 0 1 2 2h4a2 2 0 0 1 2-2h3V6a1 1 0 0 0-1-1H6a1 1 0 0 0-1 1v7zm14 2h-3a2 2 0 0 1-2 2h-4a2 2 0 0 1-2-2H5v3a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-3zM3 6a3 3 0 0 1 3-3h12a3 3 0 0 1 3 3v12a3 3 0 0 1-3 3H6a3 3 0 0 1-3-3V6z"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 348 B After Width: | Height: | Size: 353 B |
@@ -1,3 +1,3 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32" fill="none">
|
||||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M4 6.66663C4 5.60576 4.42143 4.58834 5.17157 3.8382C5.92172 3.08805 6.93913 2.66663 8 2.66663H24C25.0609 2.66663 26.0783 3.08805 26.8284 3.8382C27.5786 4.58834 28 5.60576 28 6.66663V25.3333C28 26.3942 27.5786 27.4116 26.8284 28.1617C26.0783 28.9119 25.0609 29.3333 24 29.3333H8C6.93913 29.3333 5.92172 28.9119 5.17157 28.1617C4.42143 27.4116 4 26.3942 4 25.3333V6.66663ZM10.6667 6.66663V16L13.724 12.9426C13.974 12.6927 14.3131 12.5522 14.6667 12.5522C15.0202 12.5522 15.3593 12.6927 15.6093 12.9426L18.6667 16V6.66663C18.6667 6.313 18.5262 5.97387 18.2761 5.72382C18.0261 5.47377 17.687 5.33329 17.3333 5.33329H12C11.6464 5.33329 11.3072 5.47377 11.0572 5.72382C10.8071 5.97387 10.6667 6.313 10.6667 6.66663Z" fill="#A7DC22"/>
|
<path fill-rule="evenodd" clip-rule="evenodd" d="M4 6.66663C4 5.60576 4.42143 4.58834 5.17157 3.8382C5.92172 3.08805 6.93913 2.66663 8 2.66663H24C25.0609 2.66663 26.0783 3.08805 26.8284 3.8382C27.5786 4.58834 28 5.60576 28 6.66663V25.3333C28 26.3942 27.5786 27.4116 26.8284 28.1617C26.0783 28.9119 25.0609 29.3333 24 29.3333H8C6.93913 29.3333 5.92172 28.9119 5.17157 28.1617C4.42143 27.4116 4 26.3942 4 25.3333V6.66663ZM10.6667 6.66663V16L13.724 12.9426C13.974 12.6927 14.3131 12.5522 14.6667 12.5522C15.0202 12.5522 15.3593 12.6927 15.6093 12.9426L18.6667 16V6.66663C18.6667 6.313 18.5262 5.97387 18.2761 5.72382C18.0261 5.47377 17.687 5.33329 17.3333 5.33329H12C11.6464 5.33329 11.3072 5.47377 11.0572 5.72382C10.8071 5.97387 10.6667 6.313 10.6667 6.66663Z" fill="currentColor"/>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 881 B After Width: | Height: | Size: 886 B |
@@ -1,5 +1,5 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
||||||
<g opacity="0.5">
|
<g opacity="0.5">
|
||||||
<path fill-rule="evenodd" clip-rule="evenodd" d="M1.66699 5.00018C1.66699 4.34271 2.19998 3.80972 2.85745 3.80972H17.1429C17.8004 3.80972 18.3334 4.34271 18.3334 5.00018C18.3334 5.65765 17.8004 6.19064 17.1429 6.19064H2.85745C2.19998 6.19064 1.66699 5.65765 1.66699 5.00018ZM1.66699 9.76201C1.66699 9.10454 2.19998 8.57155 2.85745 8.57155H17.1429C17.8004 8.57155 18.3334 9.10454 18.3334 9.76201C18.3334 10.4195 17.8004 10.9525 17.1429 10.9525H2.85745C2.19998 10.9525 1.66699 10.4195 1.66699 9.76201ZM1.66699 14.5238C1.66699 13.8664 2.19998 13.3334 2.85745 13.3334H17.1429C17.8004 13.3334 18.3334 13.8664 18.3334 14.5238C18.3334 15.1813 17.8004 15.7143 17.1429 15.7143H2.85745C2.19998 15.7143 1.66699 15.1813 1.66699 14.5238Z" fill="#6E8F1B"/>
|
<path fill-rule="evenodd" clip-rule="evenodd" d="M1.66699 5.00018C1.66699 4.34271 2.19998 3.80972 2.85745 3.80972H17.1429C17.8004 3.80972 18.3334 4.34271 18.3334 5.00018C18.3334 5.65765 17.8004 6.19064 17.1429 6.19064H2.85745C2.19998 6.19064 1.66699 5.65765 1.66699 5.00018ZM1.66699 9.76201C1.66699 9.10454 2.19998 8.57155 2.85745 8.57155H17.1429C17.8004 8.57155 18.3334 9.10454 18.3334 9.76201C18.3334 10.4195 17.8004 10.9525 17.1429 10.9525H2.85745C2.19998 10.9525 1.66699 10.4195 1.66699 9.76201ZM1.66699 14.5238C1.66699 13.8664 2.19998 13.3334 2.85745 13.3334H17.1429C17.8004 13.3334 18.3334 13.8664 18.3334 14.5238C18.3334 15.1813 17.8004 15.7143 17.1429 15.7143H2.85745C2.19998 15.7143 1.66699 15.1813 1.66699 14.5238Z" fill="currentColor"/>
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 876 B After Width: | Height: | Size: 881 B |
1
icons/pending.svg
Normal file
@@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="currentColor" fill-rule="evenodd" d="M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12m11-5a1 1 0 1 0-2 0v3.764a3 3 0 0 0 1.658 2.683l2.895 1.447a1 1 0 1 0 .894-1.788l-2.894-1.448a1 1 0 0 1-.553-.894z" clip-rule="evenodd"/></svg>
|
||||||
|
After Width: | Height: | Size: 348 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="#A7DC22"><path d="M19.707 6.293a1 1 0 0 1 0 1.414l-10 10a1 1 0 0 1-1.414 0l-4-4a1 1 0 1 1 1.414-1.414L9 15.586l9.293-9.293a1 1 0 0 1 1.414 0z"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="currentColor"><path d="M19.707 6.293a1 1 0 0 1 0 1.414l-10 10a1 1 0 0 1-1.414 0l-4-4a1 1 0 1 1 1.414-1.414L9 15.586l9.293-9.293a1 1 0 0 1 1.414 0z"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 248 B After Width: | Height: | Size: 253 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="none" stroke="#A7DC22" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 12h7m7 0h-7m0 0V5m0 7v7"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 12h7m7 0h-7m0 0V5m0 7v7"/></svg>
|
||||||
|
Before Width: | Height: | Size: 222 B After Width: | Height: | Size: 227 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" viewBox="0 0 28 28" fill="none"><g fill-rule="evenodd" clip-rule="evenodd" fill="#A7DC22" stroke="#A7DC22" stroke-width="1.66667" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="8" r="5" fill="#A7DC22"/><path d="M20 21a8 8 0 1 0-16 0"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" viewBox="3 2 22 24" fill="none"><g fill-rule="evenodd" clip-rule="evenodd" fill="currentColor" stroke="currentColor" stroke-width="1.66667" stroke-linecap="round" stroke-linejoin="round"><circle cx="14" cy="9" r="5" fill="currentColor"/><path d="M22 22a8 8 0 1 0-16 0"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 328 B After Width: | Height: | Size: 343 B |
1
icons/project.svg
Normal file
@@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"><path d="M3 20h.01M7 20a4 4 0 0 0-4-4m8 4a8 8 0 0 0-8-8"/><path fill="currentColor" d="M19 4H5a2 2 0 0 0-2 2v2.5c4 .167 12 2.7 12 11.5h4a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2"/></g></svg>
|
||||||
|
After Width: | Height: | Size: 365 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="#A7DC22" fill-rule="evenodd" d="M10 2a3 3 0 0 0-2.83 2H6a3 3 0 0 0-3 3v12a3 3 0 0 0 3 3h12a3 3 0 0 0 3-3V7a3 3 0 0 0-3-3h-1.17A3 3 0 0 0 14 2zM9 5a1 1 0 0 1 1-1h4a1 1 0 1 1 0 2h-4a1 1 0 0 1-1-1m6.78 6.625a1 1 0 1 0-1.56-1.25l-3.303 4.128l-1.21-1.21a1 1 0 0 0-1.414 1.414l2 2a1 1 0 0 0 1.488-.082l4-5z" clip-rule="evenodd"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="currentColor" fill-rule="evenodd" d="M10 2a3 3 0 0 0-2.83 2H6a3 3 0 0 0-3 3v12a3 3 0 0 0 3 3h12a3 3 0 0 0 3-3V7a3 3 0 0 0-3-3h-1.17A3 3 0 0 0 14 2zM9 5a1 1 0 0 1 1-1h4a1 1 0 1 1 0 2h-4a1 1 0 0 1-1-1m6.78 6.625a1 1 0 1 0-1.56-1.25l-3.303 4.128l-1.21-1.21a1 1 0 0 0-1.414 1.414l2 2a1 1 0 0 0 1.488-.082l4-5z" clip-rule="evenodd"/></svg>
|
||||||
|
Before Width: | Height: | Size: 426 B After Width: | Height: | Size: 431 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="#A7DC22" fill-rule="evenodd" d="M10 2a3 3 0 0 0-2.83 2H6a3 3 0 0 0-3 3v12a3 3 0 0 0 3 3h12a3 3 0 0 0 3-3V7a3 3 0 0 0-3-3h-1.17A3 3 0 0 0 14 2zM9 5a1 1 0 0 1 1-1h4a1 1 0 1 1 0 2h-4a1 1 0 0 1-1-1m6 8a1 1 0 1 1 0 2H9a1 1 0 1 1 0-2z" clip-rule="evenodd"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="currentColor" fill-rule="evenodd" d="M10 2a3 3 0 0 0-2.83 2H6a3 3 0 0 0-3 3v12a3 3 0 0 0 3 3h12a3 3 0 0 0 3-3V7a3 3 0 0 0-3-3h-1.17A3 3 0 0 0 14 2zM9 5a1 1 0 0 1 1-1h4a1 1 0 1 1 0 2h-4a1 1 0 0 1-1-1m6 8a1 1 0 1 1 0 2H9a1 1 0 1 1 0-2z" clip-rule="evenodd"/></svg>
|
||||||
|
Before Width: | Height: | Size: 354 B After Width: | Height: | Size: 359 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M8.949 2.684a1 1 0 0 0-1.898.632l1 3a1 1 0 1 0 1.898-.632l-1-3zm6.758 3.023a1 1 0 0 0-1.414-1.414l-2 2a1 1 0 0 0 1.414 1.414l2-2zM3.317 7.051a1 1 0 0 0-.633 1.898l3 1a1 1 0 1 0 .632-1.898l-3-1zm7.025 2.01a1 1 0 0 0-1.282 1.28l4 11a1 1 0 0 0 1.868.03l1.437-3.591l3.928 3.927a1 1 0 1 0 1.414-1.414l-3.928-3.928l3.592-1.436a1 1 0 0 0-.03-1.869l-11-4zm-2.635 4.646a1 1 0 1 0-1.414-1.414l-2 2a1 1 0 1 0 1.414 1.414l2-2z" fill="#A7DC22"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M8.949 2.684a1 1 0 0 0-1.898.632l1 3a1 1 0 1 0 1.898-.632l-1-3zm6.758 3.023a1 1 0 0 0-1.414-1.414l-2 2a1 1 0 0 0 1.414 1.414l2-2zM3.317 7.051a1 1 0 0 0-.633 1.898l3 1a1 1 0 1 0 .632-1.898l-3-1zm7.025 2.01a1 1 0 0 0-1.282 1.28l4 11a1 1 0 0 0 1.868.03l1.437-3.591l3.928 3.927a1 1 0 1 0 1.414-1.414l-3.928-3.928l3.592-1.436a1 1 0 0 0-.03-1.869l-11-4zm-2.635 4.646a1 1 0 1 0-1.414-1.414l-2 2a1 1 0 1 0 1.414 1.414l2-2z" fill="currentColor"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 591 B After Width: | Height: | Size: 596 B |
@@ -1 +1,4 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" viewBox="0 0 28 28" fill="none"><path fill="#A7DC22" fill-rule="evenodd" d="M9.024 2.783A1 1 0 0 1 10 2h4a1 1 0 0 1 .976.783l.44 1.981q.6.285 1.14.66l1.938-.61a1 1 0 0 1 1.166.454l2 3.464a1 1 0 0 1-.19 1.237l-1.497 1.373a8 8 0 0 1 0 1.316l1.497 1.373a1 1 0 0 1 .19 1.237l-2 3.464a1 1 0 0 1-1.166.454l-1.937-.61q-.54.375-1.14.66l-.44 1.98A1 1 0 0 1 14 22h-4a1 1 0 0 1-.976-.783l-.44-1.981q-.6-.285-1.14-.66l-1.938.61a1 1 0 0 1-1.166-.454l-2-3.464a1 1 0 0 1 .19-1.237l1.497-1.373a8 8 0 0 1 0-1.316L2.53 9.97a1 1 0 0 1-.19-1.237l2-3.464a1 1 0 0 1 1.166-.454l1.937.61q.54-.375 1.14-.66l.44-1.98zM12 15a3 3 0 1 0 0-6a3 3 0 0 0 0 6" clip-rule="evenodd"/></svg>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28" viewBox="2 2 24 24" fill="none">
|
||||||
|
<path fill="currentColor" fill-rule="evenodd" d="M 10.748 4.096 C 10.85 3.638 11.255 3.313 11.724 3.313 L 15.724 3.313 C 16.193 3.313 16.598 3.638 16.7 4.096 L 17.14 6.077 C 17.54 6.267 17.92 6.487 18.28 6.737 L 20.218 6.127 C 20.665 5.986 21.15 6.175 21.384 6.581 L 23.384 10.045 C 23.618 10.451 23.539 10.965 23.194 11.282 L 21.697 12.655 C 21.733 13.093 21.733 13.533 21.697 13.971 L 23.194 15.344 C 23.539 15.661 23.618 16.175 23.384 16.581 L 21.384 20.045 C 21.15 20.451 20.665 20.639 20.218 20.499 L 18.281 19.889 C 17.921 20.139 17.541 20.359 17.141 20.549 L 16.701 22.529 C 16.6 22.987 16.193 23.313 15.724 23.313 L 11.724 23.313 C 11.255 23.313 10.85 22.987 10.748 22.53 L 10.308 20.549 C 9.908 20.359 9.528 20.139 9.168 19.889 L 7.23 20.499 C 6.783 20.639 6.298 20.451 6.064 20.045 L 4.064 16.581 C 3.83 16.175 3.908 15.661 4.254 15.344 L 5.751 13.971 C 5.715 13.533 5.715 13.093 5.751 12.655 L 4.254 11.283 C 3.908 10.966 3.83 10.452 4.064 10.046 L 6.064 6.582 C 6.298 6.176 6.783 5.987 7.23 6.128 L 9.167 6.738 C 9.527 6.488 9.907 6.268 10.307 6.078 L 10.747 4.098 L 10.748 4.096 Z M 13.931 17.38 C 17.01 17.38 18.935 14.046 17.395 11.38 C 16.68 10.142 15.36 9.38 13.931 9.38 C 10.852 9.38 8.927 12.713 10.467 15.38 C 11.181 16.617 12.502 17.38 13.931 17.38" clip-rule="evenodd"/>
|
||||||
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 717 B After Width: | Height: | Size: 1.4 KiB |
@@ -1,4 +1,4 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="18" viewBox="0 0 16 18" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="18" viewBox="0 0 16 18" fill="none">
|
||||||
<path d="M1.3335 4.83332V6.49999H14.6668V4.83332C14.6668 4.3913 14.4912 3.96737 14.1787 3.65481C13.8661 3.34225 13.4422 3.16666 13.0002 3.16666H3.00016C2.55814 3.16666 2.13421 3.34225 1.82165 3.65481C1.50909 3.96737 1.3335 4.3913 1.3335 4.83332Z" fill="#A7DC22"/>
|
<path d="M1.3335 4.83332V6.49999H14.6668V4.83332C14.6668 4.3913 14.4912 3.96737 14.1787 3.65481C13.8661 3.34225 13.4422 3.16666 13.0002 3.16666H3.00016C2.55814 3.16666 2.13421 3.34225 1.82165 3.65481C1.50909 3.96737 1.3335 4.3913 1.3335 4.83332Z" fill="currentColor"/>
|
||||||
<path d="M11.3335 3.16667H13.0002C13.4422 3.16667 13.8661 3.34226 14.1787 3.65482C14.4912 3.96738 14.6668 4.39131 14.6668 4.83333V6.5H1.3335V4.83333C1.3335 4.39131 1.50909 3.96738 1.82165 3.65482C2.13421 3.34226 2.55814 3.16667 3.00016 3.16667H4.66683M11.3335 3.16667V1.5M11.3335 3.16667H4.66683M4.66683 3.16667V1.5M1.3335 6.91667V14.8333C1.3335 15.2754 1.50909 15.6993 1.82165 16.0118C2.13421 16.3244 2.55814 16.5 3.00016 16.5H13.0002C13.4422 16.5 13.8661 16.3244 14.1787 16.0118C14.4912 15.6993 14.6668 15.2754 14.6668 14.8333V6.91667" stroke="#A7DC22" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M11.3335 3.16667H13.0002C13.4422 3.16667 13.8661 3.34226 14.1787 3.65482C14.4912 3.96738 14.6668 4.39131 14.6668 4.83333V6.5H1.3335V4.83333C1.3335 4.39131 1.50909 3.96738 1.82165 3.65482C2.13421 3.34226 2.55814 3.16667 3.00016 3.16667H4.66683M11.3335 3.16667V1.5M11.3335 3.16667H4.66683M4.66683 3.16667V1.5M1.3335 6.91667V14.8333C1.3335 15.2754 1.50909 15.6993 1.82165 16.0118C2.13421 16.3244 2.55814 16.5 3.00016 16.5H13.0002C13.4422 16.5 13.8661 16.3244 14.1787 16.0118C14.4912 15.6993 14.6668 15.2754 14.6668 14.8333V6.91667" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 991 B After Width: | Height: | Size: 1001 B |
@@ -1,5 +1,5 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
|
||||||
<g opacity="0.5">
|
<g opacity="0.5">
|
||||||
<path d="M3.33325 7.5V15.8333C3.33325 16.2754 3.50885 16.6993 3.82141 17.0118C4.13397 17.3244 4.55789 17.5 4.99992 17.5H14.9999C15.4419 17.5 15.8659 17.3244 16.1784 17.0118C16.491 16.6993 16.6666 16.2754 16.6666 15.8333V7.5M3.33325 7.5V5.83333C3.33325 5.39131 3.50885 4.96738 3.82141 4.65482C4.13397 4.34226 4.55789 4.16667 4.99992 4.16667H6.66659M3.33325 7.5H16.6666M16.6666 7.5V5.83333C16.6666 5.39131 16.491 4.96738 16.1784 4.65482C15.8659 4.34226 15.4419 4.16667 14.9999 4.16667H13.3333M6.66659 4.16667H13.3333M6.66659 4.16667V2.5M13.3333 4.16667V2.5" stroke="#6E8F1B" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
<path d="M3.33325 7.5V15.8333C3.33325 16.2754 3.50885 16.6993 3.82141 17.0118C4.13397 17.3244 4.55789 17.5 4.99992 17.5H14.9999C15.4419 17.5 15.8659 17.3244 16.1784 17.0118C16.491 16.6993 16.6666 16.2754 16.6666 15.8333V7.5M3.33325 7.5V5.83333C3.33325 5.39131 3.50885 4.96738 3.82141 4.65482C4.13397 4.34226 4.55789 4.16667 4.99992 4.16667H6.66659M3.33325 7.5H16.6666M16.6666 7.5V5.83333C16.6666 5.39131 16.491 4.96738 16.1784 4.65482C15.8659 4.34226 15.4419 4.16667 14.9999 4.16667H13.3333M6.66659 4.16667H13.3333M6.66659 4.16667V2.5M13.3333 4.16667V2.5" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/>
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 772 B After Width: | Height: | Size: 777 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M11 5a1 1 0 0 0-1 1h4a1 1 0 0 0-1-1h-2zm0-2a3 3 0 0 0-3 3H4a1 1 0 0 0 0 2h1v10a3 3 0 0 0 3 3h8a3 3 0 0 0 3-3V8h1a1 1 0 1 0 0-2h-4a3 3 0 0 0-3-3h-2zm0 8a1 1 0 1 0-2 0v5a1 1 0 1 0 2 0v-5zm4 0a1 1 0 1 0-2 0v5a1 1 0 1 0 2 0v-5z" fill="#A7DC22"/></g></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><g fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M11 5a1 1 0 0 0-1 1h4a1 1 0 0 0-1-1h-2zm0-2a3 3 0 0 0-3 3H4a1 1 0 0 0 0 2h1v10a3 3 0 0 0 3 3h8a3 3 0 0 0 3-3V8h1a1 1 0 1 0 0-2h-4a3 3 0 0 0-3-3h-2zm0 8a1 1 0 1 0-2 0v5a1 1 0 1 0 2 0v-5zm4 0a1 1 0 1 0-2 0v5a1 1 0 1 0 2 0v-5z" fill="currentColor"/></g></svg>
|
||||||
|
Before Width: | Height: | Size: 400 B After Width: | Height: | Size: 405 B |
@@ -1 +1 @@
|
|||||||
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="none" stroke="#A7DC22" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 9v5h5m11 2c-.497-4.5-3.367-8-8-8c-2.73 0-5.929 2.268-7.294 5.5"/></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" width="128" height="128" viewBox="0 0 24 24"><path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 9v5h5m11 2c-.497-4.5-3.367-8-8-8c-2.73 0-5.929 2.268-7.294 5.5"/></svg>
|
||||||
|
Before Width: | Height: | Size: 261 B After Width: | Height: | Size: 266 B |
BIN
images/firka_logo_128_c.png
Normal file
|
After Width: | Height: | Size: 8.4 KiB |
BIN
images/firka_logo_c.png
Normal file
|
After Width: | Height: | Size: 213 KiB |
BIN
images/folio.png
Normal file
|
After Width: | Height: | Size: 46 KiB |
@@ -54,7 +54,6 @@ body {
|
|||||||
flex-direction:column;
|
flex-direction:column;
|
||||||
align-items:center;
|
align-items:center;
|
||||||
gap:8px;
|
gap:8px;
|
||||||
margin:16px 0;
|
|
||||||
background:var(--card-card) !important;
|
background:var(--card-card) !important;
|
||||||
border-bottom:1px solid rgba(0,0,0,0) !important;
|
border-bottom:1px solid rgba(0,0,0,0) !important;
|
||||||
}
|
}
|
||||||
@@ -66,6 +65,7 @@ body {
|
|||||||
font-style:normal;
|
font-style:normal;
|
||||||
font-weight:700;
|
font-weight:700;
|
||||||
line-height:normal;
|
line-height:normal;
|
||||||
|
margin-bottom: 12px;
|
||||||
}
|
}
|
||||||
.logo {
|
.logo {
|
||||||
width:48px;
|
width:48px;
|
||||||
@@ -136,7 +136,7 @@ body {
|
|||||||
height:20px;
|
height:20px;
|
||||||
opacity:0.6;
|
opacity:0.6;
|
||||||
transition:opacity 0.2s ease;
|
transition:opacity 0.2s ease;
|
||||||
filter:invert(var(--icon-invert)) sepia(var(--icon-sepia)) saturate(var(--icon-saturate)) hue-rotate(var(--icon-hue-rotate)) brightness(var(--icon-brightness));
|
filter: var(--icon-filter);
|
||||||
}
|
}
|
||||||
.show-password:hover .icon-eye {
|
.show-password:hover .icon-eye {
|
||||||
opacity:1;
|
opacity:1;
|
||||||
|
|||||||
@@ -1,11 +1,21 @@
|
|||||||
async function transformLoginPage() {
|
async function transformLoginPage() {
|
||||||
try {
|
try {
|
||||||
|
while (
|
||||||
|
typeof window.LanguageManager === "undefined" ||
|
||||||
|
!window.LanguageManager.t("login.username_placeholder") ||
|
||||||
|
window.LanguageManager.t("login.username_placeholder") === "login.username_placeholder"
|
||||||
|
) {
|
||||||
|
await new Promise((resolve) => setTimeout(resolve, 50));
|
||||||
|
}
|
||||||
|
|
||||||
if (document.readyState !== "complete") {
|
if (document.readyState !== "complete") {
|
||||||
await new Promise((resolve) => {
|
await new Promise((resolve) => {
|
||||||
window.addEventListener("load", resolve);
|
window.addEventListener("load", resolve);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const loginSettings = await loadLoginSettings();
|
||||||
|
|
||||||
const existingForm = document.querySelector("form");
|
const existingForm = document.querySelector("form");
|
||||||
const formData = {
|
const formData = {
|
||||||
action: existingForm?.getAttribute("action") || "",
|
action: existingForm?.getAttribute("action") || "",
|
||||||
@@ -50,11 +60,11 @@ async function transformLoginPage() {
|
|||||||
<img src=${chrome.runtime.getURL("images/firka_logo.png")} alt="Firka" class="logo">
|
<img src=${chrome.runtime.getURL("images/firka_logo.png")} alt="Firka" class="logo">
|
||||||
Firka
|
Firka
|
||||||
</p>
|
</p>
|
||||||
<h1 class="school-name">${schoolInfo.name}</h1>
|
${!loginSettings.hideSchoolInfo ? `<h1 class="school-name">${schoolInfo.name}</h1>
|
||||||
<div class="school-details">
|
<div class="school-details">
|
||||||
${schoolInfo.kretaId ? `<div>${schoolInfo.kretaId}</div>` : ""}
|
${schoolInfo.kretaId ? `<div>${schoolInfo.kretaId}</div>` : ""}
|
||||||
${schoolInfo.omCode ? `<div>${LanguageManager.t("login.kreta_id")}: ${schoolInfo.omCode}</div>` : ""}
|
${schoolInfo.omCode ? `<div>${LanguageManager.t("login.kreta_id")}: ${schoolInfo.omCode}</div>` : ""}
|
||||||
</div>
|
</div>` : ''}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<form class="login-form" method="post" action="${formData.action}" id="loginForm" novalidate>
|
<form class="login-form" method="post" action="${formData.action}" id="loginForm" novalidate>
|
||||||
@@ -93,7 +103,7 @@ async function transformLoginPage() {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
${
|
${
|
||||||
systemMessage
|
systemMessage && !loginSettings.hideSystemMessage
|
||||||
? `
|
? `
|
||||||
<div class="system-message">
|
<div class="system-message">
|
||||||
<h4>${LanguageManager.t("login.system_message")}</h4>
|
<h4>${LanguageManager.t("login.system_message")}</h4>
|
||||||
@@ -110,13 +120,11 @@ async function transformLoginPage() {
|
|||||||
</div>
|
</div>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
document.body.innerHTML = '';
|
const template = document.createElement('template');
|
||||||
const parser = new DOMParser();
|
template.innerHTML = newHTML;
|
||||||
const doc = parser.parseFromString(newHTML, 'text/html');
|
|
||||||
const tempDiv = doc.body;
|
helper.clearElement(document.body);
|
||||||
while (tempDiv.firstChild) {
|
document.body.appendChild(template.content);
|
||||||
document.body.appendChild(tempDiv.firstChild);
|
|
||||||
}
|
|
||||||
|
|
||||||
setupEventListeners();
|
setupEventListeners();
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
@@ -195,7 +203,35 @@ function handleSubmit(event) {
|
|||||||
form.submit();
|
form.submit();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (window.location.href.includes("idp.e-kreta.hu/Account/Login")) {
|
async function loadLoginSettings() {
|
||||||
transformLoginPage().catch((error) => {
|
try {
|
||||||
});
|
const settings = await storageManager.get("pageSettings_login", {});
|
||||||
|
return {
|
||||||
|
hideSystemMessage: settings.hideSystemMessage || false,
|
||||||
|
hideSchoolInfo: settings.hideSchoolInfo || false
|
||||||
|
};
|
||||||
|
} catch (error) {
|
||||||
|
console.error("Error loading login settings:", error);
|
||||||
|
return {
|
||||||
|
hideSystemMessage: false,
|
||||||
|
hideSchoolInfo: false
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
chrome.runtime.onMessage.addListener((message, sender, sendResponse) => {
|
||||||
|
if (message.action === "pageSettingChanged" && message.pageType === "login") {
|
||||||
|
transformLoginPage();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
if (window.location.href.includes("idp.e-kreta.hu/Account/Login")) {
|
||||||
|
(async () => {
|
||||||
|
while (typeof window.LanguageManager === "undefined") {
|
||||||
|
await new Promise((resolve) => setTimeout(resolve, 50));
|
||||||
|
}
|
||||||
|
transformLoginPage().catch((error) => {
|
||||||
|
console.error("Error transforming login page:", error);
|
||||||
|
});
|
||||||
|
})();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -128,7 +128,7 @@ body {
|
|||||||
height:20px;
|
height:20px;
|
||||||
opacity:0.6;
|
opacity:0.6;
|
||||||
transition:opacity 0.2s ease;
|
transition:opacity 0.2s ease;
|
||||||
filter:invert(var(--icon-invert)) sepia(var(--icon-sepia)) saturate(var(--icon-saturate)) hue-rotate(var(--icon-hue-rotate)) brightness(var(--icon-brightness));
|
filter: var(--icon-filter);
|
||||||
}
|
}
|
||||||
.show-password:hover .icon-eye {
|
.show-password:hover .icon-eye {
|
||||||
opacity:1;
|
opacity:1;
|
||||||
|
|||||||
@@ -83,13 +83,12 @@ async function transformTwoFactorPage() {
|
|||||||
</div>
|
</div>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
document.body.innerHTML = '';
|
const template = document.createElement('template');
|
||||||
const parser = new DOMParser();
|
template.innerHTML = newHTML;
|
||||||
const doc = parser.parseFromString(newHTML, 'text/html');
|
|
||||||
const tempDiv = doc.body;
|
helper.clearElement(document.body);
|
||||||
while (tempDiv.firstChild) {
|
document.body.appendChild(template.content);
|
||||||
document.body.appendChild(tempDiv.firstChild);
|
|
||||||
}
|
|
||||||
applyTheme();
|
applyTheme();
|
||||||
setupEventListeners();
|
setupEventListeners();
|
||||||
if (typeof loadingScreen !== "undefined") {
|
if (typeof loadingScreen !== "undefined") {
|
||||||
@@ -170,7 +169,7 @@ function handleSubmit(event) {
|
|||||||
const submitButton = form.querySelector(".btn-kreta");
|
const submitButton = form.querySelector(".btn-kreta");
|
||||||
if (submitButton) {
|
if (submitButton) {
|
||||||
submitButton.disabled = true;
|
submitButton.disabled = true;
|
||||||
submitButton.innerHTML = '';
|
helper.clearElement(submitButton);
|
||||||
const spinnerSpan = document.createElement('span');
|
const spinnerSpan = document.createElement('span');
|
||||||
spinnerSpan.className = 'spinner';
|
spinnerSpan.className = 'spinner';
|
||||||
const textSpan = document.createElement('span');
|
const textSpan = document.createElement('span');
|
||||||
|
|||||||
@@ -34,10 +34,10 @@
|
|||||||
</footer>
|
</footer>
|
||||||
</div>
|
</div>
|
||||||
`;
|
`;
|
||||||
document.body.innerHTML = '';
|
helper.clearElement(document.body);
|
||||||
const parser = new DOMParser();
|
const template = document.createElement('template');
|
||||||
const doc = parser.parseFromString(newHTML, 'text/html');
|
template.innerHTML = newHTML;
|
||||||
const tempDiv = doc.body;
|
const tempDiv = template.content;
|
||||||
while (tempDiv.firstChild) {
|
while (tempDiv.firstChild) {
|
||||||
document.body.appendChild(tempDiv.firstChild);
|
document.body.appendChild(tempDiv.firstChild);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"manifest_version": 3,
|
"manifest_version": 3,
|
||||||
"name": "Firxa",
|
"name": "Firxa",
|
||||||
"version": "1.3.5",
|
"version": "1.4.8",
|
||||||
"description": "KRÉTA webes verziójának újraírása",
|
"description": "KRÉTA webes verziójának újraírása",
|
||||||
"icons": {
|
"icons": {
|
||||||
"128": "images/firka_logo_128.png"
|
"128": "images/firka_logo_128.png"
|
||||||
@@ -13,7 +13,8 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"permissions": [
|
"permissions": [
|
||||||
"storage"
|
"storage",
|
||||||
|
"tabs"
|
||||||
],
|
],
|
||||||
"background": {
|
"background": {
|
||||||
"service_worker": "tools/background.js"
|
"service_worker": "tools/background.js"
|
||||||
@@ -31,6 +32,7 @@
|
|||||||
{
|
{
|
||||||
"resources": [
|
"resources": [
|
||||||
"settings/*",
|
"settings/*",
|
||||||
|
"setup/*",
|
||||||
"global/language.js",
|
"global/language.js",
|
||||||
"images/*",
|
"images/*",
|
||||||
"fonts/*.woff2",
|
"fonts/*.woff2",
|
||||||
@@ -189,18 +191,6 @@
|
|||||||
],
|
],
|
||||||
"run_at": "document_end"
|
"run_at": "document_end"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"matches": [
|
|
||||||
"https://*.e-kreta.hu/Adminisztracio/ElfelejtettJelszo*"
|
|
||||||
],
|
|
||||||
"js": [
|
|
||||||
"forgotpassword/forgotpassword.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"forgotpassword/forgotpassword.css"
|
|
||||||
],
|
|
||||||
"run_at": "document_end"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"matches": [
|
"matches": [
|
||||||
"https://intezmenykereso.e-kreta.hu/"
|
"https://intezmenykereso.e-kreta.hu/"
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"manifest_version": 3,
|
"manifest_version": 3,
|
||||||
"name": "Firxa",
|
"name": "Firxa",
|
||||||
"version": "1.3.4",
|
"version": "1.4.8",
|
||||||
"description": "KRÉTA webes verziójának újraírása",
|
"description": "KRÉTA webes verziójának újraírása",
|
||||||
"icons": {
|
"icons": {
|
||||||
"128": "images/firka_logo_128.png"
|
"128": "images/firka_logo_128.png"
|
||||||
@@ -13,19 +13,18 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"permissions": [
|
"permissions": [
|
||||||
"storage"
|
"storage",
|
||||||
|
"tabs"
|
||||||
],
|
],
|
||||||
"background": {
|
"background": {
|
||||||
"service_worker": "tools/background.js",
|
"scripts": ["tools/background.js"]
|
||||||
"scripts": ["tools/background.js"],
|
|
||||||
"persistent": false
|
|
||||||
},
|
},
|
||||||
"browser_specific_settings": {
|
"browser_specific_settings": {
|
||||||
"gecko": {
|
"gecko": {
|
||||||
"id": "firxa@zan1456.hu",
|
"id": "firxa@zan1456.hu",
|
||||||
"strict_min_version": "109.0",
|
"strict_min_version": "109.0",
|
||||||
"data_collection_permissions": {
|
"data_collection_permissions": {
|
||||||
"required": ["none"]
|
"required": []
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -33,6 +32,7 @@
|
|||||||
{
|
{
|
||||||
"resources": [
|
"resources": [
|
||||||
"settings/*",
|
"settings/*",
|
||||||
|
"setup/*",
|
||||||
"global/language.js",
|
"global/language.js",
|
||||||
"images/*",
|
"images/*",
|
||||||
"fonts/*.woff2",
|
"fonts/*.woff2",
|
||||||
@@ -191,18 +191,6 @@
|
|||||||
],
|
],
|
||||||
"run_at": "document_end"
|
"run_at": "document_end"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"matches": [
|
|
||||||
"https://*.e-kreta.hu/Adminisztracio/ElfelejtettJelszo*"
|
|
||||||
],
|
|
||||||
"js": [
|
|
||||||
"forgotpassword/forgotpassword.js"
|
|
||||||
],
|
|
||||||
"css": [
|
|
||||||
"forgotpassword/forgotpassword.css"
|
|
||||||
],
|
|
||||||
"run_at": "document_end"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"matches": [
|
"matches": [
|
||||||
"https://intezmenykereso.e-kreta.hu/"
|
"https://intezmenykereso.e-kreta.hu/"
|
||||||
|
|||||||
@@ -128,16 +128,23 @@ body {
|
|||||||
padding: 10px 12px;
|
padding: 10px 12px;
|
||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
}
|
}
|
||||||
.bulk-actions-left,
|
.bulk-actions-left {
|
||||||
|
justify-content: space-between;
|
||||||
|
flex-wrap: nowrap;
|
||||||
|
gap: 6px;
|
||||||
|
order: 1;
|
||||||
|
}
|
||||||
.bulk-actions-right {
|
.bulk-actions-right {
|
||||||
justify-content: center;
|
justify-content: space-between;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
gap: 6px;
|
gap: 6px;
|
||||||
|
order: 2;
|
||||||
}
|
}
|
||||||
.bulk-btn,
|
.bulk-btn,
|
||||||
.view-toggle button {
|
.view-toggle button {
|
||||||
width: 32px;
|
width: 32px;
|
||||||
height: 32px;
|
height: 32px;
|
||||||
|
flex: 1;
|
||||||
}
|
}
|
||||||
.bulk-btn img,
|
.bulk-btn img,
|
||||||
.view-toggle button img {
|
.view-toggle button img {
|
||||||
@@ -151,12 +158,19 @@ body {
|
|||||||
.view-toggle button {
|
.view-toggle button {
|
||||||
width: 28px;
|
width: 28px;
|
||||||
height: 28px;
|
height: 28px;
|
||||||
|
flex: 1;
|
||||||
}
|
}
|
||||||
.bulk-btn img,
|
.bulk-btn img,
|
||||||
.view-toggle button img {
|
.view-toggle button img {
|
||||||
width: 16px;
|
width: 16px;
|
||||||
height: 16px;
|
height: 16px;
|
||||||
}
|
}
|
||||||
|
.bulk-actions-left {
|
||||||
|
order: 1;
|
||||||
|
}
|
||||||
|
.bulk-actions-right {
|
||||||
|
order: 2;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.messages-grid {
|
.messages-grid {
|
||||||
@@ -426,7 +440,6 @@ body.modal-open {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
padding: 20px;
|
padding: 20px;
|
||||||
border-bottom: 1px solid var(--background-0);
|
border-bottom: 1px solid var(--background-0);
|
||||||
background: var(--background);
|
|
||||||
border-radius: 12px 12px 0 0;
|
border-radius: 12px 12px 0 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -511,7 +524,7 @@ body.modal-open {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.message-info {
|
.message-info {
|
||||||
background-color: var(--card-card);
|
background-color: var(--button-secondaryFill);
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
@@ -550,7 +563,7 @@ body.modal-open {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.message-text {
|
.message-text {
|
||||||
background-color: var(--card-card);
|
background-color: var(--button-secondaryFill);
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
line-height: 1.6;
|
line-height: 1.6;
|
||||||
@@ -577,14 +590,14 @@ body.modal-open {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.message-attachments {
|
.message-attachments {
|
||||||
background: #f9f9f9;
|
background: var(--button-secondaryFill);
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.message-attachments h4 {
|
.message-attachments h4 {
|
||||||
margin: 0 0 10px 0;
|
margin: 0 0 10px 0;
|
||||||
color: #333;
|
color: var(--text-secondary);
|
||||||
font-size: 1.1em;
|
font-size: 1.1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -42,7 +42,7 @@
|
|||||||
function sanitizeHTML(html) {
|
function sanitizeHTML(html) {
|
||||||
const div = document.createElement('div');
|
const div = document.createElement('div');
|
||||||
div.textContent = html;
|
div.textContent = html;
|
||||||
return div.innerHTML;
|
return div.textContent;
|
||||||
}
|
}
|
||||||
|
|
||||||
class APIManager {
|
class APIManager {
|
||||||
@@ -159,20 +159,37 @@
|
|||||||
|
|
||||||
const modalContent = document.createElement('div');
|
const modalContent = document.createElement('div');
|
||||||
modalContent.className = 'modal-content';
|
modalContent.className = 'modal-content';
|
||||||
modalContent.innerHTML = `
|
|
||||||
<div class="modal-header">
|
const modalHeader = document.createElement('div');
|
||||||
<h2>Üzenet részletei</h2>
|
modalHeader.className = 'modal-header';
|
||||||
<button class="modal-close" onclick="closeMessageModal()">×</button>
|
const modalTitle = document.createElement('h2');
|
||||||
</div>
|
modalTitle.textContent = 'Üzenet részletei';
|
||||||
<div class="modal-body">
|
const modalClose = document.createElement('button');
|
||||||
<div class="loading-content">
|
modalClose.className = 'modal-close';
|
||||||
<div class="loading-spinner"></div>
|
modalClose.textContent = '×';
|
||||||
<p>Üzenet betöltése...</p>
|
modalHeader.appendChild(modalTitle);
|
||||||
</div>
|
modalHeader.appendChild(modalClose);
|
||||||
</div>
|
|
||||||
`;
|
const modalBody = document.createElement('div');
|
||||||
|
modalBody.className = 'modal-body';
|
||||||
|
const loadingContent = document.createElement('div');
|
||||||
|
loadingContent.className = 'loading-content';
|
||||||
|
const loadingSpinner = document.createElement('div');
|
||||||
|
loadingSpinner.className = 'loading-spinner';
|
||||||
|
const loadingText = document.createElement('p');
|
||||||
|
loadingText.textContent = 'Üzenet betöltése...';
|
||||||
|
loadingContent.appendChild(loadingSpinner);
|
||||||
|
loadingContent.appendChild(loadingText);
|
||||||
|
modalBody.appendChild(loadingContent);
|
||||||
|
|
||||||
|
modalContent.appendChild(modalHeader);
|
||||||
|
modalContent.appendChild(modalBody);
|
||||||
|
|
||||||
modalOverlay.appendChild(modalContent);
|
modalOverlay.appendChild(modalContent);
|
||||||
document.body.appendChild(modalOverlay);
|
document.body.appendChild(modalOverlay);
|
||||||
|
|
||||||
|
const closeBtn = modalContent.querySelector('.modal-close');
|
||||||
|
closeBtn.addEventListener('click', closeMessageModal);
|
||||||
|
|
||||||
if (!isRead) {
|
if (!isRead) {
|
||||||
try {
|
try {
|
||||||
@@ -210,13 +227,24 @@
|
|||||||
console.error('Error loading message details:', error);
|
console.error('Error loading message details:', error);
|
||||||
const modalContent = document.querySelector('.modal-content');
|
const modalContent = document.querySelector('.modal-content');
|
||||||
if (modalContent) {
|
if (modalContent) {
|
||||||
modalContent.querySelector('.modal-body').innerHTML = `
|
const modalBody = modalContent.querySelector('.modal-body');
|
||||||
<div class="error-content">
|
helper.clearElement(modalBody);
|
||||||
<h3>Hiba történt</h3>
|
|
||||||
<p>Az üzenet betöltése sikertelen.</p>
|
const errorContent = document.createElement('div');
|
||||||
<button class="retry-btn" onclick="openMessageModal(${messageId})">Újrapróbálás</button>
|
errorContent.className = 'error-content';
|
||||||
</div>
|
const errorTitle = document.createElement('h3');
|
||||||
`;
|
errorTitle.textContent = 'Hiba történt';
|
||||||
|
const errorText = document.createElement('p');
|
||||||
|
errorText.textContent = 'Az üzenet betöltése sikertelen.';
|
||||||
|
const retryBtn = document.createElement('button');
|
||||||
|
retryBtn.className = 'retry-btn';
|
||||||
|
retryBtn.textContent = 'Újrapróbálás';
|
||||||
|
retryBtn.onclick = () => openMessageModal(messageId);
|
||||||
|
|
||||||
|
errorContent.appendChild(errorTitle);
|
||||||
|
errorContent.appendChild(errorText);
|
||||||
|
errorContent.appendChild(retryBtn);
|
||||||
|
modalBody.appendChild(errorContent);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -228,38 +256,90 @@
|
|||||||
const subject = message.targy || 'Nincs tárgy';
|
const subject = message.targy || 'Nincs tárgy';
|
||||||
const content = message.szoveg || 'Nincs tartalom';
|
const content = message.szoveg || 'Nincs tartalom';
|
||||||
|
|
||||||
modalContent.querySelector('.modal-body').innerHTML = `
|
const modalBody = modalContent.querySelector('.modal-body');
|
||||||
<div class="message-details">
|
helper.clearElement(modalBody);
|
||||||
<div class="message-info">
|
|
||||||
<div class="info-row">
|
const messageDetails = document.createElement('div');
|
||||||
<span class="info-label">Feladó:</span>
|
messageDetails.className = 'message-details';
|
||||||
<span class="info-value">${sanitizeHTML(sender)}</span>
|
|
||||||
</div>
|
const messageInfo = document.createElement('div');
|
||||||
<div class="info-row">
|
messageInfo.className = 'message-info';
|
||||||
<span class="info-label">Dátum:</span>
|
|
||||||
<span class="info-value">${date}</span>
|
const senderRow = document.createElement('div');
|
||||||
</div>
|
senderRow.className = 'info-row';
|
||||||
<div class="info-row">
|
const senderLabel = document.createElement('span');
|
||||||
<span class="info-label">Tárgy:</span>
|
senderLabel.className = 'info-label';
|
||||||
<span class="info-value">${sanitizeHTML(subject)}</span>
|
senderLabel.textContent = 'Feladó:';
|
||||||
</div>
|
const senderValue = document.createElement('span');
|
||||||
</div>
|
senderValue.className = 'info-value';
|
||||||
<div class="message-content">
|
senderValue.textContent = sanitizeHTML(sender);
|
||||||
<h4>Üzenet tartalma:</h4>
|
senderRow.appendChild(senderLabel);
|
||||||
<div class="message-text">${content}</div>
|
senderRow.appendChild(senderValue);
|
||||||
</div>
|
messageInfo.appendChild(senderRow);
|
||||||
${message.csatolmanyok && message.csatolmanyok.length > 0 ? `
|
|
||||||
<div class="message-attachments">
|
const dateRow = document.createElement('div');
|
||||||
<h4>Mellékletek:</h4>
|
dateRow.className = 'info-row';
|
||||||
<ul>
|
const dateLabel = document.createElement('span');
|
||||||
${message.csatolmanyok.map(attachment => `
|
dateLabel.className = 'info-label';
|
||||||
<li><a href="#" onclick="downloadAttachment('${attachment.azonosito}')">${sanitizeHTML(attachment.nev)}</a></li>
|
dateLabel.textContent = 'Dátum:';
|
||||||
`).join('')}
|
const dateValue = document.createElement('span');
|
||||||
</ul>
|
dateValue.className = 'info-value';
|
||||||
</div>
|
dateValue.textContent = date;
|
||||||
` : ''}
|
dateRow.appendChild(dateLabel);
|
||||||
</div>
|
dateRow.appendChild(dateValue);
|
||||||
`;
|
messageInfo.appendChild(dateRow);
|
||||||
|
|
||||||
|
const subjectRow = document.createElement('div');
|
||||||
|
subjectRow.className = 'info-row';
|
||||||
|
const subjectLabel = document.createElement('span');
|
||||||
|
subjectLabel.className = 'info-label';
|
||||||
|
subjectLabel.textContent = 'Tárgy:';
|
||||||
|
const subjectValue = document.createElement('span');
|
||||||
|
subjectValue.className = 'info-value';
|
||||||
|
subjectValue.textContent = sanitizeHTML(subject);
|
||||||
|
subjectRow.appendChild(subjectLabel);
|
||||||
|
subjectRow.appendChild(subjectValue);
|
||||||
|
messageInfo.appendChild(subjectRow);
|
||||||
|
|
||||||
|
messageDetails.appendChild(messageInfo);
|
||||||
|
|
||||||
|
const messageContent = document.createElement('div');
|
||||||
|
messageContent.className = 'message-content';
|
||||||
|
const contentTitle = document.createElement('h4');
|
||||||
|
contentTitle.textContent = 'Üzenet tartalma:';
|
||||||
|
messageContent.appendChild(contentTitle);
|
||||||
|
const messageText = document.createElement('div');
|
||||||
|
messageText.className = 'message-text';
|
||||||
|
messageText.innerHTML = content;
|
||||||
|
|
||||||
|
messageContent.appendChild(messageText);
|
||||||
|
messageDetails.appendChild(messageContent);
|
||||||
|
|
||||||
|
if (message.csatolmanyok && message.csatolmanyok.length > 0) {
|
||||||
|
const messageAttachments = document.createElement('div');
|
||||||
|
messageAttachments.className = 'message-attachments';
|
||||||
|
const attachTitle = document.createElement('h4');
|
||||||
|
attachTitle.textContent = 'Mellékletek:';
|
||||||
|
messageAttachments.appendChild(attachTitle);
|
||||||
|
|
||||||
|
const attachList = document.createElement('ul');
|
||||||
|
message.csatolmanyok.forEach(attachment => {
|
||||||
|
const li = document.createElement('li');
|
||||||
|
const a = document.createElement('a');
|
||||||
|
a.href = '#';
|
||||||
|
a.textContent = sanitizeHTML(attachment.fajlNev || attachment.nev || 'Ismeretlen fájl');
|
||||||
|
a.onclick = (e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
downloadAttachment(attachment.azonosito, attachment.fajlNev || attachment.nev);
|
||||||
|
};
|
||||||
|
li.appendChild(a);
|
||||||
|
attachList.appendChild(li);
|
||||||
|
});
|
||||||
|
messageAttachments.appendChild(attachList);
|
||||||
|
messageDetails.appendChild(messageAttachments);
|
||||||
|
}
|
||||||
|
|
||||||
|
modalBody.appendChild(messageDetails);
|
||||||
}
|
}
|
||||||
|
|
||||||
function closeMessageModal() {
|
function closeMessageModal() {
|
||||||
@@ -269,47 +349,90 @@
|
|||||||
}
|
}
|
||||||
document.body.classList.remove('modal-open');
|
document.body.classList.remove('modal-open');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async function downloadAttachment(azonosito, fileName) {
|
||||||
|
try {
|
||||||
|
const response = await chrome.runtime.sendMessage({
|
||||||
|
action: 'download_attachment',
|
||||||
|
azonosito: azonosito,
|
||||||
|
fileName: fileName
|
||||||
|
});
|
||||||
|
|
||||||
|
if (response.success && response.data) {
|
||||||
|
const a = document.createElement('a');
|
||||||
|
a.href = response.data;
|
||||||
|
a.download = response.fileName || 'letoltes';
|
||||||
|
document.body.appendChild(a);
|
||||||
|
a.click();
|
||||||
|
document.body.removeChild(a);
|
||||||
|
} else {
|
||||||
|
console.error('Melléklet letöltési hiba:', response.error);
|
||||||
|
alert('Nem sikerült letölteni a mellékletet.');
|
||||||
|
}
|
||||||
|
} catch (error) {
|
||||||
|
console.error('Melléklet letöltési hiba:', error);
|
||||||
|
alert('Hiba történt a melléklet letöltése során.');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
window.openMessageModal = openMessageModal;
|
window.openMessageModal = openMessageModal;
|
||||||
window.closeMessageModal = closeMessageModal;
|
window.closeMessageModal = closeMessageModal;
|
||||||
|
|
||||||
function createLoadingState() {
|
function createLoadingState() {
|
||||||
const loadingDiv = document.createElement('div');
|
const loadingDiv = document.createElement('div');
|
||||||
loadingDiv.className = 'loading-state';
|
loadingDiv.className = 'loading-state';
|
||||||
loadingDiv.innerHTML = `
|
|
||||||
<div class="loading-content">
|
const loadingContent = document.createElement('div');
|
||||||
<div class="loading-spinner"></div>
|
loadingContent.className = 'loading-content';
|
||||||
<p>${LanguageManager.t('messages.loading', 'Üzenetek betöltése...')}</p>
|
const spinner = document.createElement('div');
|
||||||
</div>
|
spinner.className = 'loading-spinner';
|
||||||
`;
|
const text = document.createElement('p');
|
||||||
|
text.textContent = LanguageManager.t('messages.loading', 'Üzenetek betöltése...');
|
||||||
|
loadingContent.appendChild(spinner);
|
||||||
|
loadingContent.appendChild(text);
|
||||||
|
loadingDiv.appendChild(loadingContent);
|
||||||
|
|
||||||
return loadingDiv;
|
return loadingDiv;
|
||||||
}
|
}
|
||||||
|
|
||||||
function createErrorState(onRetry) {
|
function createErrorState(onRetry) {
|
||||||
const errorDiv = document.createElement('div');
|
const errorDiv = document.createElement('div');
|
||||||
errorDiv.className = 'error-state';
|
errorDiv.className = 'error-state';
|
||||||
errorDiv.innerHTML = `
|
|
||||||
<div class="error-content">
|
|
||||||
<h3>${LanguageManager.t('messages.error.title', 'Hiba történt')}</h3>
|
|
||||||
<p>${LanguageManager.t('messages.error.description', 'Az üzenetek betöltése sikertelen volt.')}</p>
|
|
||||||
<button class="retry-btn">${LanguageManager.t('messages.error.retry', 'Újrapróbálás')}</button>
|
|
||||||
</div>
|
|
||||||
`;
|
|
||||||
|
|
||||||
const retryBtn = errorDiv.querySelector('.retry-btn');
|
const errorContent = document.createElement('div');
|
||||||
|
errorContent.className = 'error-content';
|
||||||
|
const title = document.createElement('h3');
|
||||||
|
title.textContent = LanguageManager.t('messages.error.title', 'Hiba történt');
|
||||||
|
const desc = document.createElement('p');
|
||||||
|
desc.textContent = LanguageManager.t('messages.error.description', 'Az üzenetek betöltése sikertelen volt.');
|
||||||
|
const retryBtn = document.createElement('button');
|
||||||
|
retryBtn.className = 'retry-btn';
|
||||||
|
retryBtn.textContent = LanguageManager.t('messages.error.retry', 'Újrapróbálás');
|
||||||
retryBtn.addEventListener('click', onRetry);
|
retryBtn.addEventListener('click', onRetry);
|
||||||
|
|
||||||
|
errorContent.appendChild(title);
|
||||||
|
errorContent.appendChild(desc);
|
||||||
|
errorContent.appendChild(retryBtn);
|
||||||
|
errorDiv.appendChild(errorContent);
|
||||||
|
|
||||||
return errorDiv;
|
return errorDiv;
|
||||||
}
|
}
|
||||||
|
|
||||||
function createEmptyState() {
|
function createEmptyState() {
|
||||||
const emptyDiv = document.createElement('div');
|
const emptyDiv = document.createElement('div');
|
||||||
emptyDiv.className = 'empty-state';
|
emptyDiv.className = 'empty-state';
|
||||||
emptyDiv.innerHTML = `
|
|
||||||
<div class="empty-content">
|
const emptyContent = document.createElement('div');
|
||||||
<h3>${LanguageManager.t('messages.empty.title', 'Nincsenek üzenetek')}</h3>
|
emptyContent.className = 'empty-content';
|
||||||
<p>${LanguageManager.t('messages.empty.description', 'Jelenleg nincsenek elérhető üzenetek.')}</p>
|
const title = document.createElement('h3');
|
||||||
</div>
|
title.textContent = LanguageManager.t('messages.empty.title', 'Nincsenek üzenetek');
|
||||||
`;
|
const desc = document.createElement('p');
|
||||||
|
desc.textContent = LanguageManager.t('messages.empty.description', 'Jelenleg nincsenek elérhető üzenetek.');
|
||||||
|
|
||||||
|
emptyContent.appendChild(title);
|
||||||
|
emptyContent.appendChild(desc);
|
||||||
|
emptyDiv.appendChild(emptyContent);
|
||||||
|
|
||||||
return emptyDiv;
|
return emptyDiv;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -329,18 +452,42 @@
|
|||||||
const subject = message.uzenetTargy || 'Nincs tárgy';
|
const subject = message.uzenetTargy || 'Nincs tárgy';
|
||||||
const date = formatDate(message.uzenetKuldesDatum);
|
const date = formatDate(message.uzenetKuldesDatum);
|
||||||
const hasAttachment = message.hasCsatolmany;
|
const hasAttachment = message.hasCsatolmany;
|
||||||
|
|
||||||
|
const cardHeader = document.createElement('div');
|
||||||
|
cardHeader.className = 'message-card-header';
|
||||||
|
|
||||||
card.innerHTML = `
|
const senderInfo = document.createElement('div');
|
||||||
<div class="message-card-header">
|
senderInfo.className = 'sender-info';
|
||||||
<div class="sender-info">
|
const senderNameSpan = document.createElement('span');
|
||||||
<span class="sender-name">${sanitizeHTML(senderName)}</span>
|
senderNameSpan.className = 'sender-name';
|
||||||
${!message.isElolvasva ? '<span class="unread-indicator"></span>' : ''}
|
senderNameSpan.textContent = sanitizeHTML(senderName);
|
||||||
</div>
|
senderInfo.appendChild(senderNameSpan);
|
||||||
<div class="message-date">${date}</div>
|
|
||||||
</div>
|
if (!message.isElolvasva) {
|
||||||
<div class="message-subject">${sanitizeHTML(subject)}</div>
|
const unreadIndicator = document.createElement('span');
|
||||||
${hasAttachment ? '<div class="attachment-indicator">📎</div>' : ''}
|
unreadIndicator.className = 'unread-indicator';
|
||||||
`;
|
senderInfo.appendChild(unreadIndicator);
|
||||||
|
}
|
||||||
|
|
||||||
|
const messageDate = document.createElement('div');
|
||||||
|
messageDate.className = 'message-date';
|
||||||
|
messageDate.textContent = date;
|
||||||
|
|
||||||
|
cardHeader.appendChild(senderInfo);
|
||||||
|
cardHeader.appendChild(messageDate);
|
||||||
|
card.appendChild(cardHeader);
|
||||||
|
|
||||||
|
const messageSubject = document.createElement('div');
|
||||||
|
messageSubject.className = 'message-subject';
|
||||||
|
messageSubject.textContent = sanitizeHTML(subject);
|
||||||
|
card.appendChild(messageSubject);
|
||||||
|
|
||||||
|
if (hasAttachment) {
|
||||||
|
const attachmentIndicator = document.createElement('div');
|
||||||
|
attachmentIndicator.className = 'attachment-indicator';
|
||||||
|
attachmentIndicator.textContent = '📎';
|
||||||
|
card.appendChild(attachmentIndicator);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
return card;
|
return card;
|
||||||
@@ -394,41 +541,111 @@
|
|||||||
function renderBulkActions(container) {
|
function renderBulkActions(container) {
|
||||||
const bulk = document.createElement('div');
|
const bulk = document.createElement('div');
|
||||||
bulk.className = 'bulk-actions-card';
|
bulk.className = 'bulk-actions-card';
|
||||||
bulk.innerHTML = `
|
|
||||||
<div class="bulk-actions-left">
|
const bulkActionsLeft = document.createElement('div');
|
||||||
<div class="view-toggle">
|
bulkActionsLeft.className = 'bulk-actions-left';
|
||||||
<button id="viewInboxBtn" class="${currentView==='inbox'?'active':''}" title="Beérkezett">
|
|
||||||
<img src="${chrome.runtime.getURL('icons/messages-active.svg')}" alt="Beérkezett">
|
const viewToggle = document.createElement('div');
|
||||||
</button>
|
viewToggle.className = 'view-toggle';
|
||||||
<button id="viewTrashBtn" class="${currentView==='trash'?'active':''}" title="Törölt">
|
|
||||||
<img src="${chrome.runtime.getURL('icons/delete.svg')}" alt="Törölt">
|
const viewInboxBtn = document.createElement('button');
|
||||||
</button>
|
viewInboxBtn.id = 'viewInboxBtn';
|
||||||
</div>
|
viewInboxBtn.className = currentView === 'inbox' ? 'active' : '';
|
||||||
<button id="toggleSelectionModeBtn" class="bulk-btn" title="Kijelölés mód">
|
viewInboxBtn.title = 'Beérkezett';
|
||||||
<img src="${chrome.runtime.getURL('icons/select.svg')}" alt="Kijelölés mód">
|
const inboxImg = document.createElement('img');
|
||||||
</button>
|
inboxImg.src = chrome.runtime.getURL('icons/messages-active.svg');
|
||||||
<button id="selectAllBtn" class="bulk-btn" title="Mind kijelöl">
|
inboxImg.alt = 'Beérkezett';
|
||||||
<img src="${chrome.runtime.getURL('icons/select-all.svg')}" alt="Mind kijelöl">
|
viewInboxBtn.appendChild(inboxImg);
|
||||||
</button>
|
|
||||||
<button id="clearSelectionBtn" class="bulk-btn" title="Kijelölés törlése">
|
const viewTrashBtn = document.createElement('button');
|
||||||
<img src="${chrome.runtime.getURL('icons/select-none.svg')}" alt="Kijelölés törlése">
|
viewTrashBtn.id = 'viewTrashBtn';
|
||||||
</button>
|
viewTrashBtn.className = currentView === 'trash' ? 'active' : '';
|
||||||
</div>
|
viewTrashBtn.title = 'Törölt';
|
||||||
<div class="bulk-actions-right">
|
const trashImg = document.createElement('img');
|
||||||
<button id="markReadBtn" class="bulk-btn" title="Olvasott">
|
trashImg.src = chrome.runtime.getURL('icons/delete.svg');
|
||||||
<img src="${chrome.runtime.getURL('icons/eye-on.svg')}" alt="Olvasott">
|
trashImg.alt = 'Törölt';
|
||||||
</button>
|
viewTrashBtn.appendChild(trashImg);
|
||||||
<button id="markUnreadBtn" class="bulk-btn" title="Olvasatlan">
|
|
||||||
<img src="${chrome.runtime.getURL('icons/eye-off.svg')}" alt="Olvasatlan">
|
viewToggle.appendChild(viewInboxBtn);
|
||||||
</button>
|
viewToggle.appendChild(viewTrashBtn);
|
||||||
<button id="deleteBtn" class="bulk-btn" title="Törlés">
|
bulkActionsLeft.appendChild(viewToggle);
|
||||||
<img src="${chrome.runtime.getURL('icons/trash.svg')}" alt="Törlés">
|
|
||||||
</button>
|
const toggleSelBtn = document.createElement('button');
|
||||||
<button id="restoreBtn" class="bulk-btn" title="Visszaállítás">
|
toggleSelBtn.id = 'toggleSelectionModeBtn';
|
||||||
<img src="${chrome.runtime.getURL('icons/undo.svg')}" alt="Visszaállítás">
|
toggleSelBtn.className = 'bulk-btn';
|
||||||
</button>
|
toggleSelBtn.title = 'Kijelölés mód';
|
||||||
</div>
|
const selectImg = document.createElement('img');
|
||||||
`;
|
selectImg.src = chrome.runtime.getURL('icons/select.svg');
|
||||||
|
selectImg.alt = 'Kijelölés mód';
|
||||||
|
toggleSelBtn.appendChild(selectImg);
|
||||||
|
bulkActionsLeft.appendChild(toggleSelBtn);
|
||||||
|
|
||||||
|
const selectAllBtn = document.createElement('button');
|
||||||
|
selectAllBtn.id = 'selectAllBtn';
|
||||||
|
selectAllBtn.className = 'bulk-btn';
|
||||||
|
selectAllBtn.title = 'Mind kijelöl';
|
||||||
|
const selectAllImg = document.createElement('img');
|
||||||
|
selectAllImg.src = chrome.runtime.getURL('icons/select-all.svg');
|
||||||
|
selectAllImg.alt = 'Mind kijelöl';
|
||||||
|
selectAllBtn.appendChild(selectAllImg);
|
||||||
|
bulkActionsLeft.appendChild(selectAllBtn);
|
||||||
|
|
||||||
|
const clearSelBtn = document.createElement('button');
|
||||||
|
clearSelBtn.id = 'clearSelectionBtn';
|
||||||
|
clearSelBtn.className = 'bulk-btn';
|
||||||
|
clearSelBtn.title = 'Kijelölés törlése';
|
||||||
|
const clearSelImg = document.createElement('img');
|
||||||
|
clearSelImg.src = chrome.runtime.getURL('icons/select-none.svg');
|
||||||
|
clearSelImg.alt = 'Kijelölés törlése';
|
||||||
|
clearSelBtn.appendChild(clearSelImg);
|
||||||
|
bulkActionsLeft.appendChild(clearSelBtn);
|
||||||
|
|
||||||
|
bulk.appendChild(bulkActionsLeft);
|
||||||
|
|
||||||
|
const bulkActionsRight = document.createElement('div');
|
||||||
|
bulkActionsRight.className = 'bulk-actions-right';
|
||||||
|
|
||||||
|
const markReadBtn = document.createElement('button');
|
||||||
|
markReadBtn.id = 'markReadBtn';
|
||||||
|
markReadBtn.className = 'bulk-btn';
|
||||||
|
markReadBtn.title = 'Olvasott';
|
||||||
|
const markReadImg = document.createElement('img');
|
||||||
|
markReadImg.src = chrome.runtime.getURL('icons/eye-on.svg');
|
||||||
|
markReadImg.alt = 'Olvasott';
|
||||||
|
markReadBtn.appendChild(markReadImg);
|
||||||
|
bulkActionsRight.appendChild(markReadBtn);
|
||||||
|
|
||||||
|
const markUnreadBtn = document.createElement('button');
|
||||||
|
markUnreadBtn.id = 'markUnreadBtn';
|
||||||
|
markUnreadBtn.className = 'bulk-btn';
|
||||||
|
markUnreadBtn.title = 'Olvasatlan';
|
||||||
|
const markUnreadImg = document.createElement('img');
|
||||||
|
markUnreadImg.src = chrome.runtime.getURL('icons/eye-off.svg');
|
||||||
|
markUnreadImg.alt = 'Olvasatlan';
|
||||||
|
markUnreadBtn.appendChild(markUnreadImg);
|
||||||
|
bulkActionsRight.appendChild(markUnreadBtn);
|
||||||
|
|
||||||
|
const deleteBtn = document.createElement('button');
|
||||||
|
deleteBtn.id = 'deleteBtn';
|
||||||
|
deleteBtn.className = 'bulk-btn';
|
||||||
|
deleteBtn.title = 'Törlés';
|
||||||
|
const deleteImg = document.createElement('img');
|
||||||
|
deleteImg.src = chrome.runtime.getURL('icons/trash.svg');
|
||||||
|
deleteImg.alt = 'Törlés';
|
||||||
|
deleteBtn.appendChild(deleteImg);
|
||||||
|
bulkActionsRight.appendChild(deleteBtn);
|
||||||
|
|
||||||
|
const restoreBtn = document.createElement('button');
|
||||||
|
restoreBtn.id = 'restoreBtn';
|
||||||
|
restoreBtn.className = 'bulk-btn';
|
||||||
|
restoreBtn.title = 'Visszaállítás';
|
||||||
|
const restoreImg = document.createElement('img');
|
||||||
|
restoreImg.src = chrome.runtime.getURL('icons/undo.svg');
|
||||||
|
restoreImg.alt = 'Visszaállítás';
|
||||||
|
restoreBtn.appendChild(restoreImg);
|
||||||
|
bulkActionsRight.appendChild(restoreBtn);
|
||||||
|
|
||||||
|
bulk.appendChild(bulkActionsRight);
|
||||||
container.appendChild(bulk);
|
container.appendChild(bulk);
|
||||||
|
|
||||||
bulk.querySelector('#viewInboxBtn').addEventListener('click', () => switchView('inbox'));
|
bulk.querySelector('#viewInboxBtn').addEventListener('click', () => switchView('inbox'));
|
||||||
@@ -565,13 +782,13 @@ async function switchView(view) {
|
|||||||
async function transformMessagesPage() {
|
async function transformMessagesPage() {
|
||||||
try {
|
try {
|
||||||
await waitForTranslations();
|
await waitForTranslations();
|
||||||
document.body.innerHTML = '';
|
helper.clearElement(document.body);
|
||||||
const kretaContainer = document.createElement('div');
|
const kretaContainer = document.createElement('div');
|
||||||
kretaContainer.className = 'kreta-container';
|
kretaContainer.className = 'kreta-container';
|
||||||
const headerDiv = document.createElement('div');
|
const headerDiv = document.createElement('div');
|
||||||
const parser = new DOMParser();
|
const template = document.createElement('template');
|
||||||
const headerDoc = parser.parseFromString(await createTemplate.header(), 'text/html');
|
template.innerHTML = await createTemplate.header();
|
||||||
const headerContent = headerDoc.body;
|
const headerContent = template.content;
|
||||||
while (headerContent.firstChild) {
|
while (headerContent.firstChild) {
|
||||||
headerDiv.appendChild(headerContent.firstChild);
|
headerDiv.appendChild(headerContent.firstChild);
|
||||||
}
|
}
|
||||||
@@ -594,9 +811,6 @@ async function switchView(view) {
|
|||||||
if (typeof setupUserDropdown === 'function') {
|
if (typeof setupUserDropdown === 'function') {
|
||||||
setupUserDropdown();
|
setupUserDropdown();
|
||||||
}
|
}
|
||||||
if (typeof setupMobileNavigation === 'function') {
|
|
||||||
setupMobileNavigation();
|
|
||||||
}
|
|
||||||
|
|
||||||
await loadMessages(messagesContainer);
|
await loadMessages(messagesContainer);
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,5 @@
|
|||||||
@import url('../global/theme.css');
|
@import url('../global/theme.css');
|
||||||
|
|
||||||
|
|
||||||
.main-header,
|
.main-header,
|
||||||
.main-menu,
|
.main-menu,
|
||||||
.main-sidebar,
|
.main-sidebar,
|
||||||
@@ -11,11 +10,17 @@
|
|||||||
.navbar,
|
.navbar,
|
||||||
.sidebar-container,
|
.sidebar-container,
|
||||||
#sidepanel_tabs,
|
#sidepanel_tabs,
|
||||||
.sidepanel-wrapper {
|
.sidepanel-wrapper,
|
||||||
|
.main-footer2,
|
||||||
|
.lakatimg,
|
||||||
|
.modalContainer,
|
||||||
|
.modalOuter,
|
||||||
|
#ProfilTab,
|
||||||
|
#KretaProgressBar {
|
||||||
display: none !important;
|
display: none !important;
|
||||||
|
visibility: hidden !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
@@ -26,6 +31,11 @@ body {
|
|||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
h2 {
|
||||||
|
background-color: var(--card-card) !important;
|
||||||
|
border-bottom: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
.page-wrapper {
|
.page-wrapper {
|
||||||
background-color: var(--background) !important;
|
background-color: var(--background) !important;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
@@ -50,271 +60,295 @@ body {
|
|||||||
padding: 0;
|
padding: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.content-container {
|
.profile-container {
|
||||||
max-width: 1200px;
|
max-width: 1400px;
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
padding: clamp(1rem, 3vw, 2rem);
|
padding: 2rem;
|
||||||
background-color: var(--background) !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.profile-wrapper {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 280px 1fr;
|
||||||
|
gap: 2rem;
|
||||||
|
min-height: calc(100vh - 200px);
|
||||||
|
}
|
||||||
|
|
||||||
.firka-header {
|
.profile-sidebar {
|
||||||
padding: clamp(1rem, 3vw, 2rem);
|
position: sticky;
|
||||||
|
top: 2rem;
|
||||||
|
height: fit-content;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tabs {
|
||||||
|
background: var(--card-card);
|
||||||
|
border-radius: 16px;
|
||||||
|
padding: 1rem;
|
||||||
|
box-shadow: 0px 1px 2px 0px var(--accent-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab {
|
||||||
|
width: 100%;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 1rem;
|
gap: 0.75rem;
|
||||||
background-color: var(--background);
|
padding: 1rem;
|
||||||
|
border: none;
|
||||||
|
background: transparent;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
font-family: 'Montserrat', sans-serif;
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 500;
|
||||||
|
cursor: pointer;
|
||||||
|
border-radius: 12px;
|
||||||
|
transition: all 0.2s ease;
|
||||||
|
text-align: left;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab:hover {
|
||||||
|
background: var(--button-secondaryFill);
|
||||||
|
color: var(--text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab.active {
|
||||||
|
background: var(--accent-accent);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab svg {
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-content {
|
||||||
|
background: var(--card-card);
|
||||||
|
border-radius: 16px;
|
||||||
|
padding: 2rem;
|
||||||
|
box-shadow: 0px 1px 2px 0px var(--accent-shadow);
|
||||||
|
min-height: 500px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-content {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-content.active {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-header {
|
||||||
|
margin-bottom: 2rem;
|
||||||
|
padding-bottom: 1rem;
|
||||||
|
border-bottom: 2px solid var(--accent-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-header h2 {
|
||||||
|
margin: 0;
|
||||||
|
color: var(--text-primary);
|
||||||
|
font-size: 28px;
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-section {
|
||||||
|
margin-bottom: 2.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-section:last-child {
|
||||||
|
margin-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-section h3 {
|
||||||
|
color: var(--text-primary);
|
||||||
|
font-size: 20px;
|
||||||
|
font-weight: 600;
|
||||||
|
margin: 0 0 1.5rem 0;
|
||||||
|
padding-bottom: 0.75rem;
|
||||||
border-bottom: 1px solid var(--accent-15);
|
border-bottom: 1px solid var(--accent-15);
|
||||||
}
|
}
|
||||||
|
|
||||||
.back-button {
|
.data-grid {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
|
||||||
|
gap: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-item {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-item label {
|
||||||
|
color: var(--text-secondary);
|
||||||
|
font-size: 13px;
|
||||||
|
font-weight: 500;
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-item span {
|
||||||
|
color: var(--text-primary);
|
||||||
|
font-size: 15px;
|
||||||
|
font-weight: 500;
|
||||||
|
padding: 0.75rem;
|
||||||
|
background: var(--button-secondaryFill);
|
||||||
|
border-radius: 8px;
|
||||||
|
word-break: break-word;
|
||||||
|
}
|
||||||
|
|
||||||
|
.address-list {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.address-item {
|
||||||
|
padding: 1.25rem;
|
||||||
|
background: var(--button-secondaryFill);
|
||||||
|
border-radius: 12px;
|
||||||
|
border-left: 4px solid var(--accent-15);
|
||||||
|
transition: all 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.address-item:hover {
|
||||||
|
transform: translateX(4px);
|
||||||
|
box-shadow: 0px 2px 8px 0px var(--accent-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.address-item.default {
|
||||||
|
border-left-color: var(--accent-accent);
|
||||||
|
background: var(--accent-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.address-type {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 0.5rem;
|
gap: 0.75rem;
|
||||||
background: var(--card-card);
|
margin-bottom: 0.5rem;
|
||||||
border: none;
|
}
|
||||||
border-radius: 12px;
|
|
||||||
padding: 12px 16px;
|
.address-type strong {
|
||||||
color: var(--text-primary);
|
color: var(--text-primary);
|
||||||
font-family: 'Montserrat', sans-serif;
|
font-size: 15px;
|
||||||
font-weight: 500;
|
|
||||||
font-size: 14px;
|
|
||||||
cursor: pointer;
|
|
||||||
transition: all 0.2s ease;
|
|
||||||
text-decoration: none;
|
|
||||||
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
|
||||||
}
|
|
||||||
|
|
||||||
.back-button:hover {
|
|
||||||
background: var(--button-secondaryFill);
|
|
||||||
transform: translateY(-1px);
|
|
||||||
box-shadow: 0px 2px var(--shadow-blur, 4px) 0px var(--accent-shadow);
|
|
||||||
}
|
|
||||||
|
|
||||||
.back-button svg {
|
|
||||||
width: 16px;
|
|
||||||
height: 16px;
|
|
||||||
fill: var(--text-primary);
|
|
||||||
}
|
|
||||||
|
|
||||||
.page-title {
|
|
||||||
color: var(--text-primary);
|
|
||||||
font-size: 24px;
|
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
|
||||||
|
.badge {
|
||||||
|
display: inline-block;
|
||||||
|
padding: 0.25rem 0.75rem;
|
||||||
|
background: var(--accent-accent);
|
||||||
|
color: white;
|
||||||
|
font-size: 11px;
|
||||||
|
font-weight: 600;
|
||||||
|
border-radius: 12px;
|
||||||
|
text-transform: uppercase;
|
||||||
|
letter-spacing: 0.5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.address-details {
|
||||||
|
color: var(--text-secondary);
|
||||||
|
font-size: 14px;
|
||||||
|
line-height: 1.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.loading-spinner {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
padding: 4rem 2rem;
|
||||||
|
gap: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.spinner {
|
||||||
|
width: 48px;
|
||||||
|
height: 48px;
|
||||||
|
border: 4px solid var(--accent-15);
|
||||||
|
border-top-color: var(--accent-accent);
|
||||||
|
border-radius: 50%;
|
||||||
|
animation: spin 1s linear infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes spin {
|
||||||
|
to {
|
||||||
|
transform: rotate(360deg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.loading-spinner p {
|
||||||
|
color: var(--text-secondary);
|
||||||
|
font-size: 16px;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.info-message {
|
||||||
.k-content {
|
display: flex;
|
||||||
background-color: var(--background) !important;
|
flex-direction: column;
|
||||||
}
|
align-items: center;
|
||||||
|
gap: 1.5rem;
|
||||||
.k-content h4 {
|
padding: 3rem 2rem;
|
||||||
color: var(--text-primary) !important;
|
|
||||||
font-family: 'Montserrat', sans-serif !important;
|
|
||||||
font-size: 28px !important;
|
|
||||||
font-weight: 600 !important;
|
|
||||||
margin: 0 0 2rem 0 !important;
|
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.info-message svg {
|
||||||
.k-tabstrip-wrapper {
|
|
||||||
background: var(--card-card) !important;
|
|
||||||
border-radius: 24px !important;
|
|
||||||
overflow: hidden;
|
|
||||||
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
|
||||||
border: none !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-tabstrip {
|
|
||||||
background: var(--card-card) !important;
|
|
||||||
border: none !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-tabstrip-items {
|
|
||||||
background: var(--card-card) !important;
|
|
||||||
border: none !important;
|
|
||||||
border-radius: 24px 24px 0 0 !important;
|
|
||||||
padding: 0 20px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-tabstrip-items .k-item {
|
|
||||||
background: transparent !important;
|
|
||||||
border: none !important;
|
|
||||||
margin: 0 !important;
|
|
||||||
border-radius: 0 !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-tabstrip-items .k-item .k-link {
|
|
||||||
color: var(--text-secondary) !important;
|
|
||||||
font-family: 'Montserrat', sans-serif !important;
|
|
||||||
font-weight: 500 !important;
|
|
||||||
font-size: 14px !important;
|
|
||||||
padding: 16px 20px !important;
|
|
||||||
border: none !important;
|
|
||||||
background: transparent !important;
|
|
||||||
border-radius: 0 !important;
|
|
||||||
transition: all 0.2s ease !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-tabstrip-items .k-item.k-state-active .k-link {
|
|
||||||
color: var(--accent-accent) !important;
|
|
||||||
font-weight: 600 !important;
|
|
||||||
border-bottom: 2px solid var(--accent-accent) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-tabstrip-items .k-item:hover .k-link {
|
|
||||||
color: var(--text-primary) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
.k-tabstrip .k-content {
|
|
||||||
background: var(--card-card) !important;
|
|
||||||
border: none !important;
|
|
||||||
padding: 20px !important;
|
|
||||||
border-radius: 0 0 24px 24px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
form {
|
|
||||||
background: transparent !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.container-fluid.details {
|
|
||||||
background: transparent !important;
|
|
||||||
margin-bottom: 2rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.row {
|
|
||||||
margin-bottom: 1rem;
|
|
||||||
align-items: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.windowInputLabel {
|
|
||||||
color: var(--text-primary) !important;
|
|
||||||
font-family: 'Montserrat', sans-serif !important;
|
|
||||||
font-weight: 500 !important;
|
|
||||||
font-size: 14px !important;
|
|
||||||
margin: 0 !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
input[type="text"],
|
|
||||||
input[type="password"],
|
|
||||||
input[type="email"],
|
|
||||||
select,
|
|
||||||
textarea {
|
|
||||||
background: var(--button-secondaryFill) !important;
|
|
||||||
border: 1px solid var(--accent-15) !important;
|
|
||||||
border-radius: 12px !important;
|
|
||||||
padding: 12px 16px !important;
|
|
||||||
color: var(--text-primary) !important;
|
|
||||||
font-family: 'Montserrat', sans-serif !important;
|
|
||||||
font-size: 14px !important;
|
|
||||||
transition: all 0.2s ease !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
input[type="text"]:focus,
|
|
||||||
input[type="password"]:focus,
|
|
||||||
input[type="email"]:focus,
|
|
||||||
select:focus,
|
|
||||||
textarea:focus {
|
|
||||||
outline: none !important;
|
|
||||||
border-color: var(--accent-accent) !important;
|
|
||||||
box-shadow: 0 0 0 3px var(--accent-15) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-checkbox {
|
|
||||||
appearance: none;
|
|
||||||
width: 20px !important;
|
|
||||||
height: 20px !important;
|
|
||||||
border: 2px solid var(--accent-15) !important;
|
|
||||||
border-radius: 4px !important;
|
|
||||||
background: var(--button-secondaryFill) !important;
|
|
||||||
cursor: pointer !important;
|
|
||||||
position: relative !important;
|
|
||||||
transition: all 0.2s ease !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-checkbox:checked {
|
|
||||||
background: var(--accent-accent) !important;
|
|
||||||
border-color: var(--accent-accent) !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-checkbox:checked::after {
|
|
||||||
content: '✓';
|
|
||||||
position: absolute;
|
|
||||||
top: 50%;
|
|
||||||
left: 50%;
|
|
||||||
transform: translate(-50%, -50%);
|
|
||||||
color: white;
|
color: white;
|
||||||
font-size: 12px;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.k-checkbox-label {
|
.info-message p {
|
||||||
margin-left: 8px !important;
|
color: var(--text-secondary);
|
||||||
color: var(--text-primary) !important;
|
font-size: 16px;
|
||||||
font-family: 'Montserrat', sans-serif !important;
|
line-height: 1.6;
|
||||||
cursor: pointer !important;
|
margin: 0;
|
||||||
|
max-width: 600px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.k-button,
|
.error-message {
|
||||||
button {
|
display: flex;
|
||||||
background: var(--accent-accent) !important;
|
flex-direction: column;
|
||||||
border: none !important;
|
align-items: center;
|
||||||
border-radius: 12px !important;
|
gap: 1.5rem;
|
||||||
padding: 12px 24px !important;
|
padding: 4rem 2rem;
|
||||||
color: white !important;
|
text-align: center;
|
||||||
font-family: 'Montserrat', sans-serif !important;
|
|
||||||
font-weight: 600 !important;
|
|
||||||
font-size: 14px !important;
|
|
||||||
cursor: pointer !important;
|
|
||||||
transition: all 0.2s ease !important;
|
|
||||||
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow) !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.k-button:hover,
|
.error-message svg {
|
||||||
button:hover {
|
color: #e74c3c;
|
||||||
background: var(--accent-secondary) !important;
|
|
||||||
transform: translateY(-1px) !important;
|
|
||||||
box-shadow: 0px 2px var(--shadow-blur, 4px) 0px var(--accent-shadow) !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.k-button:active,
|
.error-message p {
|
||||||
button:active {
|
color: var(--text-secondary);
|
||||||
transform: translateY(0) !important;
|
font-size: 16px;
|
||||||
|
margin: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.security-btn {
|
||||||
@media (max-width: 768px) {
|
display: inline-flex;
|
||||||
.content-container {
|
align-items: center;
|
||||||
padding: 1rem;
|
gap: 0.75rem;
|
||||||
}
|
padding: 1rem 2rem;
|
||||||
|
background: var(--accent-accent);
|
||||||
.firka-header {
|
color: white;
|
||||||
padding: 1rem;
|
border: none;
|
||||||
}
|
border-radius: 12px;
|
||||||
|
font-family: 'Montserrat', sans-serif;
|
||||||
.page-title {
|
font-size: 15px;
|
||||||
font-size: 20px;
|
font-weight: 600;
|
||||||
}
|
cursor: pointer;
|
||||||
|
transition: all 0.2s ease;
|
||||||
.k-content h4 {
|
box-shadow: 0px 2px 4px 0px var(--accent-shadow);
|
||||||
font-size: 24px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-tabstrip-items {
|
|
||||||
padding: 0 10px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.k-tabstrip-items .k-item .k-link {
|
|
||||||
padding: 12px 16px !important;
|
|
||||||
font-size: 13px !important;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.security-btn:hover {
|
||||||
|
background: var(--accent-secondary);
|
||||||
|
transform: translateY(-2px);
|
||||||
|
box-shadow: 0px 4px 8px 0px var(--accent-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.security-btn:active {
|
||||||
|
transform: translateY(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
.security-btn svg {
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
@keyframes fadeIn {
|
@keyframes fadeIn {
|
||||||
from {
|
from {
|
||||||
@@ -327,159 +361,267 @@ button:active {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.k-tabstrip-wrapper {
|
.profile-wrapper {
|
||||||
|
animation: fadeIn 0.4s ease forwards;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-section {
|
||||||
animation: fadeIn 0.5s ease forwards;
|
animation: fadeIn 0.5s ease forwards;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.data-section:nth-child(2) {
|
||||||
.k-widget,
|
animation-delay: 0.1s;
|
||||||
.k-header {
|
|
||||||
background: var(--card-card) !important;
|
|
||||||
color: var(--text-primary) !important;
|
|
||||||
border: none !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.k-state-default {
|
.data-section:nth-child(3) {
|
||||||
background: transparent !important;
|
animation-delay: 0.2s;
|
||||||
border: none !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.k-state-active {
|
.data-section:nth-child(4) {
|
||||||
background: transparent !important;
|
animation-delay: 0.3s;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media (max-width: 1024px) {
|
||||||
|
.profile-wrapper {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
gap: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
.k-overlay,
|
.profile-sidebar {
|
||||||
.k-window,
|
position: static;
|
||||||
.k-notification {
|
}
|
||||||
display: none !important;
|
|
||||||
|
.profile-tabs {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(3, 1fr);
|
||||||
|
gap: 0.5rem;
|
||||||
|
padding: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab {
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
text-align: center;
|
||||||
|
gap: 0.5rem;
|
||||||
|
padding: 1rem 0.5rem;
|
||||||
|
font-size: 13px;
|
||||||
|
min-height: 75px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab svg {
|
||||||
|
width: 22px;
|
||||||
|
height: 22px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab span {
|
||||||
|
line-height: 1.2;
|
||||||
|
word-break: break-word;
|
||||||
|
hyphens: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-grid {
|
||||||
|
grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media (max-width: 768px) {
|
||||||
|
.profile-container {
|
||||||
|
padding: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
.main-content .content-content {
|
.profile-wrapper {
|
||||||
display: block !important;
|
gap: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-content {
|
||||||
|
padding: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-grid {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
gap: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-header h2 {
|
||||||
|
font-size: 22px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-section h3 {
|
||||||
|
font-size: 17px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tabs {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(3, 1fr);
|
||||||
|
gap: 0.375rem;
|
||||||
|
padding: 0.375rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab {
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
text-align: center;
|
||||||
|
gap: 0.375rem;
|
||||||
|
padding: 0.625rem 0.25rem;
|
||||||
|
font-size: 11px;
|
||||||
|
min-height: 55px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab svg {
|
||||||
|
width: 18px;
|
||||||
|
height: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab span {
|
||||||
|
line-height: 1.1;
|
||||||
|
word-break: break-word;
|
||||||
|
hyphens: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.address-item {
|
||||||
|
padding: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.security-btn {
|
||||||
|
width: 100%;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.info-message,
|
||||||
|
.error-message,
|
||||||
|
.loading-spinner {
|
||||||
|
padding: 2rem 1rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media (max-width: 480px) {
|
||||||
|
.profile-container {
|
||||||
|
padding: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
div[style*="display:flex;justify-content:space-between"] {
|
.profile-wrapper {
|
||||||
display: flex !important;
|
gap: 0.5rem;
|
||||||
justify-content: space-between !important;
|
}
|
||||||
align-items: center !important;
|
|
||||||
margin-top: 2rem !important;
|
.profile-content {
|
||||||
padding-top: 2rem !important;
|
padding: 0.875rem;
|
||||||
border-top: 1px solid var(--accent-15) !important;
|
border-radius: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-header {
|
||||||
|
margin-bottom: 1.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-header h2 {
|
||||||
|
font-size: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-section h3 {
|
||||||
|
font-size: 15px;
|
||||||
|
margin-bottom: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-item label {
|
||||||
|
font-size: 11px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-item span {
|
||||||
|
font-size: 13px;
|
||||||
|
padding: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tabs {
|
||||||
|
padding: 0.25rem;
|
||||||
|
gap: 0.25rem;
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab {
|
||||||
|
padding: 0.5rem 0.25rem;
|
||||||
|
min-height: 50px;
|
||||||
|
font-size: 10px;
|
||||||
|
border-radius: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab svg {
|
||||||
|
width: 16px;
|
||||||
|
height: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-tab span {
|
||||||
|
font-size: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-section {
|
||||||
|
margin-bottom: 1.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.address-item {
|
||||||
|
padding: 0.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.badge {
|
||||||
|
font-size: 9px;
|
||||||
|
padding: 0.2rem 0.5rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media (prefers-color-scheme: dark) {
|
||||||
div[style*="display:flex;justify-content:space-between"] label {
|
.error-message svg {
|
||||||
color: var(--text-secondary) !important;
|
color: #ff6b6b;
|
||||||
font-size: 12px !important;
|
}
|
||||||
font-style: italic !important;
|
|
||||||
margin: 0 !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.hidden-contact-info {
|
@media print {
|
||||||
display: none !important;
|
.profile-sidebar,
|
||||||
visibility: hidden !important;
|
.security-btn,
|
||||||
|
.kreta-header,
|
||||||
|
.mobile-header,
|
||||||
|
.mobile-bottom-nav {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-wrapper {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
}
|
||||||
|
|
||||||
|
.profile-content {
|
||||||
|
box-shadow: none;
|
||||||
|
border: 1px solid #ddd;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tab-content {
|
||||||
|
display: block !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-section {
|
||||||
|
page-break-inside: avoid;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.hidden-tab {
|
.profile-tab:focus,
|
||||||
display: none !important;
|
.security-btn:focus {
|
||||||
|
outline: 2px solid var(--accent-accent);
|
||||||
|
outline-offset: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ProfilTab-3 {
|
.profile-tab:focus:not(:focus-visible),
|
||||||
padding: 20px;
|
.security-btn:focus:not(:focus-visible) {
|
||||||
background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
|
outline: none;
|
||||||
min-height: 500px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#ProfilTab-3 .container-fluid {
|
html {
|
||||||
background: white;
|
scroll-behavior: smooth;
|
||||||
border-radius: 12px;
|
|
||||||
padding: 30px;
|
|
||||||
margin-top: 20px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#ProfilTab-3 h4 {
|
::selection {
|
||||||
color: #2c3e50;
|
background: var(--accent-accent);
|
||||||
font-weight: 600;
|
|
||||||
margin-bottom: 25px;
|
|
||||||
padding-bottom: 10px;
|
|
||||||
border-bottom: 3px solid #3498db;
|
|
||||||
display: inline-block;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .row {
|
|
||||||
margin-bottom: 20px;
|
|
||||||
padding: 15px;
|
|
||||||
background: #f8f9fa;
|
|
||||||
border-radius: 8px;
|
|
||||||
border-left: 4px solid #3498db;
|
|
||||||
transition: all 0.3s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .row:hover {
|
|
||||||
background: #e3f2fd;
|
|
||||||
transform: translateX(5px);
|
|
||||||
box-shadow: 0 2px 10px rgba(52, 152, 219, 0.2);
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .windowInputLabel {
|
|
||||||
color: #34495e;
|
|
||||||
font-weight: 500;
|
|
||||||
font-size: 14px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .k-button {
|
|
||||||
background: linear-gradient(135deg, #3498db, #2980b9);
|
|
||||||
border: none;
|
|
||||||
border-radius: 6px;
|
|
||||||
padding: 10px 20px;
|
|
||||||
color: white;
|
color: white;
|
||||||
font-weight: 500;
|
|
||||||
transition: all 0.3s ease;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#ProfilTab-3 .k-button:hover {
|
::-moz-selection {
|
||||||
background: linear-gradient(135deg, #2980b9, #1f5f8b);
|
background: var(--accent-accent);
|
||||||
transform: translateY(-2px);
|
color: white;
|
||||||
box-shadow: 0 4px 15px rgba(52, 152, 219, 0.4);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#ProfilTab-3 .k-input {
|
|
||||||
border: 2px solid #e0e6ed;
|
|
||||||
border-radius: 6px;
|
|
||||||
padding: 10px;
|
|
||||||
transition: border-color 0.3s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .k-input:focus {
|
|
||||||
border-color: #3498db;
|
|
||||||
box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .alert {
|
|
||||||
border-radius: 8px;
|
|
||||||
border: none;
|
|
||||||
padding: 15px;
|
|
||||||
margin: 15px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .alert-info {
|
|
||||||
background: linear-gradient(135deg, #e3f2fd, #bbdefb);
|
|
||||||
color: #1565c0;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .alert-success {
|
|
||||||
background: linear-gradient(135deg, #e8f5e8, #c8e6c9);
|
|
||||||
color: #2e7d32;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ProfilTab-3 .alert-warning {
|
|
||||||
background: linear-gradient(135deg, #fff3e0, #ffcc02);
|
|
||||||
color: #ef6c00;
|
|
||||||
}
|
|
||||||
|
|
||||||
.details .row {
|
|
||||||
border-bottom: none !important;
|
|
||||||
}
|
|
||||||
@@ -1,228 +1,497 @@
|
|||||||
(function() {
|
(function() {
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
function hideLoadingScreen() {
|
|
||||||
const loadingElement = document.getElementById('KretaProgressBar');
|
|
||||||
if (loadingElement) {
|
|
||||||
loadingElement.style.display = 'none !important';
|
|
||||||
loadingElement.style.visibility = 'hidden';
|
|
||||||
loadingElement.style.opacity = '0';
|
|
||||||
loadingElement.remove();
|
|
||||||
|
|
||||||
}
|
const TABS = {
|
||||||
|
MY_DATA: 'my-data',
|
||||||
|
PASSWORD: 'password',
|
||||||
|
SECURITY: 'security'
|
||||||
|
};
|
||||||
|
|
||||||
const loadingElements = document.querySelectorAll('[class*="loading"], [id*="loading"], [class*="Loading"], [id*="Loading"]');
|
let currentTab = TABS.MY_DATA;
|
||||||
loadingElements.forEach(el => {
|
let profileData = null;
|
||||||
el.style.display = 'none !important';
|
let addressData = null;
|
||||||
el.style.visibility = 'hidden';
|
|
||||||
el.style.opacity = '0';
|
function getApiUrls(subdomain) {
|
||||||
});
|
return {
|
||||||
|
PROFILE_DATA: `https://${subdomain}.e-kreta.hu/Adminisztracio/Profil/SajatAdatlapPopUp`,
|
||||||
|
ADDRESS_DATA: `https://${subdomain}.e-kreta.hu/api/ProfilApi/GetElerhetosegCimGrid?sort=&page=1&pageSize=100&group=&filter=&data=%7B%7D&_=`
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function addBackButton() {
|
function hideOriginalElements() {
|
||||||
|
const elementsToHide = [
|
||||||
|
'#KretaProgressBar',
|
||||||
|
'.main-header',
|
||||||
|
'.main-menu',
|
||||||
|
'.main-sidebar',
|
||||||
|
'.content-header',
|
||||||
|
'.favoriteIconContainer',
|
||||||
|
'#frissitesDatumDiv',
|
||||||
|
'#layout_navigationBar',
|
||||||
|
'.navbar',
|
||||||
|
'.sidebar-container',
|
||||||
|
'#sidepanel_tabs',
|
||||||
|
'.sidepanel-wrapper',
|
||||||
|
'.main-footer2',
|
||||||
|
'.lakatimg',
|
||||||
|
'.modalContainer',
|
||||||
|
'.modalOuter',
|
||||||
|
'#ProfilTab'
|
||||||
|
];
|
||||||
|
|
||||||
if (document.getElementById('firka-back-button')) {
|
elementsToHide.forEach(selector => {
|
||||||
return;
|
const elements = document.querySelectorAll(selector);
|
||||||
}
|
elements.forEach(el => {
|
||||||
|
el.style.display = 'none';
|
||||||
|
el.style.visibility = 'hidden';
|
||||||
const backButton = document.createElement('button');
|
});
|
||||||
backButton.id = 'firka-back-button';
|
|
||||||
backButton.innerHTML = '← Vissza';
|
|
||||||
backButton.style.cssText = `
|
|
||||||
position: static;
|
|
||||||
margin: 20px;
|
|
||||||
z-index: 100;
|
|
||||||
background-color: var(--card-background, #ffffff);
|
|
||||||
color: var(--text-primary, #333333);
|
|
||||||
border: 1px solid var(--border-color, #e0e0e0);
|
|
||||||
border-radius: 8px;
|
|
||||||
padding: 10px 16px;
|
|
||||||
font-family: 'Montserrat', sans-serif;
|
|
||||||
font-size: 14px;
|
|
||||||
font-weight: 500;
|
|
||||||
cursor: pointer;
|
|
||||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
|
|
||||||
transition: all 0.2s ease;
|
|
||||||
display: inline-flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 8px;
|
|
||||||
width: auto;
|
|
||||||
`;
|
|
||||||
|
|
||||||
|
|
||||||
backButton.addEventListener('mouseenter', function() {
|
|
||||||
this.style.backgroundColor = 'var(--card-hover, #f5f5f5)';
|
|
||||||
this.style.transform = 'translateY(-1px)';
|
|
||||||
this.style.boxShadow = '0 4px 12px rgba(0, 0, 0, 0.15)';
|
|
||||||
});
|
});
|
||||||
|
|
||||||
backButton.addEventListener('mouseleave', function() {
|
document.body.innerHTML = '';
|
||||||
this.style.backgroundColor = 'var(--card-background, #ffffff)';
|
}
|
||||||
this.style.transform = 'translateY(0)';
|
|
||||||
this.style.boxShadow = '0 2px 8px rgba(0, 0, 0, 0.1)';
|
async function createNavbar() {
|
||||||
|
const header = await createTemplate.header();
|
||||||
|
const headerContainer = document.createElement('div');
|
||||||
|
headerContainer.innerHTML = header;
|
||||||
|
document.body.appendChild(headerContainer);
|
||||||
|
|
||||||
|
setupUserDropdown();
|
||||||
|
setupSettingsButton();
|
||||||
|
}
|
||||||
|
|
||||||
|
function setupUserDropdown() {
|
||||||
|
const userBtn = document.querySelector('.user-dropdown-btn');
|
||||||
|
const userDropdown = document.querySelector('.user-dropdown');
|
||||||
|
|
||||||
|
userBtn?.addEventListener('click', (e) => {
|
||||||
|
e.stopPropagation();
|
||||||
|
userDropdown?.classList.toggle('show');
|
||||||
|
userBtn?.classList.toggle('open');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
backButton.addEventListener('click', function() {
|
const mobileUserBtn = document.querySelector('#mobileUserBtn');
|
||||||
window.history.back();
|
const mobileUserDropdown = document.querySelector('#mobileUserDropdown');
|
||||||
|
|
||||||
|
mobileUserBtn?.addEventListener('click', (e) => {
|
||||||
|
e.stopPropagation();
|
||||||
|
mobileUserDropdown?.classList.toggle('show');
|
||||||
|
mobileUserBtn?.classList.toggle('active');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
document.body.insertBefore(backButton, document.body.firstChild);
|
document.addEventListener('click', (e) => {
|
||||||
|
if (!userBtn?.contains(e.target) && !userDropdown?.contains(e.target)) {
|
||||||
|
userDropdown?.classList.remove('show');
|
||||||
|
userBtn?.classList.remove('open');
|
||||||
|
}
|
||||||
|
|
||||||
}
|
if (!mobileUserBtn?.contains(e.target) && !mobileUserDropdown?.contains(e.target)) {
|
||||||
|
mobileUserDropdown?.classList.remove('show');
|
||||||
|
mobileUserBtn?.classList.remove('active');
|
||||||
function hideMainFooter2() {
|
|
||||||
const footer2 = document.querySelector('.main-footer2');
|
|
||||||
if (footer2) {
|
|
||||||
footer2.style.display = 'none';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
function hideLakatImg() {
|
|
||||||
const lakatImg = document.querySelector('.lakatimg');
|
|
||||||
if (lakatImg) {
|
|
||||||
lakatImg.style.display = 'none';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
function hideCustomUserSettingsTab() {
|
|
||||||
|
|
||||||
const firstTab = document.querySelector('#ProfilTab .k-tabstrip-items li[aria-controls="ProfilTab-1"]');
|
|
||||||
if (firstTab) {
|
|
||||||
firstTab.classList.add('hidden-tab');
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
const tabLinks = document.querySelectorAll('#ProfilTab .k-tabstrip-items .k-link');
|
|
||||||
tabLinks.forEach(link => {
|
|
||||||
if (link.textContent && link.textContent.includes('Egyedi felhasználó beállítások')) {
|
|
||||||
const parentTab = link.closest('li');
|
|
||||||
if (parentTab) {
|
|
||||||
parentTab.classList.add('hidden-tab');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
const contentPanel = document.querySelector('#ProfilTab-1');
|
const mobileDropdownItems = document.querySelectorAll('.mobile-dropdown-item');
|
||||||
if (contentPanel) {
|
mobileDropdownItems.forEach(item => {
|
||||||
contentPanel.classList.add('hidden-tab');
|
item.addEventListener('click', () => {
|
||||||
|
mobileUserDropdown?.classList.remove('show');
|
||||||
|
mobileUserBtn?.classList.remove('active');
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function setupSettingsButton() {
|
||||||
|
document.getElementById('settingsBtn')?.addEventListener('click', (e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
e.stopPropagation();
|
||||||
|
const url = chrome.runtime.getURL('settings/index.html');
|
||||||
|
window.open(url, '_blank', 'width=400,height=600');
|
||||||
|
});
|
||||||
|
|
||||||
|
document.getElementById('mobileSettingsBtn')?.addEventListener('click', (e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
e.stopPropagation();
|
||||||
|
const url = chrome.runtime.getURL('settings/index.html');
|
||||||
|
window.open(url, '_blank', 'width=400,height=600');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function createProfilePage() {
|
||||||
|
const t = window.LanguageManager?.t || ((key) => key);
|
||||||
|
|
||||||
|
const container = document.createElement('div');
|
||||||
|
container.className = 'profile-container';
|
||||||
|
container.innerHTML = `
|
||||||
|
<div class="profile-wrapper">
|
||||||
|
<div class="profile-sidebar">
|
||||||
|
<div class="profile-tabs">
|
||||||
|
<button class="profile-tab active" data-tab="${TABS.MY_DATA}">
|
||||||
|
<svg viewBox="0 0 24 24" width="20" height="20">
|
||||||
|
<path fill="currentColor" d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/>
|
||||||
|
</svg>
|
||||||
|
<span>${t('profile.tab_my_data')}</span>
|
||||||
|
</button>
|
||||||
|
<button class="profile-tab" data-tab="${TABS.PASSWORD}">
|
||||||
|
<svg viewBox="0 0 24 24" width="20" height="20">
|
||||||
|
<path fill="currentColor" d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z"/>
|
||||||
|
</svg>
|
||||||
|
<span>${t('profile.tab_password')}</span>
|
||||||
|
</button>
|
||||||
|
<button class="profile-tab" data-tab="${TABS.SECURITY}">
|
||||||
|
<svg viewBox="0 0 24 24" width="20" height="20">
|
||||||
|
<path fill="currentColor" d="M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm0 10.99h7c-.53 4.12-3.28 7.79-7 8.94V12H5V6.3l7-3.11v8.8z"/>
|
||||||
|
</svg>
|
||||||
|
<span>${t('profile.tab_security')}</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="profile-content">
|
||||||
|
<div id="tab-${TABS.MY_DATA}" class="tab-content active">
|
||||||
|
<div class="loading-spinner">
|
||||||
|
<div class="spinner"></div>
|
||||||
|
<p>${t('profile.loading_data')}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="tab-${TABS.PASSWORD}" class="tab-content">
|
||||||
|
<div class="tab-header">
|
||||||
|
<h2>${t('profile.tab_password')}</h2>
|
||||||
|
</div>
|
||||||
|
<div class="info-message">
|
||||||
|
<svg viewBox="0 0 24 24" width="24" height="24">
|
||||||
|
<path fill="currentColor" d="M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"/>
|
||||||
|
</svg>
|
||||||
|
<p>${t('profile.password_change_unavailable')}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="tab-${TABS.SECURITY}" class="tab-content">
|
||||||
|
<div class="tab-header">
|
||||||
|
<h2>${t('profile.tab_security')}</h2>
|
||||||
|
</div>
|
||||||
|
<div class="info-message">
|
||||||
|
<p>${t('profile.security_settings_info')}</p>
|
||||||
|
<button id="security-redirect-btn" class="security-btn">
|
||||||
|
<svg viewBox="0 0 24 24" width="20" height="20">
|
||||||
|
<path fill="currentColor" d="M12 1L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4zm0 10.99h7c-.53 4.12-3.28 7.79-7 8.94V12H5V6.3l7-3.11v8.8z"/>
|
||||||
|
</svg>
|
||||||
|
${t('profile.open_security_settings')}
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
|
||||||
|
document.body.appendChild(container);
|
||||||
|
}
|
||||||
|
|
||||||
|
async function fetchProfileData() {
|
||||||
|
try {
|
||||||
|
const subdomain = await storageManager.get('schoolSubdomain', '');
|
||||||
|
if (!subdomain) {
|
||||||
|
console.error('Nincs beállítva az iskola alcím');
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
const apiUrls = getApiUrls(subdomain);
|
||||||
|
const response = await fetch(apiUrls.PROFILE_DATA);
|
||||||
|
const html = await response.text();
|
||||||
|
return parseProfileHTML(html);
|
||||||
|
} catch (error) {
|
||||||
|
console.error('Hiba a profil adatok lekérésekor:', error);
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function hideAdditionalContactInfo() {
|
async function fetchAddressData() {
|
||||||
|
try {
|
||||||
|
const subdomain = await storageManager.get('schoolSubdomain', '');
|
||||||
|
if (!subdomain) {
|
||||||
|
console.error('Nincs beállítva az iskola alcím');
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
function hideElementsWithText(text) {
|
const apiUrls = getApiUrls(subdomain);
|
||||||
const elements = document.querySelectorAll('h4');
|
const timestamp = new Date().getTime();
|
||||||
elements.forEach(h4 => {
|
const response = await fetch(apiUrls.ADDRESS_DATA + timestamp);
|
||||||
if (h4.textContent && h4.textContent.includes(text)) {
|
const data = await response.json();
|
||||||
// Hide the parent row
|
return data;
|
||||||
let parent = h4.closest('.row');
|
} catch (error) {
|
||||||
if (parent) {
|
console.error('Hiba a cím adatok lekérésekor:', error);
|
||||||
parent.classList.add('hidden-contact-info');
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function parseProfileHTML(html) {
|
||||||
|
const parser = new DOMParser();
|
||||||
|
const doc = parser.parseFromString(html, 'text/html');
|
||||||
|
|
||||||
|
const data = {
|
||||||
|
personal: {},
|
||||||
|
contact: {},
|
||||||
|
bankAccount: {},
|
||||||
|
studentCard: {}
|
||||||
|
};
|
||||||
|
|
||||||
|
const personalFields = [
|
||||||
|
{ id: 'AlapAdat_CsaladiNev', key: 'familyName' },
|
||||||
|
{ id: 'AlapAdat_Utonev', key: 'firstName' },
|
||||||
|
{ id: 'AlapAdat_SzuletesiCsaladNev', key: 'birthFamilyName' },
|
||||||
|
{ id: 'AlapAdat_SzuletesiUtonev', key: 'birthFirstName' },
|
||||||
|
{ id: 'AlapAdat_AnyjaCsaladiNeve', key: 'motherFamilyName' },
|
||||||
|
{ id: 'AlapAdat_AnyjaUtonev', key: 'motherFirstName' },
|
||||||
|
{ id: 'AlapAdat_SzuletesiIdo_SDATE', key: 'birthDate' },
|
||||||
|
{ id: 'AlapAdat_SzuletesiHely', key: 'birthPlace' },
|
||||||
|
{ id: 'AlapAdat_SzuletesiOrszag', key: 'birthCountry' },
|
||||||
|
{ id: 'AlapAdat_Anyanyelv', key: 'motherTongue' },
|
||||||
|
{ id: 'AlapAdat_Allampolgarsag', key: 'citizenship' },
|
||||||
|
{ id: 'AlapAdat_OsztalyfonokNev', key: 'classTeacher' },
|
||||||
|
{ id: 'AlapAdat_OsztalyNev', key: 'className' },
|
||||||
|
{ id: 'AlapAdat_TeremNev', key: 'classroom' },
|
||||||
|
{ id: 'AlapAdat_BelepesiNev', key: 'username' }
|
||||||
|
];
|
||||||
|
|
||||||
|
personalFields.forEach(field => {
|
||||||
|
const label = doc.querySelector(`label[displayfor="${field.id}"]`);
|
||||||
|
if (label) {
|
||||||
|
data.personal[field.key] = {
|
||||||
|
key: field.key,
|
||||||
|
value: label.textContent.trim()
|
||||||
|
};
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const phoneInput = doc.querySelector('#Elerhetosegek_ErtesitesiTelefon_TelefonSzam');
|
||||||
|
const emailInput = doc.querySelector('#Elerhetosegek_ErtesitesiEmail_EmailCim');
|
||||||
|
|
||||||
|
if (phoneInput) {
|
||||||
|
data.contact.phone = {
|
||||||
|
key: 'phone',
|
||||||
|
value: phoneInput.value || ''
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
if (emailInput) {
|
||||||
|
data.contact.email = {
|
||||||
|
key: 'email',
|
||||||
|
value: emailInput.value || ''
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
const bankFields = [
|
||||||
|
{ id: 'BankszamlaSzam', key: 'accountNumber' },
|
||||||
|
{ id: 'SzamlavezetoBank', key: 'bankName' },
|
||||||
|
{ id: 'BankszamlaTulajdonosNeve', key: 'accountOwner' }
|
||||||
|
];
|
||||||
|
|
||||||
|
bankFields.forEach(field => {
|
||||||
|
const input = doc.querySelector(`#${field.id}`);
|
||||||
|
if (input) {
|
||||||
|
data.bankAccount[field.key] = {
|
||||||
|
key: field.key,
|
||||||
|
value: input.value || ''
|
||||||
|
};
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const cardFields = [
|
||||||
|
{ id: 'TanuloIgazolvany_Igazolvanyszam', key: 'cardNumber' },
|
||||||
|
{ id: 'TanuloIgazolvany_AdoazonositoJel', key: 'taxId' },
|
||||||
|
{ id: 'TanuloIgazolvany_DiakigazolvanySzam', key: 'studentCardNumber' },
|
||||||
|
{ id: 'TanuloIgazolvany_TajSzam', key: 'socialSecurityNumber' }
|
||||||
|
];
|
||||||
|
|
||||||
|
cardFields.forEach(field => {
|
||||||
|
const label = doc.querySelector(`label[displayfor="${field.id}"]`);
|
||||||
|
if (label) {
|
||||||
|
data.studentCard[field.key] = {
|
||||||
|
key: field.key,
|
||||||
|
value: label.textContent.trim()
|
||||||
|
};
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
|
||||||
|
function renderProfileData() {
|
||||||
|
const t = window.LanguageManager?.t || ((key) => key);
|
||||||
|
const container = document.getElementById(`tab-${TABS.MY_DATA}`);
|
||||||
|
|
||||||
|
if (!profileData && !addressData) {
|
||||||
|
container.innerHTML = `
|
||||||
|
<div class="error-message">
|
||||||
|
<svg viewBox="0 0 24 24" width="48" height="48">
|
||||||
|
<path fill="currentColor" d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"/>
|
||||||
|
</svg>
|
||||||
|
<p>${t('profile.loading_error')}</p>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
let html = `<div class="tab-header"><h2>${t('profile.my_data_title')}</h2></div>`;
|
||||||
|
|
||||||
|
if (profileData && profileData.personal && Object.keys(profileData.personal).length > 0) {
|
||||||
|
html += `<div class="data-section"><h3>${t('profile.personal_data')}</h3><div class="data-grid">`;
|
||||||
|
|
||||||
|
Object.values(profileData.personal).forEach(field => {
|
||||||
|
if (field.value && field.value !== 'XY') {
|
||||||
|
html += `
|
||||||
|
<div class="data-item">
|
||||||
|
<label>${t(`profile.field_${field.key}`)}</label>
|
||||||
|
<span>${field.value}</span>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
html += '</div></div>';
|
||||||
|
}
|
||||||
|
|
||||||
|
if (profileData && profileData.contact && Object.keys(profileData.contact).length > 0) {
|
||||||
|
html += `<div class="data-section"><h3>${t('profile.contact_data')}</h3><div class="data-grid">`;
|
||||||
|
|
||||||
|
Object.values(profileData.contact).forEach(field => {
|
||||||
|
if (field.value) {
|
||||||
|
html += `
|
||||||
|
<div class="data-item">
|
||||||
|
<label>${t(`profile.field_${field.key}`)}</label>
|
||||||
|
<span>${field.value}</span>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
html += '</div></div>';
|
||||||
|
}
|
||||||
|
|
||||||
|
if (addressData && addressData.Data && addressData.Data.length > 0) {
|
||||||
|
html += `<div class="data-section"><h3>${t('profile.address_data')}</h3><div class="address-list">`;
|
||||||
|
|
||||||
|
addressData.Data.forEach(address => {
|
||||||
|
const fullAddress = `${address.Irsz} ${address.Varos}, ${address.Kozterulet} ${address.KozteruletJellegeNev || ''} ${address.HazSzam}${address.Emelet ? ' ' + address.Emelet : ''}${address.Ajto ? ' ' + address.Ajto : ''}`;
|
||||||
|
const isDefault = address.Alapertelmezett_BOOL;
|
||||||
|
|
||||||
|
html += `
|
||||||
|
<div class="address-item ${isDefault ? 'default' : ''}">
|
||||||
|
<div class="address-type">
|
||||||
|
<strong>${address.CimTipus_DNAME}</strong>
|
||||||
|
${isDefault ? `<span class="badge">${t('profile.default_address')}</span>` : ''}
|
||||||
|
</div>
|
||||||
|
<div class="address-details">${fullAddress}</div>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
});
|
||||||
|
|
||||||
|
html += '</div></div>';
|
||||||
|
}
|
||||||
|
|
||||||
|
if (profileData && profileData.bankAccount && Object.keys(profileData.bankAccount).length > 0) {
|
||||||
|
const hasData = Object.values(profileData.bankAccount).some(field => field.value);
|
||||||
|
|
||||||
|
if (hasData) {
|
||||||
|
html += `<div class="data-section"><h3>${t('profile.bank_account_data')}</h3><div class="data-grid">`;
|
||||||
|
|
||||||
|
Object.values(profileData.bankAccount).forEach(field => {
|
||||||
|
if (field.value) {
|
||||||
|
html += `
|
||||||
|
<div class="data-item">
|
||||||
|
<label>${t(`profile.field_${field.key}`)}</label>
|
||||||
|
<span>${field.value}</span>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
}
|
}
|
||||||
}
|
});
|
||||||
|
|
||||||
|
html += '</div></div>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (profileData && profileData.studentCard && Object.keys(profileData.studentCard).length > 0) {
|
||||||
|
const hasData = Object.values(profileData.studentCard).some(field => field.value && field.value !== 'XY');
|
||||||
|
|
||||||
|
if (hasData) {
|
||||||
|
html += `<div class="data-section"><h3>${t('profile.student_card_data')}</h3><div class="data-grid">`;
|
||||||
|
|
||||||
|
Object.values(profileData.studentCard).forEach(field => {
|
||||||
|
if (field.value && field.value !== 'XY') {
|
||||||
|
html += `
|
||||||
|
<div class="data-item">
|
||||||
|
<label>${t(`profile.field_${field.key}`)}</label>
|
||||||
|
<span>${field.value}</span>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
html += '</div></div>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
container.innerHTML = html;
|
||||||
|
}
|
||||||
|
|
||||||
|
function setupTabSwitching() {
|
||||||
|
const tabs = document.querySelectorAll('.profile-tab');
|
||||||
|
const tabContents = document.querySelectorAll('.tab-content');
|
||||||
|
|
||||||
|
tabs.forEach(tab => {
|
||||||
|
tab.addEventListener('click', () => {
|
||||||
|
const tabId = tab.getAttribute('data-tab');
|
||||||
|
|
||||||
|
tabs.forEach(t => t.classList.remove('active'));
|
||||||
|
tab.classList.add('active');
|
||||||
|
|
||||||
|
tabContents.forEach(tc => tc.classList.remove('active'));
|
||||||
|
document.getElementById(`tab-${tabId}`).classList.add('active');
|
||||||
|
|
||||||
|
currentTab = tabId;
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
async function setupSecurityRedirect() {
|
||||||
|
const btn = document.getElementById('security-redirect-btn');
|
||||||
|
if (btn) {
|
||||||
|
btn.addEventListener('click', async () => {
|
||||||
|
const subdomain = await storageManager.get('schoolSubdomain', '');
|
||||||
|
const url = `https://idp.e-kreta.hu/security?returnUrl=https%3A%2F%2F${subdomain}.e-kreta.hu%2FAdminisztracio%2FProfil`;
|
||||||
|
window.location.href = url;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
hideElementsWithText('TOVÁBBI E-MAIL ELÉRHETŐSÉGEK');
|
|
||||||
hideElementsWithText('TOVÁBBI TELEFONSZÁMOK');
|
|
||||||
|
|
||||||
|
|
||||||
const rows = document.querySelectorAll('.row');
|
|
||||||
rows.forEach(row => {
|
|
||||||
const h4Elements = row.querySelectorAll('h4');
|
|
||||||
h4Elements.forEach(h4 => {
|
|
||||||
if (h4.textContent &&
|
|
||||||
(h4.textContent.includes('TOVÁBBI E-MAIL ELÉRHETŐSÉGEK') ||
|
|
||||||
h4.textContent.includes('TOVÁBBI TELEFONSZÁMOK'))) {
|
|
||||||
row.classList.add('hidden-contact-info');
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function init() {
|
async function init() {
|
||||||
hideLoadingScreen();
|
try {
|
||||||
addBackButton();
|
hideOriginalElements();
|
||||||
hideAdditionalContactInfo();
|
|
||||||
hideCustomUserSettingsTab();
|
|
||||||
hideMainFooter2();
|
|
||||||
hideLakatImg();
|
|
||||||
|
|
||||||
|
|
||||||
const observer = new MutationObserver(() => {
|
if (typeof window.LanguageManager !== 'undefined' && window.LanguageManager.init) {
|
||||||
hideAdditionalContactInfo();
|
await window.LanguageManager.init();
|
||||||
hideCustomUserSettingsTab();
|
}
|
||||||
hideMainFooter2();
|
|
||||||
hideLakatImg();
|
await createNavbar();
|
||||||
});
|
createProfilePage();
|
||||||
|
setupTabSwitching();
|
||||||
observer.observe(document.body, {
|
setupSecurityRedirect();
|
||||||
childList: true,
|
|
||||||
subtree: true
|
[profileData, addressData] = await Promise.all([
|
||||||
});
|
fetchProfileData(),
|
||||||
|
fetchAddressData()
|
||||||
|
]);
|
||||||
|
|
||||||
|
renderProfileData();
|
||||||
|
} catch (error) {
|
||||||
|
console.error('Hiba az inicializálás során:', error);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (document.readyState === 'loading') {
|
if (document.readyState === 'loading') {
|
||||||
document.addEventListener('DOMContentLoaded', init);
|
document.addEventListener('DOMContentLoaded', init);
|
||||||
} else {
|
} else {
|
||||||
init();
|
init();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
window.addEventListener('load', init);
|
})();
|
||||||
|
|
||||||
|
|
||||||
setTimeout(hideLoadingScreen, 1000);
|
|
||||||
|
|
||||||
|
|
||||||
let attempts = 0;
|
|
||||||
const maxAttempts = 20;
|
|
||||||
const aggressiveHide = setInterval(() => {
|
|
||||||
attempts++;
|
|
||||||
hideLoadingScreen();
|
|
||||||
|
|
||||||
if (attempts >= maxAttempts) {
|
|
||||||
clearInterval(aggressiveHide);
|
|
||||||
}
|
|
||||||
}, 500);
|
|
||||||
|
|
||||||
|
|
||||||
if (typeof MutationObserver !== 'undefined') {
|
|
||||||
const observer = new MutationObserver((mutations) => {
|
|
||||||
mutations.forEach((mutation) => {
|
|
||||||
mutation.addedNodes.forEach((node) => {
|
|
||||||
if (node.nodeType === 1) {
|
|
||||||
if (node.id === 'KretaProgressBar' ||
|
|
||||||
node.className && (node.className.includes('loading') || node.className.includes('Loading'))) {
|
|
||||||
node.style.display = 'none !important';
|
|
||||||
node.style.visibility = 'hidden';
|
|
||||||
node.style.opacity = '0';
|
|
||||||
if (node.parentNode) {
|
|
||||||
node.parentNode.removeChild(node);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
observer.observe(document.body, {
|
|
||||||
childList: true,
|
|
||||||
subtree: true
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
})();
|
|
||||||
|
|||||||
@@ -133,7 +133,7 @@ body {
|
|||||||
}
|
}
|
||||||
.logout-card {
|
.logout-card {
|
||||||
height:180px;
|
height:180px;
|
||||||
background:var(--error-card);
|
background:var(--card-card);
|
||||||
box-shadow:0px 1px var(--shadow-blur) 0px var(--accent-shadow);
|
box-shadow:0px 1px var(--shadow-blur) 0px var(--accent-shadow);
|
||||||
}
|
}
|
||||||
.role-icon {
|
.role-icon {
|
||||||
@@ -219,6 +219,7 @@ to {
|
|||||||
}
|
}
|
||||||
}@media (max-width:900px) {
|
}@media (max-width:900px) {
|
||||||
.role-grid {
|
.role-grid {
|
||||||
|
gap:0.5rem;
|
||||||
grid-template-columns:1fr;
|
grid-template-columns:1fr;
|
||||||
}
|
}
|
||||||
.side-roles {
|
.side-roles {
|
||||||
|
|||||||
@@ -18,6 +18,25 @@
|
|||||||
return setInterval(updateTimer, 1000);
|
return setInterval(updateTimer, 1000);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
async function loadRoleselectSettings() {
|
||||||
|
try {
|
||||||
|
const settings = await storageManager.get("pageSettings_roleselect", {
|
||||||
|
autoRedirect: false,
|
||||||
|
hideSchoolInfo: true
|
||||||
|
});
|
||||||
|
return {
|
||||||
|
autoRedirect: settings.autoRedirect || false,
|
||||||
|
hideSchoolInfo: settings.hideSchoolInfo !== undefined ? settings.hideSchoolInfo : true
|
||||||
|
};
|
||||||
|
} catch (error) {
|
||||||
|
console.error("Error loading roleselect settings:", error);
|
||||||
|
return {
|
||||||
|
autoRedirect: false,
|
||||||
|
hideSchoolInfo: true
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const handleRoleChange = async (role) => {
|
const handleRoleChange = async (role) => {
|
||||||
try {
|
try {
|
||||||
const response = await fetch(
|
const response = await fetch(
|
||||||
@@ -41,7 +60,7 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const createHTML = (schoolCode, fullSchoolName, userName) => `
|
const createHTML = (schoolCode, fullSchoolName, userName, settings) => `
|
||||||
<div class="kreta-container">
|
<div class="kreta-container">
|
||||||
<header class="kreta-header">
|
<header class="kreta-header">
|
||||||
<div class="school-info">
|
<div class="school-info">
|
||||||
@@ -49,15 +68,17 @@
|
|||||||
<img src=${chrome.runtime.getURL("images/firka_logo.png")} alt="Firka" class="logo">
|
<img src=${chrome.runtime.getURL("images/firka_logo.png")} alt="Firka" class="logo">
|
||||||
Firka
|
Firka
|
||||||
</p>
|
</p>
|
||||||
<div class="school-details">
|
${!settings.hideSchoolInfo ? `<div class="school-details">
|
||||||
<span>${schoolCode || ""} - ${fullSchoolName || "Iskola"}</span>
|
<span>${schoolCode || ""} - ${fullSchoolName || "Iskola"}</span>
|
||||||
</div>
|
</div>` : ''}
|
||||||
</div>
|
</div>
|
||||||
<div class="user-profile">
|
<div class="user-profile">
|
||||||
<div class="user-info">
|
${!settings.hideSchoolInfo ? `<div class="user-info">
|
||||||
<span class="user-name">${userName}</span>
|
<span class="user-name">${userName}</span>
|
||||||
<span class="logout-timer" id="logoutTimer">5:00</span>
|
<span class="logout-timer" id="logoutTimer">5:00</span>
|
||||||
</div>
|
</div>` : `<div class="user-info">
|
||||||
|
<span class="logout-timer" id="logoutTimer">5:00</span>
|
||||||
|
</div>`}
|
||||||
</div>
|
</div>
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
@@ -108,6 +129,12 @@
|
|||||||
window.addEventListener("load", resolve),
|
window.addEventListener("load", resolve),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
const settings = await loadRoleselectSettings();
|
||||||
|
|
||||||
|
if (settings.autoRedirect) {
|
||||||
|
handleRoleChange("Ellenorzo");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const schoolNameEl = document.querySelector(".IntezmenyNev");
|
const schoolNameEl = document.querySelector(".IntezmenyNev");
|
||||||
const schoolName = schoolNameEl?.textContent.trim() || "Iskola neve";
|
const schoolName = schoolNameEl?.textContent.trim() || "Iskola neve";
|
||||||
@@ -127,14 +154,15 @@
|
|||||||
if (userName) {
|
if (userName) {
|
||||||
await storageManager.set("userName", userName);
|
await storageManager.set("userName", userName);
|
||||||
}
|
}
|
||||||
document.body.innerHTML = '';
|
helper.clearElement(document.body);
|
||||||
const parser = new DOMParser();
|
const template = document.createElement('template');
|
||||||
const doc = parser.parseFromString(createHTML(
|
template.innerHTML = createHTML(
|
||||||
schoolCode,
|
schoolCode,
|
||||||
fullSchoolName,
|
fullSchoolName,
|
||||||
userName,
|
userName,
|
||||||
), 'text/html');
|
settings,
|
||||||
const tempDiv = doc.body;
|
);
|
||||||
|
const tempDiv = template.content;
|
||||||
while (tempDiv.firstChild) {
|
while (tempDiv.firstChild) {
|
||||||
document.body.appendChild(tempDiv.firstChild);
|
document.body.appendChild(tempDiv.firstChild);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,10 +57,13 @@ body {
|
|||||||
align-items:center;
|
align-items:center;
|
||||||
gap:8px;
|
gap:8px;
|
||||||
}
|
}
|
||||||
.logo {
|
.logos {
|
||||||
width:32px;
|
width:32px;
|
||||||
height:32px;
|
height:32px;
|
||||||
}
|
}
|
||||||
|
.logo {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
.search-title {
|
.search-title {
|
||||||
color:var(--text-primary);
|
color:var(--text-primary);
|
||||||
text-align:center;
|
text-align:center;
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ async function applyFirkaStyling() {
|
|||||||
const logoImg = document.createElement('img');
|
const logoImg = document.createElement('img');
|
||||||
logoImg.src = chrome.runtime.getURL('images/firka_logo.png');
|
logoImg.src = chrome.runtime.getURL('images/firka_logo.png');
|
||||||
logoImg.alt = 'Firka';
|
logoImg.alt = 'Firka';
|
||||||
logoImg.className = 'logo';
|
logoImg.className = 'logos';
|
||||||
|
|
||||||
logoText.appendChild(logoImg);
|
logoText.appendChild(logoImg);
|
||||||
logoText.appendChild(document.createTextNode('Firka'));
|
logoText.appendChild(document.createTextNode('Firka'));
|
||||||
|
|||||||
1434
settings/index.css
@@ -22,213 +22,326 @@
|
|||||||
</p>
|
</p>
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
<div class="settings-card">
|
<div class="tab-navigation">
|
||||||
<h2 data-i18n="settings.title">Beállítások</h2>
|
<button class="tab-button active" data-tab="appearance">
|
||||||
<div class="settings-group">
|
<span class="material-icons-round">palette</span>
|
||||||
<div class="setting-section">
|
<span data-i18n="settings.tabs.appearance">Megjelenés</span>
|
||||||
<div class="setting-header">
|
</button>
|
||||||
<span class="material-icons-round">palette</span>
|
<button class="tab-button" data-tab="settings">
|
||||||
<span data-i18n="settings.theme">Téma</span>
|
<span class="material-icons-round">tune</span>
|
||||||
</div>
|
<span data-i18n="settings.tabs.settings">Beállítások</span>
|
||||||
<div class="theme-grid">
|
</button>
|
||||||
<button class="theme-option" data-theme="light-green">
|
<button class="tab-button" data-tab="about">
|
||||||
<div class="theme-preview light-green">
|
<span class="material-icons-round">info</span>
|
||||||
<div class="preview-header"></div>
|
<span data-i18n="settings.tabs.about">Névjegy</span>
|
||||||
<div class="preview-content">
|
</button>
|
||||||
<div class="preview-card"></div>
|
</div>
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<span class="theme-name" data-i18n="settings.themes.light_green">Világos Zöld</span>
|
|
||||||
</button>
|
|
||||||
|
|
||||||
<button class="theme-option" data-theme="dark-green">
|
<div class="tab-content active" id="tab-appearance">
|
||||||
<div class="theme-preview dark-green">
|
<div class="settings-card">
|
||||||
<div class="preview-header"></div>
|
<div class="settings-group">
|
||||||
<div class="preview-content">
|
<div class="setting-section">
|
||||||
<div class="preview-card"></div>
|
<div class="setting-header theme-header">
|
||||||
|
<div class="setting-header-left">
|
||||||
|
<span class="material-icons-round">palette</span>
|
||||||
|
<span data-i18n="settings.theme">Téma</span>
|
||||||
|
</div>
|
||||||
|
<div class="theme-manage-dropdown">
|
||||||
|
<button class="theme-manage-btn" id="themeManageBtn">
|
||||||
|
<span class="material-icons-round">settings</span>
|
||||||
|
</button>
|
||||||
|
<div class="theme-manage-menu" id="themeManageMenu">
|
||||||
|
<button class="theme-manage-item" id="addCustomTheme">
|
||||||
|
<span class="material-icons-round">add</span>
|
||||||
|
<span data-i18n="settings.custom_themes.create">Új téma létrehozása</span>
|
||||||
|
</button>
|
||||||
|
<button class="theme-manage-item" id="importCustomTheme">
|
||||||
|
<span class="material-icons-round">download</span>
|
||||||
|
<span data-i18n="settings.custom_themes.import">Importálás</span>
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<span class="theme-name" data-i18n="settings.themes.dark_green">Sötét Zöld</span>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<!--
|
|
||||||
<div class="setting-section">
|
|
||||||
<div class="setting-header">
|
|
||||||
<div>
|
|
||||||
<span class="material-icons-round">brush</span>
|
|
||||||
<span data-i18n="settings.custom_theme.title">Egyéni Téma</span>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="theme-editor-controls">
|
<div class="theme-grid" id="allThemesGrid">
|
||||||
<button class="icon-btn" id="createCustomTheme" title="Új Téma Létrehozása">
|
<button class="theme-option" data-theme="light-green">
|
||||||
<span class="material-icons-round">add</span>
|
<div class="theme-preview light-green">
|
||||||
|
<div class="preview-header"></div>
|
||||||
|
<div class="preview-content">
|
||||||
|
<div class="preview-card"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<span class="theme-name" data-i18n="settings.themes.light_green">Világos Zöld</span>
|
||||||
</button>
|
</button>
|
||||||
<button class="icon-btn" id="importTheme" title="Téma Importálása">
|
|
||||||
<span class="material-icons-round">file_download</span>
|
<button class="theme-option" data-theme="dark-green">
|
||||||
|
<div class="theme-preview dark-green">
|
||||||
|
<div class="preview-header"></div>
|
||||||
|
<div class="preview-content">
|
||||||
|
<div class="preview-card"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<span class="theme-name" data-i18n="settings.themes.dark_green">Sötét Zöld</span>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="custom-theme-editor">
|
<div class="setting-section">
|
||||||
|
<div class="setting-header">
|
||||||
<div class="custom-themes-list" id="customThemesList">
|
<span class="material-icons-round">language</span>
|
||||||
|
<span data-i18n="settings.language">Nyelv</span>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="language-grid">
|
||||||
|
<button class="language-option" data-language="hu">
|
||||||
|
<span class="language-name" data-i18n="settings.languages.hu">Magyar</span>
|
||||||
|
</button>
|
||||||
|
<button class="language-option" data-language="en">
|
||||||
|
<span class="language-name" data-i18n="settings.languages.en">English</span>
|
||||||
|
</button>
|
||||||
|
<button class="language-option" data-language="de">
|
||||||
|
<span class="language-name" data-i18n="settings.languages.de">Deutsch</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<a href="https://folio.zan1456.dev" target="_blank" class="folio-ad-card">
|
||||||
|
<div class="folio-ad-left">
|
||||||
|
<img src="../images/folio.png" alt="Folio" class="folio-ad-logo">
|
||||||
|
<div class="folio-ad-text">
|
||||||
|
<span class="folio-ad-title">Folio</span>
|
||||||
|
<span class="folio-ad-desc">Material You KRÉTA app Androidra</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="folio-ad-right">
|
||||||
|
<span class="material-icons-round">download</span>
|
||||||
|
<span class="folio-ad-cta">Letöltés</span>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="theme-editor-modal" id="themeEditorModal" style="display: none;">
|
<div class="tab-content" id="tab-settings">
|
||||||
<div class="modal-content">
|
<div class="settings-card">
|
||||||
<div class="modal-header">
|
<h2 data-i18n="settings.page_settings.title">Oldal beállítások</h2>
|
||||||
<h3 data-i18n="settings.custom_theme.editor_title">Téma Szerkesztő</h3>
|
<div class="page-settings-info">
|
||||||
<button class="close-modal" id="closeThemeEditor">
|
<div class="current-page-indicator">
|
||||||
<span class="material-icons-round">close</span>
|
<span class="material-icons-round">web</span>
|
||||||
</button>
|
<span id="currentPageName" data-i18n="settings.page_settings.current_page">Aktuális oldal</span>
|
||||||
</div>
|
<span id="currentPageValue" class="page-badge">-</span>
|
||||||
<div class="modal-body">
|
</div>
|
||||||
<div class="theme-name-input">
|
</div>
|
||||||
<label for="themeName" data-i18n="settings.custom_theme.name">Téma neve:</label>
|
<div id="pageSpecificSettings" class="page-specific-settings">
|
||||||
<input type="text" id="themeName" placeholder="Saját téma" maxlength="30">
|
<div class="no-settings-placeholder">
|
||||||
</div>
|
<span class="material-icons-round">settings_suggest</span>
|
||||||
|
<p data-i18n="settings.page_settings.no_settings">Ehhez az oldalhoz nincsenek egyéni beállítások.</p>
|
||||||
<div class="color-groups">
|
</div>
|
||||||
<div class="color-group">
|
</div>
|
||||||
<h4 data-i18n="settings.custom_theme.background">Háttér</h4>
|
</div>
|
||||||
<div class="color-inputs">
|
<div class="error-reporting-card">
|
||||||
<div class="color-input-group">
|
<h2 data-i18n="settings.error_reporting.title">Hibajelentés</h2>
|
||||||
<label for="background" data-i18n="settings.custom_theme.main_background">Fő háttér:</label>
|
<div class="error-reporting-content">
|
||||||
<input type="color" id="background" value="#DAE4F7">
|
<div class="setting-item">
|
||||||
</div>
|
<div class="setting-item-info">
|
||||||
<div class="color-input-group">
|
<div class="setting-item-label" data-i18n="settings.error_reporting.enable">Hibajelentés engedélyezése</div>
|
||||||
<label for="cardCard" data-i18n="settings.custom_theme.card_background">Kártya háttér:</label>
|
<div class="setting-item-description" data-i18n="settings.error_reporting.enable_desc">Automatikus hibajelentés küldése a fejlesztőknek a bővítmény javításához</div>
|
||||||
<input type="color" id="cardCard" value="#EDF3FF">
|
</div>
|
||||||
</div>
|
<label class="toggle-switch">
|
||||||
</div>
|
<input type="checkbox" id="errorReportingToggle" checked>
|
||||||
</div>
|
<span class="toggle-slider"></span>
|
||||||
|
</label>
|
||||||
<div class="color-group">
|
</div>
|
||||||
<h4 data-i18n="settings.custom_theme.text">Szöveg</h4>
|
<div class="report-issue-button-wrapper">
|
||||||
<div class="color-inputs">
|
<a href="https://github.com/QwIT-Development/firka-extension/issues/new" target="_blank" class="report-issue-button">
|
||||||
<div class="color-input-group">
|
<span class="material-icons-round">bug_report</span>
|
||||||
<label for="textPrimary" data-i18n="settings.custom_theme.primary_text">Elsődleges szöveg:</label>
|
<div class="report-issue-text">
|
||||||
<input type="color" id="textPrimary" value="#050B15">
|
<span class="report-issue-title" data-i18n="settings.error_reporting.report_issue">Hiba vagy ötlet jelentése</span>
|
||||||
</div>
|
<span class="report-issue-desc" data-i18n="settings.error_reporting.report_issue_desc">Nyiss egy GitHub issue-t</span>
|
||||||
<div class="color-input-group">
|
|
||||||
<label for="textSecondary" data-i18n="settings.custom_theme.secondary_text">Másodlagos szöveg:</label>
|
|
||||||
<input type="color" id="textSecondary" value="#050B15">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="color-group">
|
|
||||||
<h4 data-i18n="settings.custom_theme.accent">Kiemelő színek</h4>
|
|
||||||
<div class="color-inputs">
|
|
||||||
<div class="color-input-group">
|
|
||||||
<label for="accentAccent" data-i18n="settings.custom_theme.primary_accent">Elsődleges kiemelő:</label>
|
|
||||||
<input type="color" id="accentAccent" value="#3673EE">
|
|
||||||
</div>
|
|
||||||
<div class="color-input-group">
|
|
||||||
<label for="accentSecondary" data-i18n="settings.custom_theme.secondary_accent">Másodlagos kiemelő:</label>
|
|
||||||
<input type="color" id="accentSecondary" value="#1C469A">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="theme-preview-container">
|
|
||||||
<h4 data-i18n="settings.custom_theme.preview">Előnézet</h4>
|
|
||||||
<div class="custom-theme-preview" id="customThemePreview">
|
|
||||||
<div class="preview-content">
|
|
||||||
<div class="preview-card">
|
|
||||||
<div class="preview-text-primary">Elsődleges szöveg</div>
|
|
||||||
<div class="preview-text-secondary">Másodlagos szöveg</div>
|
|
||||||
<div class="preview-accent">Kiemelő szín</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="modal-footer">
|
|
||||||
<button class="btn-secondary" id="cancelThemeEdit" data-i18n="settings.custom_theme.cancel">Mégse</button>
|
|
||||||
<button class="btn-primary" id="saveTheme" data-i18n="settings.custom_theme.save">Mentés</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</a>
|
||||||
|
|
||||||
<div class="import-modal" id="importModal" style="display: none;">
|
|
||||||
<div class="modal-content">
|
|
||||||
<div class="modal-header">
|
|
||||||
<h3 data-i18n="settings.custom_theme.import_title">Téma Importálása</h3>
|
|
||||||
<button class="close-modal" id="closeImportModal">
|
|
||||||
<span class="material-icons-round">close</span>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
<div class="modal-body">
|
|
||||||
<div class="import-input">
|
|
||||||
<label for="themeImportString" data-i18n="settings.custom_theme.import_string">Téma azonosítója:</label>
|
|
||||||
<textarea id="themeImportString" placeholder="Illeszd be ide a téma azonosítóját..." rows="4"></textarea>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="modal-footer">
|
|
||||||
<button class="btn-secondary" id="cancelImport" data-i18n="settings.custom_theme.cancel">Mégse</button>
|
|
||||||
<button class="btn-primary" id="confirmImport" data-i18n="settings.custom_theme.import">Importálás</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
-->
|
|
||||||
<div class="setting-section">
|
|
||||||
<div class="setting-header">
|
|
||||||
<span class="material-icons-round">language</span>
|
|
||||||
<span data-i18n="settings.language">Nyelv</span>
|
|
||||||
</div>
|
|
||||||
<div class="language-grid">
|
|
||||||
<button class="language-option" data-language="hu">
|
|
||||||
<span class="language-name" data-i18n="settings.languages.hu">Magyar</span>
|
|
||||||
</button>
|
|
||||||
<button class="language-option" data-language="en">
|
|
||||||
<span class="language-name" data-i18n="settings.languages.en">English</span>
|
|
||||||
</button>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="about-card">
|
<div class="tab-content" id="tab-about">
|
||||||
<h2 data-i18n="settings.about.title">Névjegy</h2>
|
<div class="about-card">
|
||||||
<div class="about-content">
|
<h2 data-i18n="settings.about.title">Névjegy</h2>
|
||||||
<p data-i18n="settings.about.description">A Firka egy nyílt forráskódú projekt, amely a KRÉTA rendszerhez készít saját felhasználói felületet.</p>
|
<div class="about-content">
|
||||||
<div class="about-links">
|
<p data-i18n="settings.about.description">A Firka egy nyílt forráskódú projekt, amely a KRÉTA rendszerhez készít saját felhasználói felületet.</p>
|
||||||
<a href="https://firka.app" target="_blank" class="about-link">
|
<div class="about-links">
|
||||||
<span class="material-icons-round">language</span>
|
<a href="https://firka.app" target="_blank" class="about-link">
|
||||||
<span>Weboldal</span>
|
<span class="material-icons-round">language</span>
|
||||||
</a>
|
<span>Weboldal</span>
|
||||||
<a href="https://github.com/QwIT-Development/" target="_blank" class="about-link">
|
</a>
|
||||||
<span class="material-icons-round">code</span>
|
<a href="https://github.com/QwIT-Development/" target="_blank" class="about-link">
|
||||||
<span data-i18n="settings.about.github">GitHub</span>
|
<span class="material-icons-round">code</span>
|
||||||
</a>
|
<span data-i18n="settings.about.github">GitHub</span>
|
||||||
<a href="https://discord.gg/firka-1111649116020285532" target="_blank" class="about-link">
|
</a>
|
||||||
<span class="material-icons-round">forum</span>
|
<a href="https://discord.gg/firka-1111649116020285532" target="_blank" class="about-link">
|
||||||
<span>Discord</span>
|
<span class="material-icons-round">forum</span>
|
||||||
</a>
|
<span>Discord</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="support-card">
|
<div class="support-card">
|
||||||
<h2 data-i18n="settings.support.title">Támogatás</h2>
|
<h2 data-i18n="settings.support.title">Támogatás</h2>
|
||||||
<div class="support-content">
|
<div class="support-content">
|
||||||
<p data-i18n="settings.support.description">Ha tetszik a munkánk és szeretnéd támogatni a fejlesztést, az alábbi módon teheted meg:</p>
|
<p data-i18n="settings.support.description">Ha tetszik a munkánk és szeretnéd támogatni a fejlesztést, az alábbi módon teheted meg:</p>
|
||||||
<div class="support-buttons">
|
<div class="support-buttons">
|
||||||
<a href="https://ko-fi.com/zan1456" target="_blank" class="support-button">
|
<a href="https://ko-fi.com/zan1456" target="_blank" class="support-button">
|
||||||
<span class="material-icons-round">coffee</span>
|
<span class="material-icons-round">coffee</span>
|
||||||
<span data-i18n="settings.support.kofi">Ko-Fi</span>
|
<span data-i18n="settings.support.kofi">Ko-Fi</span>
|
||||||
</a>
|
</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="version-info" id="version">v1.4.0</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<footer class="popup-footer">
|
|
||||||
<div class="version-info" id="version">v1.3.0</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="modal-overlay" id="updateModal">
|
||||||
|
<div class="modal-content update-modal">
|
||||||
|
<div class="modal-header">
|
||||||
|
<h3 data-i18n="settings.update.title">Új verzió érhető el!</h3>
|
||||||
|
</div>
|
||||||
|
<div class="modal-body">
|
||||||
|
<div class="update-version-info">
|
||||||
|
<div class="version-badge current">
|
||||||
|
<span class="version-label" data-i18n="settings.update.current_version">Jelenlegi verzió:</span>
|
||||||
|
<span class="version-number" id="currentVersion">-</span>
|
||||||
|
</div>
|
||||||
|
<span class="material-icons-round version-arrow">arrow_forward</span>
|
||||||
|
<div class="version-badge latest">
|
||||||
|
<span class="version-label" data-i18n="settings.update.latest_version">Legújabb verzió:</span>
|
||||||
|
<span class="version-number" id="latestVersion">-</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="update-changelog-section">
|
||||||
|
<h4 data-i18n="settings.update.whats_new">Újdonságok:</h4>
|
||||||
|
<div class="update-changelog" id="updateChangelog">
|
||||||
|
<p data-i18n="settings.update.loading">Betöltés...</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="modal-footer">
|
||||||
|
<button class="btn-secondary" id="dismissUpdate" data-i18n="settings.update.dismiss">Bezárás</button>
|
||||||
|
<a class="btn-primary update-button" id="updateButton" href="#" target="_blank">
|
||||||
|
<span data-i18n="settings.update.download">Letöltés</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="modal-overlay" id="themeEditorModal">
|
||||||
|
<div class="modal-content theme-editor-modal">
|
||||||
|
<div class="modal-header">
|
||||||
|
<h3 id="themeEditorTitle" data-i18n="settings.custom_themes.create">Új téma létrehozása</h3>
|
||||||
|
</div>
|
||||||
|
<div class="modal-body">
|
||||||
|
<div class="theme-form">
|
||||||
|
<div class="form-group">
|
||||||
|
<label for="themeName" data-i18n="settings.custom_themes.name">Téma neve</label>
|
||||||
|
<input type="text" id="themeName" placeholder="Pl. Kék éjszaka">
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label data-i18n="settings.custom_themes.mode">Mód</label>
|
||||||
|
<div class="mode-selector">
|
||||||
|
<button class="mode-option active" data-mode="dark">
|
||||||
|
<span class="material-icons-round">dark_mode</span>
|
||||||
|
<span data-i18n="settings.custom_themes.dark_mode">Sötét</span>
|
||||||
|
</button>
|
||||||
|
<button class="mode-option" data-mode="light">
|
||||||
|
<span class="material-icons-round">light_mode</span>
|
||||||
|
<span data-i18n="settings.custom_themes.light_mode">Világos</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="color-section">
|
||||||
|
<h4 data-i18n="settings.custom_themes.colors">Színek</h4>
|
||||||
|
|
||||||
|
<div class="color-group">
|
||||||
|
<label data-i18n="settings.custom_themes.accent_color">Kiemelő szín</label>
|
||||||
|
<div class="color-input-wrapper">
|
||||||
|
<input type="color" id="accentColor" value="#A7DC22">
|
||||||
|
<input type="text" class="color-hex" id="accentColorHex" value="#A7DC22">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="color-group">
|
||||||
|
<label data-i18n="settings.custom_themes.background_color">Háttér szín</label>
|
||||||
|
<div class="color-input-wrapper">
|
||||||
|
<input type="color" id="backgroundColor" value="#0D1202">
|
||||||
|
<input type="text" class="color-hex" id="backgroundColorHex" value="#0D1202">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="color-group">
|
||||||
|
<label data-i18n="settings.custom_themes.card_color">Kártya szín</label>
|
||||||
|
<div class="color-input-wrapper">
|
||||||
|
<input type="color" id="cardColor" value="#141905">
|
||||||
|
<input type="text" class="color-hex" id="cardColorHex" value="#141905">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="color-group">
|
||||||
|
<label data-i18n="settings.custom_themes.text_color">Szöveg szín</label>
|
||||||
|
<div class="color-input-wrapper">
|
||||||
|
<input type="color" id="textColor" value="#EAF7CC">
|
||||||
|
<input type="text" class="color-hex" id="textColorHex" value="#EAF7CC">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="modal-footer">
|
||||||
|
<button class="btn-secondary" id="cancelThemeEditor" data-i18n="common.cancel">Mégse</button>
|
||||||
|
<button class="btn-primary" id="saveTheme" data-i18n="common.save">Mentés</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="modal-overlay" id="shareThemeModal">
|
||||||
|
<div class="modal-content share-modal">
|
||||||
|
<div class="modal-header">
|
||||||
|
<h3 data-i18n="settings.custom_themes.share">Téma megosztása</h3>
|
||||||
|
</div>
|
||||||
|
<div class="modal-body">
|
||||||
|
<p data-i18n="settings.custom_themes.share_description">Másold ki a kódot és oszd meg másokkal:</p>
|
||||||
|
<div class="share-code-wrapper">
|
||||||
|
<textarea id="shareCode" readonly></textarea>
|
||||||
|
<button class="copy-btn" id="copyShareCode">
|
||||||
|
<span class="material-icons-round">content_copy</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="modal-footer">
|
||||||
|
<button class="btn-primary" id="closeShareModalBtn" data-i18n="common.close">Bezárás</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="modal-overlay" id="importThemeModal">
|
||||||
|
<div class="modal-content import-modal">
|
||||||
|
<div class="modal-header">
|
||||||
|
<h3 data-i18n="settings.custom_themes.import">Téma importálása</h3>
|
||||||
|
</div>
|
||||||
|
<div class="modal-body">
|
||||||
|
<p data-i18n="settings.custom_themes.import_description">Illeszd be a téma kódot:</p>
|
||||||
|
<textarea id="importCode" placeholder="Illeszd be a téma kódját ide..."></textarea>
|
||||||
|
<p class="error-message" id="importError"></p>
|
||||||
|
</div>
|
||||||
|
<div class="modal-footer">
|
||||||
|
<button class="btn-secondary" id="cancelImport" data-i18n="common.cancel">Mégse</button>
|
||||||
|
<button class="btn-primary" id="confirmImport" data-i18n="settings.custom_themes.import">Importálás</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script src="../tools/helper.js"></script>
|
||||||
<script src="../tools/storageManager.js"></script>
|
<script src="../tools/storageManager.js"></script>
|
||||||
<script src="../global/language.js"></script>
|
<script src="../global/language.js"></script>
|
||||||
<script src="index.js"></script>
|
<script src="index.js"></script>
|
||||||
|
|||||||
1490
settings/index.js
462
setup/setup.css
Normal file
@@ -0,0 +1,462 @@
|
|||||||
|
* {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: 'Montserrat', sans-serif;
|
||||||
|
min-height: 100vh;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
padding: 1rem;
|
||||||
|
background: var(--background);
|
||||||
|
color: var(--text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-container {
|
||||||
|
width: 100%;
|
||||||
|
max-width: 700px;
|
||||||
|
animation: fadeIn 0.5s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fadeIn {
|
||||||
|
from {
|
||||||
|
opacity: 0;
|
||||||
|
transform: translateY(20px);
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
transform: translateY(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-card {
|
||||||
|
background: var(--card-card);
|
||||||
|
border-radius: 20px;
|
||||||
|
padding: 2rem;
|
||||||
|
box-shadow: 0 4px 20px var(--accent-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-header {
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-logo {
|
||||||
|
width: 60px;
|
||||||
|
height: 60px;
|
||||||
|
margin-bottom: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-title {
|
||||||
|
font-size: 2rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: var(--text-primary);
|
||||||
|
margin-bottom: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-subtitle {
|
||||||
|
font-size: 1rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-bar {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
margin-bottom: 2rem;
|
||||||
|
padding: 0 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-step {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.4rem;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-circle {
|
||||||
|
width: 40px;
|
||||||
|
height: 40px;
|
||||||
|
border-radius: 50%;
|
||||||
|
background: var(--button-secondaryFill);
|
||||||
|
border: 2px solid var(--text-teritary);
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-weight: 600;
|
||||||
|
font-size: 1rem;
|
||||||
|
color: var(--text-teritary);
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-step.active .progress-circle {
|
||||||
|
background: var(--accent-accent);
|
||||||
|
border-color: var(--accent-accent);
|
||||||
|
color: white;
|
||||||
|
transform: scale(1.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-step.completed .progress-circle {
|
||||||
|
background: var(--accent-accent);
|
||||||
|
border-color: var(--accent-accent);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-label {
|
||||||
|
font-size: 0.875rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-step.active .progress-label {
|
||||||
|
color: var(--accent-accent);
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-line {
|
||||||
|
width: 80px;
|
||||||
|
height: 2px;
|
||||||
|
background: var(--text-teritary);
|
||||||
|
margin: 0 0.5rem;
|
||||||
|
margin-bottom: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-content {
|
||||||
|
min-height: 320px;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-step {
|
||||||
|
display: none;
|
||||||
|
animation: slideIn 0.4s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-step.active {
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes slideIn {
|
||||||
|
from {
|
||||||
|
opacity: 0;
|
||||||
|
transform: translateX(20px);
|
||||||
|
}
|
||||||
|
to {
|
||||||
|
opacity: 1;
|
||||||
|
transform: translateX(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.step-icon {
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.step-icon .material-icons-round {
|
||||||
|
font-size: 3rem;
|
||||||
|
color: var(--accent-accent);
|
||||||
|
}
|
||||||
|
|
||||||
|
.step-icon.success .material-icons-round {
|
||||||
|
font-size: 3.5rem;
|
||||||
|
color: var(--success);
|
||||||
|
}
|
||||||
|
|
||||||
|
.step-title {
|
||||||
|
text-align: center;
|
||||||
|
font-size: 1.5rem;
|
||||||
|
font-weight: 700;
|
||||||
|
color: var(--text-primary);
|
||||||
|
margin-bottom: 0.4rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.step-description {
|
||||||
|
text-align: center;
|
||||||
|
font-size: 0.9rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
margin-bottom: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-options {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
|
||||||
|
gap: 1rem;
|
||||||
|
margin-top: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-card {
|
||||||
|
background: var(--button-secondaryFill);
|
||||||
|
border: 3px solid transparent;
|
||||||
|
border-radius: 12px;
|
||||||
|
padding: 1rem;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.8rem;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-card:hover {
|
||||||
|
transform: translateY(-4px);
|
||||||
|
box-shadow: 0 8px 24px var(--accent-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-card.selected {
|
||||||
|
border-color: var(--accent-accent);
|
||||||
|
background: var(--accent-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-icon {
|
||||||
|
position: absolute;
|
||||||
|
top: 1rem;
|
||||||
|
right: 1rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
font-size: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-card.selected .theme-icon {
|
||||||
|
color: var(--accent-accent);
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-preview {
|
||||||
|
width: 100%;
|
||||||
|
height: 100px;
|
||||||
|
border-radius: 10px;
|
||||||
|
overflow: hidden;
|
||||||
|
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-preview.light-green {
|
||||||
|
background: #FAFFF0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-preview.dark-green {
|
||||||
|
background: #0D1202;
|
||||||
|
}
|
||||||
|
|
||||||
|
.preview-header {
|
||||||
|
height: 30%;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
padding: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-preview.light-green .preview-header {
|
||||||
|
background: #F3FBDE;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-preview.dark-green .preview-header {
|
||||||
|
background: #141905;
|
||||||
|
}
|
||||||
|
|
||||||
|
.preview-content {
|
||||||
|
height: 70%;
|
||||||
|
padding: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.preview-card {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
border-radius: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-preview.light-green .preview-card {
|
||||||
|
background: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-preview.dark-green .preview-card {
|
||||||
|
background: #1a2207;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-name {
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--text-primary);
|
||||||
|
font-size: 1.1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.language-options {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
|
||||||
|
gap: 1rem;
|
||||||
|
margin-top: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.language-card {
|
||||||
|
background: var(--button-secondaryFill);
|
||||||
|
border: 3px solid transparent;
|
||||||
|
border-radius: 12px;
|
||||||
|
padding: 1.5rem;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.8rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.language-card:hover {
|
||||||
|
transform: translateY(-4px);
|
||||||
|
box-shadow: 0 8px 24px var(--accent-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.language-card.selected {
|
||||||
|
border-color: var(--accent-accent);
|
||||||
|
background: var(--accent-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.language-flag {
|
||||||
|
font-size: 3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.language-name {
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--text-primary);
|
||||||
|
font-size: 1.1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.finish-links {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(2, 1fr);
|
||||||
|
gap: 0.8rem;
|
||||||
|
margin-top: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.finish-link {
|
||||||
|
background: var(--button-secondaryFill);
|
||||||
|
border: 2px solid transparent;
|
||||||
|
border-radius: 10px;
|
||||||
|
padding: 1rem;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.8rem;
|
||||||
|
text-decoration: none;
|
||||||
|
color: var(--text-primary);
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.finish-link:hover {
|
||||||
|
border-color: var(--accent-accent);
|
||||||
|
background: var(--accent-15);
|
||||||
|
transform: translateY(-2px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.finish-link .material-icons-round {
|
||||||
|
font-size: 2rem;
|
||||||
|
color: var(--accent-accent);
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.link-content {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 0.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.link-title {
|
||||||
|
font-weight: 600;
|
||||||
|
font-size: 1rem;
|
||||||
|
color: var(--text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.link-description {
|
||||||
|
font-size: 0.8rem;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-actions {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
margin-top: 2rem;
|
||||||
|
gap: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.actions-spacer {
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-primary,
|
||||||
|
.btn-secondary {
|
||||||
|
padding: 1rem 2rem;
|
||||||
|
border-radius: 12px;
|
||||||
|
font-weight: 600;
|
||||||
|
font-size: 1rem;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: all 0.3s ease;
|
||||||
|
border: none;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.5rem;
|
||||||
|
font-family: 'Montserrat', sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-primary {
|
||||||
|
background: var(--accent-accent);
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-primary:hover {
|
||||||
|
background: var(--accent-secondary);
|
||||||
|
transform: translateY(-2px);
|
||||||
|
box-shadow: 0 4px 12px var(--accent-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-secondary {
|
||||||
|
background: var(--button-secondaryFill);
|
||||||
|
color: var(--text-primary);
|
||||||
|
border: 2px solid var(--text-teritary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-secondary:hover {
|
||||||
|
border-color: var(--accent-accent);
|
||||||
|
transform: translateY(-2px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-primary .material-icons-round,
|
||||||
|
.btn-secondary .material-icons-round {
|
||||||
|
font-size: 1.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 768px) {
|
||||||
|
body {
|
||||||
|
padding: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-card {
|
||||||
|
padding: 1.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.setup-title {
|
||||||
|
font-size: 1.75rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.step-title {
|
||||||
|
font-size: 1.3rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-bar {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-line {
|
||||||
|
width: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.progress-circle {
|
||||||
|
width: 36px;
|
||||||
|
height: 36px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-options,
|
||||||
|
.language-options {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
}
|
||||||
|
|
||||||
|
.finish-links {
|
||||||
|
grid-template-columns: 1fr;
|
||||||
|
}
|
||||||
|
}
|
||||||
159
setup/setup.html
Normal file
@@ -0,0 +1,159 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="hu">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<title>Firxa - Kezdeti beállítások</title>
|
||||||
|
<link rel="icon" type="image/png" href="../images/firka_logo_128.png">
|
||||||
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||||
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||||
|
<link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap" rel="stylesheet">
|
||||||
|
<link href="https://fonts.googleapis.com/icon?family=Material+Icons+Round" rel="stylesheet">
|
||||||
|
<link rel="stylesheet" href="setup.css">
|
||||||
|
<link rel="stylesheet" href="../global/theme.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div class="setup-container">
|
||||||
|
<div class="setup-card">
|
||||||
|
<div class="setup-header">
|
||||||
|
<img src="../images/firka_logo.png" alt="Firka" class="setup-logo">
|
||||||
|
<h1 class="setup-title">Üdvözöl a Firxa!</h1>
|
||||||
|
<p class="setup-subtitle" data-i18n="setup.welcome">Állítsd be a bővítményt néhány egyszerű lépésben</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="progress-bar">
|
||||||
|
<div class="progress-step active" data-step="1">
|
||||||
|
<div class="progress-circle">1</div>
|
||||||
|
<span class="progress-label" data-i18n="setup.steps.theme">Téma</span>
|
||||||
|
</div>
|
||||||
|
<div class="progress-line"></div>
|
||||||
|
<div class="progress-step" data-step="2">
|
||||||
|
<div class="progress-circle">2</div>
|
||||||
|
<span class="progress-label" data-i18n="setup.steps.language">Nyelv</span>
|
||||||
|
</div>
|
||||||
|
<div class="progress-line"></div>
|
||||||
|
<div class="progress-step" data-step="3">
|
||||||
|
<div class="progress-circle">3</div>
|
||||||
|
<span class="progress-label" data-i18n="setup.steps.finish">Kész</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="setup-content">
|
||||||
|
<div class="setup-step active" data-step="1">
|
||||||
|
<div class="step-icon">
|
||||||
|
<span class="material-icons-round">palette</span>
|
||||||
|
</div>
|
||||||
|
<h2 class="step-title" data-i18n="setup.theme.title">Válassz témát</h2>
|
||||||
|
<p class="step-description" data-i18n="setup.theme.description">Válaszd ki a számodra legmegfelelőbb megjelenést</p>
|
||||||
|
|
||||||
|
<div class="theme-options">
|
||||||
|
<button class="theme-card" data-theme="light-green">
|
||||||
|
<div class="theme-preview light-green">
|
||||||
|
<div class="preview-header"></div>
|
||||||
|
<div class="preview-content">
|
||||||
|
<div class="preview-card"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<span class="theme-name" data-i18n="settings.themes.light_green">Világos Zöld</span>
|
||||||
|
<span class="theme-icon material-icons-round">light_mode</span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<button class="theme-card" data-theme="dark-green">
|
||||||
|
<div class="theme-preview dark-green">
|
||||||
|
<div class="preview-header"></div>
|
||||||
|
<div class="preview-content">
|
||||||
|
<div class="preview-card"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<span class="theme-name" data-i18n="settings.themes.dark_green">Sötét Zöld</span>
|
||||||
|
<span class="theme-icon material-icons-round">dark_mode</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="setup-step" data-step="2">
|
||||||
|
<div class="step-icon">
|
||||||
|
<span class="material-icons-round">language</span>
|
||||||
|
</div>
|
||||||
|
<h2 class="step-title" data-i18n="setup.language.title">Válassz nyelvet</h2>
|
||||||
|
<p class="step-description" data-i18n="setup.language.description">Válaszd ki a használni kívánt nyelvet</p>
|
||||||
|
|
||||||
|
<div class="language-options">
|
||||||
|
<button class="language-card" data-language="hu">
|
||||||
|
<span class="language-flag">🇭🇺</span>
|
||||||
|
<span class="language-name" data-i18n="settings.languages.hu">Magyar</span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<button class="language-card" data-language="en">
|
||||||
|
<span class="language-flag">🇬🇧</span>
|
||||||
|
<span class="language-name" data-i18n="settings.languages.en">English</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="setup-step" data-step="3">
|
||||||
|
<div class="step-icon success">
|
||||||
|
<span class="material-icons-round">check_circle</span>
|
||||||
|
</div>
|
||||||
|
<h2 class="step-title" data-i18n="setup.finish.title">Minden kész!</h2>
|
||||||
|
<p class="step-description" data-i18n="setup.finish.description">A beállítások sikeresen mentve. Indulhat a tanulás!</p>
|
||||||
|
|
||||||
|
<div class="finish-links">
|
||||||
|
<a href="https://firka.app" target="_blank" class="finish-link">
|
||||||
|
<span class="material-icons-round">info</span>
|
||||||
|
<div class="link-content">
|
||||||
|
<span class="link-title" data-i18n="setup.finish.about">Weboldal</span>
|
||||||
|
<span class="link-description" data-i18n="setup.finish.about_desc">Tudj meg többet a projektről</span>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="https://ko-fi.com/zan1456" target="_blank" class="finish-link">
|
||||||
|
<span class="material-icons-round">favorite</span>
|
||||||
|
<div class="link-content">
|
||||||
|
<span class="link-title" data-i18n="setup.finish.support">Támogatás</span>
|
||||||
|
<span class="link-description" data-i18n="setup.finish.support_desc">Támogasd a fejlesztést</span>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="https://github.com/QwIT-Development/" target="_blank" class="finish-link">
|
||||||
|
<span class="material-icons-round">code</span>
|
||||||
|
<div class="link-content">
|
||||||
|
<span class="link-title" data-i18n="setup.finish.github">GitHub</span>
|
||||||
|
<span class="link-description" data-i18n="setup.finish.github_desc">Nézd meg a forráskódot</span>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="https://discord.gg/firka-1111649116020285532" target="_blank" class="finish-link">
|
||||||
|
<span class="material-icons-round">forum</span>
|
||||||
|
<div class="link-content">
|
||||||
|
<span class="link-title" data-i18n="setup.finish.discord">Discord</span>
|
||||||
|
<span class="link-description" data-i18n="setup.finish.discord_desc">Csatlakozz a közösséghez</span>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="setup-actions">
|
||||||
|
<button class="btn-secondary" id="backBtn" style="display: none;">
|
||||||
|
<span class="material-icons-round">arrow_back</span>
|
||||||
|
<span data-i18n="common.back">Vissza</span>
|
||||||
|
</button>
|
||||||
|
<div class="actions-spacer"></div>
|
||||||
|
<button class="btn-primary" id="nextBtn">
|
||||||
|
<span data-i18n="common.next">Tovább</span>
|
||||||
|
<span class="material-icons-round">arrow_forward</span>
|
||||||
|
</button>
|
||||||
|
<button class="btn-primary" id="finishBtn" style="display: none;">
|
||||||
|
<span data-i18n="setup.finish.start">Kezdés</span>
|
||||||
|
<span class="material-icons-round">check</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script src="../tools/storageManager.js"></script>
|
||||||
|
<script src="../global/language.js"></script>
|
||||||
|
<script src="setup.js"></script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
146
setup/setup.js
Normal file
@@ -0,0 +1,146 @@
|
|||||||
|
let currentStep = 1;
|
||||||
|
const totalSteps = 3;
|
||||||
|
let selectedTheme = 'light-green';
|
||||||
|
let selectedLanguage = 'hu';
|
||||||
|
|
||||||
|
document.addEventListener('DOMContentLoaded', async () => {
|
||||||
|
selectedTheme = await storageManager.get('themePreference', 'light-green');
|
||||||
|
selectedLanguage = await storageManager.get('languagePreference', 'hu');
|
||||||
|
|
||||||
|
initializeThemeSelection();
|
||||||
|
initializeLanguageSelection();
|
||||||
|
|
||||||
|
document.getElementById('nextBtn').addEventListener('click', nextStep);
|
||||||
|
document.getElementById('backBtn').addEventListener('click', previousStep);
|
||||||
|
document.getElementById('finishBtn').addEventListener('click', finishSetup);
|
||||||
|
|
||||||
|
document.querySelectorAll('.theme-card').forEach(card => {
|
||||||
|
card.addEventListener('click', () => selectTheme(card.dataset.theme));
|
||||||
|
});
|
||||||
|
|
||||||
|
document.querySelectorAll('.language-card').forEach(card => {
|
||||||
|
card.addEventListener('click', () => selectLanguage(card.dataset.language));
|
||||||
|
});
|
||||||
|
|
||||||
|
applyTheme(selectedTheme);
|
||||||
|
});
|
||||||
|
|
||||||
|
function initializeThemeSelection() {
|
||||||
|
const themeCards = document.querySelectorAll('.theme-card');
|
||||||
|
themeCards.forEach(card => {
|
||||||
|
if (card.dataset.theme === selectedTheme) {
|
||||||
|
card.classList.add('selected');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function initializeLanguageSelection() {
|
||||||
|
const languageCards = document.querySelectorAll('.language-card');
|
||||||
|
languageCards.forEach(card => {
|
||||||
|
if (card.dataset.language === selectedLanguage) {
|
||||||
|
card.classList.add('selected');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function selectTheme(theme) {
|
||||||
|
selectedTheme = theme;
|
||||||
|
|
||||||
|
document.querySelectorAll('.theme-card').forEach(card => {
|
||||||
|
card.classList.remove('selected');
|
||||||
|
});
|
||||||
|
|
||||||
|
document.querySelector(`[data-theme="${theme}"]`).classList.add('selected');
|
||||||
|
|
||||||
|
applyTheme(theme);
|
||||||
|
}
|
||||||
|
|
||||||
|
function selectLanguage(language) {
|
||||||
|
selectedLanguage = language;
|
||||||
|
|
||||||
|
document.querySelectorAll('.language-card').forEach(card => {
|
||||||
|
card.classList.remove('selected');
|
||||||
|
});
|
||||||
|
document.querySelector(`[data-language="${language}"]`).classList.add('selected');
|
||||||
|
}
|
||||||
|
|
||||||
|
function applyTheme(theme) {
|
||||||
|
document.documentElement.setAttribute('data-theme', theme);
|
||||||
|
}
|
||||||
|
|
||||||
|
function nextStep() {
|
||||||
|
if (currentStep < totalSteps) {
|
||||||
|
saveCurrentStepSettings();
|
||||||
|
|
||||||
|
currentStep++;
|
||||||
|
updateStepDisplay();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function previousStep() {
|
||||||
|
if (currentStep > 1) {
|
||||||
|
currentStep--;
|
||||||
|
updateStepDisplay();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
async function saveCurrentStepSettings() {
|
||||||
|
if (currentStep === 1) {
|
||||||
|
await storageManager.set('themePreference', selectedTheme);
|
||||||
|
} else if (currentStep === 2) {
|
||||||
|
await storageManager.set('language', selectedLanguage);
|
||||||
|
await storageManager.set('languagePreference', selectedLanguage);
|
||||||
|
if (window.LanguageManager) {
|
||||||
|
await window.LanguageManager.changeLanguage(selectedLanguage);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function updateStepDisplay() {
|
||||||
|
document.querySelectorAll('.progress-step').forEach(step => {
|
||||||
|
const stepNumber = parseInt(step.dataset.step);
|
||||||
|
if (stepNumber < currentStep) {
|
||||||
|
step.classList.add('completed');
|
||||||
|
step.classList.remove('active');
|
||||||
|
} else if (stepNumber === currentStep) {
|
||||||
|
step.classList.add('active');
|
||||||
|
step.classList.remove('completed');
|
||||||
|
} else {
|
||||||
|
step.classList.remove('active', 'completed');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
document.querySelectorAll('.setup-step').forEach(step => {
|
||||||
|
if (parseInt(step.dataset.step) === currentStep) {
|
||||||
|
step.classList.add('active');
|
||||||
|
} else {
|
||||||
|
step.classList.remove('active');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
const backBtn = document.getElementById('backBtn');
|
||||||
|
const nextBtn = document.getElementById('nextBtn');
|
||||||
|
const finishBtn = document.getElementById('finishBtn');
|
||||||
|
|
||||||
|
if (currentStep === 1) {
|
||||||
|
backBtn.style.display = 'none';
|
||||||
|
} else {
|
||||||
|
backBtn.style.display = 'flex';
|
||||||
|
}
|
||||||
|
|
||||||
|
if (currentStep === totalSteps) {
|
||||||
|
nextBtn.style.display = 'none';
|
||||||
|
finishBtn.style.display = 'flex';
|
||||||
|
} else {
|
||||||
|
nextBtn.style.display = 'flex';
|
||||||
|
finishBtn.style.display = 'none';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
async function finishSetup() {
|
||||||
|
await saveCurrentStepSettings();
|
||||||
|
|
||||||
|
await storageManager.set('setupCompleted', true);
|
||||||
|
|
||||||
|
window.location.href = 'https://intezmenykereso.e-kreta.hu/';
|
||||||
|
}
|
||||||
@@ -21,128 +21,6 @@ body {
|
|||||||
display:flex;
|
display:flex;
|
||||||
flex-direction:column;
|
flex-direction:column;
|
||||||
}
|
}
|
||||||
.kreta-header {
|
|
||||||
padding:clamp(1rem,3vw,2rem);
|
|
||||||
display:grid;
|
|
||||||
grid-template-columns:minmax(300px,400px) 1fr minmax(200px,300px);
|
|
||||||
align-items:center;
|
|
||||||
gap:1rem;
|
|
||||||
}
|
|
||||||
@media (max-width:1200px) {
|
|
||||||
.kreta-header {
|
|
||||||
grid-template-columns:minmax(250px,350px) 1fr minmax(180px,250px);
|
|
||||||
}
|
|
||||||
}@media (max-width:768px) {
|
|
||||||
.kreta-header {
|
|
||||||
grid-template-columns:1fr auto auto;
|
|
||||||
grid-template-areas:"school toggle user"
|
|
||||||
"nav nav nav";
|
|
||||||
padding:1rem;
|
|
||||||
gap:0.5rem;
|
|
||||||
}
|
|
||||||
}.school-info {
|
|
||||||
margin:0;
|
|
||||||
}
|
|
||||||
@media (max-width:768px) {
|
|
||||||
.school-info {
|
|
||||||
grid-area:school;
|
|
||||||
max-width:none;
|
|
||||||
display:flex;
|
|
||||||
align-items:center;
|
|
||||||
gap:0.5rem;
|
|
||||||
}
|
|
||||||
}.logo-text {
|
|
||||||
color:var(--text-primary);
|
|
||||||
font-size:24px;
|
|
||||||
font-weight:600;
|
|
||||||
margin:0 0 0.5rem;
|
|
||||||
display:flex;
|
|
||||||
align-items:center;
|
|
||||||
}
|
|
||||||
@media (max-width:768px) {
|
|
||||||
.logo-text {
|
|
||||||
margin:0;
|
|
||||||
font-size:20px;
|
|
||||||
}
|
|
||||||
}.logo {
|
|
||||||
width:24px;
|
|
||||||
border-radius:8px;
|
|
||||||
margin-right:0.5rem;
|
|
||||||
}
|
|
||||||
.school-details {
|
|
||||||
color:var(--text-secondary);
|
|
||||||
font-size:14px;
|
|
||||||
}
|
|
||||||
.school-details span {
|
|
||||||
display:block;
|
|
||||||
white-space:nowrap;
|
|
||||||
overflow:hidden;
|
|
||||||
text-overflow:ellipsis;
|
|
||||||
max-width:300px;
|
|
||||||
}
|
|
||||||
@media (max-width:768px) {
|
|
||||||
.school-details span {
|
|
||||||
max-width:200px;
|
|
||||||
}
|
|
||||||
.school-details {
|
|
||||||
font-size:12px;
|
|
||||||
}
|
|
||||||
}.user-profile {
|
|
||||||
position:relative;
|
|
||||||
justify-self:flex-end;
|
|
||||||
}
|
|
||||||
@media (max-width:768px) {
|
|
||||||
.user-profile {
|
|
||||||
grid-area:user;
|
|
||||||
}
|
|
||||||
}.user-dropdown-btn {
|
|
||||||
display:flex;
|
|
||||||
align-items:center;
|
|
||||||
gap:1rem;
|
|
||||||
background:none;
|
|
||||||
border:none;
|
|
||||||
cursor:pointer;
|
|
||||||
padding:0.5rem;
|
|
||||||
border-radius:8px;
|
|
||||||
transition:background-color 0.2s;
|
|
||||||
}
|
|
||||||
.user-dropdown-btn:hover {
|
|
||||||
background:var(--hover);
|
|
||||||
}
|
|
||||||
.user-info {
|
|
||||||
text-align:right;
|
|
||||||
}
|
|
||||||
.user-dropdown {
|
|
||||||
position:absolute;
|
|
||||||
top:100%;
|
|
||||||
right:0;
|
|
||||||
margin-top:0.5rem;
|
|
||||||
background:var(--card-card);
|
|
||||||
border-radius:12px;
|
|
||||||
box-shadow:0 4px 6px -1px rgba(0,0,0,0.1);
|
|
||||||
width:200px;
|
|
||||||
display:none;
|
|
||||||
z-index:1000;
|
|
||||||
}
|
|
||||||
.user-dropdown.show {
|
|
||||||
display:block;
|
|
||||||
animation:dropdownShow 0.2s ease;
|
|
||||||
}
|
|
||||||
.dropdown-item {
|
|
||||||
display:flex;
|
|
||||||
align-items:center;
|
|
||||||
gap:0.75rem;
|
|
||||||
padding:0.75rem 1rem;
|
|
||||||
color:var(--text-primary);
|
|
||||||
text-decoration:none;
|
|
||||||
transition:background-color 0.2s;
|
|
||||||
}
|
|
||||||
.dropdown-item:hover {
|
|
||||||
background:var(--hover);
|
|
||||||
color:var(--accent-accent);
|
|
||||||
border-radius:8px;
|
|
||||||
text-decoration:none;
|
|
||||||
}
|
|
||||||
.kreta-main {
|
.kreta-main {
|
||||||
flex:1;
|
flex:1;
|
||||||
padding:clamp(1rem,3vw,2rem);
|
padding:clamp(1rem,3vw,2rem);
|
||||||
@@ -269,7 +147,8 @@ body {
|
|||||||
transition:all 0.3s cubic-bezier(0.4,0,0.2,1);
|
transition:all 0.3s cubic-bezier(0.4,0,0.2,1);
|
||||||
transform:translateY(0);
|
transform:translateY(0);
|
||||||
}
|
}
|
||||||
.lesson-card:hover {
|
.lesson-card:hover,
|
||||||
|
.lesson-card.group-hover {
|
||||||
transform:translateY(-4px);
|
transform:translateY(-4px);
|
||||||
box-shadow:0 8px 12px var(--accent-shadow);
|
box-shadow:0 8px 12px var(--accent-shadow);
|
||||||
}
|
}
|
||||||
@@ -284,6 +163,28 @@ body {
|
|||||||
opacity:0.5;
|
opacity:0.5;
|
||||||
text-decoration:line-through;
|
text-decoration:line-through;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.lesson-card.lesson-spans-multiple {
|
||||||
|
border-bottom-left-radius: 0;
|
||||||
|
border-bottom-right-radius: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.lesson-card.lesson-continuation.continuation-middle {
|
||||||
|
border-radius: 0;
|
||||||
|
}
|
||||||
|
.lesson-card.lesson-continuation.continuation-end {
|
||||||
|
border-top-left-radius: 0;
|
||||||
|
border-top-right-radius: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.lesson-slot.has-multi-start {
|
||||||
|
padding-bottom: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.lesson-slot.has-continuation {
|
||||||
|
padding-top: 0;
|
||||||
|
}
|
||||||
|
|
||||||
.lesson-subject {
|
.lesson-subject {
|
||||||
align-self:stretch;
|
align-self:stretch;
|
||||||
color:var(--text-primary);
|
color:var(--text-primary);
|
||||||
@@ -431,8 +332,8 @@ body {
|
|||||||
flex-direction:column;
|
flex-direction:column;
|
||||||
align-items:center;
|
align-items:center;
|
||||||
justify-content:center;
|
justify-content:center;
|
||||||
width:60px;
|
width:40px;
|
||||||
height:50px;
|
height:40px;
|
||||||
border:2px solid var(--button-secondaryFill);
|
border:2px solid var(--button-secondaryFill);
|
||||||
border-radius:8px;
|
border-radius:8px;
|
||||||
background:var(--button-secondaryFill);
|
background:var(--button-secondaryFill);
|
||||||
@@ -513,7 +414,7 @@ body {
|
|||||||
.week-modal-content {
|
.week-modal-content {
|
||||||
background:var(--card-card);
|
background:var(--card-card);
|
||||||
border-radius:16px;
|
border-radius:16px;
|
||||||
max-width:1000px;
|
max-width:700px;
|
||||||
max-height:70vh;
|
max-height:70vh;
|
||||||
width:100%;
|
width:100%;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
@@ -531,12 +432,11 @@ body {
|
|||||||
grid-template-columns:repeat(13,1fr);
|
grid-template-columns:repeat(13,1fr);
|
||||||
gap:8px;
|
gap:8px;
|
||||||
padding:20px;
|
padding:20px;
|
||||||
max-height:calc(70vh - 80px);
|
|
||||||
overflow-y:auto;
|
overflow-y:auto;
|
||||||
}
|
}
|
||||||
.modal-week-cell {
|
.modal-week-cell {
|
||||||
width:40px;
|
width:60px;
|
||||||
height:40px;
|
height:60px;
|
||||||
font-size:12px;
|
font-size:12px;
|
||||||
}
|
}
|
||||||
@media (max-width:768px) {
|
@media (max-width:768px) {
|
||||||
@@ -583,29 +483,26 @@ body {
|
|||||||
}
|
}
|
||||||
.week-modal-grid {
|
.week-modal-grid {
|
||||||
display:grid;
|
display:grid;
|
||||||
grid-template-columns:repeat(13,1fr);
|
grid-template-columns:repeat(auto-fill, 60px);
|
||||||
gap:8px;
|
gap:4px;
|
||||||
padding:24px;
|
padding:24px;
|
||||||
max-height:70vh;
|
max-height:70vh;
|
||||||
overflow-y:auto;
|
overflow-y:auto;
|
||||||
|
justify-content:center;
|
||||||
}
|
}
|
||||||
.week-modal-grid .week-cell {
|
.week-modal-grid .week-cell {
|
||||||
width:60px;
|
width:60px;
|
||||||
height:50px;
|
height:60px;
|
||||||
font-size:14px;
|
font-size:14px;
|
||||||
}
|
}
|
||||||
@media (max-width:1200px) {
|
@media (max-width:768px) {
|
||||||
.week-modal-grid {
|
.week-modal-grid {
|
||||||
grid-template-columns:repeat(10,1fr);
|
grid-template-columns:repeat(auto-fill, 40px);
|
||||||
}
|
gap:4px;
|
||||||
}@media (max-width:768px) {
|
|
||||||
.week-modal-grid {
|
|
||||||
grid-template-columns:repeat(7,1fr);
|
|
||||||
gap:6px;
|
|
||||||
}
|
}
|
||||||
.week-modal-grid .week-cell {
|
.week-modal-grid .week-cell {
|
||||||
width:50px;
|
width:40px;
|
||||||
height:45px;
|
height:40px;
|
||||||
font-size:12px;
|
font-size:12px;
|
||||||
}
|
}
|
||||||
.week-modal-content {
|
.week-modal-content {
|
||||||
@@ -615,7 +512,7 @@ body {
|
|||||||
padding:16px 20px;
|
padding:16px 20px;
|
||||||
}
|
}
|
||||||
.week-modal-grid {
|
.week-modal-grid {
|
||||||
padding:20px;
|
padding:16px;
|
||||||
}
|
}
|
||||||
}@media (max-width:768px) {
|
}@media (max-width:768px) {
|
||||||
.week-grid {
|
.week-grid {
|
||||||
@@ -637,8 +534,8 @@ body {
|
|||||||
gap:4px;
|
gap:4px;
|
||||||
}
|
}
|
||||||
.week-cell {
|
.week-cell {
|
||||||
width:35px;
|
width:40px;
|
||||||
height:30px;
|
height:40px;
|
||||||
font-size:11px;
|
font-size:11px;
|
||||||
}
|
}
|
||||||
.week-controls {
|
.week-controls {
|
||||||
@@ -654,7 +551,7 @@ body {
|
|||||||
}
|
}
|
||||||
.day-nav-btn {
|
.day-nav-btn {
|
||||||
background:var(--card-card);
|
background:var(--card-card);
|
||||||
border:1px solid var(--accent-15);
|
box-shadow: 0px 1px var(--shadow-blur, 2px) 0px var(--accent-shadow);
|
||||||
border-radius:12px;
|
border-radius:12px;
|
||||||
padding:12px 16px;
|
padding:12px 16px;
|
||||||
color:var(--text-secondary);
|
color:var(--text-secondary);
|
||||||
@@ -663,6 +560,7 @@ body {
|
|||||||
display:flex;
|
display:flex;
|
||||||
align-items:center;
|
align-items:center;
|
||||||
gap:8px;
|
gap:8px;
|
||||||
|
border: #00000000 0px solid;
|
||||||
}
|
}
|
||||||
.day-nav-btn:hover {
|
.day-nav-btn:hover {
|
||||||
background:var(--accent-15);
|
background:var(--accent-15);
|
||||||
@@ -695,7 +593,10 @@ body {
|
|||||||
display:flex;
|
display:flex;
|
||||||
}
|
}
|
||||||
.timetable-container {
|
.timetable-container {
|
||||||
overflow:hidden;
|
overflow: hidden;
|
||||||
|
flex: 1;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
}
|
}
|
||||||
.timetable-grid {
|
.timetable-grid {
|
||||||
grid-template-columns:60px 1fr;
|
grid-template-columns:60px 1fr;
|
||||||
@@ -1535,3 +1436,331 @@ to {
|
|||||||
transition:gap 0.2s ease;
|
transition:gap 0.2s ease;
|
||||||
font-size:clamp(0.875rem,1.5vw,1rem);
|
font-size:clamp(0.875rem,1.5vw,1rem);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.timetable-calendar {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
background: var(--card-card);
|
||||||
|
border-radius: 16px;
|
||||||
|
overflow: hidden;
|
||||||
|
box-shadow: 0px 1px 2px 0px var(--accent-shadow);
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-header {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 80px repeat(5, 1fr);
|
||||||
|
background: var(--background-0);
|
||||||
|
border-bottom: 1px solid var(--background-0);
|
||||||
|
padding: 0;
|
||||||
|
gap: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-column-header {
|
||||||
|
padding: 12px;
|
||||||
|
border-right: 1px solid var(--background-0);
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-header {
|
||||||
|
padding: 12px;
|
||||||
|
border-right: 1px solid var(--background-0);
|
||||||
|
text-align: center;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
gap: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-header:last-child {
|
||||||
|
border-right: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-header .day-name {
|
||||||
|
font-weight: 600;
|
||||||
|
color: var(--text-primary);
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-header .day-date {
|
||||||
|
color: var(--text-secondary);
|
||||||
|
font-size: 12px;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-notices {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 80px repeat(5, 1fr);
|
||||||
|
border-bottom: 1px solid var(--background-0);
|
||||||
|
padding: 0;
|
||||||
|
gap: 0;
|
||||||
|
background: var(--background);
|
||||||
|
}
|
||||||
|
|
||||||
|
.notices-time-column {
|
||||||
|
border-right: 1px solid var(--background-0);
|
||||||
|
}
|
||||||
|
|
||||||
|
.notice-day-slot {
|
||||||
|
padding: 8px;
|
||||||
|
border-right: 1px solid var(--background-0);
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
min-height: 60px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.notice-day-slot:last-child {
|
||||||
|
border-right: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.notice-day-slot .special-day-notice {
|
||||||
|
width: 100%;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-grid {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: 80px repeat(5, 1fr);
|
||||||
|
gap: 0;
|
||||||
|
background: var(--background);
|
||||||
|
position: relative;
|
||||||
|
flex: 1;
|
||||||
|
min-height: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-column {
|
||||||
|
border-right: 1px solid var(--background-0);
|
||||||
|
background: var(--background-0);
|
||||||
|
position: sticky;
|
||||||
|
left: 0;
|
||||||
|
z-index: 10;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-marker {
|
||||||
|
padding: 8px;
|
||||||
|
text-align: center;
|
||||||
|
font-size: 12px;
|
||||||
|
font-weight: 500;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
border-bottom: 1px solid var(--background);
|
||||||
|
display: flex;
|
||||||
|
align-items: flex-start;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-marker:last-child {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-column {
|
||||||
|
position: relative;
|
||||||
|
border-right: 1px solid var(--background-0);
|
||||||
|
background: var(--background);
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-column:last-child {
|
||||||
|
border-right: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.day-background {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
pointer-events: none;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-slot-bg {
|
||||||
|
border-bottom: 1px solid var(--background-0);
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-slot-bg:last-child {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.lessons-container {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card {
|
||||||
|
position: absolute;
|
||||||
|
left: 4px;
|
||||||
|
right: 4px;
|
||||||
|
width: calc(100% - 8px);
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
padding: 10px;
|
||||||
|
border-radius: 12px;
|
||||||
|
background: var(--card-card);
|
||||||
|
box-shadow: 0px 1px 2px 0px var(--accent-shadow);
|
||||||
|
border: 1px solid var(--background-0);
|
||||||
|
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
||||||
|
cursor: pointer;
|
||||||
|
overflow: hidden;
|
||||||
|
z-index: 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card:hover {
|
||||||
|
transform: translateY(-2px);
|
||||||
|
box-shadow: 0 4px 8px var(--accent-shadow);
|
||||||
|
z-index: 5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card.substituted {
|
||||||
|
background: var(--warning-card);
|
||||||
|
border-color: var(--warning-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card.cancelled {
|
||||||
|
background: var(--card-translucent);
|
||||||
|
opacity: 0.6;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card.cancelled .lesson-subject,
|
||||||
|
.calendar-lesson-card.cancelled .lesson-teacher,
|
||||||
|
.calendar-lesson-card.cancelled .lesson-time-info {
|
||||||
|
opacity: 0.5;
|
||||||
|
text-decoration: line-through;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-subject {
|
||||||
|
font-weight: 600;
|
||||||
|
font-size: 13px;
|
||||||
|
color: var(--text-primary);
|
||||||
|
line-height: 1.2;
|
||||||
|
margin-bottom: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-teacher {
|
||||||
|
font-size: 11px;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
margin-bottom: 4px;
|
||||||
|
line-height: 1.2;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-time-info {
|
||||||
|
font-size: 11px;
|
||||||
|
color: var(--text-secondary);
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
gap: 4px;
|
||||||
|
margin-top: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-room {
|
||||||
|
background: var(--accent-15);
|
||||||
|
padding: 2px 6px;
|
||||||
|
border-radius: 8px;
|
||||||
|
font-size: 10px;
|
||||||
|
font-weight: 500;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card.substituted .lesson-room {
|
||||||
|
background: var(--warning-15);
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-time {
|
||||||
|
font-weight: 500;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-indicators {
|
||||||
|
position: absolute;
|
||||||
|
top: 4px;
|
||||||
|
right: 4px;
|
||||||
|
display: flex;
|
||||||
|
gap: 2px;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-indicator {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
border-radius: 50%;
|
||||||
|
background: var(--accent-15);
|
||||||
|
color: var(--accent-accent);
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-indicator.test-indicator {
|
||||||
|
background: var(--warning-15);
|
||||||
|
color: var(--warning-accent);
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-indicator.custom-homework-indicator,
|
||||||
|
.calendar-lesson-card .lesson-indicator.custom-test-indicator {
|
||||||
|
background: rgba(0, 0, 0, 0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (max-width: 768px) {
|
||||||
|
.calendar-grid {
|
||||||
|
grid-template-columns: 60px repeat(5, 1fr);
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-column-header {
|
||||||
|
padding: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-header {
|
||||||
|
padding: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-header .day-name {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-day-header .day-date {
|
||||||
|
font-size: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-marker {
|
||||||
|
padding: 4px;
|
||||||
|
font-size: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card {
|
||||||
|
padding: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-subject {
|
||||||
|
font-size: 11px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-teacher {
|
||||||
|
font-size: 9px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-time-info {
|
||||||
|
font-size: 9px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-indicator {
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.calendar-lesson-card .lesson-indicator img {
|
||||||
|
width: 14px !important;
|
||||||
|
height: 14px !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -160,7 +160,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
function getLessonKey(lesson) {
|
function getLessonKey(lesson) {
|
||||||
return `${lesson.subject}_${lesson.startTime}_${lesson.day}`;
|
return `${lesson.subject}_${lesson.startTime}_${lesson.date}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
async function updateHomeworkIconsFromCookie() {
|
async function updateHomeworkIconsFromCookie() {
|
||||||
@@ -197,8 +197,9 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
const htmlText = await response.text();
|
const htmlText = await response.text();
|
||||||
const parser = new DOMParser();
|
const template = document.createElement('template');
|
||||||
const doc = parser.parseFromString(htmlText, 'text/html');
|
template.innerHTML = htmlText;
|
||||||
|
const doc = template.content;
|
||||||
const panelBody = doc.querySelector('.panel-body');
|
const panelBody = doc.querySelector('.panel-body');
|
||||||
const panelFooter = doc.querySelector('.panel-footer');
|
const panelFooter = doc.querySelector('.panel-footer');
|
||||||
const teacherInfo = doc.querySelector('.panel-heading');
|
const teacherInfo = doc.querySelector('.panel-heading');
|
||||||
@@ -312,7 +313,16 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async function loadTestDetailsFromAPI(testId) {
|
let cachedTestData = null;
|
||||||
|
let testDataTimestamp = 0;
|
||||||
|
const TEST_DATA_CACHE_DURATION = 60000;
|
||||||
|
|
||||||
|
async function loadAllTestDataFromAPI() {
|
||||||
|
const now = Date.now();
|
||||||
|
if (cachedTestData && (now - testDataTimestamp) < TEST_DATA_CACHE_DURATION) {
|
||||||
|
return cachedTestData;
|
||||||
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const timestamp = Date.now();
|
const timestamp = Date.now();
|
||||||
const apiUrl = `https://${window.location.hostname}/api/TanuloBejelentettSzamonkeresekApi/GetBejelentettSzamonkeresekGrid?sort=SzamonkeresDatuma-asc~Oraszam-asc&page=1&pageSize=1000&group=&filter=&data=%7B%22RegiSzamonkeresekElrejtese%22%3Afalse%7D&_=${timestamp}`;
|
const apiUrl = `https://${window.location.hostname}/api/TanuloBejelentettSzamonkeresekApi/GetBejelentettSzamonkeresekGrid?sort=SzamonkeresDatuma-asc~Oraszam-asc&page=1&pageSize=1000&group=&filter=&data=%7B%22RegiSzamonkeresekElrejtese%22%3Afalse%7D&_=${timestamp}`;
|
||||||
@@ -326,15 +336,30 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
if (!response.ok) {
|
if (!response.ok) {
|
||||||
throw new Error(
|
throw new Error(`Számonkérés API hiba: ${response.status}`);
|
||||||
`Számonkérés API hiba: ${response.status}`,
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const data = await response.json();
|
const data = await response.json();
|
||||||
const testData = data.Data || [];
|
cachedTestData = data.Data || [];
|
||||||
|
testDataTimestamp = now;
|
||||||
|
return cachedTestData;
|
||||||
|
} catch (error) {
|
||||||
|
console.error("Számonkérés adatok betöltési hiba:", error);
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
async function getTestTypeById(testId) {
|
||||||
|
const testData = await loadAllTestDataFromAPI();
|
||||||
|
const testDetail = testData.find(test => test.ID === testId.toString());
|
||||||
|
return testDetail ? testDetail.ErtekelesModNev : null;
|
||||||
|
}
|
||||||
|
|
||||||
|
async function loadTestDetailsFromAPI(testId) {
|
||||||
|
try {
|
||||||
|
const testData = await loadAllTestDataFromAPI();
|
||||||
const testDetail = testData.find(test => test.ID === testId.toString());
|
const testDetail = testData.find(test => test.ID === testId.toString());
|
||||||
|
|
||||||
if (testDetail) {
|
if (testDetail) {
|
||||||
return {
|
return {
|
||||||
name: testDetail.SzamonkeresMegnevezes || 'Nincs megnevezés',
|
name: testDetail.SzamonkeresMegnevezes || 'Nincs megnevezés',
|
||||||
@@ -342,7 +367,7 @@
|
|||||||
announceDate: testDetail.BejelentesDatuma ? new Date(testDetail.BejelentesDatuma).toLocaleDateString('hu-HU') : 'Nincs dátum'
|
announceDate: testDetail.BejelentesDatuma ? new Date(testDetail.BejelentesDatuma).toLocaleDateString('hu-HU') : 'Nincs dátum'
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error("Számonkérés adatok betöltési hiba:", error);
|
console.error("Számonkérés adatok betöltési hiba:", error);
|
||||||
@@ -409,6 +434,7 @@
|
|||||||
originalTeacher: "",
|
originalTeacher: "",
|
||||||
room: "",
|
room: "",
|
||||||
day: dayIndex,
|
day: dayIndex,
|
||||||
|
date: weekDates[dayIndex]?.fullDate || eventDate.toISOString().split('T')[0],
|
||||||
isSubstituted: false,
|
isSubstituted: false,
|
||||||
isCancelled: false,
|
isCancelled: false,
|
||||||
hasHomework: false,
|
hasHomework: false,
|
||||||
@@ -445,9 +471,9 @@
|
|||||||
"Ismeretlen tantárgy";
|
"Ismeretlen tantárgy";
|
||||||
|
|
||||||
if (startTimeStr && subject) {
|
if (startTimeStr && subject) {
|
||||||
const isCancelled = event.isElmaradt || event.Elmaradt || event.cancelled || event.isCancelled ||
|
const isCancelled = event.isElmaradt || event.Elmaradt || event.cancelled || event.isCancelled ||
|
||||||
event.oraType === 6 || (event.title && event.title.toLowerCase().includes('elmarad'));
|
event.oraType === 6 || (event.title && event.title.toLowerCase().includes('elmarad'));
|
||||||
|
|
||||||
const lesson = {
|
const lesson = {
|
||||||
startTime: startTimeStr,
|
startTime: startTimeStr,
|
||||||
endTime: endTimeStr,
|
endTime: endTimeStr,
|
||||||
@@ -456,14 +482,15 @@
|
|||||||
originalTeacher: event.helyettesitoId ? teacher : "",
|
originalTeacher: event.helyettesitoId ? teacher : "",
|
||||||
room: room,
|
room: room,
|
||||||
day: dayIndex,
|
day: dayIndex,
|
||||||
|
date: weekDates[dayIndex]?.fullDate || eventDate.toISOString().split('T')[0],
|
||||||
isSubstituted: !!event.helyettesitoId,
|
isSubstituted: !!event.helyettesitoId,
|
||||||
isCancelled: isCancelled,
|
isCancelled: isCancelled,
|
||||||
hasHomework: event.hasHaziFeladat || false,
|
hasHomework: event.hasHaziFeladat || false,
|
||||||
testInfo: event.hasBejelentettSzamonkeres
|
testInfo: event.hasBejelentettSzamonkeres
|
||||||
? event.Tema || LanguageManager.t("timetable.test_indicator")
|
? event.Tema || LanguageManager.t("timetable.test_indicator")
|
||||||
: "",
|
: "",
|
||||||
testId: event.hasBejelentettSzamonkeres && event.BejelentettSzamonkeresIdList && event.BejelentettSzamonkeresIdList.length > 0
|
testId: event.hasBejelentettSzamonkeres && event.BejelentettSzamonkeresIdList && event.BejelentettSzamonkeresIdList.length > 0
|
||||||
? event.BejelentettSzamonkeresIdList[0]
|
? event.BejelentettSzamonkeresIdList[0]
|
||||||
: null,
|
: null,
|
||||||
testDetails: "",
|
testDetails: "",
|
||||||
homeworkDetails: "",
|
homeworkDetails: "",
|
||||||
@@ -496,6 +523,15 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const testTypeMap = {};
|
||||||
|
const lessonsWithTests = lessons.filter(l => l.testId);
|
||||||
|
if (lessonsWithTests.length > 0) {
|
||||||
|
await loadAllTestDataFromAPI();
|
||||||
|
for (const lesson of lessonsWithTests) {
|
||||||
|
testTypeMap[lesson.testId] = await getTestTypeById(lesson.testId);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const times = [...new Set(regularLessons.map((l) => l.startTime))].sort(
|
const times = [...new Set(regularLessons.map((l) => l.startTime))].sort(
|
||||||
(a, b) => {
|
(a, b) => {
|
||||||
const timeA = helper.convertTimeToMinutes(a);
|
const timeA = helper.convertTimeToMinutes(a);
|
||||||
@@ -503,6 +539,26 @@
|
|||||||
return timeA - timeB;
|
return timeA - timeB;
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
|
||||||
|
function getLessonTimeSlots(lesson, allTimes) {
|
||||||
|
const startMinutes = helper.convertTimeToMinutes(lesson.startTime);
|
||||||
|
const endMinutes = helper.convertTimeToMinutes(lesson.endTime);
|
||||||
|
const slots = [];
|
||||||
|
for (let i = 0; i < allTimes.length; i++) {
|
||||||
|
const slotMinutes = helper.convertTimeToMinutes(allTimes[i]);
|
||||||
|
if (slotMinutes >= startMinutes && slotMinutes < endMinutes) {
|
||||||
|
slots.push(i);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return slots.length > 0 ? slots : [allTimes.indexOf(lesson.startTime)];
|
||||||
|
}
|
||||||
|
|
||||||
|
const lessonSlotMap = new Map();
|
||||||
|
regularLessons.forEach(lesson => {
|
||||||
|
const slots = getLessonTimeSlots(lesson, times);
|
||||||
|
lessonSlotMap.set(lesson, slots);
|
||||||
|
});
|
||||||
|
|
||||||
const days = [
|
const days = [
|
||||||
LanguageManager.t("timetable.monday"),
|
LanguageManager.t("timetable.monday"),
|
||||||
LanguageManager.t("timetable.tuesday"),
|
LanguageManager.t("timetable.tuesday"),
|
||||||
@@ -568,38 +624,84 @@
|
|||||||
const dayLessons = regularLessons.filter(
|
const dayLessons = regularLessons.filter(
|
||||||
(l) => l.startTime === time && l.day === dayIndex,
|
(l) => l.startTime === time && l.day === dayIndex,
|
||||||
);
|
);
|
||||||
|
|
||||||
|
const continuingInSlot = regularLessons.filter(lesson => {
|
||||||
|
if (lesson.day !== dayIndex) return false;
|
||||||
|
const slots = lessonSlotMap.get(lesson);
|
||||||
|
return slots && slots.includes(timeIndex) && slots[0] !== timeIndex;
|
||||||
|
});
|
||||||
|
|
||||||
|
const hasMultiLesson = dayLessons.some(lesson => {
|
||||||
|
const slots = lessonSlotMap.get(lesson);
|
||||||
|
return slots && slots.length > 1;
|
||||||
|
});
|
||||||
|
|
||||||
const lastLessonTime = lastLessonTimes[dayIndex];
|
const lastLessonTime = lastLessonTimes[dayIndex];
|
||||||
const isAfterLastLesson = lastLessonTime && helper.convertTimeToMinutes(time) > helper.convertTimeToMinutes(lastLessonTime);
|
const isAfterLastLesson = lastLessonTime && helper.convertTimeToMinutes(time) > helper.convertTimeToMinutes(lastLessonTime);
|
||||||
|
|
||||||
if (dayLessons.length === 0 && isAfterLastLesson) {
|
if (dayLessons.length === 0 && continuingInSlot.length === 0 && isAfterLastLesson) {
|
||||||
return `<div class="lesson-slot"></div>`;
|
return `<div class="lesson-slot"></div>`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (continuingInSlot.length > 0) {
|
||||||
return `
|
return `
|
||||||
<div class="lesson-slot ${dayLessons.length === 0 ? 'empty-slot' : ''}">
|
<div class="lesson-slot has-continuation">
|
||||||
${dayLessons.length === 0 ? '<div class="empty-lesson-placeholder"></div>' : ''}
|
${continuingInSlot.map(lesson => {
|
||||||
${dayLessons
|
const slots = lessonSlotMap.get(lesson);
|
||||||
.map(
|
const isLastSlot = slots[slots.length - 1] === timeIndex;
|
||||||
(lesson) => `
|
const lessonGroupId = `${lesson.subject}_${lesson.day}_${lesson.date}_${lesson.startTime}`;
|
||||||
<div class="lesson-card ${lesson.isSubstituted ? "substituted" : ""}
|
return `
|
||||||
|
<div class="lesson-card ${lesson.isSubstituted ? "substituted" : ""}
|
||||||
${lesson.isCancelled ? "cancelled" : ""}
|
${lesson.isCancelled ? "cancelled" : ""}
|
||||||
${lesson.hasHomework ? "has-homework" : ""}"
|
lesson-continuation ${isLastSlot ? 'continuation-end' : 'continuation-middle'}"
|
||||||
data-lesson='${JSON.stringify(lesson)}'
|
data-lesson='${JSON.stringify(lesson)}'
|
||||||
data-lesson-id='${lesson.lessonId || ""}'>
|
data-lesson-id='${lesson.lessonId || ""}'
|
||||||
<div class="lesson-subject">${lesson.subject}</div>
|
data-lesson-group='${lessonGroupId}'>
|
||||||
<div class="lesson-teacher">${lesson.teacher}</div>
|
|
||||||
<div class="lesson-bottom">
|
<div class="lesson-bottom">
|
||||||
<div class="lesson-room">${lesson.room}</div>
|
<div class="lesson-room">${lesson.room}</div>
|
||||||
<div class="lesson-time">${lesson.isCancelled ? LanguageManager.t("timetable.cancelled") : lesson.startTime}</div>
|
<div class="lesson-time">${lesson.isCancelled ? LanguageManager.t("timetable.cancelled") : lesson.startTime}</div>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
`}).join('')}
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
}
|
||||||
|
|
||||||
|
return `
|
||||||
|
<div class="lesson-slot ${dayLessons.length === 0 ? 'empty-slot' : ''} ${hasMultiLesson ? 'has-multi-start' : ''}">
|
||||||
|
${dayLessons.length === 0 ? '<div class="empty-lesson-placeholder"></div>' : ''}
|
||||||
|
${dayLessons
|
||||||
|
.map(
|
||||||
|
(lesson) => {
|
||||||
|
const slots = lessonSlotMap.get(lesson);
|
||||||
|
const spansMultiple = slots && slots.length > 1;
|
||||||
|
const lessonGroupId = `${lesson.subject}_${lesson.day}_${lesson.date}_${lesson.startTime}`;
|
||||||
|
return `
|
||||||
|
<div class="lesson-card ${lesson.isSubstituted ? "substituted" : ""}
|
||||||
|
${lesson.isCancelled ? "cancelled" : ""}
|
||||||
|
${lesson.hasHomework ? "has-homework" : ""}
|
||||||
|
${spansMultiple ? "lesson-spans-multiple" : ""}"
|
||||||
|
data-lesson='${JSON.stringify(lesson)}'
|
||||||
|
data-lesson-id='${lesson.lessonId || ""}'
|
||||||
|
data-spans='${slots ? slots.length : 1}'
|
||||||
|
data-lesson-group='${lessonGroupId}'>
|
||||||
|
<div class="lesson-subject">${lesson.subject}</div>
|
||||||
|
<div class="lesson-teacher">${lesson.teacher}</div>
|
||||||
|
${!spansMultiple ? `<div class="lesson-bottom">
|
||||||
|
<div class="lesson-room">${lesson.room}</div>
|
||||||
|
<div class="lesson-time">${lesson.isCancelled ? LanguageManager.t("timetable.cancelled") : lesson.startTime}</div>
|
||||||
|
</div>` : ''}
|
||||||
${
|
${
|
||||||
(() => {
|
(() => {
|
||||||
const lessonKey = `${lesson.subject}_${lesson.startTime}_${lesson.day}`;
|
const lessonKey = `${lesson.subject}_${lesson.startTime}_${lesson.date}`;
|
||||||
const hasCustomHomework = customHomework[lessonKey] && customHomework[lessonKey].length > 0;
|
const customHomeworkItems = customHomework[lessonKey] || [];
|
||||||
const hasCustomTests = customTests[lessonKey] && customTests[lessonKey].length > 0;
|
const customTestItems = customTests[lessonKey] || [];
|
||||||
|
const hasCustomHomework = customHomeworkItems.length > 0;
|
||||||
|
const hasCustomTests = customTestItems.length > 0;
|
||||||
|
const allCustomHomeworkCompleted = hasCustomHomework && customHomeworkItems.every(hw => hw.completed);
|
||||||
|
const allCustomTestsCompleted = hasCustomTests && customTestItems.every(test => test.completed);
|
||||||
const hasAnyIndicators = lesson.hasHomework || lesson.testInfo || hasCustomHomework || hasCustomTests;
|
const hasAnyIndicators = lesson.hasHomework || lesson.testInfo || hasCustomHomework || hasCustomTests;
|
||||||
|
|
||||||
return hasAnyIndicators ? `
|
return hasAnyIndicators ? `
|
||||||
<div class="lesson-indicators">
|
<div class="lesson-indicators">
|
||||||
${
|
${
|
||||||
@@ -613,18 +715,40 @@
|
|||||||
}
|
}
|
||||||
${
|
${
|
||||||
lesson.testInfo
|
lesson.testInfo
|
||||||
? `
|
? (() => {
|
||||||
<span class="lesson-indicator test-indicator" title="${LanguageManager.t("timetable.test_indicator")}">
|
const testType = lesson.testId ? testTypeMap[lesson.testId] : null;
|
||||||
<img src="${chrome.runtime.getURL("icons/assigment.svg")}" alt="Teszt" style="width: 20px; height: 20px;">
|
const isKontaktOra = testType === "KONTAKT ÓRA";
|
||||||
|
const isProjektOra = testType === "PROJEKT ÓRA";
|
||||||
|
let indicatorClass = "test-indicator";
|
||||||
|
let iconPath = "icons/assigment.svg";
|
||||||
|
let titleText = LanguageManager.t("timetable.test_indicator");
|
||||||
|
let altText = "Teszt";
|
||||||
|
|
||||||
|
if (isKontaktOra) {
|
||||||
|
indicatorClass = "homework-indicator";
|
||||||
|
iconPath = "icons/contact.svg";
|
||||||
|
titleText = "Kontakt óra";
|
||||||
|
altText = "Kontakt óra";
|
||||||
|
} else if (isProjektOra) {
|
||||||
|
indicatorClass = "homework-indicator";
|
||||||
|
iconPath = "icons/project.svg";
|
||||||
|
titleText = "Projekt óra";
|
||||||
|
altText = "Projekt óra";
|
||||||
|
}
|
||||||
|
|
||||||
|
return `
|
||||||
|
<span class="lesson-indicator ${indicatorClass}" title="${titleText}">
|
||||||
|
<img src="${chrome.runtime.getURL(iconPath)}" alt="${altText}" style="width: 20px; height: 20px;">
|
||||||
</span>
|
</span>
|
||||||
`
|
`;
|
||||||
|
})()
|
||||||
: ""
|
: ""
|
||||||
}
|
}
|
||||||
${
|
${
|
||||||
hasCustomHomework
|
hasCustomHomework
|
||||||
? `
|
? `
|
||||||
<span class="lesson-indicator custom-homework-indicator" title="Saját házi feladat">
|
<span class="lesson-indicator custom-homework-indicator" title="Saját házi feladat">
|
||||||
<img src="${chrome.runtime.getURL("icons/homework.svg")}" alt="Saját házi feladat" style="width: 20px; height: 20px; opacity: 0.7;">
|
<img src="${chrome.runtime.getURL(allCustomHomeworkCompleted ? "icons/pipa.svg" : "icons/homework.svg")}" alt="${allCustomHomeworkCompleted ? 'Megoldott saját házi feladat' : 'Saját házi feladat'}" style="width: 20px; height: 20px; opacity: 0.7;">
|
||||||
</span>
|
</span>
|
||||||
`
|
`
|
||||||
: ""
|
: ""
|
||||||
@@ -633,7 +757,7 @@
|
|||||||
hasCustomTests
|
hasCustomTests
|
||||||
? `
|
? `
|
||||||
<span class="lesson-indicator custom-test-indicator" title="Saját számonkérés">
|
<span class="lesson-indicator custom-test-indicator" title="Saját számonkérés">
|
||||||
<img src="${chrome.runtime.getURL("icons/assigment.svg")}" alt="Saját számonkérés" style="width: 20px; height: 20px; opacity: 0.7;">
|
<img src="${chrome.runtime.getURL(allCustomTestsCompleted ? "icons/pipa.svg" : "icons/assigment.svg")}" alt="${allCustomTestsCompleted ? 'Megoldott saját számonkérés' : 'Saját számonkérés'}" style="width: 20px; height: 20px; opacity: 0.7;">
|
||||||
</span>
|
</span>
|
||||||
`
|
`
|
||||||
: ""
|
: ""
|
||||||
@@ -643,8 +767,8 @@
|
|||||||
})()
|
})()
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
`,
|
`;
|
||||||
)
|
})
|
||||||
.join("")
|
.join("")
|
||||||
}
|
}
|
||||||
</div>
|
</div>
|
||||||
@@ -711,19 +835,21 @@
|
|||||||
const lessonDetails = document.createElement('div');
|
const lessonDetails = document.createElement('div');
|
||||||
lessonDetails.className = 'lesson-details';
|
lessonDetails.className = 'lesson-details';
|
||||||
|
|
||||||
const teacherItem = document.createElement('div');
|
if (!lesson.isSubstituted) {
|
||||||
teacherItem.className = 'detail-item';
|
const teacherItem = document.createElement('div');
|
||||||
const teacherLabel = document.createElement('span');
|
teacherItem.className = 'detail-item';
|
||||||
teacherLabel.className = 'detail-label';
|
const teacherLabel = document.createElement('span');
|
||||||
teacherLabel.textContent = LanguageManager.t('timetable.teacher_label');
|
teacherLabel.className = 'detail-label';
|
||||||
const teacherValue = document.createElement('span');
|
teacherLabel.textContent = LanguageManager.t('timetable.teacher_label');
|
||||||
teacherValue.className = `detail-value ${lesson.originalTeacher != '' ? 'line-through' : ''}`;
|
const teacherValue = document.createElement('span');
|
||||||
teacherValue.textContent = lesson.originalTeacher != '' ? lesson.originalTeacher : lesson.teacher;
|
teacherValue.className = 'detail-value';
|
||||||
teacherItem.appendChild(teacherLabel);
|
teacherValue.textContent = lesson.teacher;
|
||||||
teacherItem.appendChild(teacherValue);
|
teacherItem.appendChild(teacherLabel);
|
||||||
lessonDetails.appendChild(teacherItem);
|
teacherItem.appendChild(teacherValue);
|
||||||
|
lessonDetails.appendChild(teacherItem);
|
||||||
|
}
|
||||||
|
|
||||||
if (lesson.originalTeacher != '') {
|
if (lesson.isSubstituted) {
|
||||||
const substituteItem = document.createElement('div');
|
const substituteItem = document.createElement('div');
|
||||||
substituteItem.className = 'detail-item';
|
substituteItem.className = 'detail-item';
|
||||||
const substituteLabel = document.createElement('span');
|
const substituteLabel = document.createElement('span');
|
||||||
@@ -885,18 +1011,27 @@
|
|||||||
detailsDiv.className = 'homework-details';
|
detailsDiv.className = 'homework-details';
|
||||||
|
|
||||||
const contentP = document.createElement('p');
|
const contentP = document.createElement('p');
|
||||||
contentP.innerHTML = `<strong>Feladat:</strong> ${homeworkDetails.content}`;
|
const contentStrong = document.createElement('strong');
|
||||||
|
contentStrong.textContent = 'Feladat: ';
|
||||||
|
contentP.appendChild(contentStrong);
|
||||||
|
contentP.appendChild(document.createTextNode(homeworkDetails.content));
|
||||||
detailsDiv.appendChild(contentP);
|
detailsDiv.appendChild(contentP);
|
||||||
|
|
||||||
if (homeworkDetails.deadline) {
|
if (homeworkDetails.deadline) {
|
||||||
const deadlineP = document.createElement('p');
|
const deadlineP = document.createElement('p');
|
||||||
deadlineP.innerHTML = `<strong>Határidő:</strong> ${homeworkDetails.deadline}`;
|
const deadlineStrong = document.createElement('strong');
|
||||||
|
deadlineStrong.textContent = 'Határidő: ';
|
||||||
|
deadlineP.appendChild(deadlineStrong);
|
||||||
|
deadlineP.appendChild(document.createTextNode(homeworkDetails.deadline));
|
||||||
detailsDiv.appendChild(deadlineP);
|
detailsDiv.appendChild(deadlineP);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (homeworkDetails.teacher) {
|
if (homeworkDetails.teacher) {
|
||||||
const teacherP = document.createElement('p');
|
const teacherP = document.createElement('p');
|
||||||
teacherP.innerHTML = `<strong>Tanár:</strong> ${homeworkDetails.teacher}`;
|
const teacherStrong = document.createElement('strong');
|
||||||
|
teacherStrong.textContent = 'Tanár: ';
|
||||||
|
teacherP.appendChild(teacherStrong);
|
||||||
|
teacherP.appendChild(document.createTextNode(homeworkDetails.teacher));
|
||||||
detailsDiv.appendChild(teacherP);
|
detailsDiv.appendChild(teacherP);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -906,7 +1041,9 @@
|
|||||||
attachmentsDiv.style.marginTop = '1rem';
|
attachmentsDiv.style.marginTop = '1rem';
|
||||||
|
|
||||||
const attachmentsTitle = document.createElement('p');
|
const attachmentsTitle = document.createElement('p');
|
||||||
attachmentsTitle.innerHTML = '<strong>Csatolmányok:</strong>';
|
const attachStrong = document.createElement('strong');
|
||||||
|
attachStrong.textContent = 'Csatolmányok:';
|
||||||
|
attachmentsTitle.appendChild(attachStrong);
|
||||||
attachmentsTitle.style.marginBottom = '0.5rem';
|
attachmentsTitle.style.marginBottom = '0.5rem';
|
||||||
attachmentsDiv.appendChild(attachmentsTitle);
|
attachmentsDiv.appendChild(attachmentsTitle);
|
||||||
|
|
||||||
@@ -1182,74 +1319,92 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (lesson.testInfo) {
|
if (lesson.testInfo) {
|
||||||
|
let testDetails = null;
|
||||||
|
if (lesson.testId) {
|
||||||
|
testDetails = await loadTestDetailsFromAPI(lesson.testId);
|
||||||
|
}
|
||||||
|
|
||||||
|
const isKontaktOra = testDetails && testDetails.type === "KONTAKT ÓRA";
|
||||||
|
const isProjektOra = testDetails && testDetails.type === "PROJEKT ÓRA";
|
||||||
|
const isSpecialType = isKontaktOra || isProjektOra;
|
||||||
|
|
||||||
const testSection = document.createElement('div');
|
const testSection = document.createElement('div');
|
||||||
testSection.className = 'modal-section test-section';
|
testSection.className = isSpecialType ? 'modal-section homework-section' : 'modal-section test-section';
|
||||||
|
|
||||||
const testH4 = document.createElement('h4');
|
const testH4 = document.createElement('h4');
|
||||||
const testIcon = document.createElement('img');
|
const testIcon = document.createElement('img');
|
||||||
testIcon.src = chrome.runtime.getURL('icons/assigment.svg');
|
|
||||||
testIcon.alt = 'Teszt';
|
let iconPath = 'icons/assigment.svg';
|
||||||
|
let sectionTitle = LanguageManager.t('timetable.test_indicator');
|
||||||
|
let altText = 'Teszt';
|
||||||
|
|
||||||
|
if (isKontaktOra) {
|
||||||
|
iconPath = 'icons/contact.svg';
|
||||||
|
sectionTitle = 'Kontakt óra';
|
||||||
|
altText = 'Kontakt óra';
|
||||||
|
} else if (isProjektOra) {
|
||||||
|
iconPath = 'icons/project.svg';
|
||||||
|
sectionTitle = 'Projekt óra';
|
||||||
|
altText = 'Projekt óra';
|
||||||
|
}
|
||||||
|
|
||||||
|
testIcon.src = chrome.runtime.getURL(iconPath);
|
||||||
|
testIcon.alt = altText;
|
||||||
testIcon.style.width = '20px';
|
testIcon.style.width = '20px';
|
||||||
testIcon.style.height = '20px';
|
testIcon.style.height = '20px';
|
||||||
testH4.appendChild(testIcon);
|
testH4.appendChild(testIcon);
|
||||||
testH4.appendChild(document.createTextNode(LanguageManager.t('timetable.test_indicator')));
|
testH4.appendChild(document.createTextNode(sectionTitle));
|
||||||
|
if (isSpecialType) {
|
||||||
|
testH4.style.color = 'var(--accent-accent)';
|
||||||
|
}
|
||||||
|
|
||||||
const testContent = document.createElement('div');
|
const testContent = document.createElement('div');
|
||||||
testContent.className = 'test-content';
|
testContent.className = 'test-content';
|
||||||
|
|
||||||
if (lesson.testId) {
|
if (testDetails) {
|
||||||
const loadingDiv = document.createElement('div');
|
const detailsDiv = document.createElement('div');
|
||||||
loadingDiv.className = 'test-details-loading';
|
detailsDiv.className = 'test-details';
|
||||||
loadingDiv.textContent = 'Részletek betöltése...';
|
|
||||||
testContent.appendChild(loadingDiv);
|
|
||||||
|
|
||||||
loadTestDetailsFromAPI(lesson.testId).then(testDetails => {
|
const nameP = document.createElement('p');
|
||||||
loadingDiv.remove();
|
const nameStrong = document.createElement('strong');
|
||||||
|
nameStrong.textContent = 'Megnevezés: ';
|
||||||
if (testDetails) {
|
nameP.appendChild(nameStrong);
|
||||||
const detailsDiv = document.createElement('div');
|
nameP.appendChild(document.createTextNode(testDetails.name));
|
||||||
detailsDiv.className = 'test-details';
|
detailsDiv.appendChild(nameP);
|
||||||
|
|
||||||
const nameP = document.createElement('p');
|
const typeP = document.createElement('p');
|
||||||
nameP.innerHTML = `<strong>Megnevezés:</strong> ${testDetails.name}`;
|
const typeStrong = document.createElement('strong');
|
||||||
detailsDiv.appendChild(nameP);
|
typeStrong.textContent = 'Típus: ';
|
||||||
|
typeP.appendChild(typeStrong);
|
||||||
const typeP = document.createElement('p');
|
typeP.appendChild(document.createTextNode(testDetails.type));
|
||||||
typeP.innerHTML = `<strong>Típus:</strong> ${testDetails.type}`;
|
detailsDiv.appendChild(typeP);
|
||||||
detailsDiv.appendChild(typeP);
|
|
||||||
|
const dateP = document.createElement('p');
|
||||||
const dateP = document.createElement('p');
|
const dateStrong = document.createElement('strong');
|
||||||
dateP.innerHTML = `<strong>Bejelentés dátuma:</strong> ${testDetails.announceDate}`;
|
dateStrong.textContent = 'Bejelentés dátuma: ';
|
||||||
detailsDiv.appendChild(dateP);
|
dateP.appendChild(dateStrong);
|
||||||
|
dateP.appendChild(document.createTextNode(testDetails.announceDate));
|
||||||
testContent.appendChild(detailsDiv);
|
detailsDiv.appendChild(dateP);
|
||||||
} else {
|
|
||||||
const errorP = document.createElement('p');
|
testContent.appendChild(detailsDiv);
|
||||||
errorP.className = 'test-details-error';
|
} else if (lesson.testId) {
|
||||||
errorP.textContent = 'Nem sikerült betölteni a számonkérés részleteit.';
|
const errorP = document.createElement('p');
|
||||||
testContent.appendChild(errorP);
|
errorP.className = 'test-details-error';
|
||||||
}
|
errorP.textContent = 'Nem sikerült betölteni a számonkérés részleteit.';
|
||||||
}).catch(error => {
|
testContent.appendChild(errorP);
|
||||||
loadingDiv.remove();
|
|
||||||
const errorP = document.createElement('p');
|
|
||||||
errorP.className = 'test-details-error';
|
|
||||||
errorP.textContent = 'Hiba történt a számonkérés részletek betöltése során.';
|
|
||||||
testContent.appendChild(errorP);
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
const lessonKey = getLessonKey(lesson);
|
const lessonKey = getLessonKey(lesson);
|
||||||
const customTests = await getCustomTests();
|
const customTests = await getCustomTests();
|
||||||
const customTestItems = customTests[lessonKey] || [];
|
const customTestItems = customTests[lessonKey] || [];
|
||||||
|
|
||||||
if (customTestItems.length > 0) {
|
if (customTestItems.length > 0) {
|
||||||
const customTestsDiv = document.createElement('div');
|
const customTestsDiv = document.createElement('div');
|
||||||
customTestsDiv.className = 'custom-tests-in-section';
|
customTestsDiv.className = 'custom-tests-in-section';
|
||||||
customTestsDiv.style.marginTop = '1rem';
|
customTestsDiv.style.marginTop = '1rem';
|
||||||
customTestsDiv.style.paddingTop = '1rem';
|
customTestsDiv.style.paddingTop = '1rem';
|
||||||
customTestsDiv.style.borderTop = '1px solid var(--background-0)';
|
customTestsDiv.style.borderTop = '1px solid var(--background-0)';
|
||||||
|
|
||||||
const customTestsTitle = document.createElement('h5');
|
const customTestsTitle = document.createElement('h5');
|
||||||
customTestsTitle.textContent = 'Saját számonkérések:';
|
customTestsTitle.textContent = 'Saját számonkérések:';
|
||||||
customTestsTitle.style.fontSize = '14px';
|
customTestsTitle.style.fontSize = '14px';
|
||||||
@@ -1257,10 +1412,10 @@
|
|||||||
customTestsTitle.style.color = 'var(--warning-accent)';
|
customTestsTitle.style.color = 'var(--warning-accent)';
|
||||||
customTestsTitle.style.marginBottom = '0.5rem';
|
customTestsTitle.style.marginBottom = '0.5rem';
|
||||||
customTestsDiv.appendChild(customTestsTitle);
|
customTestsDiv.appendChild(customTestsTitle);
|
||||||
|
|
||||||
const customTestsList = document.createElement('div');
|
const customTestsList = document.createElement('div');
|
||||||
customTestsList.className = 'custom-tests-list-integrated';
|
customTestsList.className = 'custom-tests-list-integrated';
|
||||||
|
|
||||||
customTestItems.forEach(test => {
|
customTestItems.forEach(test => {
|
||||||
const testItem = document.createElement('div');
|
const testItem = document.createElement('div');
|
||||||
testItem.className = `custom-test-item-integrated ${test.completed ? 'completed' : ''}`;
|
testItem.className = `custom-test-item-integrated ${test.completed ? 'completed' : ''}`;
|
||||||
@@ -1272,7 +1427,7 @@
|
|||||||
testItem.style.background = 'var(--background)';
|
testItem.style.background = 'var(--background)';
|
||||||
testItem.style.borderRadius = '6px';
|
testItem.style.borderRadius = '6px';
|
||||||
testItem.style.border = '1px solid var(--background-0)';
|
testItem.style.border = '1px solid var(--background-0)';
|
||||||
|
|
||||||
const testText = document.createElement('span');
|
const testText = document.createElement('span');
|
||||||
testText.className = 'test-text-integrated';
|
testText.className = 'test-text-integrated';
|
||||||
testText.textContent = test.text;
|
testText.textContent = test.text;
|
||||||
@@ -1282,12 +1437,12 @@
|
|||||||
testText.style.textDecoration = 'line-through';
|
testText.style.textDecoration = 'line-through';
|
||||||
testText.style.opacity = '0.6';
|
testText.style.opacity = '0.6';
|
||||||
}
|
}
|
||||||
|
|
||||||
const testActions = document.createElement('div');
|
const testActions = document.createElement('div');
|
||||||
testActions.className = 'test-actions-integrated';
|
testActions.className = 'test-actions-integrated';
|
||||||
testActions.style.display = 'flex';
|
testActions.style.display = 'flex';
|
||||||
testActions.style.gap = '0.5rem';
|
testActions.style.gap = '0.5rem';
|
||||||
|
|
||||||
const completeBtn = document.createElement('button');
|
const completeBtn = document.createElement('button');
|
||||||
completeBtn.className = 'test-complete-btn-integrated';
|
completeBtn.className = 'test-complete-btn-integrated';
|
||||||
completeBtn.title = test.completed ? 'Megoldva - kattints a visszavonáshoz' : 'Megoldottként jelöl';
|
completeBtn.title = test.completed ? 'Megoldva - kattints a visszavonáshoz' : 'Megoldottként jelöl';
|
||||||
@@ -1299,7 +1454,7 @@
|
|||||||
completeBtn.style.display = 'flex';
|
completeBtn.style.display = 'flex';
|
||||||
completeBtn.style.alignItems = 'center';
|
completeBtn.style.alignItems = 'center';
|
||||||
completeBtn.style.justifyContent = 'center';
|
completeBtn.style.justifyContent = 'center';
|
||||||
|
|
||||||
const completeIcon = document.createElement('img');
|
const completeIcon = document.createElement('img');
|
||||||
completeIcon.src = chrome.runtime.getURL('icons/pipa.svg');
|
completeIcon.src = chrome.runtime.getURL('icons/pipa.svg');
|
||||||
completeIcon.alt = 'Megoldva';
|
completeIcon.alt = 'Megoldva';
|
||||||
@@ -1312,7 +1467,7 @@
|
|||||||
completeIcon.style.opacity = '0.5';
|
completeIcon.style.opacity = '0.5';
|
||||||
}
|
}
|
||||||
completeBtn.appendChild(completeIcon);
|
completeBtn.appendChild(completeIcon);
|
||||||
|
|
||||||
const deleteBtn = document.createElement('button');
|
const deleteBtn = document.createElement('button');
|
||||||
deleteBtn.className = 'test-delete-btn-integrated';
|
deleteBtn.className = 'test-delete-btn-integrated';
|
||||||
deleteBtn.title = 'Törlés';
|
deleteBtn.title = 'Törlés';
|
||||||
@@ -1324,7 +1479,7 @@
|
|||||||
deleteBtn.style.display = 'flex';
|
deleteBtn.style.display = 'flex';
|
||||||
deleteBtn.style.alignItems = 'center';
|
deleteBtn.style.alignItems = 'center';
|
||||||
deleteBtn.style.justifyContent = 'center';
|
deleteBtn.style.justifyContent = 'center';
|
||||||
|
|
||||||
const deleteIcon = document.createElement('img');
|
const deleteIcon = document.createElement('img');
|
||||||
deleteIcon.src = chrome.runtime.getURL('icons/delete.svg');
|
deleteIcon.src = chrome.runtime.getURL('icons/delete.svg');
|
||||||
deleteIcon.alt = 'Törlés';
|
deleteIcon.alt = 'Törlés';
|
||||||
@@ -1332,7 +1487,7 @@
|
|||||||
deleteIcon.style.height = '16px';
|
deleteIcon.style.height = '16px';
|
||||||
deleteIcon.style.opacity = '0.5';
|
deleteIcon.style.opacity = '0.5';
|
||||||
deleteBtn.appendChild(deleteIcon);
|
deleteBtn.appendChild(deleteIcon);
|
||||||
|
|
||||||
completeBtn.addEventListener('click', async () => {
|
completeBtn.addEventListener('click', async () => {
|
||||||
const newCompleted = await toggleCustomTestCompletion(lessonKey, test.id);
|
const newCompleted = await toggleCustomTestCompletion(lessonKey, test.id);
|
||||||
if (newCompleted) {
|
if (newCompleted) {
|
||||||
@@ -1349,30 +1504,30 @@
|
|||||||
completeBtn.title = 'Megoldottként jelöl';
|
completeBtn.title = 'Megoldottként jelöl';
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
deleteBtn.addEventListener('click', async () => {
|
deleteBtn.addEventListener('click', async () => {
|
||||||
if (confirm('Biztosan törölni szeretnéd ezt a számonkérést?')) {
|
if (confirm('Biztosan törölni szeretnéd ezt a számonkérést?')) {
|
||||||
await removeCustomTest(lessonKey, test.id);
|
await removeCustomTest(lessonKey, test.id);
|
||||||
testItem.remove();
|
testItem.remove();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
testActions.appendChild(completeBtn);
|
testActions.appendChild(completeBtn);
|
||||||
testActions.appendChild(deleteBtn);
|
testActions.appendChild(deleteBtn);
|
||||||
testItem.appendChild(testText);
|
testItem.appendChild(testText);
|
||||||
testItem.appendChild(testActions);
|
testItem.appendChild(testActions);
|
||||||
customTestsList.appendChild(testItem);
|
customTestsList.appendChild(testItem);
|
||||||
});
|
});
|
||||||
|
|
||||||
customTestsDiv.appendChild(customTestsList);
|
customTestsDiv.appendChild(customTestsList);
|
||||||
testContent.appendChild(customTestsDiv);
|
testContent.appendChild(customTestsDiv);
|
||||||
}
|
}
|
||||||
|
|
||||||
testSection.appendChild(testH4);
|
testSection.appendChild(testH4);
|
||||||
testSection.appendChild(testContent);
|
testSection.appendChild(testContent);
|
||||||
body.appendChild(testSection);
|
body.appendChild(testSection);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
const lessonKey = getLessonKey(lesson);
|
const lessonKey = getLessonKey(lesson);
|
||||||
const customHomework = await getCustomHomework();
|
const customHomework = await getCustomHomework();
|
||||||
@@ -1630,7 +1785,7 @@
|
|||||||
modalContent.appendChild(header);
|
modalContent.appendChild(header);
|
||||||
modalContent.appendChild(body);
|
modalContent.appendChild(body);
|
||||||
|
|
||||||
modal.innerHTML = '';
|
helper.clearElement(modal);
|
||||||
modal.appendChild(modalContent);
|
modal.appendChild(modalContent);
|
||||||
|
|
||||||
document.body.appendChild(modal);
|
document.body.appendChild(modal);
|
||||||
@@ -1700,12 +1855,12 @@
|
|||||||
const timetableGrid = document.querySelector(".timetable-grid");
|
const timetableGrid = document.querySelector(".timetable-grid");
|
||||||
if (timetableGrid) {
|
if (timetableGrid) {
|
||||||
|
|
||||||
const newContent = await generateTimeGrid(lessons, weekDates);
|
const newContent = await generateTimeGrid(allLessons, weekDates);
|
||||||
timetableGrid.innerHTML = '';
|
helper.clearElement(timetableGrid);
|
||||||
|
|
||||||
const parser1 = new DOMParser();
|
const template = document.createElement('template');
|
||||||
const doc = parser1.parseFromString(`<div>${newContent}</div>`, 'text/html');
|
template.innerHTML = `<div>${newContent}</div>`;
|
||||||
const tempDiv = doc.querySelector('div');
|
const tempDiv = template.content.querySelector('div');
|
||||||
while (tempDiv.firstChild) {
|
while (tempDiv.firstChild) {
|
||||||
timetableGrid.appendChild(tempDiv.firstChild);
|
timetableGrid.appendChild(tempDiv.firstChild);
|
||||||
}
|
}
|
||||||
@@ -1867,6 +2022,24 @@
|
|||||||
const lessonData = JSON.parse(card.dataset.lesson);
|
const lessonData = JSON.parse(card.dataset.lesson);
|
||||||
await showLessonModal(lessonData);
|
await showLessonModal(lessonData);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
card.addEventListener("mouseenter", () => {
|
||||||
|
const groupId = card.dataset.lessonGroup;
|
||||||
|
if (groupId) {
|
||||||
|
document.querySelectorAll(`[data-lesson-group="${groupId}"]`).forEach(relatedCard => {
|
||||||
|
relatedCard.classList.add('group-hover');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
card.addEventListener("mouseleave", () => {
|
||||||
|
const groupId = card.dataset.lessonGroup;
|
||||||
|
if (groupId) {
|
||||||
|
document.querySelectorAll(`[data-lesson-group="${groupId}"]`).forEach(relatedCard => {
|
||||||
|
relatedCard.classList.remove('group-hover');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1982,8 +2155,10 @@
|
|||||||
|
|
||||||
dayNavigationState.currentDayIndex = currentDayIndex;
|
dayNavigationState.currentDayIndex = currentDayIndex;
|
||||||
} else {
|
} else {
|
||||||
const preservedDayIndex = dayNavigationState.currentDayIndex;
|
if (dayNavigationState.currentDayIndex >= 0 && dayNavigationState.currentDayIndex < 5) {
|
||||||
dayNavigationState.currentDayIndex = preservedDayIndex;
|
} else {
|
||||||
|
dayNavigationState.currentDayIndex = 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function updateDayDisplay() {
|
function updateDayDisplay() {
|
||||||
@@ -2182,7 +2357,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
modalGrid.innerHTML = '';
|
helper.clearElement(modalGrid);
|
||||||
allWeeks.forEach((week) => {
|
allWeeks.forEach((week) => {
|
||||||
const weekCell = document.createElement('div');
|
const weekCell = document.createElement('div');
|
||||||
weekCell.className = `week-cell ${week.selected ? 'selected' : ''} ${week.selected ? 'current-week' : ''}`;
|
weekCell.className = `week-cell ${week.selected ? 'selected' : ''} ${week.selected ? 'current-week' : ''}`;
|
||||||
@@ -2270,7 +2445,7 @@
|
|||||||
const weekGrid = document.getElementById("week-grid");
|
const weekGrid = document.getElementById("week-grid");
|
||||||
if (weekGrid) {
|
if (weekGrid) {
|
||||||
|
|
||||||
weekGrid.innerHTML = '';
|
helper.clearElement(weekGrid);
|
||||||
newWeekOptions.forEach((opt) => {
|
newWeekOptions.forEach((opt) => {
|
||||||
const weekCell = document.createElement('div');
|
const weekCell = document.createElement('div');
|
||||||
weekCell.className = `week-cell ${opt.selected ? 'selected' : ''}`;
|
weekCell.className = `week-cell ${opt.selected ? 'selected' : ''}`;
|
||||||
@@ -2317,7 +2492,7 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
document.body.innerHTML = '';
|
helper.clearElement(document.body);
|
||||||
|
|
||||||
|
|
||||||
const kretaContainer = document.createElement('div');
|
const kretaContainer = document.createElement('div');
|
||||||
@@ -2326,9 +2501,9 @@
|
|||||||
|
|
||||||
const headerDiv = document.createElement('div');
|
const headerDiv = document.createElement('div');
|
||||||
|
|
||||||
const parser2 = new DOMParser();
|
const template = document.createElement('template');
|
||||||
const headerDoc = parser2.parseFromString(await createTemplate.header(), 'text/html');
|
template.innerHTML = await createTemplate.header();
|
||||||
const headerContent = headerDoc.body;
|
const headerContent = template.content;
|
||||||
while (headerContent.firstChild) {
|
while (headerContent.firstChild) {
|
||||||
headerDiv.appendChild(headerContent.firstChild);
|
headerDiv.appendChild(headerContent.firstChild);
|
||||||
}
|
}
|
||||||
@@ -2476,9 +2651,9 @@
|
|||||||
|
|
||||||
const gridContent = await generateTimeGrid(data.lessons, data.weekDates);
|
const gridContent = await generateTimeGrid(data.lessons, data.weekDates);
|
||||||
|
|
||||||
const parser3 = new DOMParser();
|
const template3 = document.createElement('template');
|
||||||
const doc = parser3.parseFromString(`<div>${gridContent}</div>`, 'text/html');
|
template3.innerHTML = `<div>${gridContent}</div>`;
|
||||||
const tempDiv = doc.querySelector('div');
|
const tempDiv = template3.content.querySelector('div');
|
||||||
while (tempDiv.firstChild) {
|
while (tempDiv.firstChild) {
|
||||||
timetableGrid.appendChild(tempDiv.firstChild);
|
timetableGrid.appendChild(tempDiv.firstChild);
|
||||||
}
|
}
|
||||||
@@ -2501,9 +2676,6 @@
|
|||||||
if (typeof setupUserDropdown === 'function') {
|
if (typeof setupUserDropdown === 'function') {
|
||||||
setupUserDropdown();
|
setupUserDropdown();
|
||||||
}
|
}
|
||||||
if (typeof setupMobileNavigation === 'function') {
|
|
||||||
setupMobileNavigation();
|
|
||||||
}
|
|
||||||
setupEventListeners(data);
|
setupEventListeners(data);
|
||||||
initializeWeekSelector();
|
initializeWeekSelector();
|
||||||
|
|
||||||
@@ -2540,7 +2712,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
weekDisplay.innerHTML = '';
|
helper.clearElement(weekDisplay);
|
||||||
visibleWeeks.forEach((weekNum, index) => {
|
visibleWeeks.forEach((weekNum, index) => {
|
||||||
const isSelected = index === 2;
|
const isSelected = index === 2;
|
||||||
const isCurrent = weekNum === currentWeekNumber;
|
const isCurrent = weekNum === currentWeekNumber;
|
||||||
@@ -2636,16 +2808,17 @@
|
|||||||
const timetableContainer = document.querySelector(".timetable-grid");
|
const timetableContainer = document.querySelector(".timetable-grid");
|
||||||
if (timetableContainer) {
|
if (timetableContainer) {
|
||||||
|
|
||||||
timetableContainer.innerHTML = '';
|
helper.clearElement(timetableContainer);
|
||||||
const gridContent = await generateTimeGrid(lessons, weekDates);
|
const gridContent = await generateTimeGrid(lessons, weekDates);
|
||||||
|
|
||||||
const parser2 = new DOMParser();
|
const template2 = document.createElement('template');
|
||||||
const doc = parser2.parseFromString(`<div>${gridContent}</div>`, 'text/html');
|
template2.innerHTML = `<div>${gridContent}</div>`;
|
||||||
const tempDiv = doc.querySelector('div');
|
const tempDiv = template2.content.querySelector('div');
|
||||||
while (tempDiv.firstChild) {
|
while (tempDiv.firstChild) {
|
||||||
timetableContainer.appendChild(tempDiv.firstChild);
|
timetableContainer.appendChild(tempDiv.firstChild);
|
||||||
}
|
}
|
||||||
setupLessonCardListeners();
|
setupLessonCardListeners();
|
||||||
|
setupDayNavigation(weekDates);
|
||||||
|
|
||||||
setTimeout(async () => {
|
setTimeout(async () => {
|
||||||
await updateHomeworkIconsFromCookie();
|
await updateHomeworkIconsFromCookie();
|
||||||
@@ -2668,7 +2841,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
modalGrid.innerHTML = '';
|
helper.clearElement(modalGrid);
|
||||||
allWeeks.forEach((weekNumber) => {
|
allWeeks.forEach((weekNumber) => {
|
||||||
const isSelected = weekNumber === selectedWeekNumber;
|
const isSelected = weekNumber === selectedWeekNumber;
|
||||||
const isCurrent = weekNumber === currentWeekNumber;
|
const isCurrent = weekNumber === currentWeekNumber;
|
||||||
|
|||||||
@@ -1,3 +1,15 @@
|
|||||||
|
chrome.runtime.onInstalled.addListener(async (details) => {
|
||||||
|
if (details.reason === 'install') {
|
||||||
|
const setupCompleted = await chrome.storage.sync.get('firka_setupCompleted');
|
||||||
|
|
||||||
|
if (!setupCompleted.firka_setupCompleted) {
|
||||||
|
chrome.tabs.create({
|
||||||
|
url: chrome.runtime.getURL('setup/setup.html')
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
chrome.runtime.onMessage.addListener((request, sender, sendResponse) => {
|
chrome.runtime.onMessage.addListener((request, sender, sendResponse) => {
|
||||||
(async () => {
|
(async () => {
|
||||||
try {
|
try {
|
||||||
@@ -22,6 +34,11 @@ chrome.runtime.onMessage.addListener((request, sender, sendResponse) => {
|
|||||||
sendResponse({ success: true });
|
sendResponse({ success: true });
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case 'download_attachment':
|
||||||
|
const downloadResult = await handleDownloadAttachment(request.azonosito, request.fileName);
|
||||||
|
sendResponse(downloadResult);
|
||||||
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
console.warn('[Background] Unknown action:', request.action);
|
console.warn('[Background] Unknown action:', request.action);
|
||||||
sendResponse({ success: false, error: 'Unknown action' });
|
sendResponse({ success: false, error: 'Unknown action' });
|
||||||
@@ -67,7 +84,7 @@ async function handleStorageClear() {
|
|||||||
try {
|
try {
|
||||||
const allData = await chrome.storage.sync.get(null);
|
const allData = await chrome.storage.sync.get(null);
|
||||||
const firkaKeys = Object.keys(allData).filter(key => key.startsWith('firka_'));
|
const firkaKeys = Object.keys(allData).filter(key => key.startsWith('firka_'));
|
||||||
|
|
||||||
if (firkaKeys.length > 0) {
|
if (firkaKeys.length > 0) {
|
||||||
await chrome.storage.sync.remove(firkaKeys);
|
await chrome.storage.sync.remove(firkaKeys);
|
||||||
}
|
}
|
||||||
@@ -77,6 +94,82 @@ async function handleStorageClear() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
async function handleDownloadAttachment(azonosito, fileName) {
|
||||||
|
try {
|
||||||
|
const apiUrl = `https://eugyintezes.e-kreta.hu/api/v1/dokumentumok/uzenetek/${azonosito}`;
|
||||||
|
|
||||||
|
const redirectResponse = await fetch(apiUrl, {
|
||||||
|
method: 'GET',
|
||||||
|
credentials: 'include',
|
||||||
|
headers: {
|
||||||
|
'Accept': 'application/json, text/plain, */*',
|
||||||
|
'x-csrf': '1',
|
||||||
|
'x-uzenet-json-formatum': 'CamelCase',
|
||||||
|
'x-uzenet-lokalizacio': 'hu-HU',
|
||||||
|
'x-uzenet-verzio-szam': '1.2.3'
|
||||||
|
},
|
||||||
|
redirect: 'manual'
|
||||||
|
});
|
||||||
|
|
||||||
|
let fileUrl;
|
||||||
|
if (redirectResponse.type === 'opaqueredirect' || redirectResponse.status === 0) {
|
||||||
|
const followResponse = await fetch(apiUrl, {
|
||||||
|
method: 'GET',
|
||||||
|
credentials: 'include',
|
||||||
|
headers: {
|
||||||
|
'Accept': 'application/json, text/plain, */*',
|
||||||
|
'x-csrf': '1',
|
||||||
|
'x-uzenet-json-formatum': 'CamelCase',
|
||||||
|
'x-uzenet-lokalizacio': 'hu-HU',
|
||||||
|
'x-uzenet-verzio-szam': '1.2.3'
|
||||||
|
},
|
||||||
|
redirect: 'follow'
|
||||||
|
});
|
||||||
|
|
||||||
|
if (followResponse.ok) {
|
||||||
|
const blob = await followResponse.blob();
|
||||||
|
const base64 = await blobToBase64(blob);
|
||||||
|
return { success: true, data: base64, fileName: fileName };
|
||||||
|
}
|
||||||
|
} else if (redirectResponse.status === 302 || redirectResponse.status === 301) {
|
||||||
|
fileUrl = redirectResponse.headers.get('location');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (fileUrl) {
|
||||||
|
const fileResponse = await fetch(fileUrl, {
|
||||||
|
method: 'GET',
|
||||||
|
headers: {
|
||||||
|
'Accept': 'application/json, text/plain, */*',
|
||||||
|
'x-csrf': '1',
|
||||||
|
'x-uzenet-json-formatum': 'CamelCase',
|
||||||
|
'x-uzenet-lokalizacio': 'hu-HU',
|
||||||
|
'x-uzenet-verzio-szam': '1.2.3'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
if (fileResponse.ok) {
|
||||||
|
const blob = await fileResponse.blob();
|
||||||
|
const base64 = await blobToBase64(blob);
|
||||||
|
return { success: true, data: base64, fileName: fileName };
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return { success: false, error: 'Nem sikerült letölteni a mellékletet.' };
|
||||||
|
} catch (error) {
|
||||||
|
console.error('[Background] Attachment download error:', error);
|
||||||
|
return { success: false, error: error.message };
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function blobToBase64(blob) {
|
||||||
|
return new Promise((resolve, reject) => {
|
||||||
|
const reader = new FileReader();
|
||||||
|
reader.onloadend = () => resolve(reader.result);
|
||||||
|
reader.onerror = reject;
|
||||||
|
reader.readAsDataURL(blob);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
chrome.storage.onChanged.addListener((changes, namespace) => {
|
chrome.storage.onChanged.addListener((changes, namespace) => {
|
||||||
if (namespace === 'sync') {
|
if (namespace === 'sync') {
|
||||||
const firkaChanges = Object.keys(changes).filter(key => key.startsWith('firka_'));
|
const firkaChanges = Object.keys(changes).filter(key => key.startsWith('firka_'));
|
||||||
|
|||||||
@@ -17,72 +17,115 @@ const createTemplate = {
|
|||||||
const baseUrl = schoolSubdomain ? `https://${schoolSubdomain}.e-kreta.hu` : "";
|
const baseUrl = schoolSubdomain ? `https://${schoolSubdomain}.e-kreta.hu` : "";
|
||||||
const schoolNameFull = `${data.schoolInfo.id} - ${data.schoolInfo.name}`;
|
const schoolNameFull = `${data.schoolInfo.id} - ${data.schoolInfo.name}`;
|
||||||
const shortenedSchoolName = helper.shortenSchoolName(schoolNameFull);
|
const shortenedSchoolName = helper.shortenSchoolName(schoolNameFull);
|
||||||
|
const navItems = [
|
||||||
|
{ href: `${baseUrl}/Intezmeny/Faliujsag`, page: "dashboard", path: "/Intezmeny/Faliujsag", icon: "dashboard", label: LanguageManager.t("navigation.dashboard") },
|
||||||
|
{ href: `${baseUrl}/TanuloErtekeles/Osztalyzatok`, page: "grades", path: "/TanuloErtekeles/Osztalyzatok", icon: "grades", label: LanguageManager.t("navigation.grades") },
|
||||||
|
{ href: `${baseUrl}/Orarend/InformaciokOrarend`, page: "timetable", path: "/Orarend/InformaciokOrarend", icon: "timetable", label: LanguageManager.t("navigation.timetable") },
|
||||||
|
{ href: `${baseUrl}/Hianyzas/Hianyzasok`, page: "absences", path: "/Hianyzas/Hianyzasok", icon: "absences", label: LanguageManager.t("navigation.absences") },
|
||||||
|
{ href: "https://eugyintezes.e-kreta.hu/api/bff/login", page: "messages", path: "/" || "/uzenetek", icon: "messages", label: LanguageManager.t("navigation.messages") }
|
||||||
|
];
|
||||||
|
const desktopNavItems = navItems.map(item => {
|
||||||
|
const isActive = location.pathname === item.path;
|
||||||
|
return `<a href="${item.href}" data-page="${item.page}" class="nav-item ${isActive ? "active" : ""}">
|
||||||
|
<img src="${chrome.runtime.getURL("icons/" + item.icon + "-" + (isActive ? "active" : "inactive") + ".svg")}" alt="${item.label}">
|
||||||
|
${item.label}
|
||||||
|
</a>`;
|
||||||
|
}).join("");
|
||||||
|
const mobileNavItems = navItems.map(item => {
|
||||||
|
const isActive = location.pathname === item.path;
|
||||||
|
return `<a href="${item.href}" data-page="${item.page}" class="mobile-nav-item ${isActive ? "active" : ""}">
|
||||||
|
<img src="${chrome.runtime.getURL("icons/" + item.icon + "-" + (isActive ? "active" : "inactive") + ".svg")}" alt="${item.label}">
|
||||||
|
<span>${item.label}</span>
|
||||||
|
</a>`;
|
||||||
|
}).join("");
|
||||||
|
const userAvatarSvg = `<svg viewBox="0 0 24 24"><path d="M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/></svg>`;
|
||||||
|
|
||||||
const element = `<header class="kreta-header">
|
const element = `
|
||||||
<div class="school-info">
|
<header class="kreta-header">
|
||||||
<p class="logo-text">
|
<div class="school-info">
|
||||||
<img src="${chrome.runtime.getURL("images/firka_logo.png")}" alt="Firka" class="logo">
|
<p class="logo-text">
|
||||||
Firka
|
<img src="${chrome.runtime.getURL("images/firka_logo.png")}" alt="Firka" class="logo">
|
||||||
</p>
|
Firka
|
||||||
<div class="school-details" title="${schoolNameFull}">
|
</p>
|
||||||
${shortenedSchoolName}
|
<div class="school-details" title="${schoolNameFull}">
|
||||||
</div>
|
${shortenedSchoolName}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
<button class="nav-toggle" aria-label="${LanguageManager.t("navigation.nav_toggle")}">
|
|
||||||
<svg viewBox="0 0 24 24">
|
<nav class="kreta-nav">
|
||||||
<path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"/>
|
<div class="nav-links">
|
||||||
</svg>
|
${desktopNavItems}
|
||||||
</button>
|
</div>
|
||||||
|
</nav>
|
||||||
<nav class="kreta-nav">
|
|
||||||
<div class="nav-links">
|
|
||||||
<a href="${baseUrl}/Intezmeny/Faliujsag" data-page="dashboard" class="nav-item ${location.pathname == "/Intezmeny/Faliujsag" ? "active" : ""}">
|
|
||||||
<img src="${chrome.runtime.getURL("icons/dashboard-" + (location.pathname == "/Intezmeny/Faliujsag" ? "active" : "inactive") + ".svg")}" alt="${LanguageManager.t("navigation.dashboard")}">
|
|
||||||
${LanguageManager.t("navigation.dashboard")}
|
|
||||||
</a>
|
|
||||||
<a href="${baseUrl}/TanuloErtekeles/Osztalyzatok" data-page="grades" class="nav-item ${location.pathname == "/TanuloErtekeles/Osztalyzatok" ? "active" : ""}">
|
|
||||||
<img src="${chrome.runtime.getURL("icons/grades-" + (location.pathname == "/TanuloErtekeles/Osztalyzatok" ? "active" : "inactive") + ".svg")}" alt="${LanguageManager.t("navigation.grades")}">
|
|
||||||
${LanguageManager.t("navigation.grades")}
|
|
||||||
</a>
|
|
||||||
<a href="${baseUrl}/Orarend/InformaciokOrarend" data-page="timetable" class="nav-item ${location.pathname == "/Orarend/InformaciokOrarend" ? "active" : ""}">
|
|
||||||
<img src="${chrome.runtime.getURL("icons/timetable-" + (location.pathname == "/Orarend/InformaciokOrarend" ? "active" : "inactive") + ".svg")}" alt="${LanguageManager.t("navigation.timetable")}">
|
|
||||||
${LanguageManager.t("navigation.timetable")}
|
|
||||||
</a>
|
|
||||||
<a href="${baseUrl}/Hianyzas/Hianyzasok" data-page="absences" class="nav-item ${location.pathname == "/Hianyzas/Hianyzasok" ? "active" : ""}">
|
|
||||||
<img src="${chrome.runtime.getURL("icons/absences-" + (location.pathname == "/Hianyzas/Hianyzasok" ? "active" : "inactive") + ".svg")}" alt="${LanguageManager.t("navigation.absences")}">
|
|
||||||
${LanguageManager.t("navigation.absences")}
|
|
||||||
</a>
|
|
||||||
<a href="https://eugyintezes.e-kreta.hu/api/bff/login" data-page="messages" class="nav-item ${location.pathname == "/" ? "active" : ""}">
|
|
||||||
<img src="${chrome.runtime.getURL("icons/messages-" + (location.pathname == "/uzenetek" ? "active" : "inactive") + ".svg")}" alt="${LanguageManager.t("navigation.messages")}">
|
|
||||||
${LanguageManager.t("navigation.messages")}
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
<div class="user-profile">
|
<div class="user-profile">
|
||||||
<button class="user-dropdown-btn">
|
<button class="user-dropdown-btn">
|
||||||
<div class="user-info">
|
<div class="user-info">
|
||||||
<span class="user-name">${data.userData.name}</span>
|
<span class="user-name">${data.userData.name}</span>
|
||||||
<span class="nav-logout-timer" id="logoutTimer">${data.userData.time}</span>
|
<span class="nav-logout-timer" id="logoutTimer">${data.userData.time}</span>
|
||||||
</div>
|
|
||||||
</button>
|
|
||||||
<div class="user-dropdown">
|
|
||||||
<a href="${baseUrl}/Adminisztracio/Profil" data-page="profile" class="dropdown-item">
|
|
||||||
<img src="${chrome.runtime.getURL("icons/profile.svg")}" alt="${LanguageManager.t("navigation.profile")}">
|
|
||||||
${LanguageManager.t("navigation.profile")}
|
|
||||||
</a>
|
|
||||||
<a href="#" class="dropdown-item" id="settingsBtn">
|
|
||||||
<img src="${chrome.runtime.getURL("icons/settings.svg")}" alt="${LanguageManager.t("navigation.settings")}">
|
|
||||||
${LanguageManager.t("navigation.settings")}
|
|
||||||
</a>
|
|
||||||
<a href="${baseUrl}/Home/Logout" data-page="logout" class="dropdown-item">
|
|
||||||
<img src="${chrome.runtime.getURL("icons/logout.svg")}" alt="${LanguageManager.t("navigation.logout")}">
|
|
||||||
${LanguageManager.t("navigation.logout")}
|
|
||||||
</a>
|
|
||||||
</div>
|
</div>
|
||||||
|
<div class="user-avatar-icon">
|
||||||
|
${userAvatarSvg}
|
||||||
</div>
|
</div>
|
||||||
</header>`;
|
</button>
|
||||||
|
<div class="user-dropdown">
|
||||||
|
<a href="${baseUrl}/Adminisztracio/Profil" data-page="profile" class="dropdown-item">
|
||||||
|
<img src="${chrome.runtime.getURL("icons/profile.svg")}" alt="${LanguageManager.t("navigation.profile")}">
|
||||||
|
${LanguageManager.t("navigation.profile")}
|
||||||
|
</a>
|
||||||
|
<a href="#" class="dropdown-item" id="settingsBtn">
|
||||||
|
<img src="${chrome.runtime.getURL("icons/settings.svg")}" alt="${LanguageManager.t("navigation.settings")}">
|
||||||
|
${LanguageManager.t("navigation.settings")}
|
||||||
|
</a>
|
||||||
|
<a href="${baseUrl}/Home/Logout" data-page="logout" class="dropdown-item">
|
||||||
|
<img src="${chrome.runtime.getURL("icons/logout.svg")}" alt="${LanguageManager.t("navigation.logout")}">
|
||||||
|
${LanguageManager.t("navigation.logout")}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</header>
|
||||||
|
|
||||||
|
<header class="mobile-header">
|
||||||
|
<div class="school-info">
|
||||||
|
<p class="logo-text">
|
||||||
|
<img src="${chrome.runtime.getURL("images/firka_logo.png")}" alt="Firka" class="logo">
|
||||||
|
Firka
|
||||||
|
</p>
|
||||||
|
<div class="school-details" title="${schoolNameFull}">
|
||||||
|
${shortenedSchoolName}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</header>
|
||||||
|
|
||||||
|
<nav class="mobile-bottom-nav">
|
||||||
|
${mobileNavItems}
|
||||||
|
<button class="mobile-user-btn" id="mobileUserBtn">
|
||||||
|
<div class="user-avatar-icon">
|
||||||
|
${userAvatarSvg}
|
||||||
|
</div>
|
||||||
|
<span>${LanguageManager.t("navigation.profile")}</span>
|
||||||
|
</button>
|
||||||
|
</nav>
|
||||||
|
|
||||||
|
<div class="mobile-user-dropdown" id="mobileUserDropdown">
|
||||||
|
<div class="mobile-dropdown-header">
|
||||||
|
<span class="user-name">${data.userData.name}</span>
|
||||||
|
<span class="nav-logout-timer" id="mobileLogoutTimer">${data.userData.time}</span>
|
||||||
|
</div>
|
||||||
|
<a href="${baseUrl}/Adminisztracio/Profil" data-page="profile" class="mobile-dropdown-item">
|
||||||
|
<img src="${chrome.runtime.getURL("icons/profile.svg")}" alt="${LanguageManager.t("navigation.profile")}">
|
||||||
|
${LanguageManager.t("navigation.profile")}
|
||||||
|
</a>
|
||||||
|
<a href="#" class="mobile-dropdown-item" id="mobileSettingsBtn">
|
||||||
|
<img src="${chrome.runtime.getURL("icons/settings.svg")}" alt="${LanguageManager.t("navigation.settings")}">
|
||||||
|
${LanguageManager.t("navigation.settings")}
|
||||||
|
</a>
|
||||||
|
<a href="${baseUrl}/Home/Logout" data-page="logout" class="mobile-dropdown-item">
|
||||||
|
<img src="${chrome.runtime.getURL("icons/logout.svg")}" alt="${LanguageManager.t("navigation.logout")}">
|
||||||
|
${LanguageManager.t("navigation.logout")}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
|
||||||
const startTime = parseInt(data.userData.time?.match(/\d+/)?.[0] || "45");
|
const startTime = parseInt(data.userData.time?.match(/\d+/)?.[0] || "45");
|
||||||
let timeLeft = startTime * 60;
|
let timeLeft = startTime * 60;
|
||||||
@@ -90,11 +133,12 @@ const createTemplate = {
|
|||||||
const updateTimer = () => {
|
const updateTimer = () => {
|
||||||
const minutes = Math.floor(timeLeft / 60);
|
const minutes = Math.floor(timeLeft / 60);
|
||||||
const seconds = timeLeft % 60;
|
const seconds = timeLeft % 60;
|
||||||
const timerEl = document.getElementById("logoutTimer");
|
const timeText = `${minutes}:${seconds.toString().padStart(2, "0")}`;
|
||||||
if (timerEl) {
|
const desktopTimer = document.getElementById("logoutTimer");
|
||||||
timerEl.textContent = `${minutes}:${seconds.toString().padStart(2, "0")}`;
|
const mobileTimer = document.getElementById("mobileLogoutTimer");
|
||||||
}
|
|
||||||
|
if (desktopTimer) desktopTimer.textContent = timeText;
|
||||||
|
if (mobileTimer) mobileTimer.textContent = timeText;
|
||||||
if (timeLeft <= 0) {
|
if (timeLeft <= 0) {
|
||||||
window.location.href = "/Home/Logout";
|
window.location.href = "/Home/Logout";
|
||||||
} else {
|
} else {
|
||||||
@@ -110,7 +154,15 @@ const createTemplate = {
|
|||||||
|
|
||||||
document.addEventListener("DOMContentLoaded", async () => {
|
document.addEventListener("DOMContentLoaded", async () => {
|
||||||
await helper.waitForElement("#settingsBtn");
|
await helper.waitForElement("#settingsBtn");
|
||||||
document.querySelector("#settingsBtn").addEventListener("click", (e) => {
|
|
||||||
|
document.querySelector("#settingsBtn")?.addEventListener("click", (e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
e.stopPropagation();
|
||||||
|
const url = chrome.runtime.getURL("settings/index.html");
|
||||||
|
window.open(url, "_blank", "width=400,height=600");
|
||||||
|
});
|
||||||
|
|
||||||
|
document.querySelector("#mobileSettingsBtn")?.addEventListener("click", (e) => {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
const url = chrome.runtime.getURL("settings/index.html");
|
const url = chrome.runtime.getURL("settings/index.html");
|
||||||
|
|||||||
@@ -37,4 +37,28 @@ const helper = {
|
|||||||
const [hours, minutes] = timeStr.split(":").map(Number);
|
const [hours, minutes] = timeStr.split(":").map(Number);
|
||||||
return hours * 60 + minutes;
|
return hours * 60 + minutes;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
createElementFromHTML(htmlString) {
|
||||||
|
const template = document.createElement('template');
|
||||||
|
template.innerHTML = htmlString.trim();
|
||||||
|
return template.content;
|
||||||
|
},
|
||||||
|
|
||||||
|
setTextContent(element, text) {
|
||||||
|
element.textContent = text;
|
||||||
|
},
|
||||||
|
|
||||||
|
clearElement(element) {
|
||||||
|
while (element.firstChild) {
|
||||||
|
element.removeChild(element.firstChild);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
appendChildren(parent, children) {
|
||||||
|
if (Array.isArray(children)) {
|
||||||
|
children.forEach(child => parent.appendChild(child));
|
||||||
|
} else {
|
||||||
|
parent.appendChild(children);
|
||||||
|
}
|
||||||
|
}
|
||||||
};
|
};
|
||||||