Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Oct 28, 2025

  • Understand the current code structure and protection model
  • Simplify protection check to use accessibility property
  • Update isDisabled condition to check accessibility === Status.Protected
  • Update tests to use Status.Protected/Active instead of protectReasons
  • Move protection tests into vernacular describe block
  • Remove redundant test for enabled state (implicit in first test)
  • Run tests to validate changes - all tests pass (9/9 RecentEntry tests, 76/76 DataEntry suite tests)
  • Lint the code - linter passes with no warnings

Summary

Updated the implementation based on code review feedback to use the simpler accessibility property instead of checking the protectReasons array. The vernacular field is now disabled when either the word or sense has accessibility === Status.Protected. Test organization improved by moving protection tests into the vernacular describe block and removing the redundant test that checked the enabled state (already implicit in the first vernacular test).

Original prompt

This section details on the original issue you should resolve

<issue_title>[DataEntry] Evaluate what entries are changable</issue_title>
<issue_description>When you select an existing word's sense, the current domain is added to the sense and it appear in the table. If the word has multiple senses, the vernacular is locked from editing. However, in all other cases (even with a protected word), the vernacular and gloss are both editable.

Todo:

  • In src/components/DataEntry/DataEntryTable/RecentEntry.tsx, Also make vernacular isDisabled if the word or sense is protected.</issue_description>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.


This change is Reviewable

Copilot AI changed the title [WIP] Update vernacular field to be disabled for protected words Disable vernacular field when word or sense is protected Oct 28, 2025
Copilot AI requested a review from imnasnainaec October 28, 2025 19:04
Copilot finished work on behalf of imnasnainaec October 28, 2025 19:04
Copy link
Collaborator

@imnasnainaec imnasnainaec left a comment

Choose a reason for hiding this comment

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

imnasnainaec

This comment was marked as resolved.

@codecov
Copy link

codecov bot commented Oct 28, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.40%. Comparing base (0298e39) to head (3e9cd2b).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3972   +/-   ##
=======================================
  Coverage   74.40%   74.40%           
=======================================
  Files         291      291           
  Lines       10790    10790           
  Branches     1351     1351           
=======================================
  Hits         8028     8028           
  Misses       2373     2373           
  Partials      389      389           
Flag Coverage Δ
backend 85.45% <ø> (ø)
frontend 65.86% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copilot AI requested a review from imnasnainaec October 28, 2025 20:48
Copilot finished work on behalf of imnasnainaec October 28, 2025 20:48
Copy link
Collaborator

@imnasnainaec imnasnainaec left a comment

Choose a reason for hiding this comment

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

Copilot AI requested a review from imnasnainaec October 28, 2025 20:59
Copilot finished work on behalf of imnasnainaec October 28, 2025 20:59
Copy link
Collaborator

@imnasnainaec imnasnainaec left a comment

Choose a reason for hiding this comment

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

@imnasnainaec reviewed 1 of 2 files at r2, 1 of 1 files at r5, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @copilot)

@imnasnainaec imnasnainaec marked this pull request as ready for review October 29, 2025 17:34
@imnasnainaec imnasnainaec added the 🟨Medium Medium-priority PR label Oct 29, 2025
Copilot AI requested a review from imnasnainaec October 29, 2025 17:36
Copilot finished work on behalf of imnasnainaec October 29, 2025 17:36
Copy link
Contributor

@jasonleenaylor jasonleenaylor left a comment

Choose a reason for hiding this comment

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

:lgtm:

@jasonleenaylor reviewed 1 of 2 files at r2, 1 of 1 files at r5, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @copilot)

@imnasnainaec imnasnainaec merged commit a90b8f3 into master Oct 29, 2025
20 checks passed
@imnasnainaec imnasnainaec deleted the copilot/make-vernacular-disabled-for-protected branch October 29, 2025 18:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[DataEntry] Evaluate what entries are changable

3 participants