Redesign strony WGDS Wykładziny (Astro + Tailwind) - audyt treści ze starego WP: galerie kolekcji w masonry, pelne archiwum realizacji (17), skany referencji, slider opinii, redirecty i skrypty materiałowe
7
.env.example
Normal file
@@ -0,0 +1,7 @@
|
||||
# SMTP do wysyłki formularza kontaktowego (skopiuj do .env i uzupełnij)
|
||||
SMTP_HOST=smtp.twojadomena.pl
|
||||
SMTP_PORT=465
|
||||
SMTP_USER=biuro@wgdswykladziny.pl
|
||||
SMTP_PASS=haslo
|
||||
# Adres, na który przychodzą zgłoszenia (domyślnie SMTP_USER)
|
||||
MAIL_TO=biuro@wgdswykladziny.pl
|
||||
15
.gitignore
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
# build output
|
||||
dist/
|
||||
# astro generated
|
||||
.astro/
|
||||
# dependencies
|
||||
node_modules/
|
||||
# env
|
||||
.env
|
||||
.env.local
|
||||
# misc
|
||||
.DS_Store
|
||||
npm-debug.log*
|
||||
# originals (restauruj przez npm run fetch-images)
|
||||
assets-originals/
|
||||
public/images-orig/
|
||||
20
astro.config.mjs
Normal file
@@ -0,0 +1,20 @@
|
||||
import { defineConfig } from 'astro/config';
|
||||
import sitemap from '@astrojs/sitemap';
|
||||
import node from '@astrojs/node';
|
||||
import tailwindcss from '@tailwindcss/vite';
|
||||
|
||||
export default defineConfig({
|
||||
site: 'https://wgdswykladziny.pl',
|
||||
output: 'static',
|
||||
adapter: node({ mode: 'standalone' }),
|
||||
integrations: [sitemap()],
|
||||
security: {
|
||||
// Formularz kontaktowy jest publiczny i chroniony honeypotem + rate-limitem w endpoincie.
|
||||
// checkOrigin blokuje POST na niestandardowych portach (localhost:4321).
|
||||
checkOrigin: false,
|
||||
},
|
||||
vite: {
|
||||
plugins: [tailwindcss()],
|
||||
},
|
||||
trailingSlash: 'never',
|
||||
});
|
||||
55
docs/porownanie-podstron.md
Normal file
@@ -0,0 +1,55 @@
|
||||
# Porównanie ze starą stroną — uzupełnione braki
|
||||
|
||||
Audyt przeprowadzony 2026-11-16 na podstawie oryginalnych podstron WordPress
|
||||
(`https://wgdswykladziny.pl/?page_id=NNNN`).
|
||||
|
||||
## Mapa podstron (stare → nowe)
|
||||
|
||||
Stare podstrony-drugiego-poziomu są zastąpione sekcjami z kotwicami
|
||||
na stronach oferty (mapa redirectów: `docs/redirects.md`).
|
||||
|
||||
| page_id | Stara podstrona | Nowy adres | Stan |
|
||||
|---|---|---|---|
|
||||
| 16505 | Wykładziny homogeniczne (jednorodne) | /oferta/wykladziny-pcv#homogeniczne | uzupełnione: galerie 10 kolekcji (IQ Natural/Granit/Optima/Eminent/Megalit, Primo/Micra/Eclipse Premium, Standard Plus, Somplan Plus), formaty rolek 2 m i płytek 610×610 |
|
||||
| 16527 | Wykładziny heterogeniczne | /oferta/wykladziny-pcv#heterogeniczne | uzupełnione: podział na kompaktowe / akustyczne / płytki winylowe, 10 kolekcji (Acczent, Optic Compact, Tapiflex, ID), TopClean XP PUR, tłumienie akustyczne do 20 dB, Tapiflex Stairs |
|
||||
| 16529 | Wykładziny elektrostatyczne | /oferta/wykladziny-pcv#elektrostatyczne | uzupełnione: galeria Toro SC, Granit SD, Eclipse SD |
|
||||
| 16531 | Wykładziny antypoślizgowe | /oferta/wykladziny-pcv#antypo | uzupełnione: galeria Excellence Wood, Excellence Naturals, Granit safe T., Safetred Aqua; akcesoria do stref mokrych (odpływy, listwy progowe, okładziny ścienne) |
|
||||
| 16549 | Wykładzina dywanowa w rolce | /oferta/wykladziny-dywanowe#w-rolce | uzupełnione: galeria Fortesse, Quartz New, Mozart, Schubert, Tweed; włókna PA/PP/wełna, szerokości 4–5 m |
|
||||
| 16547 | Płytka dywanowa | /oferta/wykladziny-dywanowe#plytki | uzupełnione: argument wymiany pojedynczej płytki (w oryginale bez zdjęć) |
|
||||
| 16539 | Linoleum XF | /oferta/linoleum-xf | uzupełnione: galeria Veneto XF 2,0/2,5/3,2 mm, Allegro XF, Etrusco XF, Style Emme/Elle XF; skład surowcowy i zabezpieczenie XF |
|
||||
| 16542 | Wykładziny ścienne | /oferta/wykladziny-scienne | uzupełnione: galeria Wallgard, Aquarelle Wall HFS; odporność chemiczna i konserwacja |
|
||||
| 16602 | Panele | /oferta/panele | uzupełnione: lakier Proteco / Proteco Natura |
|
||||
| 16606 | Chemia budowlana | /oferta/chemia-budowlana | uzupełnione: status autoryzowanego partnera Mapei (linia podłóg), doradca techniczny |
|
||||
| 16604 | Wycieraczki obiektowe | /oferta/wycieraczki-obiektowe | uzupełnione: maty tekstylne |
|
||||
| 16608 | Montaż wykładzin | /oferta/montaz | uzupełnione: pełna lista usług z oryginału (cokoły, prądoprzewodzące pełny system, spawanie PCV i Linoleum, czyszczenie i konserwacja) |
|
||||
|
||||
Pozostałe: 13396 → /o-firmie, 16513 → /oferta, 5864 → /realizacje,
|
||||
16492 → /referencje, 1452 → /kontakt — już obecne.
|
||||
|
||||
## Materiały pobrane w ramach audytu
|
||||
|
||||
- `public/images/kolekcje/` — 41 zdjęć kolekcji ze starych podstron
|
||||
(katalog `/images/` starego WP, pobrane `npm run fetch-images`).
|
||||
- `public/images/referencje/ref1..5.jpg` — skany listów referencyjnych
|
||||
(oryginalna strona 16492; wcześniej mieliśmy tylko cytaty tekstowe).
|
||||
- `public/images/realizacje/` — 7 brakujących obiektów z archiwum portfolio:
|
||||
Decathlon Białystok/Ustowo (40.jpg), Szkoła nr 20 (22.jpg), Zakątek (15.jpg),
|
||||
Klonowica (8.jpg), Metalmex (62.jpg), B&R (b-r.jpg), City Center (51.jpg).
|
||||
Uwaga: dawne 404 wynikało z błędnych adresów — właściwe pliki się pobierają.
|
||||
|
||||
## Realizacje (portfolio)
|
||||
|
||||
Oryginał ma 17 pozycji (w tym strona 2 archiwum). Było 10, jest 17 —
|
||||
dopisane w `src/data/realizacje.ts`.
|
||||
|
||||
## Uwagi
|
||||
|
||||
- Grafiki kolekcji mają na originiale skrajnie różne proporcje (0.46–7.33).
|
||||
Nie normalizujemy ich do jednego kadru (powstawały brzydkie białe marginesy) —
|
||||
galerię renderujemy jako masonry (`columns: 190px`), każda paleta zachowuje
|
||||
swoją naturalną proporcję. Pipeline materiałowy: `npm run fetch-images` →
|
||||
`node scripts/optimize-images.mjs`.
|
||||
- Błąd w oryginale: nagłówek na stronie heterogenicznej (16527) omyłkowo
|
||||
tytułuje sekcję „homogeniczne”; poprawione w naszej treści.
|
||||
- Literówka oryginału „Venrto 3,2 mm” → Veneto XF 3,2 mm.
|
||||
- Stopka starej strony zawierała placeholder „Lorem ipsum” — nie przenoszone.
|
||||
103
docs/redirects.md
Normal file
@@ -0,0 +1,103 @@
|
||||
# Redirecty ze starej strony (WordPress ?page_id=...)
|
||||
|
||||
Stare adresy mają format `https://wgdswykladziny.pl/?page_id=NNNN`.
|
||||
Poniższe reguły wdróż na serwerze docelowym (wybierz jeden wariant).
|
||||
Fallback JavaScript jest już wbudowany w layout — zadziała nawet bez reguł serwerowych,
|
||||
ale wersja serwerowa jest właściwa dla SEO (kody 301).
|
||||
|
||||
## Mapa
|
||||
|
||||
| page_id | Nowy adres |
|
||||
|---|---|
|
||||
| 13396 | /o-firmie |
|
||||
| 16513 | /oferta |
|
||||
| 16523 | /oferta/wykladziny-pcv |
|
||||
| 16505 | /oferta/wykladziny-pcv#homogeniczne |
|
||||
| 16527 | /oferta/wykladziny-pcv#heterogeniczne |
|
||||
| 16529 | /oferta/wykladziny-pcv#elektrostatyczne |
|
||||
| 16531 | /oferta/wykladziny-pcv#antypo |
|
||||
| 16539 | /oferta/linoleum-xf |
|
||||
| 16542 | /oferta/wykladziny-scienne |
|
||||
| 16545 | /oferta/wykladziny-dywanowe |
|
||||
| 16549 | /oferta/wykladziny-dywanowe#w-rolce |
|
||||
| 16547 | /oferta/wykladziny-dywanowe#plytki |
|
||||
| 16602 | /oferta/panele |
|
||||
| 16606 | /oferta/chemia-budowlana |
|
||||
| 16604 | /oferta/wycieraczki-obiektowe |
|
||||
| 16608 | /oferta/montaz |
|
||||
| 5864 | /realizacje |
|
||||
| 16492 | /referencje |
|
||||
| 1452 | /kontakt |
|
||||
|
||||
## Apache (.htaccess w katalogu public_html)
|
||||
|
||||
```apache
|
||||
RewriteEngine On
|
||||
RewriteCond %{QUERY_STRING} page_id=(13396) [NC]
|
||||
RewriteRule ^$ /o-firmie? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16513) [NC]
|
||||
RewriteRule ^$ /oferta? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16523) [NC]
|
||||
RewriteRule ^$ /oferta/wykladziny-pcv? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16539) [NC]
|
||||
RewriteRule ^$ /oferta/linoleum-xf? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16542) [NC]
|
||||
RewriteRule ^$ /oferta/wykladziny-scienne? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16545) [NC]
|
||||
RewriteRule ^$ /oferta/wykladziny-dywanowe? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16602) [NC]
|
||||
RewriteRule ^$ /oferta/panele? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16606) [NC]
|
||||
RewriteRule ^$ /oferta/chemia-budowlana? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16604) [NC]
|
||||
RewriteRule ^$ /oferta/wycieraczki-obiektowe? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16608) [NC]
|
||||
RewriteRule ^$ /oferta/montaz? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(5864) [NC]
|
||||
RewriteRule ^$ /realizacje? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16492) [NC]
|
||||
RewriteRule ^$ /referencje? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(1452) [NC]
|
||||
RewriteRule ^$ /kontakt? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16505|16527|16529|16531) [NC]
|
||||
RewriteRule ^$ /oferta/wykladziny-pcv? [R=301,L]
|
||||
RewriteCond %{QUERY_STRING} page_id=(16547|16549) [NC]
|
||||
RewriteRule ^$ /oferta/wykladziny-dywanowe? [R=301,L]
|
||||
```
|
||||
|
||||
## nginx
|
||||
|
||||
```nginx
|
||||
if ($arg_page_id = 13396) { return 301 /o-firmie; }
|
||||
if ($arg_page_id = 16513) { return 301 /oferta; }
|
||||
if ($arg_page_id = 16523) { return 301 /oferta/wykladziny-pcv; }
|
||||
if ($arg_page_id = 16505) { return 301 /oferta/wykladziny-pcv#homogeniczne; }
|
||||
if ($arg_page_id = 16527) { return 301 /oferta/wykladziny-pcv#heterogeniczne; }
|
||||
if ($arg_page_id = 16529) { return 301 /oferta/wykladziny-pcv#elektrostatyczne; }
|
||||
if ($arg_page_id = 16531) { return 301 /oferta/wykladziny-pcv#antypo; }
|
||||
if ($arg_page_id = 16539) { return 301 /oferta/linoleum-xf; }
|
||||
if ($arg_page_id = 16542) { return 301 /oferta/wykladziny-scienne; }
|
||||
if ($arg_page_id = 16545) { return 301 /oferta/wykladziny-dywanowe; }
|
||||
if ($arg_page_id = 16549) { return 301 /oferta/wykladziny-dywanowe#w-rolce; }
|
||||
if ($arg_page_id = 16547) { return 301 /oferta/wykladziny-dywanowe#plytki; }
|
||||
if ($arg_page_id = 16602) { return 301 /oferta/panele; }
|
||||
if ($arg_page_id = 16606) { return 301 /oferta/chemia-budowlana; }
|
||||
if ($arg_page_id = 16604) { return 301 /oferta/wycieraczki-obiektowe; }
|
||||
if ($arg_page_id = 16608) { return 301 /oferta/montaz; }
|
||||
if ($arg_page_id = 5864) { return 301 /realizacje; }
|
||||
if ($arg_page_id = 16492) { return 301 /referencje; }
|
||||
if ($arg_page_id = 1452) { return 301 /kontakt; }
|
||||
```
|
||||
|
||||
## Proxy Node za nginx/Apache
|
||||
|
||||
Build `standalone` wystawia się jako serwis (`node dist/server/entry.mjs`), a nginx/apache
|
||||
proxyje cały ruch do portu 4321. Przykład nginx:
|
||||
|
||||
```nginx
|
||||
location / {
|
||||
proxy_pass http://127.0.0.1:4321;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
}
|
||||
```
|
||||
7031
package-lock.json
generated
Normal file
26
package.json
Normal file
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"name": "wgds-wykladziny",
|
||||
"type": "module",
|
||||
"version": "1.0.0",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "astro dev",
|
||||
"build": "astro build",
|
||||
"preview": "astro preview",
|
||||
"astro": "astro",
|
||||
"fetch-images": "node scripts/fetch-images.mjs",
|
||||
"fetch-fonts": "node scripts/fetch-fonts.mjs"
|
||||
},
|
||||
"dependencies": {
|
||||
"@astrojs/node": "^9.2.0",
|
||||
"@astrojs/sitemap": "^3.4.0",
|
||||
"astro": "^5.16.0",
|
||||
"nodemailer": "^7.0.0",
|
||||
"tailwindcss": "^4.1.0",
|
||||
"@tailwindcss/vite": "^4.1.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/nodemailer": "^6.4.17",
|
||||
"sharp": "^0.34.0"
|
||||
}
|
||||
}
|
||||
3
public/_redirects
Normal file
@@ -0,0 +1,3 @@
|
||||
# Redirecty WordPress (?page_id=) realizuje warstwa serwera (patrz docs/redirects.md)
|
||||
# oraz fallback JavaScript w layoutcie. Plik pozostawiony na dodatkowe reguły.
|
||||
/wordpress/ / 301
|
||||
5
public/favicon.svg
Normal file
@@ -0,0 +1,5 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64">
|
||||
<rect width="64" height="64" rx="14" fill="#21576b"/>
|
||||
<text x="32" y="41" font-family="Arial, Helvetica, sans-serif" font-size="26" font-weight="800" fill="#ffffff" text-anchor="middle">WG</text>
|
||||
<rect x="14" y="48" width="36" height="6" rx="3" fill="#c05a3c"/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 336 B |
BIN
public/fonts/bricolage-grotesque-latin-ext.woff2
Normal file
BIN
public/fonts/bricolage-grotesque-latin.woff2
Normal file
BIN
public/fonts/inter-tight-latin-ext.woff2
Normal file
BIN
public/fonts/inter-tight-latin.woff2
Normal file
BIN
public/images/cert-tarkett.jpg
Normal file
|
After Width: | Height: | Size: 43 KiB |
BIN
public/images/hero/black.jpg
Normal file
|
After Width: | Height: | Size: 151 KiB |
BIN
public/images/hero/cambridge.jpg
Normal file
|
After Width: | Height: | Size: 185 KiB |
BIN
public/images/hero/perpetual-2.jpg
Normal file
|
After Width: | Height: | Size: 224 KiB |
BIN
public/images/kolekcje/acczent.jpg
Normal file
|
After Width: | Height: | Size: 30 KiB |
BIN
public/images/kolekcje/allegro-xf-25-mm.jpg
Normal file
|
After Width: | Height: | Size: 14 KiB |
BIN
public/images/kolekcje/aquarelle-wall-hfs.jpg
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
public/images/kolekcje/eclipse_premium.jpg
Normal file
|
After Width: | Height: | Size: 33 KiB |
BIN
public/images/kolekcje/eclipse_sd.jpg
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
public/images/kolekcje/essential_30.jpg
Normal file
|
After Width: | Height: | Size: 37 KiB |
BIN
public/images/kolekcje/essential_50.jpg
Normal file
|
After Width: | Height: | Size: 45 KiB |
BIN
public/images/kolekcje/etrusco-xf-25-mm.jpg
Normal file
|
After Width: | Height: | Size: 5.4 KiB |
BIN
public/images/kolekcje/evolution.jpg
Normal file
|
After Width: | Height: | Size: 83 KiB |
BIN
public/images/kolekcje/excellence_65.jpg
Normal file
|
After Width: | Height: | Size: 73 KiB |
BIN
public/images/kolekcje/fortesse.jpg
Normal file
|
After Width: | Height: | Size: 33 KiB |
BIN
public/images/kolekcje/granit-safet.jpg
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
public/images/kolekcje/granit_sd.jpg
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
public/images/kolekcje/inspiration_55.jpg
Normal file
|
After Width: | Height: | Size: 94 KiB |
BIN
public/images/kolekcje/inspiration_70.jpg
Normal file
|
After Width: | Height: | Size: 94 KiB |
BIN
public/images/kolekcje/iq_eminent.jpg
Normal file
|
After Width: | Height: | Size: 43 KiB |
BIN
public/images/kolekcje/iq_granit.jpg
Normal file
|
After Width: | Height: | Size: 45 KiB |
BIN
public/images/kolekcje/iq_megalit.jpg
Normal file
|
After Width: | Height: | Size: 32 KiB |
BIN
public/images/kolekcje/iq_natural.jpg
Normal file
|
After Width: | Height: | Size: 25 KiB |
BIN
public/images/kolekcje/iq_optima.jpg
Normal file
|
After Width: | Height: | Size: 88 KiB |
BIN
public/images/kolekcje/micra_premium.jpg
Normal file
|
After Width: | Height: | Size: 34 KiB |
BIN
public/images/kolekcje/optic.jpg
Normal file
|
After Width: | Height: | Size: 93 KiB |
BIN
public/images/kolekcje/pm-mozart.jpg
Normal file
|
After Width: | Height: | Size: 34 KiB |
BIN
public/images/kolekcje/pm-schubert.jpg
Normal file
|
After Width: | Height: | Size: 9.9 KiB |
BIN
public/images/kolekcje/primo_premium.jpg
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
public/images/kolekcje/quartz-new.jpg
Normal file
|
After Width: | Height: | Size: 26 KiB |
BIN
public/images/kolekcje/safetred-aqua.jpg
Normal file
|
After Width: | Height: | Size: 26 KiB |
BIN
public/images/kolekcje/safetred-excellence-naturals.jpg
Normal file
|
After Width: | Height: | Size: 10 KiB |
BIN
public/images/kolekcje/safetred-excellence-wood.jpg
Normal file
|
After Width: | Height: | Size: 11 KiB |
BIN
public/images/kolekcje/somplan_plus.jpg
Normal file
|
After Width: | Height: | Size: 22 KiB |
BIN
public/images/kolekcje/standard_plus.jpg
Normal file
|
After Width: | Height: | Size: 26 KiB |
BIN
public/images/kolekcje/style-elle-xf.jpg
Normal file
|
After Width: | Height: | Size: 3.5 KiB |
BIN
public/images/kolekcje/style-emme-xf.jpg
Normal file
|
After Width: | Height: | Size: 9.9 KiB |
BIN
public/images/kolekcje/tapiflex_evolution.jpg
Normal file
|
After Width: | Height: | Size: 66 KiB |
BIN
public/images/kolekcje/tapiflex_stairs.jpg
Normal file
|
After Width: | Height: | Size: 13 KiB |
BIN
public/images/kolekcje/toro_sc.jpg
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
public/images/kolekcje/tweed.jpg
Normal file
|
After Width: | Height: | Size: 41 KiB |
BIN
public/images/kolekcje/veneto-xf-20-mm.jpg
Normal file
|
After Width: | Height: | Size: 68 KiB |
BIN
public/images/kolekcje/veneto-xf-25-mm.jpg
Normal file
|
After Width: | Height: | Size: 68 KiB |
BIN
public/images/kolekcje/veneto-xf-32-mm.jpg
Normal file
|
After Width: | Height: | Size: 8.9 KiB |
BIN
public/images/kolekcje/wallgard.jpg
Normal file
|
After Width: | Height: | Size: 1.7 KiB |
BIN
public/images/realizacje/br-strzeszynska.jpg
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
public/images/realizacje/city-center.jpg
Normal file
|
After Width: | Height: | Size: 53 KiB |
BIN
public/images/realizacje/decathlon.jpg
Normal file
|
After Width: | Height: | Size: 35 KiB |
BIN
public/images/realizacje/dpd-komorniki.jpg
Normal file
|
After Width: | Height: | Size: 147 KiB |
BIN
public/images/realizacje/klonowica.jpg
Normal file
|
After Width: | Height: | Size: 32 KiB |
BIN
public/images/realizacje/metalmex.jpg
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
public/images/realizacje/ops-suchy-las.jpg
Normal file
|
After Width: | Height: | Size: 99 KiB |
BIN
public/images/realizacje/park-point.jpg
Normal file
|
After Width: | Height: | Size: 46 KiB |
BIN
public/images/realizacje/przedszkole.jpg
Normal file
|
After Width: | Height: | Size: 46 KiB |
BIN
public/images/realizacje/przychodnia.jpg
Normal file
|
After Width: | Height: | Size: 8.9 KiB |
BIN
public/images/realizacje/sianowska.jpg
Normal file
|
After Width: | Height: | Size: 31 KiB |
BIN
public/images/realizacje/siku.jpg
Normal file
|
After Width: | Height: | Size: 74 KiB |
BIN
public/images/realizacje/szkola-sierakowska.jpg
Normal file
|
After Width: | Height: | Size: 73 KiB |
BIN
public/images/realizacje/szkola20.jpg
Normal file
|
After Width: | Height: | Size: 39 KiB |
BIN
public/images/realizacje/universytet.jpg
Normal file
|
After Width: | Height: | Size: 46 KiB |
BIN
public/images/realizacje/wix-filtron.jpg
Normal file
|
After Width: | Height: | Size: 27 KiB |
BIN
public/images/realizacje/zakatek.jpg
Normal file
|
After Width: | Height: | Size: 33 KiB |
BIN
public/images/referencje/ref1.jpg
Normal file
|
After Width: | Height: | Size: 53 KiB |
BIN
public/images/referencje/ref2.jpg
Normal file
|
After Width: | Height: | Size: 34 KiB |
BIN
public/images/referencje/ref3.jpg
Normal file
|
After Width: | Height: | Size: 37 KiB |
BIN
public/images/referencje/ref4.jpg
Normal file
|
After Width: | Height: | Size: 61 KiB |
BIN
public/images/referencje/ref5.jpg
Normal file
|
After Width: | Height: | Size: 48 KiB |
4
public/robots.txt
Normal file
@@ -0,0 +1,4 @@
|
||||
User-agent: *
|
||||
Allow: /
|
||||
|
||||
Sitemap: https://wgdswykladziny.pl/sitemap-index.xml
|
||||
59
scripts/fetch-fonts.mjs
Normal file
@@ -0,0 +1,59 @@
|
||||
import { mkdir, writeFile, access } from 'node:fs/promises';
|
||||
|
||||
const OUT = new URL('../public/fonts/', import.meta.url);
|
||||
const UA =
|
||||
'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0 Safari/537.36';
|
||||
|
||||
const families = [
|
||||
{ css: 'Bricolage+Grotesque:opsz,wght@12..96,400..800', file: 'bricolage-grotesque', label: 'Bricolage Grotesque' },
|
||||
{ css: 'Inter+Tight:wght@400..800', file: 'inter-tight', label: 'Inter Tight' },
|
||||
];
|
||||
|
||||
const wants = new Set(['latin', 'latin-ext']);
|
||||
|
||||
async function exists(url) {
|
||||
try {
|
||||
await access(url);
|
||||
return true;
|
||||
} catch {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
async function fetchText(url) {
|
||||
const res = await fetch(url, { headers: { 'User-Agent': UA } });
|
||||
if (!res.ok) throw new Error(`HTTP ${res.status} for ${url}`);
|
||||
return res.text();
|
||||
}
|
||||
|
||||
async function fetchBinary(url) {
|
||||
const res = await fetch(url, { headers: { 'User-Agent': UA } });
|
||||
if (!res.ok) throw new Error(`HTTP ${res.status} for ${url}`);
|
||||
return Buffer.from(await res.arrayBuffer());
|
||||
}
|
||||
|
||||
await mkdir(OUT, { recursive: true });
|
||||
|
||||
for (const fam of families) {
|
||||
const css = await fetchText(`https://fonts.googleapis.com/css2?family=${fam.css}&display=swap`);
|
||||
const blocks = [...css.matchAll(/\/\*\s*([\w-]+)\s*\*\/\s*@font-face\s*\{([^}]+)\}/g)];
|
||||
let found = 0;
|
||||
for (const [, subset, body] of blocks) {
|
||||
if (!wants.has(subset)) continue;
|
||||
const url = body.match(/url\((https:[^)]+\.woff2)\)/)?.[1];
|
||||
if (!url) continue;
|
||||
const dest = new URL(`${fam.file}-${subset}.woff2`, OUT);
|
||||
if (await exists(dest)) {
|
||||
console.log(`skip ${dest.pathname}`);
|
||||
found++;
|
||||
continue;
|
||||
}
|
||||
const buf = await fetchBinary(url);
|
||||
await writeFile(dest, buf);
|
||||
console.log(`ok ${fam.label} ${subset} (${(buf.length / 1024).toFixed(1)} kB)`);
|
||||
found++;
|
||||
}
|
||||
if (found === 0) throw new Error(`no woff2 subsets found for ${fam.label}`);
|
||||
}
|
||||
|
||||
console.log('fonts ready in public/fonts/');
|
||||
127
scripts/fetch-images.mjs
Normal file
@@ -0,0 +1,127 @@
|
||||
import { mkdir, writeFile } from 'node:fs/promises';
|
||||
import path from 'node:path';
|
||||
|
||||
const OUT = path.resolve('public/images');
|
||||
|
||||
const manifest = [
|
||||
{ url: 'http://test.wgdswykladziny.pl/wp-content/uploads/2015/06/Perpetual-2_1680x1050.jpg', out: 'hero/perpetual-2.jpg' },
|
||||
{ url: 'http://test.wgdswykladziny.pl/wp-content/uploads/2015/06/Cambridge_1680x1050.jpg', out: 'hero/cambridge.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/06/Black_1680x1050.jpg', out: 'hero/black.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2014/08/cer_tarkett.jpg', out: 'cert-tarkett.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/10/DSC_0004-e1444208140610.jpg', out: 'realizacje/dpd-komorniki.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/10/20150810_152519.jpeg', out: 'realizacje/wix-filtron.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/10/IMG_20150827_155335.jpg', out: 'realizacje/universytet.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/07/IMG_72751.jpg', out: 'realizacje/park-point.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/07/IMG_6344-e1436969916560.jpg', out: 'realizacje/siku.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/07/IMG_4340.jpg', out: 'realizacje/sianowska.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/07/IMG_4332-e1436963550343.jpg', out: 'realizacje/ops-suchy-las.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/07/IMG_4025-e1436206862474.jpg', out: 'realizacje/przedszkole.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/07/IMG_3686.jpg', out: 'realizacje/szkola-sierakowska.jpg' },
|
||||
// Realizacje ze strony 2 archiwum (5864 paged=2) + brakujące z strony 1:
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2013/10/40.jpg', out: 'realizacje/decathlon.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2013/10/22.jpg', out: 'realizacje/szkola20.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2013/10/15.jpg', out: 'realizacje/zakatek.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2013/10/8.jpg', out: 'realizacje/klonowica.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/06/62.jpg', out: 'realizacje/metalmex.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/05/b-r.jpg', out: 'realizacje/br-strzeszynska.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2013/10/51.jpg', out: 'realizacje/city-center.jpg' },
|
||||
// Skany referencji (strona 16492):
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/06/ref1.jpg', out: 'referencje/ref1.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/06/ref2.jpg', out: 'referencje/ref2.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/06/ref3.jpg', out: 'referencje/ref3.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/06/ref4.jpg', out: 'referencje/ref4.jpg' },
|
||||
{ url: 'http://wgdswykladziny.pl/wp-content/uploads/2015/06/ref5.jpg', out: 'referencje/ref5.jpg' },
|
||||
// Galerie kolekcji z podstron oferty (katalog /images/ starego WP):
|
||||
// homogeniczne (16505):
|
||||
{ url: 'https://wgdswykladziny.pl/images/iq_natural.jpg', out: 'kolekcje/iq_natural.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/iq_granit.jpg', out: 'kolekcje/iq_granit.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/iq_optima.jpg', out: 'kolekcje/iq_optima.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/iq_eminent.jpg', out: 'kolekcje/iq_eminent.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/iq_megalit.jpg', out: 'kolekcje/iq_megalit.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/primo_premium.jpg', out: 'kolekcje/primo_premium.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/micra_premium.jpg', out: 'kolekcje/micra_premium.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/eclipse_premium.jpg', out: 'kolekcje/eclipse_premium.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/standard_plus.jpg', out: 'kolekcje/standard_plus.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/somplan_plus.jpg', out: 'kolekcje/somplan_plus.jpg' },
|
||||
// heterogeniczne (16527):
|
||||
{ url: 'https://wgdswykladziny.pl/images/acczent.jpg', out: 'kolekcje/acczent.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/optic.jpg', out: 'kolekcje/optic.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/evolution.jpg', out: 'kolekcje/evolution.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/excellence_65.jpg', out: 'kolekcje/excellence_65.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/essential_50.jpg', out: 'kolekcje/essential_50.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/tapiflex_evolution.jpg', out: 'kolekcje/tapiflex_evolution.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/tapiflex_stairs.jpg', out: 'kolekcje/tapiflex_stairs.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/inspiration_55.jpg', out: 'kolekcje/inspiration_55.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/inspiration_70.jpg', out: 'kolekcje/inspiration_70.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/essential_30.jpg', out: 'kolekcje/essential_30.jpg' },
|
||||
// elektrostatyczne (16529):
|
||||
{ url: 'https://wgdswykladziny.pl/images/toro_sc.jpg', out: 'kolekcje/toro_sc.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/granit_sd.jpg', out: 'kolekcje/granit_sd.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/eclipse_sd.jpg', out: 'kolekcje/eclipse_sd.jpg' },
|
||||
// antypoślizgowe (16531):
|
||||
{ url: 'https://wgdswykladziny.pl/images/safetred-excellence-wood.jpg', out: 'kolekcje/safetred-excellence-wood.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/safetred-excellence-naturals.jpg', out: 'kolekcje/safetred-excellence-naturals.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/granit-safet.jpg', out: 'kolekcje/granit-safet.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/safetred-aqua.jpg', out: 'kolekcje/safetred-aqua.jpg' },
|
||||
// linoleum XF (16539):
|
||||
{ url: 'https://wgdswykladziny.pl/images/veneto-xf-20-mm.jpg', out: 'kolekcje/veneto-xf-20-mm.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/veneto-xf-25-mm.jpg', out: 'kolekcje/veneto-xf-25-mm.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/veneto-xf-32-mm.jpg', out: 'kolekcje/veneto-xf-32-mm.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/allegro-xf-25-mm.jpg', out: 'kolekcje/allegro-xf-25-mm.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/etrusco-xf-25-mm.jpg', out: 'kolekcje/etrusco-xf-25-mm.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/style-emme-xf.jpg', out: 'kolekcje/style-emme-xf.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/style-elle-xf.jpg', out: 'kolekcje/style-elle-xf.jpg' },
|
||||
// ścienne (16542):
|
||||
{ url: 'https://wgdswykladziny.pl/images/wallgard.jpg', out: 'kolekcje/wallgard.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/aquarelle-wall-hfs.jpg', out: 'kolekcje/aquarelle-wall-hfs.jpg' },
|
||||
// dywanowe w rolce (16549):
|
||||
{ url: 'https://wgdswykladziny.pl/images/fortesse.jpg', out: 'kolekcje/fortesse.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/quartz-new.jpg', out: 'kolekcje/quartz-new.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/pm-mozart.jpg', out: 'kolekcje/pm-mozart.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/pm-schubert.jpg', out: 'kolekcje/pm-schubert.jpg' },
|
||||
{ url: 'https://wgdswykladziny.pl/images/tweed.jpg', out: 'kolekcje/tweed.jpg' },
|
||||
];
|
||||
|
||||
let ok = 0;
|
||||
const failed = [];
|
||||
|
||||
for (const item of manifest) {
|
||||
const target = path.join(OUT, item.out);
|
||||
const { stat } = await import('node:fs/promises');
|
||||
try {
|
||||
const info = await stat(target);
|
||||
if (info.size > 1000) {
|
||||
console.log(`SKIP ${item.out} (już pobrane)`);
|
||||
ok++;
|
||||
continue;
|
||||
}
|
||||
} catch {}
|
||||
let done = false;
|
||||
for (let attempt = 1; attempt <= 4 && !done; attempt++) {
|
||||
try {
|
||||
const res = await fetch(item.url, { signal: AbortSignal.timeout(30_000) });
|
||||
if (!res.ok) throw new Error(`HTTP ${res.status}`);
|
||||
const buf = Buffer.from(await res.arrayBuffer());
|
||||
if (buf.length < 1000) throw new Error(`odpowiedź zbyt mała (${buf.length} B)`);
|
||||
await mkdir(path.dirname(target), { recursive: true });
|
||||
await writeFile(target, buf);
|
||||
console.log(`OK ${item.out} ${(buf.length / 1024).toFixed(0)} kB`);
|
||||
ok++;
|
||||
done = true;
|
||||
} catch (err) {
|
||||
if (attempt === 4) {
|
||||
console.error(`ERR ${item.out}: ${err.message}`);
|
||||
failed.push(item.out);
|
||||
} else {
|
||||
await new Promise((r) => setTimeout(r, 1500 * attempt));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
console.log(`\nPobrane: ${ok}/${manifest.length}`);
|
||||
if (failed.length) {
|
||||
console.log('Nie pobrano:');
|
||||
for (const f of failed) console.log(` - ${f}`);
|
||||
process.exitCode = 1;
|
||||
}
|
||||
10
scripts/kolekcje-dims.mjs
Normal file
@@ -0,0 +1,10 @@
|
||||
import sharp from 'sharp';
|
||||
import { readdir } from 'node:fs/promises';
|
||||
import path from 'node:path';
|
||||
|
||||
const dir = path.resolve('public/images/kolekcje');
|
||||
const files = (await readdir(dir)).filter((f) => /\.jpe?g$/i.test(f));
|
||||
for (const f of files) {
|
||||
const meta = await sharp(path.join(dir, f)).metadata();
|
||||
console.log(`${f}\t${meta.width}x${meta.height}\t${(meta.width / meta.height).toFixed(2)}`);
|
||||
}
|
||||
44
scripts/optimize-images.mjs
Normal file
@@ -0,0 +1,44 @@
|
||||
import sharp from 'sharp';
|
||||
import { readdir, stat, mkdir, copyFile } from 'node:fs/promises';
|
||||
import path from 'node:path';
|
||||
|
||||
const ROOT = path.resolve('public/images');
|
||||
const ORIG = path.resolve('public/images-orig');
|
||||
|
||||
const specs = [
|
||||
{ dir: 'hero', maxWidth: 1680, quality: 80 },
|
||||
{ dir: 'realizacje', maxWidth: 1000, quality: 80 },
|
||||
{ dir: 'kolekcje', maxWidth: 640, quality: 78 },
|
||||
{ dir: 'referencje', maxWidth: 1400, quality: 80 },
|
||||
{ dir: '', files: ['cert-tarkett.jpg'], maxWidth: 800, quality: 82 },
|
||||
];
|
||||
|
||||
let savedBytes = 0;
|
||||
for (const spec of specs) {
|
||||
const absDir = path.join(ROOT, spec.dir);
|
||||
let files;
|
||||
try {
|
||||
files = (await readdir(absDir)).filter((f) => /\.(jpe?g|png)$/i.test(f));
|
||||
} catch {
|
||||
continue;
|
||||
}
|
||||
for (const file of files) {
|
||||
const abs = path.join(absDir, file);
|
||||
const rel = path.relative(ROOT, abs);
|
||||
const before = (await stat(abs)).size;
|
||||
const backup = path.join(ORIG, rel);
|
||||
await mkdir(path.dirname(backup), { recursive: true });
|
||||
try {
|
||||
await copyFile(abs, backup);
|
||||
} catch {}
|
||||
const info = await sharp(abs)
|
||||
.resize({ width: Math.min(spec.maxWidth, 4096), withoutEnlargement: true })
|
||||
.jpeg({ quality: spec.quality, progressive: true, mozjpeg: true })
|
||||
.toFile(abs + '.tmp');
|
||||
await import('node:fs/promises').then((fs) => fs.rename(abs + '.tmp', abs));
|
||||
const after = info.size;
|
||||
savedBytes += before - after;
|
||||
console.log(`${rel}: ${(before / 1024).toFixed(0)}kB -> ${(after / 1024).toFixed(0)}kB`);
|
||||
}
|
||||
}
|
||||
console.log(`\nZaoszczędzono ~${(savedBytes / 1024 / 1024).toFixed(1)} MB (oryginały w public/images-orig/)`);
|
||||
52
scripts/probe-original.mjs
Normal file
@@ -0,0 +1,52 @@
|
||||
import { readFile, writeFile } from 'node:fs/promises';
|
||||
|
||||
const IDS = process.argv.slice(2).map(Number);
|
||||
if (!IDS.length) {
|
||||
console.error('usage: node scripts/probe-original.mjs <page_id> [...page_id]');
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
const BASE = 'https://wgdswykladziny.pl/?page_id=';
|
||||
|
||||
function contentSlice(html) {
|
||||
const start = html.indexOf('default_template_holder');
|
||||
const end = html.indexOf('<div class="content_bottom"');
|
||||
return start > -1 && end > start ? html.slice(start, end) : html;
|
||||
}
|
||||
|
||||
function extract(html) {
|
||||
const body = contentSlice(html);
|
||||
const out = [];
|
||||
const re = /<(h2|h4|h5)[^>]*>([\s\S]*?)<\/\1>|<img[^>]+src="([^"]+)"/g;
|
||||
let m;
|
||||
let pending = null;
|
||||
while ((m = re.exec(body))) {
|
||||
if (m[1]) {
|
||||
pending = m[2].replace(/<[^>]+>/g, '').trim();
|
||||
} else {
|
||||
out.push({ heading: pending, src: m[3] });
|
||||
pending = null;
|
||||
}
|
||||
}
|
||||
return out;
|
||||
}
|
||||
|
||||
for (const id of IDS) {
|
||||
const res = await fetch(BASE + id, { signal: AbortSignal.timeout(30_000) });
|
||||
const html = await res.text();
|
||||
console.log(`\n=== page ${id} ===`);
|
||||
for (const item of extract(html)) {
|
||||
let status = '';
|
||||
if (item.src && !item.src.startsWith('http')) {
|
||||
const url = 'https://wgdswykladziny.pl/' + item.src.replace(/^\.?\//, '');
|
||||
try {
|
||||
const head = await fetch(url, { method: 'GET', signal: AbortSignal.timeout(20_000) });
|
||||
const len = head.headers.get('content-type')?.startsWith('image') ? head.headers.get('content-length') : 'NOT-IMAGE';
|
||||
status = ` [${head.status} ${len}B ${head.headers.get('content-type')}]`;
|
||||
} catch (e) {
|
||||
status = ` [ERR ${e.message}]`;
|
||||
}
|
||||
}
|
||||
console.log(`- ${item.heading ?? '(bez nagłówka)'} | ${item.src}${status}`);
|
||||
}
|
||||
}
|
||||
9
scripts/referencje-dims.mjs
Normal file
@@ -0,0 +1,9 @@
|
||||
import sharp from 'sharp';
|
||||
import { readdir } from 'node:fs/promises';
|
||||
import path from 'node:path';
|
||||
|
||||
const dir = path.resolve('public/images/referencje');
|
||||
for (const f of await readdir(dir)) {
|
||||
const m = await sharp(path.join(dir, f)).metadata();
|
||||
console.log(`${f} ${m.width}x${m.height} ${(m.width / m.height).toFixed(2)}`);
|
||||
}
|
||||
73
scripts/smoke.mjs
Normal file
@@ -0,0 +1,73 @@
|
||||
const BASE = process.env.SMOKE_BASE ?? 'http://localhost:4321';
|
||||
let failures = 0;
|
||||
|
||||
async function check(method, path, expect, opts = {}) {
|
||||
const res = await fetch(BASE + path, { method, ...opts });
|
||||
const body = await res.text();
|
||||
const pass = res.status === expect;
|
||||
console.log(`${pass ? 'OK ' : 'ERR'} ${method} ${path} → ${res.status} (oczekiwano ${expect}) ${body.length} B`);
|
||||
if (!pass) failures++;
|
||||
return body;
|
||||
}
|
||||
|
||||
await check('GET', '/', 200);
|
||||
const ofirmie = await check('GET', '/o-firmie', 200);
|
||||
if (!ofirmie.includes('Autoryzowany instalator Tarkett')) { console.log('ERR brak treści O firmie'); failures++; }
|
||||
await check('GET', '/oferta', 200);
|
||||
await check('GET', '/oferta/wykladziny-pcv', 200);
|
||||
await check('GET', '/oferta/linoleum-xf', 200);
|
||||
await check('GET', '/oferta/montaz', 200);
|
||||
await check('GET', '/realizacje', 200);
|
||||
await check('GET', '/referencje', 200);
|
||||
await check('GET', '/kontakt', 200);
|
||||
await check('GET', '/nieistnieje', 404);
|
||||
await check('GET', '/sitemap-index.xml', 200);
|
||||
await check('GET', '/robots.txt', 200);
|
||||
await check('GET', '/images/hero/cambridge.jpg', 200);
|
||||
await check('GET', '/images/realizacje/przychodnia.jpg', 200);
|
||||
|
||||
const home = await check('GET', '/?page_id=16523', 200);
|
||||
if (!home.includes('page_id')) { console.log('ERR brak fallbacku redirect'); failures++; }
|
||||
|
||||
import http from 'node:http';
|
||||
|
||||
function postForm(fields, { accept = 'application/json' } = {}) {
|
||||
return new Promise((resolve, reject) => {
|
||||
const body = new URLSearchParams(fields).toString();
|
||||
const req = http.request(
|
||||
BASE + '/api/kontakt',
|
||||
{
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'content-type': 'application/x-www-form-urlencoded',
|
||||
origin: BASE,
|
||||
accept,
|
||||
'content-length': Buffer.byteLength(body),
|
||||
},
|
||||
},
|
||||
(res) => {
|
||||
let data = '';
|
||||
res.on('data', (c) => (data += c));
|
||||
res.on('end', () => resolve({ status: res.statusCode, body: data }));
|
||||
}
|
||||
);
|
||||
req.on('error', reject);
|
||||
req.end(body);
|
||||
});
|
||||
}
|
||||
|
||||
const bad = await postForm({});
|
||||
const badJson = JSON.parse(bad.body || '{}');
|
||||
console.log(`${bad.status === 400 && badJson.errors?.length ? 'OK ' : 'ERR'} POST /api/kontakt (walidacja) → ${bad.status}`);
|
||||
if (!(bad.status === 400 && badJson.errors?.length)) failures++;
|
||||
|
||||
const good = await postForm({
|
||||
name: 'Test Testowy',
|
||||
email: 'test@example.com',
|
||||
message: 'To jest testowa wiadomosc z formularza kontaktowego.',
|
||||
});
|
||||
console.log(`${good.status === 500 ? 'OK ' : 'ERR'} POST /api/kontakt (brak SMTP → 500) → ${good.status} ${good.body.slice(0, 120)}`);
|
||||
if (good.status !== 500) failures++;
|
||||
|
||||
console.log(failures === 0 ? '\nSMOKE OK' : `\nSMOKE FAILURES: ${failures}`);
|
||||
process.exit(failures === 0 ? 0 : 1);
|
||||
100
scripts/test-smtp.mjs
Normal file
@@ -0,0 +1,100 @@
|
||||
import net from 'node:net';
|
||||
import http from 'node:http';
|
||||
import { spawn } from 'node:child_process';
|
||||
|
||||
// Minimalna atrapa SMTP przechwytująca jedną wiadomosc
|
||||
let captured = '';
|
||||
let gotQueue = false;
|
||||
const smtp = net.createServer((sock) => {
|
||||
let collecting = false;
|
||||
let buffer = '';
|
||||
sock.write('220 fake\r\n');
|
||||
sock.on('data', (chunk) => {
|
||||
buffer += chunk.toString('latin1');
|
||||
let idx;
|
||||
while ((idx = buffer.indexOf('\r\n')) >= 0) {
|
||||
const line = buffer.slice(0, idx);
|
||||
buffer = buffer.slice(idx + 2);
|
||||
if (collecting) {
|
||||
if (line === '.') {
|
||||
collecting = false;
|
||||
gotQueue = true;
|
||||
sock.write('250 queued\r\n');
|
||||
} else {
|
||||
captured += line + '\n';
|
||||
}
|
||||
continue;
|
||||
}
|
||||
const cmd = line.toUpperCase();
|
||||
if (cmd.startsWith('EHLO') || cmd.startsWith('HELO')) sock.write('250-fake\r\n250 OK\r\n');
|
||||
else if (cmd.startsWith('MAIL FROM')) sock.write('250 ok\r\n');
|
||||
else if (cmd.startsWith('RCPT TO')) sock.write('250 ok\r\n');
|
||||
else if (cmd.startsWith('DATA')) {
|
||||
collecting = true;
|
||||
sock.write('354 go\r\n');
|
||||
} else if (cmd.startsWith('RSET')) sock.write('250 ok\r\n');
|
||||
else if (cmd.startsWith('QUIT')) {
|
||||
sock.write('221 bye\r\n');
|
||||
sock.end();
|
||||
} else sock.write('250 ok\r\n');
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
await new Promise((r) => smtp.listen(2525, '127.0.0.1', r));
|
||||
|
||||
const PORT = 4399;
|
||||
const child = spawn(process.execPath, ['dist/server/entry.mjs'], {
|
||||
env: {
|
||||
...process.env,
|
||||
PORT: String(PORT),
|
||||
HOST: '127.0.0.1',
|
||||
SMTP_HOST: '127.0.0.1',
|
||||
SMTP_PORT: '2525',
|
||||
SMTP_USER: 'biuro@wgdswykladziny.pl',
|
||||
SMTP_PASS: 'fakepass',
|
||||
MAIL_TO: 'biuro@wgdswykladziny.pl',
|
||||
},
|
||||
stdio: 'inherit',
|
||||
});
|
||||
|
||||
await new Promise((r) => setTimeout(r, 1500));
|
||||
|
||||
const body = new URLSearchParams({
|
||||
name: 'Anna Kowalska',
|
||||
email: 'anna@example.com',
|
||||
phone: '+48 600 100 200',
|
||||
topic: 'Bezpłatna wycena',
|
||||
message: 'Proszę o wycenę 240 m² płytek dywanowych w biurze.',
|
||||
}).toString();
|
||||
|
||||
let pass = false;
|
||||
try {
|
||||
const res = await new Promise((resolve, reject) => {
|
||||
const req = http.request(
|
||||
`http://127.0.0.1:${PORT}/api/kontakt`,
|
||||
{ method: 'POST', headers: { 'content-type': 'application/x-www-form-urlencoded', 'content-length': Buffer.byteLength(body) } },
|
||||
(r) => {
|
||||
let d = '';
|
||||
r.on('data', (c) => (d += c));
|
||||
r.on('end', () => resolve({ status: r.statusCode, body: d, location: r.headers.location }));
|
||||
}
|
||||
);
|
||||
req.on('error', reject);
|
||||
req.end(body);
|
||||
});
|
||||
console.log('status:', res.status, 'location:', res.location, res.body.slice(0, 160));
|
||||
pass = (res.status === 200 || (res.status === 303 && res.location === '/kontakt?sent=ok')) && gotQueue;
|
||||
} catch (e) {
|
||||
console.log('request error:', e.message);
|
||||
}
|
||||
|
||||
await new Promise((r) => setTimeout(r, 300));
|
||||
console.log('--- przechwycona wiadomosc ---');
|
||||
console.log(captured.slice(0, 600));
|
||||
|
||||
child.kill();
|
||||
smtp.close();
|
||||
|
||||
console.log(pass ? '\nSMTP SMOKE OK' : '\nSMTP SMOKE FAIL');
|
||||
process.exit(pass ? 0 : 1);
|
||||
26
src/components/Cta.astro
Normal file
@@ -0,0 +1,26 @@
|
||||
---
|
||||
const { title = 'Potrzebujesz wyceny?', text = 'Odezwij się — doradzimy dobór podłogi i przygotujemy bezpłatną ofertę.', } =
|
||||
Astro.props as { title?: string; text?: string };
|
||||
---
|
||||
|
||||
<section class="mx-auto my-16 max-w-6xl px-4">
|
||||
<div class="swatch-grid-dark grain flex flex-col items-start justify-between gap-6 rounded-2xl bg-sea-dark px-8 py-10 text-white md:flex-row md:items-center">
|
||||
<div>
|
||||
<p class="mb-3 flex items-center gap-2.5 text-xs font-bold uppercase tracking-[0.2em] text-white/60" aria-hidden="true">
|
||||
<span class="size-2 bg-accent"></span>
|
||||
<span class="size-2 bg-clay"></span>
|
||||
<span class="size-2 bg-sand"></span>
|
||||
</p>
|
||||
<h2 class="text-section text-white">{title}</h2>
|
||||
<p class="mt-2 max-w-xl text-white/75">{text}</p>
|
||||
</div>
|
||||
<div class="flex flex-wrap gap-3">
|
||||
<a href="/kontakt" class="rounded-md bg-accent-dark px-5 py-3 text-sm font-bold text-white shadow-[3px_3px_0_0_var(--color-graphite)] transition hover:-translate-y-0.5 hover:bg-[#8f4029]">
|
||||
Bezpłatna wycena
|
||||
</a>
|
||||
<a href="tel:+48500571455" class="rounded-md border border-white/30 px-5 py-3 text-sm font-semibold text-white transition hover:border-white hover:bg-white/10">
|
||||
Zadzwoń: 500 571 455
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
52
src/components/Footer.astro
Normal file
@@ -0,0 +1,52 @@
|
||||
---
|
||||
import { site } from '../data/site';
|
||||
import SwatchMark from './SwatchMark.astro';
|
||||
---
|
||||
|
||||
<footer class="mt-24 bg-ink text-white/80">
|
||||
<div class="mx-auto grid max-w-6xl gap-10 px-4 py-14 md:grid-cols-3">
|
||||
<div>
|
||||
<p class="mb-3 flex items-center gap-3">
|
||||
<SwatchMark />
|
||||
<span class="font-display text-lg font-extrabold text-white">{site.name}</span>
|
||||
</p>
|
||||
<p class="text-sm leading-relaxed">
|
||||
Sprzedaż i profesjonalny montaż wykładzin obiektowych i domowych.
|
||||
Doradzamy, dostarczamy i montujemy — na terenie całej Polski.
|
||||
</p>
|
||||
<a
|
||||
href={site.facebook}
|
||||
rel="noopener"
|
||||
class="mt-4 inline-flex items-center gap-2 text-sm text-white/80 hover:text-white"
|
||||
>
|
||||
<svg width="18" height="18" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M22 12a10 10 0 1 0-11.6 9.9v-7H7.9V12h2.5V9.8c0-2.5 1.5-3.9 3.8-3.9 1.1 0 2.2.2 2.2.2v2.5h-1.3c-1.2 0-1.6.8-1.6 1.6V12h2.8l-.4 2.9h-2.4v7A10 10 0 0 0 22 12Z"/></svg>
|
||||
Facebook
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<p class="mb-3 text-sm font-semibold uppercase tracking-wide text-white/60">Kontakt</p>
|
||||
<address class="not-italic text-sm leading-relaxed">
|
||||
{site.name}<br />
|
||||
{site.address.seat.street}<br />
|
||||
{site.address.seat.postal} {site.address.seat.city}<br />
|
||||
<a class="hover:text-white" href="tel:{site.phones.office.href}">tel. {site.phones.office.value}</a><br />
|
||||
<a class="hover:text-white" href="mailto:{site.email}">{site.email}</a>
|
||||
</address>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<p class="mb-3 text-sm font-semibold uppercase tracking-wide text-white/60">Dane rejestrowe</p>
|
||||
<p class="text-sm leading-relaxed">
|
||||
{site.name}<br />
|
||||
{site.address.registered.street}<br />
|
||||
{site.address.registered.postal} {site.address.registered.city}<br />
|
||||
NIP: {site.nip}<br />
|
||||
REGON: {site.regon}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="border-t border-white/10 py-5 text-center text-xs text-white/50">
|
||||
© {new Date().getFullYear()} {site.name}. Autoryzowany instalator Tarkett.
|
||||
</div>
|
||||
</footer>
|
||||
100
src/components/Header.astro
Normal file
@@ -0,0 +1,100 @@
|
||||
---
|
||||
import { site, nav } from '../data/site';
|
||||
import SwatchMark from './SwatchMark.astro';
|
||||
|
||||
const current = Astro.url.pathname;
|
||||
const isActive = (href: string) =>
|
||||
current === href || (href !== '/' && current.startsWith(href + '/'));
|
||||
---
|
||||
|
||||
<header class="site-header sticky top-0 z-50 border-b border-line bg-paper/95 backdrop-blur">
|
||||
<div class="hdr-inner mx-auto flex max-w-6xl items-center justify-between gap-4 px-4">
|
||||
<a href="/" class="flex items-center gap-3">
|
||||
<SwatchMark />
|
||||
<span class="leading-tight">
|
||||
<span class="font-display block text-lg font-extrabold tracking-tight text-ink">WGDS</span>
|
||||
<span class="block text-[11px] font-semibold uppercase tracking-[0.18em] text-ink-soft">Wykładziny</span>
|
||||
</span>
|
||||
</a>
|
||||
|
||||
<nav class="hidden lg:flex items-center gap-1" aria-label="Nawigacja główna">
|
||||
{nav.map((item) => (
|
||||
<div class="group relative">
|
||||
<a
|
||||
href={item.href}
|
||||
aria-current={isActive(item.href) ? 'page' : undefined}
|
||||
class={`rounded-lg px-3 py-2 text-sm font-medium transition ${
|
||||
isActive(item.href) ? 'text-accent-dark underline decoration-accent decoration-2 underline-offset-8' : 'text-ink-soft hover:text-ink hover:bg-linen'
|
||||
}`}
|
||||
>
|
||||
{item.label}
|
||||
</a>
|
||||
{item.children && (
|
||||
<div class="invisible absolute left-0 top-full min-w-64 rounded-xl border border-line bg-white p-2 shadow-lg opacity-0 transition group-hover:visible group-hover:opacity-100 group-focus-within:visible group-focus-within:opacity-100">
|
||||
{item.children.map((child) => (
|
||||
<a
|
||||
href={child.href}
|
||||
class={`block rounded-lg px-3 py-2 text-sm ${
|
||||
current === child.href ? 'bg-accent-soft text-accent-dark font-medium' : 'text-ink-soft hover:bg-linen hover:text-ink'
|
||||
}`}
|
||||
>
|
||||
{child.label}
|
||||
</a>
|
||||
))}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
))}
|
||||
<a
|
||||
href="/kontakt"
|
||||
class="ml-2 rounded-md bg-accent-dark px-4 py-2.5 text-sm font-bold text-white shadow-[2px_2px_0_0_var(--color-sea-dark)] transition hover:-translate-y-0.5 hover:bg-[#8f4029]"
|
||||
>
|
||||
Bezpłatna wycena
|
||||
</a>
|
||||
</nav>
|
||||
|
||||
<button
|
||||
id="menu-toggle"
|
||||
class="lg:hidden grid size-10 place-items-center rounded-lg border border-line text-ink"
|
||||
aria-expanded="false"
|
||||
aria-controls="mobile-menu"
|
||||
aria-label="Otwórz menu"
|
||||
>
|
||||
<svg width="20" height="20" viewBox="0 0 20 20" fill="none" aria-hidden="true">
|
||||
<path d="M3 5h14M3 10h14M3 15h14" stroke="currentColor" stroke-width="2" stroke-linecap="round" />
|
||||
</svg>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div id="mobile-menu" class="hidden lg:hidden border-t border-line bg-white px-4 pb-4">
|
||||
{nav.map((item) => (
|
||||
<div class="py-1">
|
||||
<a href={item.href} class="block rounded-lg px-3 py-2 text-sm font-medium text-ink">{item.label}</a>
|
||||
{item.children && (
|
||||
<div class="pl-4">
|
||||
{item.children.map((child) => (
|
||||
<a href={child.href} class="block rounded-lg px-3 py-1.5 text-sm text-ink-soft hover:text-ink">{child.label}</a>
|
||||
))}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
))}
|
||||
<a href="/kontakt" class="mt-2 block rounded-md bg-accent-dark px-4 py-2.5 text-center text-sm font-bold text-white">Bezpłatna wycena</a>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<script>
|
||||
const toggle = document.getElementById('menu-toggle');
|
||||
const menu = document.getElementById('mobile-menu');
|
||||
toggle?.addEventListener('click', () => {
|
||||
const open = menu?.classList.toggle('hidden') === false;
|
||||
toggle.setAttribute('aria-expanded', String(open));
|
||||
});
|
||||
|
||||
const header = document.querySelector<HTMLElement>('.site-header');
|
||||
if (header) {
|
||||
const onScroll = () => header.classList.toggle('is-compact', window.scrollY > 24);
|
||||
window.addEventListener('scroll', onScroll, { passive: true });
|
||||
onScroll();
|
||||
}
|
||||
</script>
|
||||
83
src/components/Hero.astro
Normal file
@@ -0,0 +1,83 @@
|
||||
---
|
||||
const cells = [
|
||||
{
|
||||
src: '/images/hero/perpetual-2.jpg',
|
||||
alt: 'Wykładzina PCV na korytarzu obiektu użyteczności publicznej',
|
||||
span: 'col-span-2 row-span-3',
|
||||
img: 'kb',
|
||||
loading: 'eager',
|
||||
fetchpriority: 'high',
|
||||
},
|
||||
{
|
||||
src: '/images/realizacje/dpd-komorniki.jpg',
|
||||
alt: 'Płytki dywanowe w budynku biurowym DPD w Komornikach',
|
||||
span: 'col-span-2 row-span-2',
|
||||
img: 'kb kb-delay',
|
||||
loading: 'eager',
|
||||
},
|
||||
{
|
||||
src: '/images/hero/cambridge.jpg',
|
||||
alt: 'Płytki dywanowe w przestrzeni biurowej',
|
||||
span: '',
|
||||
img: '',
|
||||
loading: 'lazy',
|
||||
},
|
||||
{
|
||||
src: '/images/hero/black.jpg',
|
||||
alt: 'Ciemna wykładzina obiektowa we wnętrzu',
|
||||
span: '',
|
||||
img: '',
|
||||
loading: 'lazy',
|
||||
},
|
||||
];
|
||||
---
|
||||
|
||||
<section class="relative isolate overflow-hidden bg-sea-dark text-white" aria-label="Nasza specjalność">
|
||||
<div class="swatch-grid-dark absolute inset-0" aria-hidden="true"></div>
|
||||
|
||||
<div class="relative mx-auto grid max-w-6xl items-center gap-10 px-4 py-16 md:py-24 lg:grid-cols-[1.05fr_0.95fr]">
|
||||
<div>
|
||||
<p class="flex items-center gap-3 text-xs font-bold uppercase tracking-[0.2em] text-white/70">
|
||||
<span class="size-2.5 shrink-0 bg-accent" aria-hidden="true"></span>
|
||||
Wykładziny obiektowe · sprzedaż · montaż · od 2010
|
||||
</p>
|
||||
<h1 class="text-hero mt-5 max-w-xl">
|
||||
Podłogi obiektowe <span class="text-accent">z charakterem</span>
|
||||
</h1>
|
||||
<p class="mt-5 max-w-lg text-lg leading-relaxed text-white/85">
|
||||
Sprzedaż i montaż wykładzin <strong class="font-semibold text-white">PCV, dywanowych i linoleum XF</strong>.
|
||||
Od szkół i przychodni po serwerownie i sale operacyjne — dobierzemy, dostarczymy i zamontujemy.
|
||||
</p>
|
||||
<div class="mt-8 flex flex-wrap items-center gap-3">
|
||||
<a
|
||||
href="/kontakt"
|
||||
class="rounded-md bg-accent-dark px-6 py-3 text-sm font-bold text-white shadow-[3px_3px_0_0_var(--color-graphite)] transition hover:-translate-y-0.5 hover:bg-[#8f4029] hover:shadow-[4px_4px_0_0_var(--color-graphite)]"
|
||||
>
|
||||
Bezpłatna wycena
|
||||
</a>
|
||||
<a href="/oferta/wykladziny-pcv" class="rounded-md border border-white/30 px-5 py-3 text-sm font-semibold text-white transition hover:border-white hover:bg-white/10">
|
||||
Wykładziny PCV →
|
||||
</a>
|
||||
<a href="/oferta/wykladziny-dywanowe" class="rounded-md border border-white/30 px-5 py-3 text-sm font-semibold text-white transition hover:border-white hover:bg-white/10">
|
||||
Dywanowe →
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid aspect-[4/3] grid-cols-4 grid-rows-3 gap-2.5">
|
||||
{cells.map((c) => (
|
||||
<div class={`grain relative overflow-hidden rounded-xl ${c.span}`}>
|
||||
<img
|
||||
src={c.src}
|
||||
alt={c.alt}
|
||||
class={`duotone ${c.img} absolute inset-0 size-full object-cover`}
|
||||
width="1680"
|
||||
height="1050"
|
||||
loading={c.loading}
|
||||
fetchpriority={c.fetchpriority}
|
||||
/>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
32
src/components/Marquee.astro
Normal file
@@ -0,0 +1,32 @@
|
||||
---
|
||||
const { items = [], lead } = Astro.props as { items?: string[]; lead?: string };
|
||||
|
||||
const visible = lead ? [lead, ...items] : items;
|
||||
---
|
||||
|
||||
<section class="border-y border-line bg-white" aria-label="Nasi dostawcy">
|
||||
<div class="marquee py-5">
|
||||
<div class="marquee-track">
|
||||
{visible.map((it) => (
|
||||
<span class="flex shrink-0 items-center gap-4 whitespace-nowrap px-7">
|
||||
<span class="size-2 shrink-0 bg-clay" aria-hidden="true"></span>
|
||||
{lead && it === lead ? (
|
||||
<span class="text-sm font-bold uppercase tracking-widest text-accent-dark">{it}</span>
|
||||
) : (
|
||||
<span class="text-sm font-semibold uppercase tracking-widest text-ink-soft">{it}</span>
|
||||
)}
|
||||
</span>
|
||||
))}
|
||||
{visible.map((it) => (
|
||||
<span class="flex shrink-0 items-center gap-4 whitespace-nowrap px-7" aria-hidden="true">
|
||||
<span class="size-2 shrink-0 bg-clay"></span>
|
||||
{lead && it === lead ? (
|
||||
<span class="text-sm font-bold uppercase tracking-widest text-accent-dark">{it}</span>
|
||||
) : (
|
||||
<span class="text-sm font-semibold uppercase tracking-widest text-ink-soft">{it}</span>
|
||||
)}
|
||||
</span>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
44
src/components/PageHero.astro
Normal file
@@ -0,0 +1,44 @@
|
||||
---
|
||||
import SwatchStrip from './SwatchStrip.astro';
|
||||
|
||||
interface Props {
|
||||
title: string;
|
||||
kicker?: string;
|
||||
text?: string;
|
||||
image: string;
|
||||
}
|
||||
const { title, kicker, text, image } = Astro.props;
|
||||
|
||||
const field = ['bg-accent', 'bg-linen', 'bg-sand', 'bg-sea'];
|
||||
---
|
||||
|
||||
<section class="relative isolate overflow-hidden bg-sea-dark text-white">
|
||||
<div class="grain absolute inset-0">
|
||||
<img src={image} alt="" class="duotone kb absolute inset-0 size-full object-cover" width="1680" height="1050" loading="eager" fetchpriority="high" />
|
||||
<div class="absolute inset-0 bg-gradient-to-r from-sea-dark/95 via-sea-dark/70 to-sea-dark/35"></div>
|
||||
<div class="absolute inset-x-0 bottom-0 h-40 bg-gradient-to-t from-sea-dark/90 to-transparent"></div>
|
||||
</div>
|
||||
|
||||
<div class="relative mx-auto grid max-w-6xl items-end gap-10 px-4 pb-16 pt-16 md:pb-24 md:pt-24 lg:grid-cols-[minmax(0,1fr)_auto]">
|
||||
<div class="max-w-2xl">
|
||||
{kicker && (
|
||||
<p class="flex items-center gap-3 text-xs font-bold uppercase tracking-[0.2em] text-white/70">
|
||||
<span class="size-2.5 shrink-0 bg-accent" aria-hidden="true"></span>
|
||||
{kicker}
|
||||
</p>
|
||||
)}
|
||||
<h1 class="text-hero mt-4">{title}</h1>
|
||||
<SwatchStrip count={10} width="w-6 sm:w-8" class="mt-7" />
|
||||
{text && <p class="mt-6 max-w-xl text-lg leading-relaxed text-white/85">{text}</p>}
|
||||
</div>
|
||||
|
||||
<div class="relative hidden h-48 w-48 shrink-0 lg:block" aria-hidden="true">
|
||||
<div class="absolute inset-0 translate-x-3 translate-y-3 rounded-xl border border-white/30"></div>
|
||||
<div class="relative grid size-full -rotate-2 grid-cols-2 grid-rows-2 gap-2 rounded-xl bg-white/10 p-2 shadow-2xl">
|
||||
{field.map((c) => <span class={`${c} aspect-square rounded-[3px]`}></span>)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="swatch-band absolute inset-x-0 bottom-0" aria-hidden="true"></div>
|
||||
</section>
|
||||
14
src/components/SwatchMark.astro
Normal file
@@ -0,0 +1,14 @@
|
||||
---
|
||||
const { size = 'size-9', radius = 'rounded-[2px]', class: className = '' } = Astro.props as {
|
||||
size?: string;
|
||||
radius?: string;
|
||||
class?: string;
|
||||
};
|
||||
---
|
||||
|
||||
<span class={`grid ${size} shrink-0 grid-cols-2 grid-rows-2 gap-[3px] ${className}`} aria-hidden="true">
|
||||
<span class={`${radius} bg-accent`}></span>
|
||||
<span class={`${radius} bg-sea`}></span>
|
||||
<span class={`${radius} bg-graphite`}></span>
|
||||
<span class={`${radius} bg-clay`}></span>
|
||||
</span>
|
||||
21
src/components/SwatchStrip.astro
Normal file
@@ -0,0 +1,21 @@
|
||||
---
|
||||
const palette = ['bg-accent', 'bg-sea', 'bg-sand', 'bg-clay', 'bg-graphite', 'bg-linen', 'bg-accent-dark'];
|
||||
const heights = ['h-12', 'h-8', 'h-14', 'h-10', 'h-7', 'h-12', 'h-9', 'h-14', 'h-8', 'h-11'];
|
||||
|
||||
const {
|
||||
count = 14,
|
||||
width = 'w-10 sm:w-12',
|
||||
class: className = '',
|
||||
} = Astro.props as { count?: number; width?: string; class?: string };
|
||||
|
||||
const tiles = Array.from({ length: count }, (_, i) => ({
|
||||
color: palette[i % palette.length],
|
||||
height: heights[i % heights.length],
|
||||
}));
|
||||
---
|
||||
|
||||
<div class={`flex items-end gap-1.5 ${className}`} aria-hidden="true">
|
||||
{tiles.map((t) => (
|
||||
<span class={`${width} ${t.height} shrink-0 rounded-[3px] ${t.color}`}></span>
|
||||
))}
|
||||
</div>
|
||||
19
src/content.config.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
import { defineCollection, z } from 'astro:content';
|
||||
import { glob } from 'astro/loaders';
|
||||
|
||||
const oferta = defineCollection({
|
||||
loader: glob({ pattern: '**/*.md', base: './src/content/oferta' }),
|
||||
schema: z.object({
|
||||
title: z.string(),
|
||||
shortTitle: z.string(),
|
||||
description: z.string(),
|
||||
kicker: z.string().default('Nasza oferta'),
|
||||
hero: z.string().default('/images/hero/cambridge.jpg'),
|
||||
order: z.number().default(99),
|
||||
anchors: z
|
||||
.array(z.object({ id: z.string(), label: z.string() }))
|
||||
.optional(),
|
||||
}),
|
||||
});
|
||||
|
||||
export const collections = { oferta };
|
||||
24
src/content/oferta/chemia-budowlana.md
Normal file
@@ -0,0 +1,24 @@
|
||||
---
|
||||
title: 'Chemia budowlana'
|
||||
shortTitle: 'Chemia'
|
||||
kicker: 'Nasza oferta'
|
||||
description: 'Systemy chemii budowlanej Mapei: masy samopoziomujące, kleje, grunty, środki czyszczące i konserwujące do podłóg. Sprzedaż i doradztwo.'
|
||||
hero: '/images/realizacje/siku.jpg'
|
||||
order: 6
|
||||
---
|
||||
|
||||
Trwałość podłogi w 80% zależy od tego, czego nie widać — jakości przygotowania podłoża i klejenia. Dlatego jako autoryzowany partner chemii budowlanej Mapei (linia podłóg) pracujemy wyłącznie na jej systemach i udostępniamy je również naszym klientom. Nasz doradca techniczny pomoże w zakupie odpowiedniej chemii.
|
||||
|
||||
## W ofercie
|
||||
|
||||
- **Masy samopoziomujące** — wyrównanie podłoża przed montażem wykładziny,
|
||||
- **Kleje i spoiwa** — dobranie kleju do typu wykładziny i podłoża,
|
||||
- **Grunty i preparaty** — poprawienie przyczepności i zamknięcie pylenia,
|
||||
- **Zaprawy naprawcze** — odbudowa i wzmocnienie podłoży betonowych,
|
||||
- **Chemia pielęgnacyjna** — środki czyszczące i konserwujące do wykładzin i podłóg twardych.
|
||||
|
||||
## Doradztwo technologiczne
|
||||
|
||||
Dobieramy system do stanu zastanego: wilgotność podłoża, rodzaj podkładu, czas realizacji. Błędnie dobrany klej albo źle przygotowana wylewka to najczęstsza przyczyna reklamacji podłóg — u nas ten etap jest objęty gwarancją wykonawcy.
|
||||
|
||||
> Prowadzisz obiekt i potrzebujesz środków do bieżącej konserwacji podłóg? Doradzimy preparaty i harmonogram pielęgnacji, który wydłuży życie podłogi o lata.
|
||||
37
src/content/oferta/linoleum-xf.md
Normal file
@@ -0,0 +1,37 @@
|
||||
---
|
||||
title: 'Wykładziny naturalne – Linoleum XF'
|
||||
shortTitle: 'Linoleum XF'
|
||||
kicker: 'Nasza oferta'
|
||||
description: 'Linoleum naturalne — podłoga z surowców odnawialnych. Trwała, antybakteryjna, w setkach kolorów. Rozwiązania Tarkett do szkół, przedszkoli i służby zdrowia.'
|
||||
hero: '/images/realizacje/przedszkole.jpg'
|
||||
order: 3
|
||||
---
|
||||
|
||||
Linoleum to podłoga, która wyprzedziła modę na ekologię o ponad sto lat. Produkcja z lnu, żywicy, mączki drzewnej i pigmentów sprawia, że jest w pełni biodegradowalna, a przy tym niezwykle trwała — służy 30 lat i więcej.
|
||||
|
||||
## Dlaczego linoleum?
|
||||
|
||||
- **Naturalne składniki:** len, żywica, mączka drzewna, pigmenty mineralne — bez PVC.
|
||||
- **Antybakteryjne:** zasadowe pH powierzchni hamuje rozwój bakterii — dlatego wraca do szpitali i przedszkoli.
|
||||
- **Trwałe:** jednolita struktura wzoru, odporność na intensywny ruch.
|
||||
- **Ekologiczne:** certyfikaty środowiskowe, pełna biodegradacja po cyklu życia.
|
||||
|
||||
## Zastosowania
|
||||
|
||||
Przedszkola i szkoły, placówki służby zdrowia, urzędy, laboratoria, wnętrza o wysokich wymaganiach ekologicznych (certyfikaty BREEAM, LEED).
|
||||
|
||||
## Nasze kolekcje
|
||||
|
||||
Główny atut linoleum to naturalny charakter — podłoga przyjazna zdrowiu i środowisku. Komponentami Linoleum są olej lniany, korek i mączka korkowa, żywica, mielone drewno i pigmenty. Zabezpieczenie powierzchni XF zapewnia niezwykłą wytrzymałość oraz łatwość w czyszczeniu. Materiał produkowany jest w różnych grubościach, w rolce oraz w płytce.
|
||||
|
||||
<ul class="gallery">
|
||||
<li><img src="/images/kolekcje/veneto-xf-20-mm.jpg" alt="Veneto XF 2,0 mm — linoleum" loading="lazy" /><span>Veneto XF 2,0 mm</span></li>
|
||||
<li><img src="/images/kolekcje/veneto-xf-25-mm.jpg" alt="Veneto XF 2,5 mm — linoleum" loading="lazy" /><span>Veneto XF 2,5 mm</span></li>
|
||||
<li><img src="/images/kolekcje/veneto-xf-32-mm.jpg" alt="Veneto XF 3,2 mm — linoleum" loading="lazy" /><span>Veneto XF 3,2 mm</span></li>
|
||||
<li><img src="/images/kolekcje/allegro-xf-25-mm.jpg" alt="Allegro XF 2,5 mm — linoleum w płytce" loading="lazy" /><span>Allegro XF 2,5 mm</span></li>
|
||||
<li><img src="/images/kolekcje/etrusco-xf-25-mm.jpg" alt="Etrusco XF 2,5 mm — linoleum w płytce" loading="lazy" /><span>Etrusco XF 2,5 mm</span></li>
|
||||
<li><img src="/images/kolekcje/style-emme-xf.jpg" alt="Style Emme XF — linoleum w płytce" loading="lazy" /><span>Style Emme XF</span></li>
|
||||
<li><img src="/images/kolekcje/style-elle-xf.jpg" alt="Style Elle XF — linoleum w płytce" loading="lazy" /><span>Style Elle XF</span></li>
|
||||
</ul>
|
||||
|
||||
> Linoleum wymaga profesjonalnego montażu — zgrzewania i spoinowania. Nasza ekipa ma wieloletnie doświadczenie w systemach Tarkett i gwarantuje efekt, który przetrwa dekady.
|
||||