mirror of
https://github.com/penpot/penpot.git
synced 2026-05-20 15:33:43 +00:00
✨ Make the table-plugin work correctly on subpath
This commit is contained in:
parent
9fb6a3ab0e
commit
eebe90b2cd
@ -219,7 +219,10 @@
|
|||||||
"build": {
|
"build": {
|
||||||
"builder": "@angular-devkit/build-angular:application",
|
"builder": "@angular-devkit/build-angular:application",
|
||||||
"options": {
|
"options": {
|
||||||
"outputPath": "dist/apps/table-plugin",
|
"outputPath": {
|
||||||
|
"base": "dist/apps/table-plugin",
|
||||||
|
"browser": ""
|
||||||
|
},
|
||||||
"index": "apps/table-plugin/src/index.html",
|
"index": "apps/table-plugin/src/index.html",
|
||||||
"browser": "apps/table-plugin/src/main.ts",
|
"browser": "apps/table-plugin/src/main.ts",
|
||||||
"polyfills": ["zone.js"],
|
"polyfills": ["zone.js"],
|
||||||
@ -227,6 +230,7 @@
|
|||||||
"assets": [
|
"assets": [
|
||||||
"apps/table-plugin/src/_headers",
|
"apps/table-plugin/src/_headers",
|
||||||
"apps/table-plugin/src/favicon.ico",
|
"apps/table-plugin/src/favicon.ico",
|
||||||
|
"apps/table-plugin/src/manifest.json",
|
||||||
"apps/table-plugin/src/assets"
|
"apps/table-plugin/src/assets"
|
||||||
],
|
],
|
||||||
"styles": [
|
"styles": [
|
||||||
|
|||||||
@ -7,9 +7,9 @@
|
|||||||
"build": "ng build table-plugin && pnpm run build:plugin",
|
"build": "ng build table-plugin && pnpm run build:plugin",
|
||||||
"build:dev": "ng build table-plugin --configuration development",
|
"build:dev": "ng build table-plugin --configuration development",
|
||||||
"build:plugin": "node ../../tools/scripts/build-plugin.mjs --plugin=table-plugin",
|
"build:plugin": "node ../../tools/scripts/build-plugin.mjs --plugin=table-plugin",
|
||||||
"build:plugin:watch": "node ../../tools/scripts/build-plugin.mjs --plugin=table-plugin --watch",
|
"watch": "node ../../tools/scripts/build-plugin.mjs --plugin=table-plugin --watch",
|
||||||
"serve": "ng serve table-plugin",
|
"serve": "ng serve table-plugin",
|
||||||
"init": "concurrently --kill-others --names plugin,serve \"pnpm run build:plugin:watch\" \"pnpm run serve\"",
|
"init": "concurrently --kill-others --names plugin,serve \"pnpm run watch\" \"pnpm run serve\"",
|
||||||
"lint": "eslint .",
|
"lint": "eslint .",
|
||||||
"test": "vitest"
|
"test": "vitest"
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
import { ApplicationConfig } from '@angular/core';
|
import { ApplicationConfig } from '@angular/core';
|
||||||
import { provideRouter } from '@angular/router';
|
import { provideRouter, withHashLocation } from '@angular/router';
|
||||||
import { appRoutes } from './app.routes';
|
import { appRoutes } from './app.routes';
|
||||||
|
|
||||||
export const appConfig: ApplicationConfig = {
|
export const appConfig: ApplicationConfig = {
|
||||||
providers: [provideRouter(appRoutes)],
|
providers: [provideRouter(appRoutes, withHashLocation())],
|
||||||
};
|
};
|
||||||
|
|||||||
@ -3,7 +3,6 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8" />
|
<meta charset="utf-8" />
|
||||||
<title>table-plugin</title>
|
<title>table-plugin</title>
|
||||||
<base href="/" />
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
<link rel="icon" type="image/x-icon" href="favicon.ico" />
|
<link rel="icon" type="image/x-icon" href="favicon.ico" />
|
||||||
</head>
|
</head>
|
||||||
|
|||||||
8
plugins/apps/table-plugin/src/manifest.json
Normal file
8
plugins/apps/table-plugin/src/manifest.json
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"name": "Table plugin",
|
||||||
|
"description": "Table plugin to import or create tables",
|
||||||
|
"version": 2,
|
||||||
|
"code": "assets/plugin.js",
|
||||||
|
"icon": "assets/icon.png",
|
||||||
|
"permissions": ["content:read", "content:write"]
|
||||||
|
}
|
||||||
6
plugins/apps/table-plugin/vite.config.ts
Normal file
6
plugins/apps/table-plugin/vite.config.ts
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
/// <reference types="vitest/config" />
|
||||||
|
import { defineConfig } from 'vite';
|
||||||
|
|
||||||
|
export default defineConfig({
|
||||||
|
root: './',
|
||||||
|
});
|
||||||
Loading…
x
Reference in New Issue
Block a user