mirror of
https://github.com/misskey-dev/misskey.git
synced 2024-12-23 17:10:39 +01:00
fix(client): fix popout url (#8494)
This commit is contained in:
parent
804fa33535
commit
d2784030ec
2 changed files with 4 additions and 3 deletions
|
@ -126,7 +126,7 @@ let changed = $ref(false);
|
||||||
useLeaveGuard($$(changed));
|
useLeaveGuard($$(changed));
|
||||||
|
|
||||||
function showPreview() {
|
function showPreview() {
|
||||||
os.pageWindow('preview');
|
os.pageWindow('/preview');
|
||||||
}
|
}
|
||||||
|
|
||||||
function setBgColor(color: typeof bgColors[number]) {
|
function setBgColor(color: typeof bgColors[number]) {
|
||||||
|
|
|
@ -1,8 +1,9 @@
|
||||||
import * as config from '@/config';
|
import * as config from '@/config';
|
||||||
|
import { appendQuery } from './url';
|
||||||
|
|
||||||
export function popout(path: string, w?: HTMLElement) {
|
export function popout(path: string, w?: HTMLElement) {
|
||||||
let url = path.startsWith('http://') || path.startsWith('https://') ? path : config.url + "/" + path;
|
let url = path.startsWith('http://') || path.startsWith('https://') ? path : config.url + path;
|
||||||
url += '?zen';
|
url = appendQuery(url, 'zen');
|
||||||
if (w) {
|
if (w) {
|
||||||
const position = w.getBoundingClientRect();
|
const position = w.getBoundingClientRect();
|
||||||
const width = parseInt(getComputedStyle(w, '').width, 10);
|
const width = parseInt(getComputedStyle(w, '').width, 10);
|
||||||
|
|
Loading…
Reference in a new issue