misskey/packages/frontend-shared/js
Julia d10fdfe973
Merge commit from fork
* SP-2025-03.1 always wrap icon&thumbnail URLs

if they're not HTTP URLs, the frontend won't be able to display them
anyway (`<img src="mailto:…">` or '<div stile="background-image:
url(nntp:…)">` aren't going to work!), so let's always run them through the
media proxy, which will fail harder (fetching a `javascript:` URL
won't do anything in the backend, might do something in the frontend)
and will always protect the client's address in cases like `gemini:`
where the browser could try to fetch

* SP-2025-03.2 use object binding for more styles

interpolating a random (remote-controlled!) string into a `style`
attribute is a bad idea; using VueJS object binding, we should get
proper quoting and therefore safe parse failures instead of CSS
injections / XSS

* SP-2025-03.3 slightly more robust "self" URL handling

parse URLs instead of treating them as strings; this is still not
perfect, but the `URL` class only handles full URLs, not relative
ones, so there's so way to ask it "give me a URL object that
represents this resource relative to this base URL"

notice that passing very weird URLs to `MkUrl` and `MkUrlPreview` will
break the frontend (in dev mode) because there's an untrapped `new
URL(…)` that may explode; production builds seem to safely ignore the
error, though

---------

Co-authored-by: dakkar <dakkar@thenautilus.net>
2025-04-29 08:15:54 +09:00
..
collapsed.ts refactor(frontend): frontend-embed/src/to-be-sharedを共通化 (#14536) 2024-09-10 18:39:53 +09:00
config.ts Enhance: 2段階認証時のリカバリーコードのファイル名にサーバーURLを含めるように (#15677) 2025-03-19 19:34:57 +09:00
const.ts feat: アップロード可能な最大ファイルサイズをロールごとに設定可能に 2025-04-27 09:35:44 +09:00
embed-page.ts update deps (#15311) 2025-02-15 10:24:22 +09:00
emoji-base.ts refactor(frontend): frontend-embed/src/to-be-sharedを共通化 (#14536) 2024-09-10 18:39:53 +09:00
emojilist.json feat(frontend): ノート・ユーザータイムライン埋め込み (#13929) 2024-09-09 20:57:36 +09:00
emojilist.ts fix(deps): update [frontend] update dependencies (#15489) 2025-02-15 14:54:45 +09:00
extract-avg-color-from-blurhash.ts feat(frontend): ノート・ユーザータイムライン埋め込み (#13929) 2024-09-09 20:57:36 +09:00
i18n.ts update deps (#15311) 2025-02-15 10:24:22 +09:00
intl-const.ts refactor(frontend): frontend-embed/src/to-be-sharedを共通化 (#14536) 2024-09-10 18:39:53 +09:00
is-link.ts refactor(frontend): frontend-embed/src/to-be-sharedを共通化 (#14536) 2024-09-10 18:39:53 +09:00
media-proxy.ts feat(frontend): ノート・ユーザータイムライン埋め込み (#13929) 2024-09-09 20:57:36 +09:00
scroll.ts enhance(frontend): disable horizontal swipe for timeline/notifications to improve ux 2025-03-29 15:00:29 +09:00
url.ts Merge commit from fork 2025-04-29 08:15:54 +09:00
use-document-visibility.ts feat(frontend): ノート・ユーザータイムライン埋め込み (#13929) 2024-09-09 20:57:36 +09:00
use-interval.ts feat(frontend): ノート・ユーザータイムライン埋め込み (#13929) 2024-09-09 20:57:36 +09:00
worker-multi-dispatch.ts refactor(frontend): frontend-embed/src/to-be-sharedを共通化 (#14536) 2024-09-10 18:39:53 +09:00