Skip to content

feat: restrictRelativePath option (close #1646) #1647

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

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

Conversation

LincZero
Copy link

Before submitting the PR, please make sure you do the following

  • Read the Contributing Guidelines.
  • Provide a description in this PR that addresses what the PR is solving. If this PR is going to solve an existing issue, please reference the issue (e.g. close #123).

What is the purpose of this pull request?

  • Bug fix
  • New feature
  • Documentation update
  • Other

Description

close #1646

Screenshots

Before

After

Copy link
Member

@Mister-Hope Mister-Hope left a comment

Choose a reason for hiding this comment

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

Since Vite's default static file is covering media files, we can also handle video and audio here as well.

@coveralls
Copy link

coveralls commented Apr 29, 2025

Pull Request Test Coverage Report for Build 14738968326

Details

  • 1 of 1 (100.0%) changed or added relevant line in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.2%) to 72.026%

Totals Coverage Status
Change from base Build 14700578882: -0.2%
Covered Lines: 648
Relevant Lines: 903

💛 - Coveralls

@LincZero LincZero requested a review from Mister-Hope April 29, 2025 18:47
@LincZero LincZero changed the title feat: restrictRelativePath option feat: restrictRelativePath option (close #1646) Apr 29, 2025
Copy link
Member

@Mister-Hope Mister-Hope left a comment

Choose a reason for hiding this comment

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

Like I said previously, video and audio tags shall also be tracked.

This means you should also modify the regexp in the first replacer function.

@LincZero
Copy link
Author

LincZero commented Apr 29, 2025

Should the unit test of the media tag be conducted in assetsPlugin.spec.ts.

This won't be available for supplementation until tomorrow.

@LincZero LincZero requested a review from Mister-Hope April 29, 2025 21:24
@Mister-Hope
Copy link
Member

Mister-Hope commented Apr 30, 2025

Audio and video tags can have src attribute.

@LincZero LincZero requested a review from Mister-Hope April 30, 2025 09:46
@Mister-Hope Mister-Hope requested a review from meteorlxy April 30, 2025 09:50
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.

[Feature request] Add img_alias_limit
3 participants