[pmwiki-users] WikiStyles refactored, can use testing

ABClf languefrancaise at gmail.com
Wed Dec 14 05:28:17 PST 2022


Will this work with localCSS ?
I just upgraded to last version and see I encounter a light issue css related.

I suspect a syntax typo (LocalCSS injected missing a linebreak –or
something like that– for every injected css taken from LocalCSS) :
if I'm looking at source page where there is something wrong, if I go
to style section in header, then I see something as follows (where h2,
h3, h4 and y11, y12, etc., are set up in LocalCSS : please note the
syntax)

.gutters .column-12 {
width: 100%;
}h2, h3, h4 {
margin-top: 0;
border-bottom: 0;
display:inline;
padding-right: 5px;
}
h4 {
font-weight: lighter;
}[class^="y11"] {background-color:#DFF2FF;}
[class^="y12"] {background-color:#DFF2FF;}
[class^="y13"] {background-color:#DFF2FF;}
[class^="y14"] {background-color:#DFF2FF;}
[class^="y15"] {background-color:#DFF2FF;}
[class^="y16"] {background-color:#DFF2FF;}
[class^="y170"], [class^="y171"], [class^="y172"], [class^="y173"],
[class^="y174"], [class^="y17xx"] {background-color:#ADD8E6;}
[class^="y175"], [class^="y176"], [class^="y177"], [class^="y178"]
{background-color:#ADD8E6;}
[class^="y179"], [class^="y180"], [class^="y181"] {background-color:#00BFFF;}
[class^="y182"], [class^="y183"], [class^="y184"] {background-color:#960018;}
[class^="y185"], [class^="y186"] {background-color:#FF6347;}
[class^="y187"], [class^="y188"] {background-color:#FF7F50;}
[class^="y189"], [class^="y190"] {background-color:#fdc3cd;}
[class^="y191"] {background-color:#57D53B;}
[class^="y192"] {background-color:#B0F2B6;}
[class^="y193"] {background-color:#FFFFE0;}
[class^="y194"] {background-color:#FBF2B7;}
[class^="y195"], [class^="y196"], [class^="y197"] {background-color:#FFCC00;}
[class^="y198"] {background-color:#D8BFD8;}
[class^="y199"], [class^="y200"] {background-color:#DDA0DD;}
[class^="y201"], [class^="y202"] {background-color:#660099;}#chronologie code {
color: black;
font-weight: light;
}

Thank you,
Gilles.

Le dim. 20 nov. 2022 à 23:05, Petko Yotov <5ko at 5ko.fr> a écrit :
>
> Hello,
>
> I am working on progressively removing the core requirement for inline
> JavaScript and styles. This would allow wikis to enable a more strict
> Content-Security-Policy, without 'unsafe-inline'. This in turn reduces
> the chances for cross-site scripting (XSS) vulnerabilities.
>
> I have refactored the core WikiStyles to replace all inline styles in
> the text with CSS class names, generated on the fly, and added to the
> header <style> element.
>
> So where before %red%red text%% produced something like:
>
>    <span style="color:red;">red text</span>
>
> it will now produce something like:
>
>    <span class="-pm--1">red text</span>
>
> with the declaration in the HTML header <style> element:
>
>    .-pm--1 { color:red; }
>
>
> I'd like to invite you to try the new functions (enabled on pmwiki.org)
> and notify me if you find any bugs or omissions.
>
> If you use custom WikiStyles on your wiki, you can test the pre-release,
> and report if you notice any problems.
>
> You can get the pre-release as usual via Subversion, or from the
> ChangeLog page:
>
>   https://www.pmwiki.org/wiki/PmWiki/ChangeLog
>
> For this specific feature, only the following files changed:
>
>   scripts/wikistyles.php
>
> To test it, you can simply replace this file from the pre-release to
> your installation.
>
> I'll normally be releasing the next version 2.3.15 in early December. If
> any bugs are reported to me in the meantime, I may have the chance to
> fix them in time.
>
> Note: This only concerns WikiStyles (>>...<< or %...%). For the moment
> it excludes inline CSS in the HTML attribute style="..." which can be
> manually added to tables, division blocks, forms and some other
> directives.
>
> Thanks,
> Petko
>
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users at pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-users



More information about the pmwiki-users mailing list