-
Notifications
You must be signed in to change notification settings - Fork 8
feat(main): button for writing rules page #386
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
Conversation
Deploying angular-love-client with
|
Latest commit: |
0f14b3e
|
Status: | ✅ Deploy successful! |
Preview URL: | https://fafa7b8b.angular-love-client.pages.dev |
Branch Preview URL: | https://feat-writing-rules-button.angular-love-client.pages.dev |
756ac1b
to
318e6e3
Compare
Deploying angular-love-client with
|
Latest commit: |
318e6e3
|
Status: | ✅ Deploy successful! |
Preview URL: | https://b5d12edd.angular-love-client.pages.dev |
Branch Preview URL: | https://feat-writing-rules-button.angular-love-client.pages.dev |
318e6e3
to
0f14b3e
Compare
WalkthroughThe changes extend the blog’s authoring section by adding a new "articleWritingRules" configuration in both English and Polish locale files. The author page is updated to display two distinct advertisement components—one linking externally via Typeform and another performing local navigation using Angular’s router. Additionally, the advertisement component itself has been refactored to allow dynamic content projection with the Changes
Sequence Diagram(s)sequenceDiagram
participant U as User
participant B as BecomeAuthorPage
participant A1 as Advertisement (External)
participant A2 as Advertisement (Local)
participant R as AngularRouter
U->>B: Load Become Author Page
B->>A1: Render External Advertisement (Typeform URL)
B->>A2: Render Local Advertisement (Writing Rules)
U->>A1: Click External Advertisement Button
A1->>U: Redirect to Typeform URL
U->>A2: Click Local Advertisement Button
A2->>R: Trigger Angular Routing
R->>U: Navigate to Writing Rules Page
Poem
Tip CodeRabbit's docstrings feature is now available as part of our Pro Plan! Simply use the command ✨ Finishing Touches
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
apps/blog/src/assets/i18n/en.json (1)
46-50
: Add a period to the end of the description for consistency.The descriptions in other sections of the i18n file typically end with a period, but the new "articleWritingRules" description doesn't. Consider adding one for consistency.
- "description": "Hey! Here are some practical tips to help you get started and make your writing stand out", + "description": "Hey! Here are some practical tips to help you get started and make your writing stand out.",
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (6)
apps/blog/src/assets/i18n/en.json
(1 hunks)apps/blog/src/assets/i18n/pl.json
(1 hunks)libs/blog/become-author/feature-become-author-page/src/lib/become-author-page/become-author-page.component.html
(1 hunks)libs/blog/become-author/feature-become-author-page/src/lib/become-author-page/become-author-page.component.ts
(2 hunks)libs/blog/become-author/feature-become-author-page/src/lib/components/become-author-advertisement/become-author-advertisement.component.html
(1 hunks)libs/blog/become-author/feature-become-author-page/src/lib/components/become-author-advertisement/become-author-advertisement.component.ts
(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: Cloudflare Pages
🔇 Additional comments (6)
libs/blog/become-author/feature-become-author-page/src/lib/become-author-page/become-author-page.component.ts (1)
2-2
: LGTM - Good addition of necessary imports.The addition of RouterLink and AlLocalizePipe imports is appropriate for implementing the writing rules button functionality. Good job organizing the imports and updating the component's imports array accordingly.
Also applies to: 5-5, 24-25
libs/blog/become-author/feature-become-author-page/src/lib/components/become-author-advertisement/become-author-advertisement.component.ts (1)
1-1
: Good use of the modern input() API and enhanced accessibility.The component has been properly refactored to:
- Use the new signal-based input() API
- Include an ariaLabel property that enhances accessibility
- Remove the TranslocoDirective which is no longer needed due to content projection
This makes the component more reusable and accessible.
Also applies to: 12-12, 17-19
libs/blog/become-author/feature-become-author-page/src/lib/components/become-author-advertisement/become-author-advertisement.component.html (1)
2-9
: Well-implemented content projection with accessibility support.The template has been refactored to use content projection via
<ng-content />
, making the component more flexible and reusable. Good use of:
- Container queries with
@container
- Proper accessibility attributes with
[attr.aria-labelledby]="ariaLabel()"
- Responsive layout with flex utilities
This is a solid improvement to the component architecture.
apps/blog/src/assets/i18n/pl.json (1)
49-53
: New "articleWritingRules" Translation Section Verification
The new"articleWritingRules"
section correctly includes the keys"title"
,"description"
, and"buttonText"
. The language is clear and aligns with the intended user guidance for writing rules. Ensure that these keys remain consistent with their counterparts in the English JSON file.libs/blog/become-author/feature-become-author-page/src/lib/become-author-page/become-author-page.component.html (2)
12-40
: First Advertisement Component – External Link
The first advertisement component is well structured. It properly uses the<al-become-author-advertisement>
component with anariaLabel
of'author-ad-title'
. The title, description, and button text are dynamically populated with the translation functiont()
, and the external link (targeting a Typeform URL) is set appropriately withtarget="_blank"
. This implementation promotes accessibility and clarity in design.
41-69
: Second Advertisement Component – Local Navigation for Writing Rules
The second advertisement component is implemented effectively. The use of[routerLink]="'/writing-rules' | alLocalize"
ensures that local navigation is dynamically localized. TheariaLabel
of'writing-rules-ad-title'
and correspondingid
on the<h3>
element correctly support accessibility. All translation keys reference the new"articleWritingRules"
section consistently. Please verify that the local route/writing-rules
is correctly configured in the application routing.
Summary by CodeRabbit
New Features
Refactor