Giter Club home page Giter Club logo

Comments (8)

xianqugithub avatar xianqugithub commented on June 4, 2024 1

Yes. It's the plantuml.jar file that I used out of date. After changing the jar file, the image is no longer dark theme.

from aws-icons-for-plantuml.

hakanson avatar hakanson commented on June 4, 2024

I think I have seen this with older versions of PlantUML. Can you add Title %version() to your file and share the output?

@startuml

Title %version()

!define AWSPuml https://raw.githubusercontent.com/awslabs/aws-icons-for-plantuml/v17.0/dist
!include AWSPuml/AWSCommon.puml
!include AWSPuml/General/SAMLtoken.puml
!include AWSPuml/Compute/Lambda.puml
!include AWSPuml/Analytics/OpenSearchService.puml
!include AWSPuml/Analytics/OpenSearchServiceOpenSearchDashboards.puml

Lambda(ingestionLambda, "Ingestion Lambda", "ingest data")

@enduml

image

from aws-icons-for-plantuml.

xianqugithub avatar xianqugithub commented on June 4, 2024
Title %version()

!define AWSPuml https://raw.githubusercontent.com/awslabs/aws-icons-for-plantuml/v17.0/dist
!include AWSPuml/AWSCommon.puml
!include AWSPuml/General/SAMLtoken.puml
!include AWSPuml/Compute/Lambda.puml
!include AWSPuml/Analytics/OpenSearchService.puml
!include AWSPuml/Analytics/OpenSearchServiceOpenSearchDashboards.puml

Lambda(ingestionLambda, "Ingestion Lambda", "ingest data")

test

from aws-icons-for-plantuml.

hakanson avatar hakanson commented on June 4, 2024

1.2021.12 is about 2 years old and must not like the Dark Mode support detection logic (included in AWSCommon.puml using the code below). Is this something you can get upgraded?

Can you try and set !$AWS_DARK = false before you !include AWSPuml/AWSCommon.puml and see if that works. Any chance $PUML_MODE being set as plantuml.jar arg?

' Dark Mode support
' ##################################
' if $AWS_DARK is not defined, check $PUML_MODE
!if (%not(%variable_exists("$AWS_DARK")) && (%variable_exists("$PUML_MODE") && $PUML_MODE == "dark"))
!$AWS_DARK = true
!endif
' ensure $AWS_DARK is either true or false
!if %not(%variable_exists("$AWS_DARK") && ($AWS_DARK == true))
!$AWS_DARK = false
!endif

from aws-icons-for-plantuml.

bsem-twlo avatar bsem-twlo commented on June 4, 2024

Was hit with the same issue - out of nowhere all diagrams have black / dark background. Reverted to v15.
Specifying these (before include AWSPuml/AWSCommon) didn't help:

!$AWS_DARK = false
!$PUML_MODE = "light"

I think Dark Mode detection logic should be flipped to have bias towards transparent (white) background (maintain compatibility with previous versions).

from aws-icons-for-plantuml.

hakanson avatar hakanson commented on June 4, 2024

The logic is supposed to default to light mode - this is the code inside AWSCommon.puml that would set $AWS_DARK = true

' if $AWS_DARK is not defined, check $PUML_MODE
!if (%not(%variable_exists("$AWS_DARK")) && (%variable_exists("$PUML_MODE") && $PUML_MODE == "dark"))
!$AWS_DARK = true
!endif

I tested with 1.2022.5 and see the same default as dark behavior. I testing the "nested if" logic below and now it works as expect on the older version. Must have been a bug with &&

!if (%not(%variable_exists("$AWS_DARK")))
!if ((%variable_exists("$PUML_MODE") && $PUML_MODE == "dark"))
!$AWS_DARK = true
!endif
!endif

Can you do a local test of the new logic (maybe edit AWSCommon.puml or import a local version) and see if works for you?

from aws-icons-for-plantuml.

hakanson avatar hakanson commented on June 4, 2024

fixed with release 18.0

from aws-icons-for-plantuml.

bsem-twlo avatar bsem-twlo commented on June 4, 2024

Tested v18 - all seems good (light mode as expected)

  • with !$AWS_DARK = false & !$PUML_MODE = "light"
  • w/o any vars

Thank you for a quick update 😲 👍

from aws-icons-for-plantuml.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.