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

feat(LEMS-1733): adds aria labels to line segment #2032

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

anakaren-rojas
Copy link
Contributor

@anakaren-rojas anakaren-rojas commented Dec 18, 2024

Summary:

  • Adds aria label and description to whole line segment
  • Adds aria label for individual end points of line segment

Issue: LEMS-1733

Test plan:

  1. Navigate to Chromatic
  2. Select Line Segment Interactive Graph from drop down
  3. Validate screen reader can read line segment

Expected behavior

  1. Screen reader reads aria label for whole graph: A line segment on a coordinate plane
  2. Screen reader reads aria description for whole graph: Endpoint 1 at ${point1X} comma ${point1Y}. Endpoint 2 ${point2X} comma ${point2Y}. Segment length %(length)s
  3. When selected, screen reader reads aria label for end points: Endpoint ${endpointNumber} at ${x} comma ${y}
  4. When moving a point, aria labels adjust to include new end points and length, as appropriate

Screenshots:

image

@anakaren-rojas anakaren-rojas self-assigned this Dec 18, 2024
Copy link
Contributor

github-actions bot commented Dec 18, 2024

npm Snapshot: Published

Good news!! We've packaged up the latest commit from this PR (06114d8) and published it to npm. You
can install it using the tag PR2032.

Example:

yarn add @khanacademy/perseus@PR2032

If you are working in Khan Academy's webapp, you can run:

./dev/tools/bump_perseus_version.sh -t PR2032

Copy link
Contributor

github-actions bot commented Dec 18, 2024

Size Change: +728 B (+0.06%)

Total Size: 1.27 MB

Filename Size Change
packages/perseus/dist/es/index.js 418 kB +447 B (+0.11%)
packages/perseus/dist/es/strings.js 5.21 kB +281 B (+5.7%) 🔍
ℹ️ View Unchanged
Filename Size
packages/kas/dist/es/index.js 39 kB
packages/keypad-context/dist/es/index.js 760 B
packages/kmath/dist/es/index.js 4.27 kB
packages/math-input/dist/es/index.js 78 kB
packages/math-input/dist/es/strings.js 1.79 kB
packages/perseus-core/dist/es/index.js 1.48 kB
packages/perseus-editor/dist/es/index.js 688 kB
packages/perseus-linter/dist/es/index.js 22.2 kB
packages/pure-markdown/dist/es/index.js 3.67 kB
packages/simple-markdown/dist/es/index.js 12.5 kB

compressed-size-action

@anakaren-rojas anakaren-rojas changed the title docs(changeset): adds aria labels to line segment feat(LEMS01733): adds aria labels to line segment Dec 18, 2024
@anakaren-rojas anakaren-rojas changed the title feat(LEMS01733): adds aria labels to line segment feat(LEMS-1733): adds aria labels to line segment Dec 18, 2024
@anakaren-rojas anakaren-rojas marked this pull request as ready for review December 18, 2024 23:34
Copy link
Contributor

@nishasy nishasy left a comment

Choose a reason for hiding this comment

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

A couple of small requests.

packages/perseus/src/strings.ts Outdated Show resolved Hide resolved
packages/perseus/src/strings.ts Outdated Show resolved Hide resolved
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.

2 participants