Commit graph

193 commits

Author SHA1 Message Date
Matthieu Riegler
ffad78360f refactor(core): add dedicated deprecated signatures for providedIn: any / NgModule.
Those were deprecated by #47616 back in v15.

fixes #65923

(cherry picked from commit 8199945637)
2025-12-09 10:38:14 -08:00
SkyZeroZx
5d73893219 docs(docs-infra): Refactors tutorial generation and updates ng-container docs
Updates the `ng-container` documentation page to use the correct `angular-html` code format and removes an unused CLI documentation file.

(cherry picked from commit 9a6b8e0315)
2025-12-09 09:25:34 -08:00
Matthieu Riegler
182116582e docs(docs-infra): prefer/avoid code block styling
fixes #65866

(cherry picked from commit 3411638f65)
2025-12-09 09:23:17 -08:00
Joey Perrott
ed7db0e0a2 build: update to bazel version 8.4.2
Update bazel to use version 8.4.2

(cherry picked from commit aa92f19307)
2025-12-08 10:22:04 -08:00
Matthieu Riegler
10bdae9098 build: enable angular formatting on all html files
This should also be safe on any html file that isn't an angular template

(cherry picked from commit 9d1d742f1b)
2025-12-08 10:19:50 -08:00
SkyZeroZx
5b911d6025 docs(docs-infra): fix hideCopy option to code snippets
Adds the ability to hide the copy button on code snippets.

Updates documentation to use the new `hideCopy` option with the new
markdown code fence syntax.

(cherry picked from commit a4563044ad)
2025-12-08 08:48:25 -08:00
Shuaib Hasan Akib
2e5d187120 fix(docs-infra): prevent readonly TypeScript keyword from being linked
This updates the docs infrastructure to avoid incorrectly linking the `readonly` keyword in TypeScript examples.

Fixes #65632

(cherry picked from commit 7f8ffa3304)
2025-12-03 16:30:55 +01:00
Joey Perrott
8e837cc226 docs: rename visibleRegion to region
Use the attribute region instead of visibleRegion

(cherry picked from commit 34bedae101)
2025-12-03 10:06:06 +01:00
Joey Perrott
76f784c340 refactor(docs-infra): extract only the visibleRegion
Previously we extracted the regions and only made the visible region visible on the page, but since there is not a need for the
non-visible code to be presented, we don't need to include it in the generated code snippets.

(cherry picked from commit 9b3b5fb4cf)
2025-12-03 10:06:05 +01:00
Matthieu Riegler
8e0df4083d docs(docs-infra): Show examples on function overloads
(cherry picked from commit a784995a98)
2025-12-02 12:13:16 +01:00
Joey Perrott
53e0aaba4e refactor(docs-infra): move header id tracking into RendererContext
Move the header id tracking into the renderer context rather than a global state.  Since the RendererContext is
initialized for each execution of the marked parser, we can store the context of which header ids have been seen within
a single page there which allows us to run these parse interactions in parallel.

(cherry picked from commit a16a70ca74)
2025-12-02 12:03:39 +01:00
Joey Perrott
5ec3bd9c55 refactor(docs-infra): transform all headings using the built in transformer
Rather than manually calling the transformer we use for headings from within a render function, we now properly call into the Renderer to do them
via the tokens they are require instead.  This is being done to allow us to have a per Renderer instance of state instead of a global state, which will
allow us to run marked async and hopefully speed up the pipeline

(cherry picked from commit 8b296543ae)
2025-12-02 12:03:38 +01:00
SkyZeroZx
dad3d7900f feat(docs-infra): Adds copy link to anchor functionality
Enables copying a direct link to any section by clicking its anchor. Also updates the aria-label to remove the code tag

(cherry picked from commit 4e89bc6244)
2025-12-01 19:19:35 +01:00
SkyZeroZx
b7ccb308b8 docs(docs-infra): Improves symbol linking for Angular Aria selectors
Improves the symbol linking logic to handle Angular component selectors (e.g., ngCombobox). It attempts to convert Angular selector patterns to their corresponding class names, improving navigation to Angular API documentation.

(cherry picked from commit 2d854e01bc)
2025-12-01 18:47:23 +01:00
SkyZeroZx
10201b6873 docs(docs-infra): renders inline code snippets in docs pills
Improves the rendering of `DocsPillRow` to correctly display inline code snippets (using backticks) within the pill labels.

(cherry picked from commit ef034c15c1)
2025-11-25 18:30:09 -05:00
Joey Perrott
0424a998c9 refactor(docs-infra): make docs-alert an inline token
Migrate docs-alert to be inline instead of block, this ensures that the content is placed within a <p> tag as expected. This is important
for ensuring that the iconography is placed correctly within the wrapper div generated for the alert. Additionally, we refactor the matcher
code to be more efficient, running with fewer loops.

(cherry picked from commit 046501fd33)
2025-11-24 13:26:03 -05:00
SkyZeroZx
93ef5d410e feat(docs-infra): add docs-image extension for enhanced image handling in markdown
Extends the Markdown parser to support `loading`, `decoding`, and `fetchpriority` attributes for images via curly brace syntax.

(cherry picked from commit 46269be842)
2025-11-21 13:25:02 -05:00
Joey Perrott
a30fe81ae8 refactor(docs-infra): improve code efficiency for adding line numbers
Only run the code for adding line numbers if line numbers are required, otherwise skip the code block

(cherry picked from commit 88753d6a5a)
2025-11-21 13:20:49 -05:00
Joey Perrott
557cc41ff0 refactor(docs-infra): remove the unnecessary whitespace using shiki
Use a transformer within shiki to remove the unnecessary whitespace between code lines

(cherry picked from commit a873c4eb1a)
2025-11-21 13:20:49 -05:00
Joey Perrott
121997b8c2 refactor(docs-infra): drop support for providing a file diff in docs-code
Drop support for exposing a diff view in the docs-code element as it is unused and costly to even check for

(cherry picked from commit 8ec0a4ee5c)
2025-11-21 13:20:49 -05:00
Joey Perrott
7f7a2187a8 refactor(docs-infra): use shiki for highlighting
Use shiki to perform highlighting instead of a postprocessing action

(cherry picked from commit fee79e37d5)
2025-11-21 13:20:49 -05:00
Jessica Janiuk
28810e0914 build: bump adev version
Bump adev versions for v21 release

(cherry picked from commit d42d7523ec)
2025-11-19 20:09:29 +00:00
Andrew Seguin
1355edde69 docs: hide temporary prerender tabs and multifile docs sections
(cherry picked from commit d4595791d6)
2025-11-18 14:54:52 -08:00
Amy Sorto
e08a8e2678 docs: update overview page
(cherry picked from commit 111a7644ef)
2025-11-18 14:54:13 -08:00
Joey Perrott
6551b65172 docs: update examples to latest Angular
Updates the adev examples to use Angular 21.0.0-rc.2

(cherry picked from commit 7e70682f2b)
2025-11-17 19:18:01 +00:00
Shuaib Hasan Akib
c03b1fa8a0 fix(docs-infra): add bash language support for shell prompt rendering
Code blocks with `bash` language identifier were not rendering the `$`
prefix, while `shell` blocks did.

This ensures consistent command-line prompt rendering across both
`bash` and `shell` code blocks in the documentation.

(cherry picked from commit f462684211)
2025-11-17 16:31:31 +00:00
Cheng-Hsuan Tsai
3228cce727 docs(docs-infra): enable tabs layout
(cherry picked from commit de234def0e)
2025-11-14 20:24:05 +00:00
cexbrayat
f550f4ab4a docs: ExperimentalIsolatedShadowDom mentions
(cherry picked from commit c137f1fe91)
2025-11-14 16:41:16 +00:00
Matthieu Riegler
4f6f9b8e8d docs(docs-infra): Add support for metadata on fenced code blocks
This will help us replace `docs-code` with inline code usages and prevent future indentation issues

(cherry picked from commit f737a9dd5c)
2025-11-13 17:36:17 +00:00
hawkgs
c133f48902 docs(docs-infra): improve playground layout
Improve the layout and optimize the empty space; Introduce some minor improvements to the code editor

(cherry picked from commit 7ab1b3a32a)
2025-11-13 17:07:58 +00:00
Matthieu Riegler
5e86299ec4 docs(docs-infra): Add support for experimental enum entries
(cherry picked from commit 16e61f5dd0)
2025-11-11 08:46:09 -08:00
Alan Agius
3bed9f0f16
build: format md files
This commit configures prettier to format markdown files.
2025-11-06 10:07:13 -08:00
Miles Malerba
4bdd317596 docs: improve docs generation for namespaces (#64747)
Improves docs epxerience for interfaces / type aliases that are merged
with a namespace.

PR Close #64747
2025-11-05 22:42:59 +00:00
marktechson
fcd5f9f0ef docs: add v21 landing page
Adds a new landing page for developer events, starting with the v21 page. It also includes an ICS file link for calendar invites. Also updated the tests for the docs-pill to support two new attributes so developers can add the event to their calendars.

(cherry picked from commit 7a422c209a)
2025-11-03 15:59:31 -08:00
Miles Malerba
981fabc9b6 feat(docs-infra): add support for namespaces
Adds support for generating docs for namespaces (and merged declarations
of namespace + type)

(cherry picked from commit 662f0e5c00)
2025-10-29 13:22:26 -07:00
SkyZeroZx
207a26c125 docs(docs-infra): Prevent empty extends clause in interface documentation
Interfaces with no extends clause were incorrectly rendered with a trailing extends keyword followed by nothing, resulting in invalid TypeScript syntax

(cherry picked from commit f3d056a065)
2025-10-29 18:48:35 +01:00
Shuaib Hasan Akib
e62da0d1c7 fix(docs-infra): preserve shell class for multifile code blocks
The ExampleViewer component was extracting only innerHTML from code
blocks in multifile examples, which lost the shell class applied by
the formatCode function. This caused the $ prompt to not appear for
shell commands in multifile blocks even when language="shell" was set.

Modified the Snippet interface to track shell language state and
updated getCodeSnippetsFromMultifileWrapper and getStandaloneCodeSnippet
methods to preserve the shell class. Updated example-viewer template
to conditionally apply the shell class to the code wrapper element.

Fixes inconsistency between standalone and multifile shell code blocks.

(cherry picked from commit 27e183330e)
2025-10-27 09:29:42 +01:00
Matthieu Riegler
d8388b210a docs(docs-infra): Support linking to individual playground templates
(cherry picked from commit 6e7b3c2aa6)
2025-10-24 18:47:14 +02:00
Matthieu Riegler
54636eacca docs(docs-infra): Extract multiple extends statements for interfaces (#64539)
fixes #64528

PR Close #64539
2025-10-20 21:18:13 +00:00
SkyZeroZx
ecb2507c8b docs(docs-infra): Corrects repo name typo in entry parsing logic (#64487)
Ensures the repository reference uses the correct name to prevent confusion and maintain consistency across generated documentation entries.

PR Close #64487
2025-10-17 14:52:24 +00:00
Matthieu Riegler
59c152833e docs: add check for non-existing anchor (#64309)
This is only for the anchors on the same document for now.
Commit also includes some reformating.

fixes #64303

PR Close #64309
2025-10-10 06:43:51 -07:00
Matthieu Riegler
69b3c05b9e docs: add mentions host style bindings (#64257)
Also adds a section about css custom properties

fixes #64256

PR Close #64257
2025-10-07 20:39:40 -04:00
Matthieu Riegler
1ffc643737 docs(docs-infra): fix @example in class members (#64249)
eg: ApplicationRef

PR Close #64249
2025-10-06 15:11:31 -04:00
Alan Agius
fc643c9044 build: adopt moduleResolution: "bundler" (#64125)
This commit updates the TypeScript configuration across the project to use `moduleResolution: "bundler"`. This modernizes our module resolution strategy to align with current TypeScript best practices and bundler behaviors.

The following changes are included:
- Updated `tsconfig.json` files to set `moduleResolution` to `"bundler"`.
- Updated the `rules_angular` bazel dependency to a version compatible with these changes.
- Adjusted related test files and golden files to reflect the new module resolution strategy.

PR Close #64125
2025-09-29 14:20:23 -04:00
Matthieu Riegler
5eb9f57ae8 docs: Introduce API category sorting (#63914)
PR Close #63914
2025-09-19 14:44:10 +00:00
Matthieu Riegler
5612ad5b45 docs: add alert about routelinkactive being a content query (#63829)
This commit also fixes an issue with alert that we're parse correctly if they were at the end of the markdown string

fixes #52877

PR Close #63829
2025-09-16 15:15:24 +00:00
Shuaib Hasan Akib
7e828e3d39 docs(docs-infra): code style improvement and component update (#63557)
- Improved code style consistency in docs-infra
- Updated app.component.ts for enhancements

Co-authored-by: Matthieu Riegler <kyro38@gmail.com>

PR Close #63557
2025-09-15 15:02:24 +00:00
Shuaib Hasan Akib
be790e5f5c docs(docs-infra): prevent empty h3 tags when title is empty (#63573)
Conditionally render h3 element only when title attribute has content

PR Close #63573
2025-09-08 14:50:47 -07:00
Shuaib Hasan Akib
e7fbee0a13 docs(docs-infra): quote title attributes in links (#63578)
Prevent broken HTML when link titles contain spaces by properly quoting the title attribute

PR Close #63578
2025-09-08 10:14:47 -07:00
Kristiyan Kostadinov
ecef955185 docs: update examples to latest Angular and TypeScript (#63589)
Updates the adev examples to use TypeScript 5.9 and Angular 20.2.

PR Close #63589
2025-09-05 13:54:40 -07:00