Update last version
This commit is contained in:
42
.github/workflows/publish-gitea.yml
vendored
Normal file
42
.github/workflows/publish-gitea.yml
vendored
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
name: Publicar Paquete SigProGrid (NPM)
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- 'v*'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
publish:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: node:20-bullseye
|
||||||
|
options: >-
|
||||||
|
--dns 192.168.1.1
|
||||||
|
--add-host git.natxocc.com:host-gateway
|
||||||
|
--add-host gitea:host-gateway
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout código
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
env:
|
||||||
|
GIT_CONFIG_PARAMETERS: "'url.https://git.natxocc.com/.insteadOf=http://gitea:3000/'"
|
||||||
|
|
||||||
|
- name: Instalar Bun
|
||||||
|
run: |
|
||||||
|
curl -fsSL https://bun.sh/install | bash
|
||||||
|
echo "$HOME/.bun/bin" >> $GITHUB_PATH
|
||||||
|
|
||||||
|
- name: Instalar y Build
|
||||||
|
run: |
|
||||||
|
export PATH="$HOME/.bun/bin:$PATH"
|
||||||
|
git config --global url."https://git.natxocc.com/".insteadOf "http://gitea:3000/"
|
||||||
|
bun install
|
||||||
|
bun run build
|
||||||
|
|
||||||
|
- name: Configurar Registro y Publicar
|
||||||
|
run: |
|
||||||
|
export PATH="$HOME/.bun/bin:$PATH"
|
||||||
|
REGISTRY="git.natxocc.com/api/packages/natxocc/npm/"
|
||||||
|
echo "//${REGISTRY}:_authToken=${{ secrets.PACK_TOKEN }}" > ~/.npmrc
|
||||||
|
npm publish --registry "https://${REGISTRY}" --userconfig ~/.npmrc
|
||||||
42
.github/workflows/publish.yml
vendored
Normal file
42
.github/workflows/publish.yml
vendored
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
name: Publish to NPM (Manual)
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
version:
|
||||||
|
description: 'Versión a publicar (ej: 1.0.0)'
|
||||||
|
required: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
publish:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: node:20-bullseye
|
||||||
|
options: >-
|
||||||
|
--dns 192.168.1.1
|
||||||
|
--add-host git.natxocc.com:host-gateway
|
||||||
|
--add-host gitea:host-gateway
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Clone source from Gitea
|
||||||
|
run: |
|
||||||
|
git clone https://git.natxocc.com/natxocc/sigpro-grid.git source
|
||||||
|
cd source
|
||||||
|
git checkout main
|
||||||
|
|
||||||
|
- name: Configurar Git para dependencias
|
||||||
|
run: |
|
||||||
|
git config --global url."https://git.natxocc.com/".insteadOf "http://gitea:3000/"
|
||||||
|
|
||||||
|
- uses: oven-sh/setup-bun@v1
|
||||||
|
with:
|
||||||
|
bun-version: latest
|
||||||
|
|
||||||
|
- name: Install and publish
|
||||||
|
run: |
|
||||||
|
cd source
|
||||||
|
bun install
|
||||||
|
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > .npmrc
|
||||||
|
npm publish --access public
|
||||||
|
env:
|
||||||
|
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||||
22
.github/workflows/unpublish.yml
vendored
Normal file
22
.github/workflows/unpublish.yml
vendored
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
name: Delete npm version
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
version:
|
||||||
|
description: 'Versión a eliminar'
|
||||||
|
required: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
delete:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Setup Node
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: '20'
|
||||||
|
registry-url: 'https://registry.npmjs.org'
|
||||||
|
- name: Unpublish version
|
||||||
|
run: npm unpublish sigpro-grid@${{ github.event.inputs.version }} --force
|
||||||
|
env:
|
||||||
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||||
38
bun.lock
Normal file
38
bun.lock
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
{
|
||||||
|
"lockfileVersion": 1,
|
||||||
|
"configVersion": 1,
|
||||||
|
"workspaces": {
|
||||||
|
"": {
|
||||||
|
"name": "sigpro-grid",
|
||||||
|
"dependencies": {
|
||||||
|
"ag-grid-community": "^35.2.0",
|
||||||
|
"ag-grid-enterprise": "^35.2.0",
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"sigpro-ui": "^1.2.6",
|
||||||
|
},
|
||||||
|
"peerDependencies": {
|
||||||
|
"sigpro": "^1.2.28",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
"packages": {
|
||||||
|
"ag-charts-community": ["ag-charts-community@13.2.1", "", { "dependencies": { "ag-charts-core": "13.2.1", "ag-charts-locale": "13.2.1", "ag-charts-types": "13.2.1" } }, "sha512-A+DCiesRp6WQ5R5e3x9bLh50IWCachVF6gkz6Dz4icMcq6WL5JNKL+xZEzrKYl+kuD8Y8728xmVm/H53o9Nayw=="],
|
||||||
|
|
||||||
|
"ag-charts-core": ["ag-charts-core@13.2.1", "", { "dependencies": { "ag-charts-types": "13.2.1" } }, "sha512-Y7rk3kF+fA6bUMjU+vIzG5rRBd+8EKjyIjzNR2uV1+HyrlnOn6b7Eb9HPkDUoosWHhz+UNCOW/lYDzPP6mivHQ=="],
|
||||||
|
|
||||||
|
"ag-charts-enterprise": ["ag-charts-enterprise@13.2.1", "", { "dependencies": { "ag-charts-community": "13.2.1", "ag-charts-core": "13.2.1" } }, "sha512-QiNuNUu3o5qWUz9cPLuKr9r9k2YsO8Nwp4qJGR0s76WT6AeCmqKa12cSJrvIpwvPdjZ3PVlwsMA8s8EZ4dqrXA=="],
|
||||||
|
|
||||||
|
"ag-charts-locale": ["ag-charts-locale@13.2.1", "", {}, "sha512-lwwV/l/O187R4DYUfjm6p8LijITe46IlDz8nOxNQNJAOpkzs+cWmjSxfNiM1BMVCWTcMdah/AKN+6iihbDa8IA=="],
|
||||||
|
|
||||||
|
"ag-charts-types": ["ag-charts-types@13.2.1", "", {}, "sha512-r7veb3QqJtIKlXmeUsLR4/oDPwmHxFI2tmbZra/203mdaz3uwQUrrgYNg628nrK+7L2YxXnwGc6L05tWjLLjNQ=="],
|
||||||
|
|
||||||
|
"ag-grid-community": ["ag-grid-community@35.2.1", "", { "dependencies": { "ag-charts-types": "13.2.1" } }, "sha512-ycmGI+1EbUT7i3eg/Kgi1owwnkdHXRufo10Xm6cfSsVPM3TMpvlbLgi28KIPt9DGHZWHq9fOBn7nxMNdv1Yaow=="],
|
||||||
|
|
||||||
|
"ag-grid-enterprise": ["ag-grid-enterprise@35.2.1", "", { "dependencies": { "ag-grid-community": "35.2.1" }, "optionalDependencies": { "ag-charts-community": "13.2.1", "ag-charts-enterprise": "13.2.1" } }, "sha512-nLl06cc7/THzf7mGZt7PotdeaBN74X3K9g2looyvJEymrOOJfjrLePrV4aNNhz/WZnATkbyblm5DM/qv3BeHKA=="],
|
||||||
|
|
||||||
|
"sigpro": ["sigpro@1.2.28", "", {}, "sha512-4fz70tNpLdgyreLweEuORdlTqvegCrjohgU6wHtil7+ItjSMsu2u0+1ICE06xsybgReCi+YCkGndwukwBLfMHA=="],
|
||||||
|
|
||||||
|
"sigpro-ui": ["sigpro-ui@1.2.6", "", {}, "sha512-I0HP4yGJ5wtVYTDd2Ig6Wqk7iUV8hlaq3DO7KZIG8ZKmZMRMWAaBzz5i4gFelY5hfpcwo0wJk7KVFYVbaXZXsg=="],
|
||||||
|
}
|
||||||
|
}
|
||||||
106
dist/sigpro-grid.esm.min.js
vendored
106
dist/sigpro-grid.esm.min.js
vendored
File diff suppressed because one or more lines are too long
106
dist/sigpro-grid.min.js
vendored
106
dist/sigpro-grid.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -23,6 +23,9 @@
|
|||||||
"ag-grid-enterprise": "^35.2.0"
|
"ag-grid-enterprise": "^35.2.0"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"sigpro": "^1.1.21"
|
"sigpro": "^1.2.28"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"sigpro-ui": "^1.2.6"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
10
src/index.js
10
src/index.js
@@ -1,4 +1,4 @@
|
|||||||
import { Tag, Watch, onUnmount } from "../sigpro.js";
|
import { h, watch, onUnmount } from "sigpro";
|
||||||
import {
|
import {
|
||||||
ModuleRegistry,
|
ModuleRegistry,
|
||||||
ValidationModule,
|
ValidationModule,
|
||||||
@@ -106,7 +106,7 @@ export const Grid = (props) => {
|
|||||||
|
|
||||||
gridApi = createGrid(container, gridOptions);
|
gridApi = createGrid(container, gridOptions);
|
||||||
|
|
||||||
const stopData = Watch(data, () => {
|
const stopData = watch(data, () => {
|
||||||
if (!gridApi || gridApi.isDestroyed()) return;
|
if (!gridApi || gridApi.isDestroyed()) return;
|
||||||
const newData = typeof data === "function" ? data() : data;
|
const newData = typeof data === "function" ? data() : data;
|
||||||
if (Array.isArray(newData)) {
|
if (Array.isArray(newData)) {
|
||||||
@@ -117,7 +117,7 @@ export const Grid = (props) => {
|
|||||||
}
|
}
|
||||||
}, true);
|
}, true);
|
||||||
|
|
||||||
const stopTheme = Watch(isDark, () => {
|
const stopTheme = watch(isDark, () => {
|
||||||
if (gridApi && !gridApi.isDestroyed()) {
|
if (gridApi && !gridApi.isDestroyed()) {
|
||||||
const dark = isDark();
|
const dark = isDark();
|
||||||
const newTheme = getTheme(dark);
|
const newTheme = getTheme(dark);
|
||||||
@@ -134,7 +134,7 @@ export const Grid = (props) => {
|
|||||||
'stopEditingWhenCellsLoseFocus', 'enterMovesDown', 'enterMovesDownAfterEdit'
|
'stopEditingWhenCellsLoseFocus', 'enterMovesDown', 'enterMovesDownAfterEdit'
|
||||||
];
|
];
|
||||||
|
|
||||||
const stopOptions = Watch(options, () => {
|
const stopOptions = watch(options, () => {
|
||||||
if (!gridApi || gridApi.isDestroyed() || !options) return;
|
if (!gridApi || gridApi.isDestroyed() || !options) return;
|
||||||
const newOptions = typeof options === "function" ? options() : options;
|
const newOptions = typeof options === "function" ? options() : options;
|
||||||
safeOptions.forEach(key => {
|
safeOptions.forEach(key => {
|
||||||
@@ -158,7 +158,7 @@ export const Grid = (props) => {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
return Tag("div", {
|
return h("div", {
|
||||||
class: className,
|
class: className,
|
||||||
style: style,
|
style: style,
|
||||||
ref: initGrid
|
ref: initGrid
|
||||||
|
|||||||
Reference in New Issue
Block a user