Advanced BBCode Box

BBCode highlight - Advanced BBCode Box

BBCode highlight

by wintstar » Wed Jan 08, 2025 5:07 pm

The BBCode highlight is not optimal for prosilver and other styles. The font colour is missing. Better to replace the tag style="background-color: with a tag class.

My solution

Code: Select all

<span style="background-color: {COLOR};">{TEXT}</span>
replace with

Code: Select all

<span class="bbcode-highlight">{TEXT}</span>
add to css file

Code: Select all

span.bbcode-highlight {
	background-color: yellow;
	color: #191919;
	padding: 6px 8px;
	display: inherit;
	width: fit-content;
	text-align: justify;
	text-justify: auto;
}
Screenshot 2025-01-08 at 17-56-33 Advanced BBCode Box highlight-light.png
light style
Screenshot 2025-01-08 at 17-57-32 Advanced BBCode Box highlight dark.png
dark style
User avatar
wintstar
Registered User
Posts: 363
Joined: Sat Mar 07, 2009 12:39 pm
Location: Central Hessen, close to the "heart of nature", Germany

Re: BBCode highlight

by Talk19Zehn » Mon Jan 13, 2025 9:44 am

Hello, in dark styles all those BBCodes are affected that do not have their own class, because from my personal point of view they are background-color inline modified and sometimes not readable at all or only very poorly readable. Example:

Code: Select all

[highlight=yellow]
[glow=color]
[shadow=color]
[dropshadow=color]
[blur=color]
This also has an effect on the instruction: Generate BBCode help FAQ for ABBC3's custom BBCodes, BBCode guide.
For example color white on a yellow background is not readable, to stay with the example for highlight=yellow.
The problem should be known, I think. The https://www.phpbb.com/customise/db/exte ... x/faq/1551 (FAQ) did not help me personally. Or I had overlooked something(?).
Therefore I ask whether it is possible to query the style ID in order to be able to adjust the color of the BBCodes mentioned in it, which then flows into the Generate BBCode help FAQ for ABBC3's custom BBCodes, BBCode guide instruction.
Thank you very much.
highliht_yellow2.png
highliht_yellow2.png (8.83 KiB) Viewed 15 times
highliht_yellow1.png
highliht_yellow1.png (8.92 KiB) Viewed 15 times
glow_shadow_dropshadow_blur2.png
glow_shadow_dropshadow_blur.png

EDIT:
========
On the fly - for highlight "out of desperation" I have written my own BBCode:

CSS:

Code: Select all

span.bbcode-highlight {
	background-color: transparent;
	background-image: -webkit-linear-gradient(right, #F78D4C 0%, #E94057 50%, #E94057 51%, #BF7ABD 100%);
	background-image: linear-gradient(to right, #F78D4C, #E94057, #BF7ABD);
	filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#E94057', endColorstr='#BF7ABD',GradientType=0 );
	border-radius: 6px;
	color: black;
	padding: 6px 7px;
	display: inline-block;
	width: fit-content;
	text-align: justify;
	text-justify: auto;
}
For color: black; = color: inherit; is conceivable. The individual case decides.
bbcodehighlightinherit.png
bbcodehighlightinherit.png (6.45 KiB) Viewed 13 times
Many regards
User avatar
Talk19Zehn
Registered User
Posts: 917
Joined: Tue Aug 09, 2011 1:10 pm