-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 2cbcd1d
Showing
28 changed files
with
6,396 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# This file is for unifying the coding style for different editors and IDEs | ||
# editorconfig.org | ||
|
||
[*] | ||
charset = utf-8 | ||
indent_style = tab | ||
indent_size = 2 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
|
||
[*.php] | ||
indent_size = 4 | ||
|
||
[*.md] | ||
indent_style = space | ||
trim_trailing_whitespace = false | ||
insert_final_newline = false | ||
|
||
[composer.json] | ||
indent_size = 4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
module.exports = { | ||
extends: ["eslint:recommended", "plugin:vue/recommended", "prettier"], | ||
rules: { | ||
"vue/attributes-order": "error", | ||
"vue/component-definition-name-casing": "off", | ||
"vue/html-closing-bracket-newline": [ | ||
"error", | ||
{ | ||
singleline: "never", | ||
multiline: "always", | ||
}, | ||
], | ||
"vue/multi-word-component-names": "off", | ||
"vue/require-default-prop": "off", | ||
"vue/require-prop-types": "error", | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Git | ||
.gitattributes export-ignore | ||
.github/ export-ignore | ||
.gitignore export-ignore | ||
|
||
# Source files | ||
src/ export-ignore | ||
|
||
# Development files | ||
.editorconfig export-ignore | ||
.eslintrc.js export-ignore | ||
composer.lock export-ignore | ||
package-lock.json export-ignore | ||
package.json export-ignore | ||
|
||
# Docs | ||
docs/ export-ignore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
custom: ["https://paypal.me/distantnative"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
--- | ||
name: "🐛 Bug report" | ||
about: "If something isn't working as expected 🤬" | ||
--- | ||
|
||
## Describe the bug | ||
|
||
## Steps to reproduce | ||
|
||
1. | ||
1. | ||
1. | ||
|
||
## Expected behavior | ||
|
||
## Additional context | ||
|
||
E.g. screenshots | ||
|
||
## Context | ||
|
||
- Browser: | ||
- Kirby version: | ||
- Retour version: | ||
- Retour config: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
name: "⭐️ Feature request" | ||
about: "If you have an idea to share ☁️" | ||
--- | ||
|
||
## What's your idea? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
Fixes # | ||
|
||
## Proposed Changes | ||
|
||
- | ||
- | ||
- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
![Kirby CSV field](https://distantnative.com/kirby-csv-field/ogimage.png) | ||
|
||
[![Version](https://img.shields.io/badge/version-1.0.0-8dbae7.svg?style=for-the-badge)](https://github.com/distantnative/kirby-csv-field/releases) | ||
[![Dependency](https://img.shields.io/badge/kirby-4.0.0--4.x-f0d575.svg?style=for-the-badge)](https://getkirby.com/) | ||
[![Donate](https://img.shields.io/badge/support-give_back-bdde7a.svg?style=for-the-badge)](https://paypal.me/distantnative) | ||
|
||
> [!NOTE] | ||
> Kirby CMS Panel field to upload and display a single CSV file | ||
## [Documentation](https://distantnative.github.io/kirby-csv-field/) | ||
|
||
## Pay it forward 💛 | ||
|
||
This plugin is completely free and published under the MIT license. However, development needs time and effort. If you are using it in a commercial project or just want to support me to keep this plugin alive, please [make a donation of your choice](https://paypal.me/distantnative). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Security | ||
|
||
## Reporting a vulnerability | ||
|
||
If you have spotted a vulnerability in Retour, please make sure to let me know immediately. I take any report very seriously and will react as soon as possible. | ||
|
||
You can always write me directly at nico@getkirby.com. | ||
|
||
Please do not write to me publicly, e.g. in an issue, as making security vulnerabilities public before they are fixed can give attackers valuable time to exploit the issue. By letting me know directly, you can protect other users from such attacks. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name: Deploy docs to GitHub Pages | ||
|
||
on: | ||
push: | ||
branches: [main] | ||
paths: | ||
- "docs/**" | ||
workflow_dispatch: | ||
|
||
permissions: | ||
contents: read | ||
pages: write | ||
id-token: write | ||
|
||
concurrency: | ||
group: pages | ||
cancel-in-progress: false | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup Node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 20 | ||
cache: npm | ||
- name: Setup Pages | ||
uses: actions/configure-pages@v4 | ||
- name: Install dependencies | ||
run: npm ci | ||
- name: Build with VitePress | ||
run: npm run docs:build | ||
- name: Upload artifact | ||
uses: actions/upload-pages-artifact@v3 | ||
with: | ||
path: docs/.vitepress/dist | ||
|
||
deploy: | ||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
needs: build | ||
runs-on: ubuntu-latest | ||
name: Deploy | ||
steps: | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# OS files | ||
.DS_Store | ||
|
||
# Vendor files | ||
/node_modules | ||
/vendor | ||
|
||
# Cache and temporary files | ||
/.cache | ||
|
||
# Docs | ||
/docs/.vitepress/dist | ||
/docs/.vitepress/cache |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"name": "distantnative/kirby-csv-field", | ||
"description": "Kirby CMS Panel field to upload and display a single CSV file", | ||
"license": "MIT", | ||
"type": "kirby-plugin", | ||
"version": "1.0.0-beta.1", | ||
"homepage": "https://distantnative.com/kirby-csv-field/", | ||
"authors": [ | ||
{ | ||
"name": "Nico Hoffmann", | ||
"email": "nico@getkirby.com" | ||
} | ||
], | ||
"require": { | ||
"php": ">=8.1.0 <8.4.0", | ||
"getkirby/cms": "^4.0", | ||
"getkirby/composer-installer": "^1.1" | ||
}, | ||
"extra": { | ||
"installer-name": "csv-field", | ||
"kirby-cms-path": false | ||
}, | ||
"config": { | ||
"allow-plugins": { | ||
"getkirby/composer-installer": true | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
import { defineConfig } from "vitepress"; | ||
|
||
// https://vitepress.dev/reference/site-config | ||
export default defineConfig({ | ||
title: "CSV field", | ||
description: "Preview your CSV file in the Panel", | ||
lang: "en-US", | ||
base: "/kirby-csv-field/", | ||
appearance: false, | ||
cleanUrls: true, | ||
head: [["link", { rel: "og:image", href: "/kirby-csv-field/ogimage.png" }]], | ||
themeConfig: { | ||
nav: [ | ||
{ text: "Home", link: "/" }, | ||
{ text: "Docs", link: "/quickstart" }, | ||
{ | ||
text: "Changelog", | ||
link: "https://github.com/distantnative/kirby-csv-field/releases", | ||
}, | ||
{ | ||
text: "Donate", | ||
link: "https://paypal.me/distantnative", | ||
}, | ||
], | ||
|
||
search: { | ||
provider: "local", | ||
}, | ||
|
||
sidebar: [ | ||
{ | ||
text: "Documentation", | ||
items: [ | ||
{ text: "Getting started", link: "/quickstart" }, | ||
{ text: "Panel field", link: "/field" }, | ||
{ text: "Use in templates", link: "/templates" }, | ||
], | ||
}, | ||
{ | ||
text: "Support development", | ||
items: [ | ||
{ | ||
text: "Donate", | ||
link: "https://paypal.me/distantnative", | ||
}, | ||
], | ||
}, | ||
], | ||
|
||
socialLinks: [ | ||
{ | ||
icon: "github", | ||
link: "https://github.com/distantnative/retour-for-kirby", | ||
}, | ||
{ | ||
icon: "mastodon", | ||
link: "https://chaos.social/@distantnative", | ||
}, | ||
], | ||
|
||
footer: { | ||
message: | ||
"CSV field is made for <a href='https://getkirby.com'>Kirby CMS</a> with love 💛", | ||
}, | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
:root { | ||
--vp-font-family-base: ui-rounded, "Hiragino Maru Gothic ProN", Quicksand, | ||
Comfortaa, Manjari, "Arial Rounded MT", "Arial Rounded MT Bold", Calibri, | ||
source-sans-pro, sans-serif; | ||
--vp-font-family-mono: ui-monospace, "Cascadia Code", "Source Code Pro", Menlo, | ||
Consolas, "DejaVu Sans Mono", monospace; | ||
|
||
--vp-c-brand-1: var(--vp-c-green-1); | ||
--vp-c-brand-2: var(--vp-c-green-2); | ||
--vp-c-brand-3: var(--vp-c-green-3); | ||
--vp-c-brand-soft: var(--vp-c-green-soft); | ||
|
||
--vp-c-bg: #eaf2ea; | ||
--vp-home-hero-name-color: #89ba74; | ||
--vp-home-hero-image-filter: blur(10rem); | ||
--vp-button-alt-bg: #b6dabf; | ||
--vp-button-alt-hover-bg: #a2caac; | ||
} | ||
|
||
.VPHomeFeatures { | ||
margin-bottom: 4.5rem; | ||
} | ||
|
||
.VPHomeHero .image-bg { | ||
opacity: 0.5; | ||
} | ||
|
||
.vp-doc img { | ||
border-radius: 0.5rem; | ||
box-shadow: | ||
rgba(0, 0, 0, 0.08) 0px 20px 25px -5px, | ||
rgba(0, 0, 0, 0.05) 0px 10px 10px -5px; | ||
} | ||
|
||
.vp-doc ul + .custom-block { | ||
margin-top: 2rem; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import DefaultTheme from "vitepress/theme"; | ||
import "./custom.css"; | ||
|
||
export default DefaultTheme; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Panel field | ||
|
||
```yml | ||
myCsvField: | ||
type: csv | ||
label: My CSV field | ||
delimiter: ; | ||
``` | ||
![CSV field in the Panel](/csv-field.png) | ||
## Custom columns | ||
```yml | ||
myCsvField: | ||
type: csv | ||
columns: | ||
a: | ||
key: User names | ||
label: User | ||
``` | ||
## Uploads | ||
### Assign template on upload | ||
```yml | ||
myCsvField: | ||
type: csv | ||
uploads: | ||
template: my-file-template | ||
``` | ||
### Prevent uploads | ||
```yml | ||
myCsvField: | ||
type: csv | ||
uploads: false | ||
``` |
Oops, something went wrong.