mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2026-03-11 21:55:01 +01:00
chore(deps): update web npm deps non-major (#6213)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: qwerty287 <qwerty287@posteo.de>
This commit is contained in:
561
web/pnpm-lock.yaml
generated
561
web/pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@@ -247,12 +247,14 @@ function setAdditionalOptions<T extends keyof Record<string, unknown>>(
|
||||
};
|
||||
}
|
||||
|
||||
const replaceRegex = /\/$/;
|
||||
|
||||
const oauthAppForgeUrl = computed(() => {
|
||||
if (!forge.value || !forge.value.type || !forge.value.url) {
|
||||
return '';
|
||||
}
|
||||
|
||||
const forgeUrl = `${forge.value.url.startsWith('http') ? '' : 'https://'}${forge.value.url.replace(/\/$/, '')}`;
|
||||
const forgeUrl = `${forge.value.url.startsWith('http') ? '' : 'https://'}${forge.value.url.replace(replaceRegex, '')}`;
|
||||
|
||||
switch (forge.value.type) {
|
||||
case 'github':
|
||||
|
||||
@@ -56,7 +56,7 @@ const emit = defineEmits<{
|
||||
const items = ref(Object.entries(props.modelValue).map(([key, value]) => ({ key, value })));
|
||||
|
||||
const displayItems = computed(() => {
|
||||
if (items.value.length === 0 || items.value[items.value.length - 1].key !== '') {
|
||||
if (items.value.length === 0 || items.value.at(-1)?.key !== '') {
|
||||
return [...items.value, { key: '', value: '' }];
|
||||
}
|
||||
return items.value;
|
||||
|
||||
@@ -26,7 +26,7 @@ function isSameRoute(a: RouteLocationRaw, b: RouteLocationRaw): boolean {
|
||||
|
||||
onMounted(() => {
|
||||
// don't add tab if tab id is already present
|
||||
if (tabs.value.find(({ to }) => isSameRoute(to, props.to))) {
|
||||
if (tabs.value.some(({ to }) => isSameRoute(to, props.to))) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -97,6 +97,7 @@ const updateVisibleItems = () => {
|
||||
const gapWidth = 16; // This need to match the gap between the tabs (gap-4)
|
||||
let totalWidth = 0;
|
||||
|
||||
// eslint-disable-next-line e18e/prefer-spread-syntax
|
||||
const items = Array.from(tabsRef.value!.children);
|
||||
|
||||
for (let i = 0; i < items.length; i++) {
|
||||
|
||||
@@ -187,6 +187,8 @@ const logBuffer = ref<LogLine[]>([]);
|
||||
const maxLineCount = 5000; // TODO(2653): set back to 500 and implement lazy-loading support
|
||||
const hasPushPermission = computed(() => repoPermissions?.value?.push);
|
||||
|
||||
const urlRegex = /https?:\/\/\S+/g;
|
||||
|
||||
function isScrolledToBottom(): boolean {
|
||||
if (!consoleElement.value) {
|
||||
return false;
|
||||
@@ -204,7 +206,6 @@ function formatTime(time?: number): string {
|
||||
}
|
||||
|
||||
function processText(text: string): string {
|
||||
const urlRegex = /https?:\/\/\S+/g;
|
||||
let txt = ansiUp.value.ansi_to_html(`${decode(text)}\n`);
|
||||
txt = txt.replace(
|
||||
urlRegex,
|
||||
|
||||
@@ -29,7 +29,7 @@ function toLocaleString(date: Date) {
|
||||
}
|
||||
|
||||
function timeAgo(date: number) {
|
||||
const seconds = Math.floor((new Date().getTime() - date) / 1000);
|
||||
const seconds = Math.floor((Date.now() - date) / 1000);
|
||||
|
||||
const formatter = new Intl.RelativeTimeFormat(currentLocale);
|
||||
|
||||
|
||||
@@ -54,7 +54,7 @@ export const usePipelineStore = defineStore('pipelines', () => {
|
||||
}
|
||||
|
||||
function getRepoPipelines(repoId: Ref<number>) {
|
||||
return computed(() => Array.from(pipelines.get(repoId.value)?.values() ?? []).sort(comparePipelines));
|
||||
return computed(() => [...(pipelines.get(repoId.value)?.values() ?? [])].sort(comparePipelines));
|
||||
}
|
||||
|
||||
function getPipeline(repoId: Ref<number>, _pipelineNumber: Ref<string | number>) {
|
||||
@@ -99,9 +99,10 @@ export const usePipelineStore = defineStore('pipelines', () => {
|
||||
}
|
||||
|
||||
const pipelineFeed = computed(() =>
|
||||
Array.from(pipelines.entries())
|
||||
[...pipelines.entries()]
|
||||
.reduce<PipelineFeed[]>((acc, [_repoId, repoPipelines]) => {
|
||||
const repoPipelinesArray = Array.from(repoPipelines.entries()).map(
|
||||
const repoPipelinesArray = Array.from(
|
||||
repoPipelines.entries(),
|
||||
([_pipelineNumber, pipeline]) =>
|
||||
<PipelineFeed>{
|
||||
...pipeline,
|
||||
|
||||
@@ -17,9 +17,7 @@ export const useRepoStore = defineStore('repos', () => {
|
||||
const ownedRepoIds = ref<number[]>([]);
|
||||
|
||||
const ownedRepos = computed(() =>
|
||||
Array.from(repos.entries())
|
||||
.filter(([repoId]) => ownedRepoIds.value.includes(repoId))
|
||||
.map(([, repo]) => repo),
|
||||
[...repos.entries()].filter(([repoId]) => ownedRepoIds.value.includes(repoId)).map(([, repo]) => repo),
|
||||
);
|
||||
|
||||
function getRepo(repoId: Ref<number>) {
|
||||
|
||||
@@ -43,9 +43,7 @@ const orgPermissions = requiredInject('org-permissions');
|
||||
|
||||
const search = ref('');
|
||||
const repos = computed(() =>
|
||||
Array.from(repoStore.repos.values())
|
||||
.filter((repo) => repo.org_id === org.value?.id)
|
||||
.map(repoWithLastPipeline),
|
||||
[...repoStore.repos.values()].filter((repo) => repo.org_id === org.value?.id).map(repoWithLastPipeline),
|
||||
);
|
||||
const { searchedRepos } = useRepoSearch(repos, search);
|
||||
const reposLastActivity = computed(() => sortReposByLastActivity(searchedRepos.value || []));
|
||||
|
||||
@@ -166,9 +166,7 @@ const selectedCronVariables = computed<Record<string, string>>({
|
||||
selectedCron.value!.variables = _vars;
|
||||
},
|
||||
get() {
|
||||
return selectedCron.value!.variables !== undefined && selectedCron.value!.variables !== null
|
||||
? selectedCron.value!.variables
|
||||
: {};
|
||||
return selectedCron.value!.variables ?? {};
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user