Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CLDR-17462 update ST status icons for clarity #3763

Merged
merged 7 commits into from
May 30, 2024

Conversation

srl295
Copy link
Member

@srl295 srl295 commented May 29, 2024

CLDR-17462

  • This PR completes the ticket.

ALLOW_MANY_COMMITS=true

image

image_360

@srl295 srl295 self-assigned this May 29, 2024
@srl295 srl295 marked this pull request as ready for review May 29, 2024 22:18
- update missing and inherited
@macchiati
Copy link
Member

Has this been pushed to staging for UI review?

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

Has this been pushed to staging for UI review?

Yes and you reviewed it, i'm preparing another push incorporating your feedback (such as the word 'inherited')

- move redesign.css and surveytool.css out of java printfs and into index.js
- this gives us the capability for minimization and reduces network loads
@srl295
Copy link
Member Author

srl295 commented May 30, 2024

how's this for inherited+provisional?
image

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

@macchiati i've now updated staging to e39d2b8

@macchiati
Copy link
Member

how's this for inherited+provisional? image

I think that is ok, if you have a narrow space between them. That will allow for narrower columns

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

how's this for inherited+provisional? image

I think that is ok, if you have a narrow space between them. That will allow for narrower columns

maybe a NNBSP

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

how's this for inherited+provisional? image

I think that is ok, if you have a narrow space between them. That will allow for narrower columns

maybe a NNBSP

Chrome, right-aligned, nnbsp

image

@macchiati
Copy link
Member

macchiati commented May 30, 2024

I didn't mean NBSP. That will force all columns on the page to be wide if one of them is. I was thinking the reverse; adding a narrow space (aka thin space) to allow the two icons to be on different lines. Not a non-break one, a breaking one.

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

I didn't mean NBSP. That will force all columns on the page to be wide if one of them is. I was thinking the reverse; adding a narrow space (aka thin space) to allow the two icons to be on different lines. Not a non-break one, a breaking one.

different lines could be hard to scan, it'll look like alternating content. Here's the result with ZWSP:

image

Comment on lines -212 to -214
final String cb = getCacheBustingExtension(request);
out.write(
"<link rel='stylesheet' href='" + contextPath + "/surveytool" + cb + ".css' />\n");
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This wasn't working properly, tended to cache the out of date file. Webpack worked correctly.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great to know webpack now handles all the cache busting!

Does that mean getCacheBustingExtension is now unused, in which case it should be removed?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is used when loading the error and waiting pages still, since the bundle may not be loaded properly.

@macchiati
Copy link
Member

Hmmm. Ok, let's try with them on the same line, and we'll ask the TC about it. Note: that only happens when the item being inherited is provisional or worse, right? If it is Contributes or Accepted, we see just a regular ⬆️, right?

@stenshamn
Copy link
Contributor

I didn't mean NBSP. That will force all columns on the page to be wide if one of them is. I was thinking the reverse; adding a narrow space (aka thin space) to allow the two icons to be on different lines. Not a non-break one, a breaking one.

different lines could be hard to scan, it'll look like alternating content. Here's the result with ZWSP:

image

This looks OK to me, FWIW. I agree it's better than causing change in column width.

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

Hmmm. Ok, let's try with them on the same line, and we'll ask the TC about it. Note: that only happens when the item being inherited is provisional or worse, right? If it is Contributes or Accepted, we see just a regular ⬆️, right?

If I'm reading the logic correctly… only unconfirmed or provisional adds the "inherited" ⬆️. Otherwise it will only show the approved, contributed, missing symbols.

I don't see a code path where it shows only the uparrow.

@macchiati
Copy link
Member

macchiati commented May 30, 2024 via email

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

If that is the case, we don't need the ⬆️ at all, just the X. People will be able to see in the winning cell (from the color) that it is inherited, and the X tells them that it isn't approved/contributed

That's fine, we can drop the inheritance marker symbol then. (Reference to its discussion: CLDR-11103 )

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

So, thoughts? drop the inheritance icon?

@macchiati
Copy link
Member

Let's leave it in for now, so we don't delay.

macchiati
macchiati previously approved these changes May 30, 2024
@srl295
Copy link
Member Author

srl295 commented May 30, 2024

@macchiati just to be really clear, you are approving

A: NNBSP e0a503e - this is the current code in the PR

(updated image)

image

B: e39d2b8 what is currently on cldr-staging

image

C: (not committed) using a ZWSP instead of NNBSP

image

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

Let's leave it in for now, so we don't delay.

let me know A B or C and i'll accept the ticket and get ready to merge

@macchiati
Copy link
Member

Ok, if C: (not committed) using a ZWSP instead of NNBSP is ready to go, let's do that.

@srl295
Copy link
Member Author

srl295 commented May 30, 2024

@macchiati it's option C now

@AEApple
Copy link
Contributor

AEApple commented May 30, 2024

Looks nice!

@srl295 srl295 merged commit f9b3376 into unicode-org:main May 30, 2024
11 checks passed
@srl295 srl295 deleted the cldr-17462/icons branch May 30, 2024 21:06
Copy link
Member

@btangmu btangmu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have some doubts about getCacheBustingExtension and redesign.css, see my comments on those; otherwise looks fine

default:
return "?"; // U+003F
return "\ufffd";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is kind of a non-standard use for U+FFFD; normally it's for encoding errors ( per https://en.wikipedia.org/wiki/Specials_(Unicode_block) ), not software bugs or incompatibilities between front and back ends; not that it matters much, still I think it's not as good as a question mark here

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that's true, but this is an internal error of some sort.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not an encoding error though; I think it should be reserved for errors in encoding, such as illegal sequences of UTF-8 bytes, or characters from other character sets with no corresponding code in Unicode

status_contributed: "☑️",
status_provisional: "✖️",
status_unconfirmed: "❌\uFE0F",
status_missing: "🕳️",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Hole"? :-)

Comment on lines -212 to -214
final String cb = getCacheBustingExtension(request);
out.write(
"<link rel='stylesheet' href='" + contextPath + "/surveytool" + cb + ".css' />\n");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great to know webpack now handles all the cache busting!

Does that mean getCacheBustingExtension is now unused, in which case it should be removed?

+ contextPath
+ "/css/redesign"
+ cb
+ ".css' />\n");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are you sure this isn't still needed by any legacy code, such as jsp?

I searched for "redesign" with a shortcut I like to use:

$ cldrgrep redesign
tools/cldr-apps/js/src/esm/cldrEvent.mjs: * (this is mostly derived from old redesign.js and should be divided
tools/cldr-apps/js/src/esm/cldrInfo.mjs:const ITEM_INFO_ID = "itemInfo"; // must match redesign.css
tools/cldr-apps/js/src/esm/cldrInfo.mjs:const ITEM_INFO_CLASS = "sidebyside-scrollable"; // must match redesign.css, cldrGui.mjs, DashboardWidget.vue
tools/cldr-apps/src/main/webapp/css/redesign.css:/* redesign.css contains a lot of the 'bootstrap' type css,
tools/cldr-apps/src/main/webapp/css/redesign.css: The following is here in redesign.css temporarily!
tools/cldr-apps/src/main/webapp/css/redesign.css: Note: redesign.css is loaded by SurveyTool.java AFTER surveytool.css and bootstrap, so has higher priority;

That confirms it doesn't occur in any jsp files. It points to this comment in redesign.css itself:

/***
 The following is here in redesign.css temporarily!
 Note: redesign.css is loaded by SurveyTool.java AFTER surveytool.css and bootstrap, so has higher priority;
 style.css (for webpack, currently empty) is effectively loaded first, has the lowest priority
***/

body,
html {
	width: 100vw !important;
	height: 100vh !important;
	overflow: hidden !important;
	margin: 0 !important;
	padding: 0 !important;
}

I might have written part of that comment myself a long time ago. What I'm wondering is, does the relative priority between these css files (redesign.css, surveytool.css, bootstrap, style.css) matter, and if it does matter, does this change preserve it?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW I have

$ cat ~/bin/cldrgrep
#!/bin/bash
egrep -H "$@" tools/cldr-apps/js/package.json
egrep -H "$@" tools/cldr-apps/js/src/* -d skip
egrep -H "$@" tools/cldr-apps/js/src/esm/*
egrep -H "$@" tools/cldr-apps/js/src/views/*
egrep -H "$@" tools/cldr-apps/src/main/webapp/*.css
egrep -H "$@" tools/cldr-apps/src/main/webapp/css/*.css
egrep -H "$@" tools/cldr-apps/src/main/webapp/*.jsp
egrep -H "$@" tools/cldr-apps/src/main/webapp/WEB-INF/tmpl/*.jsp
egrep -H "$@" tools/cldr-apps/src/main/webapp/WEB-INF/jspf/*.jspf

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The JSPs don't go through the 'serve normally' route… they would be loaded from their own jsp path.

This change makes sure our css files are loaded last and so can have the final override.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants