Skip to content

Commit

Permalink
Master release (#673)
Browse files Browse the repository at this point in the history
* update ky, fix ag to svelte example, RestDataApi will look for q and do stringify if its an object

* Fixed quick search

* Fixed search

* refactor select2 so uses same fomratter for displayFields

* comment out select tests since we dont support

* get tests working for jest and ts. revamp truthy and empty

* add jest to the checks

* remove the setup for now

* get jest tests working and move critical tests in, all tests are in __tests__

* Select fixes (#643)

* Fixed select with complex dataApiParams

* Lint fix

* esm to get mockserver working with imports

* reverted ts, to slow.

* fix and cleanup the listctrl dep (#644)

* fix and cleanup the listctrl dep

* should have a property that we pass to GRidCtrl for contextMenuClickAction

* pass everything through with the gridOpts

* fixed showSearchForm

* more clean up

* cleanup to get rid of extendFilters

* removed a bunch of console logs

* add init search to config

* Filtering refactoring

Co-authored-by: alexeyzvegintcev <alexey.zvegintcev@sysgears.com>

* Grid remove listctrl dep (#645)

* fix and cleanup the listctrl dep

* should have a property that we pass to GRidCtrl for contextMenuClickAction

* pass everything through with the gridOpts

* fixed showSearchForm

* more clean up

* cleanup to get rid of extendFilters

* removed a bunch of console logs

* add init search to config

* Filtering refactoring

* get sort squared away

* more lodash cleanup

* fix for es6

* rename to restrictSearch

* add start of the DataQuery class

Co-authored-by: alexeyzvegintcev <alexey.zvegintcev@sysgears.com>

* Grid remove listctrl dep (#646)

* fix and cleanup the listctrl dep

* should have a property that we pass to GRidCtrl for contextMenuClickAction

* pass everything through with the gridOpts

* fixed showSearchForm

* more clean up

* cleanup to get rid of extendFilters

* removed a bunch of console logs

* add init search to config

* Filtering refactoring

* get sort squared away

* more lodash cleanup

* fix for es6

* rename to restrictSearch

* add start of the DataQuery class

Co-authored-by: alexeyzvegintcev <alexey.zvegintcev@sysgears.com>

* fixed foo bar

* Grid fixes (#648)

* Fixed cors issue for grids

* Grid actions without listCtrl import

* Custom toolbar actions

* Fixed typo

Co-authored-by: alexeyzvegintcev <alexey.zvegintcev@sysgears.com>

* Datastore (#647)

* added mixer and batch of tests

* added getter

* added ky type

* get common stuff out on datastore

* rename

* removed grails from demo to cut down on noise

* fix session store

* working demos

* working grids, select2 is broken

* mostly working now

* renames

* simplify

* out of chaos comes order

* det names in order

* fix oageView sub, add unsun for destroy

* rm pwd

* lint fix

* added chip and fixed setting current item

* fix bad comma

* added chip css

* hack to fix sub on addJson

* add go to AppState and apiUrl

* redo api to standardize key instead of endpoint

* add some logging

* more logging

* remove pocs

* Restrict apply grids (#651)

* grids adde restrict search

* gridList restrictSearch

* Fixed grid toolbar (#652)

* TEmp quick fix (#653)

* Ds grid (#654)

* fix open on memdata, dont blow up if no config is found, fix tailwind warning

* Fixed editting grid (#655)

* fix bad squigly

* tests passing again

* remove bad case

* flush out forms and bad camel case on StoreHolder

* z-index on selects

* fix select2 ability to have special key

* fixes grid flash on insert 9ci/rcm-ui#102

* Edit modal errors 9ci/rcm#110 (#656)

* Edit modal errors 9ci/rcm#110

* see if this works

Co-authored-by: Joshua B <joshdev@9ci.com>

* Fixed typo for error handler (#657)

* change to html5 date inputs

* remove placeholder until we figure it out

* Swal fix (#658)

* Remove swal from grids

* Fixed typo

* Added ctx to gridz directive (#660)

* Fixed export to excel 9ci/rcm-ui#118 (#659)

* Svelte select (#661)

* Fix Date Formatting (#662)

* Added ability to change restrict search (#663)

* Added ability to specify qSearch and q for select (#664)

* Added ability to specify qSearch and q for select

* Added XXX

* change for more detailed format on selects

* Fixed gridId genaration (#666)

* yakit move (#667)

move to  @yakit/core, @yakit/ui, @yakit/svelte

* Added ability to set deafult sorting (#668)

* forms and crudQuery (#671)

* add tile comps and import text-editor from f7.

* Grid edit popover (#672)

* popover edit, formify from config with yup validation and examples.

* on submit

* edit example is working

* create new popup working but failing on save

* popover working for new

* moved create form into core

* fix tests

* fix where editSchema get setup

* add example for rest select in dynamic

* added showLink formatter and fixed for type=date on schema forms

* fixed sort reset and turned off multiSort by default

Co-authored-by: alexeyzvegintcev <alexey.zvegintcev@sysgears.com>
  • Loading branch information
basejump and alexeyzvegintcev authored Feb 3, 2022
1 parent fb4d019 commit 9042740
Show file tree
Hide file tree
Showing 418 changed files with 14,428 additions and 5,424 deletions.
8 changes: 8 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"useTabs": false,
"singleQuote": true,
"trailingComma": "none",
"printWidth": 120,
"tabWidth": 2,
"semi": false
}
3 changes: 1 addition & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
{
"git.ignoreLimitWarning": true
}
}
42 changes: 42 additions & 0 deletions babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
module.exports = function(api) {
api.cache(true);
const presets = [
["@babel/preset-env",{
// "useBuiltIns": "entry" ,
"useBuiltIns": "usage" ,
"corejs": 3,
"targets": { "node": "current" }
}]
];
const plugins = [
["angularjs-annotate"],
"lodash",
"babel-plugin-transform-async-to-promises",
"@babel/plugin-proposal-class-properties",
"@babel/plugin-proposal-optional-chaining",
"wildcard",
//aliases are not DRY, setup here for Jest, in jsconfig.json for vscode and webpack for svelte
["module-resolver", {
"root": ["./src"],
//make it work with both
"alias": [
{"@yakit/core": "./yakit/core"},
{"@yakit/ui": "./yakit/ui"},
{"@yakit/svelte": "./yakit/svelte"},
{"@ag": "./src"},
{"angle-grinder/src": "./src"},
//used for demo
{ "~": "./examples/demo/src"},
]
}],
[ // required for svelte-jsx and svelte-fragment-component
"@babel/plugin-transform-react-jsx",
{"runtime": "automatic", "importSource": "svelte-jsx"}
]
];

return {
presets,
plugins
};
}
31 changes: 0 additions & 31 deletions babel.config.json

This file was deleted.

9 changes: 7 additions & 2 deletions examples/demo/public/data/CustomerConfig.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ gridOptions:
toolbarOptions:
selectedButtons:
delete:
icon: fa-trash-alt
icon: delete
tooltip: Delete

editForm:
Expand Down Expand Up @@ -56,7 +56,12 @@ editForm:
label: ''
placeholder: Zip
className: column is-2
country: {}
country:
type: select
selectOptions:
multiple: false
useDataObject: false
data: [US, CA, MX ]
timezone: {}
nested.foo:
label: 'nested.foo'
Expand Down
25 changes: 15 additions & 10 deletions examples/demo/public/index.ejs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en" data-ng-app="app" ng-strict-di class="aurora device-desktop">
<html lang="en" data-ng-app="app" ng-strict-di class="device-desktop">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
Expand Down Expand Up @@ -36,14 +36,19 @@
<script src="<%= htmlWebpackPlugin.options.configPath %>"></script>
</head>
<body ng-controller="AppCtrl as $appCtrl" [ng-strict-di="boolean"]>
<div ui-view id="app" ng-class="{
'app-sidebar-fixed' : $appCtrl.layout.isSidebarFixed,
'app-sidenav-fixed' : $appCtrl.layout.isSidebarFixed,
'app-sidebar-open': appState.sidenav.open,
'app-sidebar-closed': !appState.sidenav.open,
'app-sidenav-open': appState.sidenav.open,
'app-sidenav-closed': !appState.sidenav.open
}"></div>

<div id="app" style="height: 100%;">
<!-- App root element -->
<div id="f7app" ng-class="{
'app-sidebar-fixed' : $appCtrl.layout.isSidebarFixed,
'app-sidenav-fixed' : $appCtrl.layout.isSidebarFixed,
'app-sidebar-open': appState.sidenav.open,
'app-sidebar-closed': !appState.sidenav.open,
'app-sidenav-open': appState.sidenav.open,
'app-sidenav-closed': !appState.sidenav.open
}">
<div ui-view class="view view-main">
</div>
</div>
</div>
</body>
</html>
2 changes: 1 addition & 1 deletion examples/demo/src/AppCtrl.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import appState from 'angle-grinder/src/tools/AppState'
import appState from '@yakit/ui/AppState'

/**
* Main Application Controller
Expand Down
9 changes: 7 additions & 2 deletions examples/demo/src/app.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,16 @@
import _ from 'lodash'
import appName from './app.module'
import './config.router'
import appState from 'angle-grinder/src/tools/AppState'
import { KyFactory } from "angle-grinder/src/stores/ky";
import appState from '@yakit/ui/AppState'
import apiHolder from '@yakit/core/stores/apiHolder'
import dataApiFactory from './store/dataApiFactory'
import { KyFactory } from "@yakit/core/stores/ky";

KyFactory.enableAuthHeader()
KyFactory.defaults.prefixUrl = configData.base_url

apiHolder.dataApiFactory = dataApiFactory

const app = angular.module(appName)
// export default app.name

Expand Down
6 changes: 6 additions & 0 deletions examples/demo/src/app.module.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ import snippetsModule from './utils/demo/demo.module'

// demo sections
import svelteModule from './svelte'
import svelteDataList from './svelteDataList'
import svelteSelects from './svelteSelects'
import formify from './formify'
import componentsModule from './components'
import formsModule from './controls'
import gridsModule from './grids'
Expand All @@ -35,6 +38,9 @@ export default angular.module('app', [
loginModule,
snippetsModule,
svelteModule,
svelteDataList,
svelteSelects,
formify,
componentsModule,
pagesModule,
formsModule,
Expand Down
2 changes: 1 addition & 1 deletion examples/demo/src/assets/_examples.scss
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ $example-border: $yellow;

.example-section {
//make room for the little call out
padding-top: 40px;
padding-top: 10px;
}
.example {
position: relative;
Expand Down
2 changes: 1 addition & 1 deletion examples/demo/src/components/avatars/component.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div class="card-content">
<h3 class="title is-thin is-6">Avatars</h3>
<p>Avatars are rounded images used for media and personal pages. Avatar sizes can
be controled with css classes. Available modifier classes are <code>is-small</code>,
be controled with css classes. Available modifier classes are <code>is-xs</code>, <code>is-small</code>,
<code>is-medium</code>, <code>is-large</code>, <code>is-big</code> and
<code>is-xl</code>. See code for more details about usage.
</p>
Expand Down
3 changes: 0 additions & 3 deletions examples/demo/src/components/avatars/component.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@ class controller {
avatarData = people

get randomAvatar(){
// randomAvatar(){
const idx = Math.floor((Math.random() * (9 - 0)) + 0)
// const idx = Math.random() * (0 - 9) + 0
console.log('random idx', idx)
// const avatar = people[idx].avatar
// return `/assets/images/photos/${avatar}`
return 'WTF'
Expand All @@ -34,7 +32,6 @@ export default angular.module('ag.demo.avatarDemo', [])
controller: controller
// controller: function() {
// this.randomAvatar = () => {
// console.log('wtf')
// return 'wtf'
// }
// }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import template from './component.html'
import toast from 'angle-grinder/src/tools/toast'
import toast from '@yakit/ui/growl'

class ClrController {
content = 'Click Me'
Expand All @@ -16,7 +16,6 @@ class ClrController {
}

toggleLoading = (event) => {
// console.log("toggleLoading this", this)
this.loading = !this.loading
this.$timeout(() => {
this.loading = !this.loading
Expand Down
2 changes: 1 addition & 1 deletion examples/demo/src/components/button/demo/component.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import template from './component.html'
import toast from 'angle-grinder/src/tools/toast'
import toast from '@yakit/ui/growl'

class controller {
content = 'Click Me'
Expand Down
3 changes: 1 addition & 2 deletions examples/demo/src/components/button/icons/component.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import template from './component.html'
import toast from 'angle-grinder/src/tools/toast'
import toast from '@yakit/ui/growl'

class ClrController {
content = 'Click Me'
Expand All @@ -16,7 +16,6 @@ class ClrController {
}

toggleLoading = (event) => {
// console.log("toggleLoading this", this)
this.loading = !this.loading
this.$timeout(() => {
this.loading = !this.loading
Expand Down
2 changes: 1 addition & 1 deletion examples/demo/src/components/contextMenu/component.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import template from './component.html'
import Swal from 'angle-grinder/src/tools/swal'
import Swal from '@yakit/ui/swal'

class controller {
player = {
Expand Down
3 changes: 1 addition & 2 deletions examples/demo/src/components/dropdown/component.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import template from './component.html'
import Swal from 'angle-grinder/src/tools/swal'
import Swal from '@yakit/ui/swal'

class controller {
menuItems = [
Expand All @@ -21,7 +21,6 @@ class controller {
]

menuItemClick = function(menuItem, event) {
// console.log('menuItemClick params', { menuItem, event })
Swal.fire(
`${menuItem.display} item clicked `,
`<pre><code class="json">${JSON.stringify(menuItem, null, 2)}</code></pre>`
Expand Down
3 changes: 0 additions & 3 deletions examples/demo/src/components/icons/letter/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,7 @@ export default angular.module('demo.list.comps', [])
template: require('./letterIcons.html')
})
.component('letterIconsList', {
// implicit controllerAs: '$ctrl',
template: function($element, $attrs) {
console.log('$element', $element)
console.log('$attrs.box', $attrs.box)
const alphabet = 'abcdefghijklmnopqrstuvwxyz'.split('')
let tpl = '<p>'
alphabet.forEach(letter => {
Expand Down
6 changes: 6 additions & 0 deletions examples/demo/src/components/routes.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
const componentsStates = {
name: 'ngComponents',
abstract: true,
template: `\
<div class="page">
<div class="page-content">
<div class="block"><div ui-view></div></div>
</div>
</div>`,
// template: '<div ui-view class="fade-in-up"></div>',
data: {
title: 'ng Components',
Expand Down
6 changes: 2 additions & 4 deletions examples/demo/src/components/sweetalert/component.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import template from './component.html'
import Swal from 'angle-grinder/src/tools/swal'
import toast from 'angle-grinder/src/tools/toast'
import Swal from '@yakit/ui/swal'
import toast from '@yakit/ui/growl'

class controller {

Expand All @@ -10,7 +10,6 @@ class controller {
}

buttonClick(event) {
// console.log('menuItemClick params', { menuItem, event })
Swal.fire(
'The Title',
'Some Text or <strong>html</strong>'
Expand Down Expand Up @@ -87,7 +86,6 @@ class controller {
confirmButtonText: 'Change Name',
showCancelButton: true
})
console.log('result', result)

toast.success(`your foo is now named ${result.value}`, 'Named Foo!')
}
Expand Down
4 changes: 2 additions & 2 deletions examples/demo/src/components/tabs/basic/component.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<div>

<uib-tabset type="is-boxed">
<uib-tab index="0" heading="Static title">
<h4>Static content</h4>
Expand Down Expand Up @@ -29,4 +29,4 @@ <h4>Static content</h4>
<a class="button" href="javascript:void(0)" ng-click="active = 2"> Go to tab 3 </a>
<a class="button" href="javascript:void(0)" ng-click="tabs[1].disabled = ! tabs[1].disabled"> Enable / Disable third tab </a>
</p>
</div>

2 changes: 1 addition & 1 deletion examples/demo/src/components/tabs/basic/component.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import template from './component.html'

import angular from 'angular'
import Swal from 'angle-grinder/src/tools/swal'
import Swal from '@yakit/ui/swal'

class controller {
vm = {
Expand Down
2 changes: 1 addition & 1 deletion examples/demo/src/components/tabs/complex/component.html
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ <h3 class="view-header">
</div>
</div>

<div>
<div class="bulma">
<uib-tabset class="tabbable" active="active">
<uib-tab index="0" heading="X editable">
<div class="columns">
Expand Down
3 changes: 1 addition & 2 deletions examples/demo/src/components/toolbar/comp/component.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import template from './component.html'
import Swal from 'angle-grinder/src/tools/swal'
import Swal from '@yakit/ui/swal'

class controller {
menuItems = [
Expand All @@ -20,7 +20,6 @@ class controller {
]

menuItemClick = function(menuItem, event) {
// console.log('menuItemClick params', { menuItem, event })
Swal.fire(
`${menuItem.display} item clicked `,
`<pre><code class="json">${JSON.stringify(menuItem, null, 2)}</code></pre>`
Expand Down
3 changes: 1 addition & 2 deletions examples/demo/src/config.router.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// import angular from 'angular'
import { packet, fresh, login } from './routerStates'
import appState from 'angle-grinder/src/tools/AppState'
import appState from '@yakit/ui/AppState'
import stateHelperInit from 'angle-grinder/src/ng/uirouter/stateHelperInit'
import _ from 'lodash'

Expand Down Expand Up @@ -32,7 +32,6 @@ angular.module('app')
// stateHelperProvider.state(packetCopy)
// appState.packetStates = packetCopy

// console.log("appState.routerStates", appState.routerStates)
// $stateProvider.state({
// name: 'fresh',
// url: '/fresh',
Expand Down
Loading

0 comments on commit 9042740

Please sign in to comment.