Template Customization
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 20/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Da chiarire
- Stato di attività
- Ferma
- Stack tecnologico
- css, html, javascript, php
Direzione di ricerca
Start with the related initiatives #6028 and #6027, then examine how template modifications and template events are used across WoltLab Suite styles. The issue calls for investigating common customization needs and consulting style creators before deciding on a path; done would mean an agreed approach that reduces template edits while preserving reasonable customization options.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Note: This is part of a larger initiative to overhaul the style system and the customization options in general. See #6028 to learn more.
The template system permits arbitrary changes to almost all existing templates with a few exceptions for stability reasons. Creating custom variants of existing templates is an extremely powerful tool but comes with a lot of drawbacks. We should work towards reducing the need to make template modifications to both improve updates and to allow users to customize their site without interfering with style creators.
Use Cases for Template Modifications
Generally speaking, there are two distinct cases that we need to differentiate:
- Template modifications to achieve visual modifications.
- Adding content to the HTML that did not exist before.
These are somewhat similar but are likely to be carried out by different people.
Visual Modifications
This is a typical example for style creators that need to insert extra elements or to move existing components around. Examples include additional wrapper elements to achieve certain visual effects, changing the position of header components and adding extra boxes that contain new information.
Sometimes template modifications are used to simply make changes that could be achieved using pure CSS but that would interfere with the existing JavaScript logic. This is something we need to improve by making it easier to move components around without having strong expectations about the visual representation or at least adapt to it. A prime example is the inability of the user panel menus to identify wether or not they are using a sticky position or not.
Adding Content
The second use case somewhat overlaps with the first one and is about introducing new components that did not exist before. This requires a lot more effort because it isn’t just about some HTML and CSS but usually also requires the user to make changes to the content. This is often times achieved through options which is somewhat addressed in #6027.
However, it is questionable wether or not that is a proper user of template modifications. Styles right now do not contain any logic to hold custom options and instead this is achieved through the use of a wrapper package that provides the options. This is an odd situation where the goal is achieved by loosely coupling two different parts.
We could consider discouraging this practice because it is quite messy and the same can be achieved by offering extra plugins that introduce this functionality by using existing placeholders in templates. This way that functionality is no longer tied to a specific style and reduces the amount of conflicts caused by outdated templates or those being also edited by the site owner.
Path Forward
We need to carefully examine the typical changes being made with template modifications to thoroughly understand the motivations behind those. It makes sense to reach out to style creators to find a path that allows them to make their desired changes without relying solely on template changes.
Customizable Layout for the Header
The header consists of four distinct components: Site logo, user menu, main menu and the search bar. Being able to define the layout per style would remove a primary template modification. Ideally there is some visual builder that allows those to be rearranged which makes this easy even for non-tech savvy users and allows us to maintain the necessary HTML and JS logic going forward.
Insert Arbitrary HTML
Another important aspect is the ability to inject extra HTML at will to accomplish additional tasks. This can be an extra menu strip at the bar for a shared header or an extra wrapper element for visual purposes. These could potentially take advantage of (select) template events or even a new class of template events dedicated to styles on. The benefit of using a dedicated set of events is that these could be dynamic and restricted to styles only which prevents collisions with HTML added by plugins.
Template Modifications in the Future
It is unclear to what degree we want to support template modifications in the future. Being able to make arbitrary changes is a double-edged sword where it’s easy to break existing logic and/or make it very painful when the source template is updated.
This is even worse today where the source of modified templates can be both the site owner and the style creator. But this is mostly an afterthought, this pretty much relies on the result of the aforementioned changes that aims to remove a lot of the needs for this feature in the first place. The goal is to provide a path forward without crippling the ability to make reasonable changes.
- Lingua principale
- PHP
- Stelle
- 248
- Fork
- 147
- Merge medio
- 17m
- PR unite (30g)
- 21
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di WoltLab/WCF
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 75/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 58/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 30/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 20/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
WoltLab/WCF#6771 · 1 reazione ·
I maintainer di solito rispondono entro 1 giorno
Issue simili
-
bug: juros do parcelamento travados em 1x no gateway Rede Débito e Crédito 3DS (woo-rede 5.6.0)Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
LinkNacional/woo-rede#367 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Translation is missing for sw-app.component.sw-app-shop-id-change-modal.error.shop-id-change-failedApertaneeds-triage Platform(Default)
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Configuration consistency enhancement
Difficoltà 2/5 Meno di un'ora Idoneità per principianti 72/100
novalo-dev/Prestashop-MCP-Server#405 ·
I maintainer di solito rispondono entro 1 giorno
-
OpenRouter errors returned in a 200 body are thrown as a plain AiExceptionForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 80/100
I maintainer di solito rispondono entro 2 giorni