Skip to content

feat(meetings): enforce YouTube title 100-char limit (LFXV2-2534)#1040

Open
andrest50 wants to merge 8 commits into
mainfrom
feat/andrest50/LFXV2-2534-youtube-meeting-title-limit
Open

feat(meetings): enforce YouTube title 100-char limit (LFXV2-2534)#1040
andrest50 wants to merge 8 commits into
mainfrom
feat/andrest50/LFXV2-2534-youtube-meeting-title-limit

Conversation

@andrest50

@andrest50 andrest50 commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add YOUTUBE_MAX_TITLE_LENGTH, YOUTUBE_TITLE_DATE_SUFFIX_LENGTH, and YOUTUBE_MAX_MEETING_TITLE_LENGTH constants to meeting.constants.ts
  • Dynamically add/remove Validators.maxLength(87) on the title form control whenever youtube_upload_enabled changes
  • Show a conditional character counter under the title field in the Meeting Details step (color-coded amber at 90% and red past the limit)
  • Show an inline validation error on the title field when the limit is exceeded; this also blocks forward step navigation
  • Add a warning banner on the Platform & Features step when YouTube uploads are enabled but the existing title is already too long, with a button to navigate back to Meeting Details to fix it

Background

The YouTube Data API enforces a 100-character video title limit. The upload handler in itx-service-zoom automatically appends - DD/MM/YYYY (13 chars) to the meeting title when uploading, leaving an effective limit of 87 characters for the meeting title itself. Titles exceeding this cause an invalidTitle API rejection and get stuck in in_progress upload state (see PCC-1315 for the incident that surfaced this).

Screenshots

This shows what the validation error looks like when you set the meeting title too long when the youtube upload is already enabled.
Screenshot 2026-06-29 at 4 30 37 PM

This shows what the text looks like when the meeting title is within its character limit for a meeting that has youtube upload enabled.
Screenshot 2026-06-29 at 4 30 59 PM

This shows the warning the user gets when they try to enable youtube uploads for a meeting that has too long of a title.
Screenshot 2026-06-29 at 4 31 30 PM

Ticket

LFXV2-2534

Test plan

  • Create a new meeting, enable YouTube uploads on step 3 — confirm character counter appears on the title field in step 2 when navigating back
  • Type a title longer than 87 chars with YouTube uploads enabled — confirm counter turns red, inline error appears, and the "Next" button is blocked
  • Enable YouTube uploads when an existing title is already > 87 chars — confirm the warning banner appears on step 3 and the "Go back" button navigates to step 2
  • Edit an existing meeting that has YouTube uploads already enabled — confirm the counter is shown from the start
  • Disable YouTube uploads — confirm the maxlength validator is removed and titles longer than 87 chars are accepted again
  • Keep title <= 87 chars with YouTube uploads enabled — confirm no errors and the form submits normally

🤖 Generated with Claude Code

When YouTube uploads are enabled the upload handler appends " - DD/MM/YYYY"
(13 chars) to the meeting title, so the title itself must be ≤ 87 chars to
stay within the YouTube API's 100-char video title limit.

- Add YOUTUBE_MAX_TITLE_LENGTH, YOUTUBE_TITLE_DATE_SUFFIX_LENGTH, and
  YOUTUBE_MAX_MEETING_TITLE_LENGTH constants
- Dynamically add/remove Validators.maxLength(87) on the title control
  whenever youtube_upload_enabled changes
- Show conditional char counter under title in Meeting Details step
  (color-coded amber at 90 % and red past the limit)
- Show inline error on title field when maxlength is exceeded
- Add warning banner on Platform & Features step when YouTube is on
  but the title is already too long, with a button to navigate back
  to Meeting Details; forward navigation is also blocked until fixed

Generated with [Claude Code](https://claude.com/claude-code)

Signed-off-by: Andres Tobon <andrest2455@gmail.com>
Copilot AI review requested due to automatic review settings June 29, 2026 14:51
@andrest50 andrest50 requested a review from a team as a code owner June 29, 2026 14:51

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Conventional Commits FTW!

@coderabbitai

coderabbitai Bot commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: cd9f94e8-a0d2-4c24-b00b-ffc97716de72

📥 Commits

Reviewing files that changed from the base of the PR and between 5a71b49 and 83f0955.

📒 Files selected for processing (2)
  • apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.ts
  • apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.ts

Walkthrough

Adds shared YouTube title-length constants, conditionally applies a maxlength validator to the meeting title field when YouTube uploads are enabled, and shows YouTube-specific limit messaging in the meeting details and platform-features steps.

Changes

YouTube Title Length Validation

Layer / File(s) Summary
Shared YouTube title length constants
packages/shared/src/constants/meeting.constants.ts
Exports the meeting-details step index and the YouTube title length constants.
Dynamic maxlength validator on title control
apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts
Imports the shared YouTube title limit, defines a title max-length validator, subscribes to youtube_upload_enabled to add or remove it, refreshes title validity, and updates step navigation gating.
YouTube title feedback in meeting steps
apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.ts, apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.html, apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.ts, apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.html, apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.html
Exposes the YouTube title limit and current title length in the meeting details and platform-features components, renders YouTube-specific warning and validation messaging, and wires step navigation from the platform-features panel back to meeting details.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: enforcing the YouTube meeting title length limit.
Description check ✅ Passed The description is directly related and accurately describes the new validation, counter, and warning UI.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/andrest50/LFXV2-2534-youtube-meeting-title-limit

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install failed. For unrecoverable errors, disable the tool in CodeRabbit configuration.


Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds YouTube-specific meeting-title length enforcement to prevent upload failures caused by the YouTube 100-character title cap (accounting for an auto-appended date suffix).

Changes:

  • Introduces shared constants for the YouTube title cap, date suffix length, and effective max meeting title length.
  • Dynamically enforces a max-length validator on the meeting title field when youtube_upload_enabled is enabled.
  • Adds UI feedback: a character counter + inline error in Meeting Details, and a warning banner in Platform & Features with navigation back to fix the title.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
packages/shared/src/constants/meeting.constants.ts Adds derived constants defining the effective YouTube-safe meeting title length.
apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts Subscribes to youtube_upload_enabled changes to add/remove a max-length validator on title.
apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.html Wires a new child output to navigate back to Meeting Details from the warning banner.
apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.ts Exposes YouTube title limit + emits navigation event for “fix title” action.
apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.html Displays warning banner when YouTube uploads are enabled and the title exceeds the max length.
apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.ts Exposes YouTube title limit for template display.
apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.html Shows conditional character counter + maxlength validation message for YouTube-enabled meetings.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.html`:
- Around line 47-50: The YouTube max-length validator is being recreated instead
of reused, so removeValidators in the meeting details form cannot clear the
earlier one. Update the validation logic in the meeting details component so the
same maxLength validator instance is cached and reused for both adding and
removing, or rebuild the validators list when the YouTube toggle changes. Use
the relevant form setup and toggle-handling code in MeetingDetailsComponent to
ensure the title control’s validator reference stays stable.

In
`@apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts`:
- Around line 186-199: The validator handling in meeting-manage.component.ts is
using a fresh Validators.maxLength(...) reference for removal, so the previously
added max-length rule on the title control will not be cleared. Update the
youtube_upload_enabled subscription logic to reuse the same validator instance
for both addValidators and removeValidators, or manage the title control’s
validators as a full set. Use the existing title control inside the subscription
and keep the reusable validator tied to the MeetingManageComponent logic.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: e4efa8c2-bc2f-40a8-b91c-df772ac2dfb1

📥 Commits

Reviewing files that changed from the base of the PR and between 1896785 and 3cbf065.

📒 Files selected for processing (7)
  • apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.html
  • apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.ts
  • apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.html
  • apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.ts
  • apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.html
  • apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts
  • packages/shared/src/constants/meeting.constants.ts

Comment thread apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts Outdated
@andrest50 andrest50 changed the title [LFXV2-2534] feat(meetings): enforce YouTube title 100-char limit feat(meetings): enforce YouTube title 100-char limit (LFXV2-2534) Jun 29, 2026
@github-actions

Copy link
Copy Markdown

🚀 Deployment Status

Your branch has been deployed to: https://ui-pr-1040.dev.v2.cluster.linuxfound.info

Deployment Details:

  • Environment: Development
  • Namespace: ui-pr-1040
  • ArgoCD App: ui-pr-1040

The deployment will be automatically removed when this PR is closed.

Validators.maxLength() returns a new function instance on every call, so
removeValidators(Validators.maxLength(...)) was silently failing — Angular
compares validators by reference. Storing the instance as a class property
ensures add and remove operate on the same reference.

Generated with [Claude Code](https://claude.ai/code)

Signed-off-by: Andres Tobon <andrest2455@gmail.com>
Generated with [Claude Code](https://claude.ai/code)

Signed-off-by: Andres Tobon <andrest2455@gmail.com>
Copilot AI review requested due to automatic review settings June 29, 2026 17:56

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

Generated with [Claude Code](https://claude.ai/code)

Signed-off-by: Andres Tobon <andrest2455@gmail.com>
Generated with [Claude Code](https://claude.ai/code)

Signed-off-by: Andres Tobon <andrest2455@gmail.com>
Copilot AI review requested due to automatic review settings June 29, 2026 18:50

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Generated with [Claude Code](https://claude.ai/code)

Signed-off-by: Andres Tobon <andrest2455@gmail.com>

@audigregorie audigregorie left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review Summary

Solid, well-targeted fix. The validator wiring (single Validators.maxLength instance, add/remove on youtube_upload_enabled valueChanges, paired updateValueAndValidity) and the updateCanProceed look-ahead change correctly block Next/Create Meeting when a previous step becomes invalid. Main feedback is around extracting the repeated title.length expression to a computed() per the project's init*() convention, a few minor naming/wording polish items, and dropping a couple of "what" comments per global-rules.mdc.

What's done well

  • Validator instance reused (private readonly youtubeMaxLengthValidator = Validators.maxLength(...)) so add/remove reference the same object.
  • Constants derived from the YouTube API limit and the appended date suffix (single source of truth).
  • updateCanProceed now validates prior steps via canNavigateToStep(next) — correctly handles cross-step invalidity (the actual reason behind the refresh canProceed on youtube toggle commit).
  • Modern Angular surface area: input.required, output(), takeUntilDestroyed(destroyRef), @if, signals throughout.

Rating: 4/5

Comment thread apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts Outdated

@MRashad26 MRashad26 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review — PR #1040 feat(meetings): enforce YouTube title 100-char limit (LFXV2-2534)

Overview

Adds end-to-end enforcement of YouTube's 100-char video title limit. Three new shared constants (YOUTUBE_MAX_TITLE_LENGTH = 100, YOUTUBE_TITLE_DATE_SUFFIX_LENGTH = 13, YOUTUBE_MAX_MEETING_TITLE_LENGTH = 87) drive a dynamic Validators.maxLength(87) added/removed via valueChanges on youtube_upload_enabled. Meeting Details step gains a color-coded character counter and an inline validation error; Platform & Features step gains a warning banner with a "Go back" button that emits a new goToDetailsStep output. updateCanProceed is fixed to check forward-navigation validity rather than current-step validity so the Next button correctly blocks when the title exceeds the limit.

Secrets / critical-constants check ✅

No secrets or hardcoded credentials introduced. The YouTube API limit and date-suffix length are functional constants, correctly placed in @lfx-one/shared/constants.

Code-standards audit

# Severity Finding
1 🔵 Info [ngClass] in meeting-details evaluates form().get('title')?.value?.length 4× per CD cycle — not reactive in zoneless mode

Code quality notes

  • YOUTUBE_MAX_MEETING_TITLE_LENGTH = YOUTUBE_MAX_TITLE_LENGTH - YOUTUBE_TITLE_DATE_SUFFIX_LENGTH is the right derivation pattern — the limit self-documents and stays in sync if the suffix ever changes. ✅
  • valueChanges.pipe(takeUntilDestroyed(this.destroyRef)).subscribe(...) with addValidators / removeValidators + updateValueAndValidity() is the correct reactive-forms pattern (no effect()). ✅
  • private readonly youtubeMaxLengthValidator = Validators.maxLength(...) — storing the validator instance is required for removeValidators identity comparison; this is correct. ✅
  • output<number>() for goToDetailsStep + (goToDetailsStep)="goToStep($event)" — clean Angular 20 output pattern. ✅
  • updateCanProceed fix: checking canNavigateToStep(currentStep + 1) rather than isStepValid(currentStep) ensures the maxlength validator blocks forward navigation correctly. ✅

Verdict: PASS ✅ (1 info)

All standards pass. The info item below is a performance + reactivity improvement — not blocking.

- Add MEETING_DETAILS_STEP constant to shared meeting.constants.ts
- Add titleLength computed signal and youtubeAmberThreshold to MeetingDetailsComponent
- Add titleLength computed signal and meetingDetailsStep property to MeetingPlatformFeaturesComponent
- Rename goToDetailsStep output to goToStep for consistency with meeting-resources-summary
- Replace five inline form().get(title).value.length expressions with titleLength()
- Tighten hint text: remove YouTube API 100-char detail, use full word characters
- Trim warning banner: drop redundant third paragraph, keep sentence + action button
- Replace hardcoded step 2 with MEETING_DETAILS_STEP constant
- Remove what comments per global-rules.mdc
- Add ordering guarantee comment on youtube_upload_enabled subscription

Generated with [Claude Code](https://claude.com/claude-code)

Signed-off-by: Andres Tobon <andrest2455@gmail.com>
Copilot AI review requested due to automatic review settings June 29, 2026 21:16

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.ts`:
- Line 74: The titleLength signal is currently derived from plain Reactive Forms
state in MeetingDetailsComponent, so it won’t stay in sync as the user types.
Update the MeetingDetailsComponent logic to derive titleLength from the title
control’s valueChanges using toSignal, or otherwise bind the title control value
directly so the counter updates live; use the existing title control in the
form() lookup as the source of truth.

In
`@apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.ts`:
- Line 30: The title character count is currently derived with computed() from
the form object only, so it will not update when the FormControl value changes.
Update MeetingPlatformFeaturesComponent’s titleLength to derive from the title
control stream by using the title control’s valueChanges (preferably converted
to a signal) so the count stays in sync after edits.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 0dd04049-e59e-45ab-a00e-9272f2df062b

📥 Commits

Reviewing files that changed from the base of the PR and between a765acd and 5a71b49.

📒 Files selected for processing (7)
  • apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.html
  • apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.ts
  • apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.html
  • apps/lfx-one/src/app/modules/meetings/components/meeting-platform-features/meeting-platform-features.component.ts
  • apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.html
  • apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts
  • packages/shared/src/constants/meeting.constants.ts
🚧 Files skipped from review as they are similar to previous changes (3)
  • apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.html
  • apps/lfx-one/src/app/modules/meetings/components/meeting-details/meeting-details.component.html
  • apps/lfx-one/src/app/modules/meetings/meeting-manage/meeting-manage.component.ts

computed() depends only on the form input signal (the FormGroup
reference), so it returns stale character counts when the user types.
toSignal() + toObservable(form) + switchMap(ctrl.valueChanges) subscribes
to the RxJS valueChanges stream, making the counter and ngClass colours
update reactively on every keystroke in both zone and zoneless mode.

Generated with [Claude Code](https://claude.com/claude-code)

Signed-off-by: Andres Tobon <andrest2455@gmail.com>
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.

4 participants