Skip to content

Commit

Permalink
fix: deploy docs
Browse files Browse the repository at this point in the history
  • Loading branch information
steve-lebleu committed Mar 28, 2024
1 parent 05f4559 commit 63c641b
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ jobs:
- name: Deploy documentation using SCP
uses: garygrossgarten/github-action-scp@release
with:
local: docs/.vuepress/dist
local: docs/.vitepress/dist
remote: "${{ vars.KONFER_SSH_TARGET }}/docs"
host: ${{ secrets.KONFER_SSH_HOST }}
username: ${{ secrets.KONFER_SSH_USER }}
Expand Down
22 changes: 16 additions & 6 deletions demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -67,26 +67,26 @@
}
document.addEventListener('DOMContentLoaded', fn);
};

ready(() => {
const input = document.getElementById('auto-complete');

const headers = new Headers();
headers.append('content-type', 'application/x-www-form-urlencoded');
headers.append('method', 'GET');

fetch(`./files/data.json`, headers)
fetch(`./data.json`, headers)
.then(result => result.json())
.then(data => {
input.kompletr({
input: null, // Optional
kompletr({
input,
data,
options: {
animation: {
type: 'slideDown',
duration: 1000
},
theme: 'dark',
multiple: false,
fieldsToDisplay: [
'Name',
'CountryCode',
Expand All @@ -96,7 +96,17 @@
propToMapAsValue: 'Name',
startQueriyngFromChar: 2,
filterOn: 'prefix',
// cache: 50000
},
/*onKeyup: async function (value, done) {
console.log('cb.onKeyup ', value);
console.log('I\'m doing scrappy stuffs with the data!');
const result = await fetch(`http://localhost:3000/api?q=${value}`, headers);
const d = await result.json();
console.log('DATA', d)
// data = ['string', 'string', 'string'];
done(d);
},*/
onSelect: (selected) => {
console.log('cb.onSelect', selected);
},
Expand Down

0 comments on commit 63c641b

Please sign in to comment.