├── examples ├── i18n │ ├── store │ │ ├── index.js │ │ └── auth.js │ ├── static │ │ └── favicon.ico │ ├── assets │ │ └── sprite │ │ │ └── svg │ │ │ └── circle.svg │ ├── serverMiddleware │ │ └── index.js │ ├── .editorconfig │ ├── README.md │ ├── awes.config.js │ ├── package.json │ ├── plugins │ │ └── menu.js │ └── pages │ │ └── index.vue ├── admin │ ├── store │ │ └── index.js │ ├── static │ │ └── favicon.ico │ ├── pages │ │ ├── index.vue │ │ ├── admin │ │ │ └── roles │ │ │ │ ├── _id.vue │ │ │ │ └── _id │ │ │ │ └── permissions.vue │ │ └── fake-auth │ │ │ └── _service.vue │ ├── assets │ │ └── sprite │ │ │ └── svg │ │ │ ├── circle.svg │ │ │ ├── arrow-alt-right.svg │ │ │ ├── minus-circle.svg │ │ │ ├── plus-circle.svg │ │ │ ├── arrow-circle-right.svg │ │ │ ├── edit.svg │ │ │ ├── cloud-download.svg │ │ │ └── engine-warning.svg │ ├── api │ │ └── index.js │ ├── README.md │ └── package.json ├── dayjs │ ├── store │ │ └── index.js │ ├── static │ │ ├── favicon.ico │ │ └── README.md │ ├── prettier.config.js │ ├── .editorconfig │ ├── pages │ │ ├── README.md │ │ └── index.vue │ ├── README.md │ └── package.json ├── permissions │ ├── store │ │ └── index.js │ ├── static │ │ └── favicon.ico │ ├── package.json │ ├── README.md │ ├── pages │ │ └── admin.vue │ ├── serverMiddleware │ │ ├── users.js │ │ └── api.js │ ├── CHANGELOG.md │ ├── plugins │ │ └── menu.js │ └── nuxt.config.js ├── tabs-routing │ ├── store │ │ └── index.js │ ├── .prettierrc │ ├── pages │ │ └── index │ │ │ ├── index.vue │ │ │ ├── other.vue │ │ │ └── filtered.vue │ ├── .editorconfig │ ├── README.md │ ├── .eslintrc.js │ ├── package.json │ └── nuxt.config.js └── basic-ui │ ├── assets │ ├── js │ │ └── url.js │ ├── img │ │ └── avatar_placeholder.png │ └── sprite │ │ └── svg │ │ ├── circle.svg │ │ ├── arrow-alt-right.svg │ │ ├── minus-circle.svg │ │ ├── coffee.svg │ │ ├── star.svg │ │ ├── duotone │ │ ├── mobile.svg │ │ ├── user-crown.svg │ │ ├── concierge-bell.svg │ │ ├── align-justify.svg │ │ ├── images.svg │ │ ├── credit-card.svg │ │ ├── university.svg │ │ ├── clock.svg │ │ ├── browser.svg │ │ ├── palette.svg │ │ ├── check-circle.svg │ │ ├── user-friends.svg │ │ ├── list-alt.svg │ │ ├── chart-network.svg │ │ ├── gift.svg │ │ ├── map-marker-check.svg │ │ ├── question-square.svg │ │ ├── analytics.svg │ │ ├── clipboard-list-check.svg │ │ └── cog.svg │ │ ├── plus-circle.svg │ │ ├── wallet.svg │ │ ├── lock-alt.svg │ │ ├── arrow-circle-right.svg │ │ ├── money-bill.svg │ │ ├── university.svg │ │ ├── book.svg │ │ ├── plus-square.svg │ │ ├── credit-card.svg │ │ ├── arrow-from-right.svg │ │ ├── arrow-to-right.svg │ │ ├── trash-alt.svg │ │ ├── tags.svg │ │ ├── landmark-alt.svg │ │ ├── percentage.svg │ │ ├── smile-wink.svg │ │ ├── island-tropical.svg │ │ ├── edit.svg │ │ ├── cloud-download.svg │ │ ├── coins.svg │ │ ├── hands-helping.svg │ │ ├── shopping-cart.svg │ │ ├── piggy-bank.svg │ │ ├── receipt.svg │ │ ├── hand-paper.svg │ │ ├── money-bill-alt.svg │ │ ├── box-usd.svg │ │ ├── exchange.svg │ │ ├── tools.svg │ │ ├── sack-dollar.svg │ │ ├── sync-alt.svg │ │ ├── hand-holding-usd.svg │ │ ├── engine-warning.svg │ │ ├── cash-register.svg │ │ └── hotel.svg │ ├── store │ ├── index.js │ └── auth.js │ ├── static │ ├── favicon.ico │ └── img │ │ ├── icon.jpg │ │ ├── icon.png │ │ ├── white_logo.png │ │ └── awes-io-avatar.jpg │ ├── api │ ├── data │ │ └── translations.js │ ├── dev.js │ ├── routes │ │ ├── chart.js │ │ ├── records.js │ │ └── translations.js │ └── index.js │ ├── pages │ ├── index.vue │ ├── aw-calendar.vue │ ├── aw-markdown-editor.vue │ ├── aw-cropper.vue │ ├── aw-link.vue │ └── overview.vue │ ├── components │ ├── BuiIconCard.vue │ └── BuiColorCard.vue │ ├── plugins │ └── helper.js │ └── package.json ├── packages ├── ui │ ├── docs │ │ ├── index.md │ │ ├── aw-calendar-view.md │ │ ├── aw-dashboard-line.md │ │ ├── aw-code-snippet.md │ │ ├── aw-svg-image.md │ │ ├── aw-uploader-files.md │ │ ├── aw-table-head.md │ │ ├── aw-dashboard-speed.md │ │ ├── aw-calendar-nav.md │ │ ├── aw-dashboard-donut.md │ │ ├── aw-layout-default.md │ │ ├── aw-layout-frame-center.md │ │ ├── aw-table-row.md │ │ ├── aw-context-menu.md │ │ ├── aw-slider.md │ │ ├── aw-dropdown-button.md │ │ ├── aw-dashboard-section.md │ │ ├── aw-user-menu.md │ │ ├── aw-badge.md │ │ ├── aw-dashboard-progress.md │ │ ├── aw-toggler.md │ │ ├── aw-content-wrapper.md │ │ ├── aw-page.md │ │ ├── aw-dashboard-card.md │ │ └── aw-chip-select.md │ ├── package.js │ ├── tests │ │ ├── .eslintrc.js │ │ └── App.spec.js │ ├── assets │ │ ├── css │ │ │ ├── additional │ │ │ │ ├── _index.css │ │ │ │ ├── focus-outline.css │ │ │ │ └── comma.css │ │ │ ├── components │ │ │ │ ├── context-menu.css │ │ │ │ ├── icon.css │ │ │ │ ├── form.css │ │ │ │ ├── toggler.css │ │ │ │ ├── bottom-bar.css │ │ │ │ ├── header-notification.css │ │ │ │ ├── animation.css │ │ │ │ ├── usermenu.css │ │ │ │ ├── filter-month.css │ │ │ │ ├── select.css │ │ │ │ ├── cropper.css │ │ │ │ ├── mobile-menu-item.css │ │ │ │ ├── dropdown.css │ │ │ │ ├── table-head.css │ │ │ │ ├── tags.css │ │ │ │ ├── date.css │ │ │ │ ├── page-headline.css │ │ │ │ ├── page-buttons.css │ │ │ │ └── user-menu.css │ │ │ └── main.css │ │ ├── js │ │ │ ├── unmask-param.js │ │ │ ├── css.js │ │ │ ├── object.js │ │ │ ├── constants.js │ │ │ └── string.js │ │ └── img │ │ │ ├── powered_by_google_on_none.png │ │ │ └── powered_by_google_on_white.png │ ├── nuxt │ │ ├── templates │ │ │ ├── directives.plugin.js │ │ │ ├── store.plugin.js │ │ │ ├── core.plugin.js │ │ │ └── screen.plugin.js │ │ ├── layouts │ │ │ ├── empty.vue │ │ │ ├── default.vue │ │ │ └── center.vue │ │ └── awes.config.js │ ├── .eslintignore │ ├── components │ │ ├── 2_molecules │ │ │ └── AwButtonNav.vue │ │ ├── 5_layouts │ │ │ ├── _AwNavItem.vue │ │ │ └── AwLayoutScreen.vue │ │ ├── 3_organisms │ │ │ ├── AwTable │ │ │ │ └── _AwTableRowHidden.vue │ │ │ └── AwCalendar │ │ │ │ ├── _AwCalendarDay.vue │ │ │ │ ├── _AwCalendarWeekdays.vue │ │ │ │ └── AwCalendarView.vue │ │ ├── 1_atoms │ │ │ ├── AwIcon │ │ │ │ ├── AwIconSystemColor.vue │ │ │ │ └── AwIcon.vue │ │ │ └── AwAccordionFold.vue │ │ └── 4_pages │ │ │ └── _AwPageButtons.vue │ ├── .gitignore │ ├── build │ │ └── icons │ │ │ └── icon-tpl.hbs │ ├── .eslintrc.js │ └── mixins │ │ ├── arrow-focus.js │ │ └── watch-params.js ├── dayjs │ ├── package.js │ ├── src │ │ ├── utils │ │ │ ├── string-format.js │ │ │ └── options.js │ │ └── index.js │ └── package.json ├── nuxt-auth │ ├── .browserslistrc │ ├── package.js │ ├── tests │ │ ├── .eslintrc.js │ │ └── nuxt-auth.spec.js │ ├── prettier.config.js │ ├── .editorconfig │ ├── .gitignore │ ├── babel.config.js │ ├── src │ │ ├── pages │ │ │ ├── Logout.vue │ │ │ ├── VerifyEmail.vue │ │ │ └── LoginOAuth.vue │ │ └── assets │ │ │ └── js │ │ │ ├── merge-routes.js │ │ │ └── strategy.js │ ├── README.md │ ├── docs │ │ └── index.md │ ├── .gitlab-ci.yml │ ├── .eslintrc.js │ ├── jest.config.js │ ├── lang │ │ ├── en.js │ │ ├── ru.js │ │ ├── uk.js │ │ └── de.js │ └── commitlint.config.js ├── vue-mc │ ├── package.js │ ├── src │ │ ├── index.js │ │ └── Structures │ │ │ ├── Collection.js │ │ │ ├── Response.js │ │ │ ├── Request.js │ │ │ └── Model.js │ ├── .editorconfig │ ├── .babelrc │ ├── rollup.config.js │ ├── .gitignore │ ├── README.md │ └── package.json ├── nuxt-admin │ ├── package.js │ ├── src │ │ ├── mixins │ │ │ ├── redirectToRoles.js │ │ │ └── redirectToUsers.js │ │ ├── collections │ │ │ ├── Permission.js │ │ │ ├── Roles.js │ │ │ ├── Users.js │ │ │ ├── Permissions.js │ │ │ └── Role.js │ │ ├── utils │ │ │ └── merge-routes.js │ │ └── pages │ │ │ └── User.vue │ └── commitlint.config.js ├── nuxt-i18n │ ├── package.js │ ├── src │ │ └── template │ │ │ └── header.js │ └── package.json ├── nuxt-profile │ ├── .browserslistrc │ ├── package.js │ ├── docs │ │ └── index.md │ ├── tests │ │ ├── .eslintrc.js │ │ └── nuxt-profile.spec.js │ ├── src │ │ └── assets │ │ │ ├── css │ │ │ ├── components │ │ │ │ └── nuxt-profile.css │ │ │ └── main.css │ │ │ └── img │ │ │ ├── apple.png │ │ │ ├── avatar.jpg │ │ │ └── google.png │ ├── prettier.config.js │ ├── .editorconfig │ ├── .gitignore │ ├── babel.config.js │ ├── README.md │ ├── .gitlab-ci.yml │ ├── .eslintrc.js │ ├── jest.config.js │ ├── commitlint.config.js │ └── lang │ │ ├── en.js │ │ ├── ru.js │ │ ├── uk.js │ │ └── de.js ├── nuxt-laravel │ ├── package.js │ ├── plugins │ │ └── version.js │ └── package.json └── nuxt-localization │ ├── package.js │ ├── src │ ├── components │ │ └── AwTranslationDownload.vue │ ├── pages │ │ ├── LocalizationExport.vue │ │ └── Localization.vue │ └── utils │ │ └── options.js │ └── package.json ├── .npmrc ├── .yarnrc ├── .browserslistrc ├── prettier.config.js ├── .eslintignore ├── .editorconfig ├── .eslintrc.js ├── lerna.json ├── .gitlab-ci.yml ├── commitlint.config.js └── .gitignore /examples/i18n/store/index.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/admin/store/index.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/dayjs/store/index.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/permissions/store/index.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/tabs-routing/store/index.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/docs/index.md: -------------------------------------------------------------------------------- 1 | # UI Component -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | registry=https://registry.npmjs.org 2 | -------------------------------------------------------------------------------- /.yarnrc: -------------------------------------------------------------------------------- 1 | registry "https://registry.npmjs.org" 2 | -------------------------------------------------------------------------------- /.browserslistrc: -------------------------------------------------------------------------------- 1 | > 1% 2 | last 2 versions 3 | ie 11 4 | -------------------------------------------------------------------------------- /packages/dayjs/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-auth/.browserslistrc: -------------------------------------------------------------------------------- 1 | > 1% 2 | last 2 versions 3 | ie 11 4 | -------------------------------------------------------------------------------- /packages/ui/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/vue-mc/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-admin/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-auth/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-i18n/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-profile/.browserslistrc: -------------------------------------------------------------------------------- 1 | > 1% 2 | last 2 versions 3 | ie 11 4 | -------------------------------------------------------------------------------- /packages/nuxt-laravel/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-profile/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-localization/package.js: -------------------------------------------------------------------------------- 1 | export default { 2 | build: true 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-profile/docs/index.md: -------------------------------------------------------------------------------- 1 | # NuxtProfile 2 | 3 | Initial documentation file... -------------------------------------------------------------------------------- /packages/ui/tests/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | env: { 3 | jest: true 4 | } 5 | } -------------------------------------------------------------------------------- /packages/nuxt-auth/tests/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | env: { 3 | jest: true 4 | } 5 | } -------------------------------------------------------------------------------- /packages/nuxt-profile/tests/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | env: { 3 | jest: true 4 | } 5 | } -------------------------------------------------------------------------------- /packages/ui/assets/css/additional/_index.css: -------------------------------------------------------------------------------- 1 | @import './comma.css'; 2 | @import './focus-outline.css'; 3 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/js/url.js: -------------------------------------------------------------------------------- 1 | export const urlify = (str = '') => str.toLowerCase().replace(/\s/g, '_') 2 | -------------------------------------------------------------------------------- /examples/basic-ui/store/index.js: -------------------------------------------------------------------------------- 1 | export const state = () => ({ 2 | logo: '/img/white_logo.png' 3 | }) 4 | -------------------------------------------------------------------------------- /examples/admin/static/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/admin/static/favicon.ico -------------------------------------------------------------------------------- /examples/dayjs/static/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/dayjs/static/favicon.ico -------------------------------------------------------------------------------- /examples/i18n/static/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/i18n/static/favicon.ico -------------------------------------------------------------------------------- /examples/basic-ui/static/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/basic-ui/static/favicon.ico -------------------------------------------------------------------------------- /examples/basic-ui/static/img/icon.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/basic-ui/static/img/icon.jpg -------------------------------------------------------------------------------- /examples/basic-ui/static/img/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/basic-ui/static/img/icon.png -------------------------------------------------------------------------------- /packages/nuxt-profile/src/assets/css/components/nuxt-profile.css: -------------------------------------------------------------------------------- 1 | .the-example { 2 | @apply p-8 bg-primary-100; 3 | } 4 | -------------------------------------------------------------------------------- /packages/nuxt-profile/src/assets/css/main.css: -------------------------------------------------------------------------------- 1 | @import './variables.css'; 2 | 3 | @import './components/nuxt-profile.css'; 4 | -------------------------------------------------------------------------------- /examples/dayjs/prettier.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | tabWidth: 4, 3 | semi: false, 4 | singleQuote: true 5 | } 6 | -------------------------------------------------------------------------------- /examples/permissions/static/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/permissions/static/favicon.ico -------------------------------------------------------------------------------- /examples/tabs-routing/.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "semi": false, 3 | "arrowParens": "always", 4 | "singleQuote": true 5 | } 6 | -------------------------------------------------------------------------------- /packages/nuxt-auth/prettier.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | tabWidth: 4, 3 | semi: false, 4 | singleQuote: true 5 | } -------------------------------------------------------------------------------- /packages/nuxt-profile/prettier.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | tabWidth: 4, 3 | semi: false, 4 | singleQuote: true 5 | } -------------------------------------------------------------------------------- /examples/basic-ui/static/img/white_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/basic-ui/static/img/white_logo.png -------------------------------------------------------------------------------- /packages/ui/assets/js/unmask-param.js: -------------------------------------------------------------------------------- 1 | export default (str, value, mask = '%s') => { 2 | return str.split(mask).join(value) 3 | } 4 | -------------------------------------------------------------------------------- /examples/basic-ui/static/img/awes-io-avatar.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/basic-ui/static/img/awes-io-avatar.jpg -------------------------------------------------------------------------------- /packages/nuxt-profile/src/assets/img/apple.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/packages/nuxt-profile/src/assets/img/apple.png -------------------------------------------------------------------------------- /packages/nuxt-profile/src/assets/img/avatar.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/packages/nuxt-profile/src/assets/img/avatar.jpg -------------------------------------------------------------------------------- /packages/nuxt-profile/src/assets/img/google.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/packages/nuxt-profile/src/assets/img/google.png -------------------------------------------------------------------------------- /examples/basic-ui/assets/img/avatar_placeholder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/examples/basic-ui/assets/img/avatar_placeholder.png -------------------------------------------------------------------------------- /packages/ui/assets/img/powered_by_google_on_none.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/packages/ui/assets/img/powered_by_google_on_none.png -------------------------------------------------------------------------------- /packages/ui/assets/img/powered_by_google_on_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/awes-io/client/master/packages/ui/assets/img/powered_by_google_on_white.png -------------------------------------------------------------------------------- /examples/admin/pages/index.vue: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /packages/vue-mc/src/index.js: -------------------------------------------------------------------------------- 1 | export { default as BaseCollection } from './Structures/Collection' 2 | 3 | export { default as BaseModel } from './Structures/Model' 4 | -------------------------------------------------------------------------------- /packages/ui/nuxt/templates/directives.plugin.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import tooltip from '@awes-io/ui/directives/tooltip' 3 | 4 | Vue.directive('tooltip', tooltip) 5 | -------------------------------------------------------------------------------- /prettier.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | tabWidth: 4, 3 | semi: false, 4 | singleQuote: true, 5 | trailingComma: 'none', 6 | arrowParens: 'always' 7 | } 8 | -------------------------------------------------------------------------------- /packages/ui/.eslintignore: -------------------------------------------------------------------------------- 1 | # Common 2 | node_modules 3 | dist 4 | .nuxt 5 | coverage 6 | 7 | # Template modules 8 | nuxt/layouts/LayoutFrameCenter.vue 9 | nuxt/plugin.js 10 | -------------------------------------------------------------------------------- /packages/ui/nuxt/layouts/empty.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 10 | -------------------------------------------------------------------------------- /examples/tabs-routing/pages/index/index.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 10 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/context-menu.css: -------------------------------------------------------------------------------- 1 | .aw-context-menu { 2 | &__list { 3 | list-style: none; 4 | margin: 0; 5 | padding: 0; 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /examples/admin/assets/sprite/svg/circle.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/i18n/assets/sprite/svg/circle.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/tabs-routing/pages/index/other.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 10 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/circle.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/api/data/translations.js: -------------------------------------------------------------------------------- 1 | const en = { 2 | test: 'Test' 3 | } 4 | 5 | const ru = { 6 | test: 'Тест' 7 | } 8 | 9 | module.exports = { 10 | en, 11 | ru 12 | } 13 | -------------------------------------------------------------------------------- /packages/nuxt-laravel/plugins/version.js: -------------------------------------------------------------------------------- 1 | export default function() { 2 | console.log( 3 | '[<%=options.name%>] Build Version: <%=options.version%>(<%=options.versionDate%>)' 4 | ) 5 | } 6 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | # Common 2 | node_modules 3 | dist 4 | .nuxt 5 | coverage 6 | 7 | 8 | # TODO 9 | packages/ui/nuxt/layouts/LayoutFrameCenter.vue 10 | packages/ui/nuxt/plugin.js 11 | packages/vue-mc/dist/* 12 | -------------------------------------------------------------------------------- /examples/tabs-routing/pages/index/filtered.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 10 | -------------------------------------------------------------------------------- /examples/admin/pages/admin/roles/_id.vue: -------------------------------------------------------------------------------- 1 | 8 | -------------------------------------------------------------------------------- /examples/admin/api/index.js: -------------------------------------------------------------------------------- 1 | import express from 'express' 2 | import auth from './auth' 3 | 4 | const app = express() 5 | 6 | app.use(auth) 7 | 8 | export default { 9 | handler: app, 10 | path: '/api' 11 | } 12 | -------------------------------------------------------------------------------- /examples/admin/pages/admin/roles/_id/permissions.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 12 | -------------------------------------------------------------------------------- /packages/ui/nuxt/layouts/default.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 12 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-calendar-view.md: -------------------------------------------------------------------------------- 1 | # [name] 2 | 3 | ## Events 4 | 5 | 6 | |Event Name|Description|Parameters| 7 | |---|---|---| 8 | |click:date|-|-| 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /examples/basic-ui/pages/index.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 14 | -------------------------------------------------------------------------------- /examples/i18n/store/auth.js: -------------------------------------------------------------------------------- 1 | export const state = () => ({ 2 | // mock authorized user 3 | user: { 4 | name: 'User Name', 5 | info: 'Standart until 10 November
5 users $500 per month', 6 | avatar: '/favicon.ico' 7 | } 8 | }) 9 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/icon.css: -------------------------------------------------------------------------------- 1 | /* Same size as AwButton */ 2 | .aw-icon { 3 | color: inherit; 4 | fill: currentColor; 5 | vertical-align: middle; 6 | 7 | &--size-text { 8 | width: 1em; 9 | height: 1em; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /packages/ui/nuxt/layouts/center.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 12 | -------------------------------------------------------------------------------- /packages/nuxt-auth/.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | indent_style = space 5 | indent_size = 4 6 | end_of_line = lf 7 | charset = utf-8 8 | trim_trailing_whitespace = true 9 | insert_final_newline = true 10 | 11 | [*.md] 12 | trim_trailing_whitespace = false 13 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | root = true 3 | 4 | [*] 5 | indent_size = 4 6 | indent_style = space 7 | end_of_line = lf 8 | charset = utf-8 9 | trim_trailing_whitespace = true 10 | insert_final_newline = true 11 | 12 | [*.md] 13 | trim_trailing_whitespace = false 14 | -------------------------------------------------------------------------------- /packages/nuxt-profile/.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | indent_style = space 5 | indent_size = 4 6 | end_of_line = lf 7 | charset = utf-8 8 | trim_trailing_whitespace = true 9 | insert_final_newline = true 10 | 11 | [*.md] 12 | trim_trailing_whitespace = false 13 | -------------------------------------------------------------------------------- /examples/admin/assets/sprite/svg/arrow-alt-right.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/arrow-alt-right.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/i18n/serverMiddleware/index.js: -------------------------------------------------------------------------------- 1 | import express from 'express' 2 | import translations from './routes/translations' 3 | 4 | const app = express() 5 | 6 | app.use('/translations', translations) 7 | 8 | export default { 9 | path: '/api', 10 | handler: app 11 | } 12 | -------------------------------------------------------------------------------- /examples/admin/assets/sprite/svg/minus-circle.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/api/dev.js: -------------------------------------------------------------------------------- 1 | const express = require('express') 2 | const { path, handler } = require('./index') 3 | 4 | const app = express() 5 | 6 | // Parse JSON bodies (as sent by API clients) 7 | app.use(express.json()) 8 | 9 | app.use(path, handler) 10 | 11 | app.listen(3030) 12 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/minus-circle.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/dayjs/.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | root = true 3 | 4 | [*] 5 | indent_style = space 6 | indent_size = 4 7 | end_of_line = lf 8 | charset = utf-8 9 | trim_trailing_whitespace = true 10 | insert_final_newline = true 11 | 12 | [*.md] 13 | trim_trailing_whitespace = false 14 | -------------------------------------------------------------------------------- /examples/i18n/.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | root = true 3 | 4 | [*] 5 | indent_style = space 6 | indent_size = 4 7 | end_of_line = lf 8 | charset = utf-8 9 | trim_trailing_whitespace = true 10 | insert_final_newline = true 11 | 12 | [*.md] 13 | trim_trailing_whitespace = false 14 | -------------------------------------------------------------------------------- /packages/nuxt-auth/.gitignore: -------------------------------------------------------------------------------- 1 | ##IDEs 2 | /.idea 3 | /.vscode 4 | .phpstorm.meta.php 5 | _ide_helper.php 6 | _ide_helper_models.php 7 | 8 | ## package managers 9 | /node_modules 10 | *.log 11 | npm-debug.log* 12 | yarn-debug.log* 13 | yarn-error.log* 14 | package-lock.json 15 | yarn.lock 16 | -------------------------------------------------------------------------------- /packages/vue-mc/.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | root = true 3 | 4 | [*] 5 | indent_style = space 6 | indent_size = 4 7 | end_of_line = lf 8 | charset = utf-8 9 | trim_trailing_whitespace = true 10 | insert_final_newline = true 11 | 12 | [*.md] 13 | trim_trailing_whitespace = false 14 | -------------------------------------------------------------------------------- /examples/tabs-routing/.editorconfig: -------------------------------------------------------------------------------- 1 | # editorconfig.org 2 | root = true 3 | 4 | [*] 5 | indent_style = space 6 | indent_size = 4 7 | end_of_line = lf 8 | charset = utf-8 9 | trim_trailing_whitespace = true 10 | insert_final_newline = true 11 | 12 | [*.md] 13 | trim_trailing_whitespace = false 14 | -------------------------------------------------------------------------------- /packages/nuxt-profile/.gitignore: -------------------------------------------------------------------------------- 1 | ##IDEs 2 | /.idea 3 | /.vscode 4 | .phpstorm.meta.php 5 | _ide_helper.php 6 | _ide_helper_models.php 7 | 8 | ## package managers 9 | /node_modules 10 | *.log 11 | npm-debug.log* 12 | yarn-debug.log* 13 | yarn-error.log* 14 | package-lock.json 15 | yarn.lock 16 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/form.css: -------------------------------------------------------------------------------- 1 | .aw-form { 2 | /* loading state */ 3 | &.is-loading { 4 | .aw-text-field, 5 | .aw-switch-field { 6 | opacity: .5; 7 | pointer-events: none; 8 | user-select: none; 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/mixins/redirectToRoles.js: -------------------------------------------------------------------------------- 1 | export default { 2 | methods: { 3 | redirectToRoles() { 4 | this.$router.push( 5 | this.localePath({ 6 | path: `/admin/roles` 7 | }) 8 | ) 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/mixins/redirectToUsers.js: -------------------------------------------------------------------------------- 1 | export default { 2 | methods: { 3 | redirectToUsers() { 4 | this.$router.push( 5 | this.localePath({ 6 | path: `/admin/users` 7 | }) 8 | ) 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/collections/Permission.js: -------------------------------------------------------------------------------- 1 | import { BaseModel } from '@awes-io/vue-mc' 2 | 3 | export default class Permission extends BaseModel { 4 | defaults() { 5 | return { 6 | id: null, 7 | name: null, 8 | description: null, 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /packages/vue-mc/src/Structures/Collection.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import { Collection } from 'vue-mc' 3 | import Request from './Request' 4 | 5 | export default class BaseCollection extends Collection { 6 | createRequest(config) { 7 | return new Request(config, Vue.prototype.$nuxt.$axios) 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /examples/basic-ui/api/routes/chart.js: -------------------------------------------------------------------------------- 1 | const { Router } = require('express') 2 | const chartData = require('../data/chart') 3 | 4 | const router = Router() 5 | 6 | router.post('/chart', function(req, res) { 7 | setTimeout(() => { 8 | res.json(chartData) 9 | }, 800) 10 | }) 11 | 12 | module.exports = router 13 | -------------------------------------------------------------------------------- /examples/dayjs/pages/README.md: -------------------------------------------------------------------------------- 1 | # PAGES 2 | 3 | This directory contains your Application Views and Routes. 4 | The framework reads all the `*.vue` files inside this directory and creates the router of your application. 5 | 6 | More information about the usage of this directory in [the documentation](https://nuxtjs.org/guide/routing). 7 | -------------------------------------------------------------------------------- /packages/ui/components/2_molecules/AwButtonNav.vue: -------------------------------------------------------------------------------- 1 | 15 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/coffee.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-localization/src/components/AwTranslationDownload.vue: -------------------------------------------------------------------------------- 1 | 9 | 10 | 15 | -------------------------------------------------------------------------------- /packages/nuxt-localization/src/pages/LocalizationExport.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 17 | -------------------------------------------------------------------------------- /packages/ui/assets/css/additional/focus-outline.css: -------------------------------------------------------------------------------- 1 | @layer utilities { 2 | .focus-outline:focus { 3 | outline: none; 4 | } 5 | 6 | .focus-outline > [tabindex="-1"]:focus { 7 | outline: none; 8 | } 9 | 10 | .focus-outline:focus > [tabindex="-1"] { 11 | outline: theme('focusOutline'); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /packages/ui/.gitignore: -------------------------------------------------------------------------------- 1 | ##IDEs 2 | /.idea 3 | /.vscode 4 | .phpstorm.meta.php 5 | _ide_helper.php 6 | _ide_helper_models.php 7 | 8 | ## package managers 9 | node_modules 10 | *.log 11 | npm-debug.log* 12 | yarn-debug.log* 13 | yarn-error.log* 14 | package-lock.json 15 | 16 | ## reports 17 | /stats.html 18 | 19 | ## temp 20 | dist 21 | nuxt/icons.css 22 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/collections/Roles.js: -------------------------------------------------------------------------------- 1 | import { BaseCollection } from '@awes-io/vue-mc' 2 | import Role from './Role' 3 | 4 | export default class Roles extends BaseCollection { 5 | model() { 6 | return Role 7 | } 8 | 9 | routes() { 10 | return { 11 | fetch: '/api/admin/roles' 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/collections/Users.js: -------------------------------------------------------------------------------- 1 | import { BaseCollection } from '@awes-io/vue-mc' 2 | import User from './User' 3 | 4 | export default class Users extends BaseCollection { 5 | model() { 6 | return User 7 | } 8 | 9 | routes() { 10 | return { 11 | fetch: '/api/admin/users' 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /packages/nuxt-auth/tests/nuxt-auth.spec.js: -------------------------------------------------------------------------------- 1 | import { shallowMount } from '@vue/test-utils' 2 | import Login from '../src/pages/Login.vue' 3 | 4 | describe('Login page', () => { 5 | it('renders props.message when passed', () => { 6 | const wrapper = shallowMount(Login) 7 | 8 | expect(wrapper.isVueInstance()).toBe(true) 9 | }) 10 | }) 11 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/star.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/vue-mc/.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": [ 3 | [ 4 | "@babel/env", 5 | { 6 | "targets": { 7 | "ie": 11 8 | }, 9 | "useBuiltIns": false, 10 | "modules": false 11 | } 12 | ] 13 | ], 14 | "exclude": "node_modules/**" 15 | } 16 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/mobile.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-profile/tests/nuxt-profile.spec.js: -------------------------------------------------------------------------------- 1 | import { shallowMount } from '@vue/test-utils' 2 | import Profile from '../src/pages/Profile.vue' 3 | 4 | describe('NuxtProfile.vue', () => { 5 | it('renders props.message when passed', () => { 6 | const wrapper = shallowMount(Profile) 7 | 8 | expect(wrapper.isVueInstance()).toBe(true) 9 | }) 10 | }) 11 | -------------------------------------------------------------------------------- /examples/basic-ui/api/routes/records.js: -------------------------------------------------------------------------------- 1 | const express = require('express') 2 | const recordsData = require('../data/records.json') 3 | 4 | const records = express.Router() 5 | 6 | records.get('/', function(req, res) { 7 | setTimeout(() => { 8 | res.json({ 9 | data: recordsData 10 | }) 11 | }, 250) 12 | }) 13 | 14 | module.exports = records 15 | -------------------------------------------------------------------------------- /examples/admin/assets/sprite/svg/plus-circle.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/plus-circle.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/wallet.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/store/auth.js: -------------------------------------------------------------------------------- 1 | export const state = () => ({ 2 | // mock authorized user 3 | user: { 4 | name: 'John Doe', 5 | info: 'Business Owner', 6 | avatar: 'https://static.awes.io/noava.svg', 7 | profile: { 8 | first_name: 'John', 9 | last_name: 'Doe', 10 | position: 'Business Owner' 11 | } 12 | } 13 | }) 14 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/toggler.css: -------------------------------------------------------------------------------- 1 | .aw-toggler__content::before { 2 | content: ''; 3 | @apply absolute w-0 h-0 top-0 border-mono-800; 4 | left: theme('spacing.3'); 5 | border-left: theme('spacing.3') solid transparent; 6 | border-right: theme('spacing.3') solid transparent; 7 | border-bottom-width: theme('spacing.3'); 8 | transform: translateY(-0.75rem); 9 | } 10 | -------------------------------------------------------------------------------- /packages/vue-mc/src/Structures/Response.js: -------------------------------------------------------------------------------- 1 | import { Response as VueMCResponse } from 'vue-mc' 2 | import { pathOr } from 'rambdax' 3 | 4 | export default class Response extends VueMCResponse { 5 | getData() { 6 | return pathOr(null, 'data.data', this.response) 7 | } 8 | 9 | getValidationErrors() { 10 | return pathOr(null, 'data.errors', this.response) 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/lock-alt.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/permissions/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "permissions-example", 3 | "version": "1.1.1", 4 | "description": "Example of casl-vue integration", 5 | "author": "ILLJAH42", 6 | "private": true, 7 | "scripts": { 8 | "dev": "nuxt", 9 | "build": "nuxt build", 10 | "start": "nuxt start", 11 | "generate": "nuxt generate" 12 | }, 13 | "dependencies": { 14 | "nuxt": "^2.0.0" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /examples/admin/assets/sprite/svg/arrow-circle-right.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/components/BuiIconCard.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 18 | -------------------------------------------------------------------------------- /packages/nuxt-auth/babel.config.js: -------------------------------------------------------------------------------- 1 | const isModern = process.env.BROWSERS_ENV === 'modern' 2 | 3 | module.exports = { 4 | presets: [ 5 | [ 6 | '@babel/preset-env', 7 | { 8 | useBuiltIns: 'usage', 9 | corejs: '2', 10 | targets: isModern ? { esmodules: true } : undefined 11 | // debug: true 12 | } 13 | ] 14 | ] 15 | } 16 | -------------------------------------------------------------------------------- /packages/nuxt-profile/babel.config.js: -------------------------------------------------------------------------------- 1 | const isModern = process.env.BROWSERS_ENV === 'modern' 2 | 3 | module.exports = { 4 | presets: [ 5 | [ 6 | '@babel/preset-env', 7 | { 8 | useBuiltIns: 'usage', 9 | corejs: '2', 10 | targets: isModern ? { esmodules: true } : undefined 11 | // debug: true 12 | } 13 | ] 14 | ] 15 | } 16 | -------------------------------------------------------------------------------- /examples/basic-ui/api/routes/translations.js: -------------------------------------------------------------------------------- 1 | const express = require('express') 2 | const lang = require('../data/translations.js') 3 | 4 | const translations = express.Router() 5 | 6 | translations.get('/', (req, res) => { 7 | const locale = req.query.lang || 'en' 8 | const translations = lang[locale] || lang['en'] 9 | 10 | res.json({ 11 | data: translations 12 | }) 13 | }) 14 | 15 | module.exports = translations 16 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/arrow-circle-right.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/collections/Permissions.js: -------------------------------------------------------------------------------- 1 | import { BaseCollection } from '@awes-io/vue-mc' 2 | import Permission from './Permission' 3 | 4 | export default class Permissions extends BaseCollection { 5 | model() { 6 | return Permission 7 | } 8 | 9 | routes() { 10 | return { 11 | fetch: '/api/admin/permissions', 12 | save: '/api/admin/roles/{id}/permissions' 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /packages/ui/components/5_layouts/_AwNavItem.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 17 | -------------------------------------------------------------------------------- /packages/nuxt-auth/src/pages/Logout.vue: -------------------------------------------------------------------------------- 1 | 20 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/money-bill.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/user-crown.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/dayjs/README.md: -------------------------------------------------------------------------------- 1 | # dayjs 2 | 3 | > Example project with dayjs module 4 | 5 | ## Build Setup 6 | 7 | ``` bash 8 | # install dependencies 9 | $ yarn install 10 | 11 | # serve with hot reload at localhost:3000 12 | $ yarn dev 13 | 14 | # build for production and launch server 15 | $ yarn build 16 | $ yarn start 17 | 18 | # generate static project 19 | $ yarn generate 20 | ``` 21 | 22 | For detailed explanation on how things work, check out [Nuxt.js docs](https://nuxtjs.org). 23 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-dashboard-line.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: DashboardLine сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwDashboardLine /> component is used to render DashboardLine - UI Vue component for Awes.io. 6 | title: DashboardLine 7 | --- 8 | 9 | # AwDashboardLine 10 | 11 | ## MixIns 12 | 13 | 14 | |MixIn| 15 | |---| 16 | |dashboardMixin| 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /packages/ui/nuxt/templates/store.plugin.js: -------------------------------------------------------------------------------- 1 | import storeModule from '@awes-io/ui/store/awesIo.js' 2 | 3 | export default ({ store, app }) => { 4 | /** 5 | * Register store module 6 | */ 7 | if (!store.hasModule('awesIo')) { 8 | store.registerModule('awesIo', storeModule) 9 | } 10 | 11 | /** 12 | * Sync router with store 13 | */ 14 | app.router.afterEach((...transition) => 15 | store.commit('awesIo/SET_ROUTE', transition) 16 | ) 17 | } 18 | -------------------------------------------------------------------------------- /examples/admin/README.md: -------------------------------------------------------------------------------- 1 | # example-admin 2 | 3 | > @awes-io/admin installation example 4 | 5 | ## Build Setup 6 | 7 | ``` bash 8 | # install dependencies 9 | $ yarn install 10 | 11 | # serve with hot reload at localhost:3000 12 | $ yarn dev 13 | 14 | # build for production and launch server 15 | $ yarn build 16 | $ yarn start 17 | 18 | # generate static project 19 | $ yarn generate 20 | ``` 21 | 22 | For detailed explanation on how things work, check out [Nuxt.js docs](https://nuxtjs.org). 23 | -------------------------------------------------------------------------------- /examples/i18n/README.md: -------------------------------------------------------------------------------- 1 | # example-nuxt-i18n 2 | 3 | > Example of @awes-io/nuxt-i18n usage 4 | 5 | ## Build Setup 6 | 7 | ``` bash 8 | # install dependencies 9 | $ yarn install 10 | 11 | # serve with hot reload at localhost:3000 12 | $ yarn dev 13 | 14 | # build for production and launch server 15 | $ yarn build 16 | $ yarn start 17 | 18 | # generate static project 19 | $ yarn generate 20 | ``` 21 | 22 | For detailed explanation on how things work, check out [Nuxt.js docs](https://nuxtjs.org). 23 | -------------------------------------------------------------------------------- /examples/tabs-routing/README.md: -------------------------------------------------------------------------------- 1 | # tabs-routing 2 | 3 | > Awes.io AwTabNav routing example 4 | 5 | ## Build Setup 6 | 7 | ``` bash 8 | # install dependencies 9 | $ yarn install 10 | 11 | # serve with hot reload at localhost:3000 12 | $ yarn dev 13 | 14 | # build for production and launch server 15 | $ yarn build 16 | $ yarn start 17 | 18 | # generate static project 19 | $ yarn generate 20 | ``` 21 | 22 | For detailed explanation on how things work, check out [Nuxt.js docs](https://nuxtjs.org). 23 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/bottom-bar.css: -------------------------------------------------------------------------------- 1 | .aw-bottom-bar { 2 | --icon-color: rgba(var(--c-on-surface-rgb), 0.5); 3 | --icon-color-active: var(--c-accent, currentColor); 4 | @apply bg-surface shadow; 5 | display: flex; 6 | padding-bottom: env(safe-area-inset-bottom, 0); 7 | 8 | position: sticky; 9 | bottom: 0; 10 | min-height: 4rem; 11 | 12 | & > * { 13 | flex-basis: 100%; 14 | flex-grow: 1; 15 | flex-shrink: 1; 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /examples/dayjs/static/README.md: -------------------------------------------------------------------------------- 1 | # STATIC 2 | 3 | **This directory is not required, you can delete it if you don't want to use it.** 4 | 5 | This directory contains your static files. 6 | Each file inside this directory is mapped to `/`. 7 | Thus you'd want to delete this README.md before deploying to production. 8 | 9 | Example: `/static/robots.txt` is mapped as `/robots.txt`. 10 | 11 | More information about the usage of this directory in [the documentation](https://nuxtjs.org/guide/assets#static). 12 | -------------------------------------------------------------------------------- /examples/permissions/README.md: -------------------------------------------------------------------------------- 1 | # permissions-example 2 | 3 | > Example of casl-vue integration 4 | 5 | ## Build Setup 6 | 7 | ```bash 8 | # install dependencies 9 | $ yarn install 10 | 11 | # serve with hot reload at localhost:3000 12 | $ yarn dev 13 | 14 | # build for production and launch server 15 | $ yarn build 16 | $ yarn start 17 | 18 | # generate static project 19 | $ yarn generate 20 | ``` 21 | 22 | For detailed explanation on how things work, check out [Nuxt.js docs](https://nuxtjs.org). 23 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/header-notification.css: -------------------------------------------------------------------------------- 1 | .aw-header-notification { 2 | display: flex; 3 | align-items: flex-start; 4 | 5 | &__content { 6 | flex-grow: 1; 7 | 8 | display: flex; 9 | align-items: center; 10 | justify-content: center; 11 | flex-wrap: wrap; 12 | gap: theme('spacing.3', 0.75rem); 13 | 14 | padding-top: theme('spacing.3', 0.75rem); 15 | padding-bottom: theme('spacing.3', 0.75rem); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /packages/ui/tests/App.spec.js: -------------------------------------------------------------------------------- 1 | // import { shallowMount, createLocalVue } from '@vue/test-utils' 2 | // import VueRouter from 'vue-router' 3 | // import App from '../src/App.vue' 4 | 5 | // const localVue = createLocalVue() 6 | // localVue.use(VueRouter) 7 | // const router = new VueRouter() 8 | 9 | describe('App.vue', () => { 10 | it('is a Vue instance', () => { 11 | // const wrapper = shallowMount(App, { localVue, router }) 12 | 13 | expect(true).toBe(true) 14 | }) 15 | }) 16 | -------------------------------------------------------------------------------- /examples/tabs-routing/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { 4 | browser: true, 5 | node: true 6 | }, 7 | parserOptions: { 8 | parser: 'babel-eslint' 9 | }, 10 | extends: [ 11 | '@nuxtjs', 12 | 'prettier', 13 | 'prettier/vue', 14 | 'plugin:prettier/recommended', 15 | 'plugin:nuxt/recommended' 16 | ], 17 | plugins: ['prettier'], 18 | // add your custom rules here 19 | rules: {} 20 | } 21 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-code-snippet.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: Code Snippet | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwCodeSnippet /> component is used to render Chip - UI Vue component for Awes.io. 6 | title: Chip 7 | --- 8 | # Code Snippet 9 | 10 | ## Props 11 | 12 | 13 | |Name|Description|Type|Required|Default| 14 | |---|---|---|---|---| 15 | |language|-|`String`|`false`|markup| 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/concierge-bell.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/utils/merge-routes.js: -------------------------------------------------------------------------------- 1 | export function mergeRoutes(existingRoutes, newRoutes) { 2 | newRoutes.forEach(newRoute => { 3 | const existing = existingRoutes.find( 4 | ({ path }) => path === newRoute.path 5 | ) 6 | 7 | if (existing && existing.children) { 8 | return mergeRoutes(existing.children, newRoute.children) 9 | } 10 | 11 | if (!existing) { 12 | existingRoutes.push(newRoute) 13 | } 14 | }) 15 | } 16 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/university.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/plugins/helper.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | 3 | Vue.prototype._getTitle = function(title) { 4 | return 'Component <' + title + ' />' 5 | } 6 | Vue.prototype._getMetaTitle = function(title) { 7 | return '<' + title + ' /> :: Live preview - Awes.io' 8 | } 9 | Vue.prototype._getMetaDescription = function(title) { 10 | return { 11 | hid: 'description', 12 | name: 'description', 13 | content: 'Live preview of Awes.io UI component - <' + title + ' />' 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /examples/permissions/pages/admin.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 19 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-svg-image.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: SvgImage сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwSvgImage /> component is used to render SvgImage - UI Vue component for Awes.io. 6 | title: SvgImage 7 | --- 8 | 9 | # AwSvgImage 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |name|Name of the svg image|`String`|`true`|-| 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/animation.css: -------------------------------------------------------------------------------- 1 | /* select uses */ 2 | .animation-rotate { 3 | animation: aw-rotate 1s linear infinite; 4 | } 5 | 6 | .animation-rotate-slow { 7 | animation: aw-rotate 2s linear infinite; 8 | } 9 | 10 | @keyframes aw-rotate { 11 | to { 12 | transform: rotate(1turn) 13 | } 14 | } 15 | 16 | /* chip uses */ 17 | .animation-pulse { 18 | animation: aw-pulse 1s infinite; 19 | } 20 | 21 | @keyframes aw-pulse { 22 | 50% { 23 | transform: scale(1.3); 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /packages/nuxt-auth/src/assets/js/merge-routes.js: -------------------------------------------------------------------------------- 1 | export function mergeRoutes(existingRoutes, newRoutes) { 2 | newRoutes.forEach(newRoute => { 3 | const existing = existingRoutes.find( 4 | ({ path }) => path === newRoute.path 5 | ) 6 | 7 | if (existing && existing.children && newRoute.children) { 8 | return mergeRoutes(existing.children, newRoute.children) 9 | } 10 | 11 | if (!existing) { 12 | existingRoutes.push(newRoute) 13 | } 14 | }) 15 | } 16 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/book.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/i18n/awes.config.js: -------------------------------------------------------------------------------- 1 | export const lang = { 2 | locales: ['ru', 'en'], 3 | locale: 'ru', 4 | fetchTranslation: (locale) => ({ 5 | url: 'api/translations', 6 | params: { locale }, 7 | transformResponse: [ 8 | (data) => { 9 | try { 10 | const response = JSON.parse(data) 11 | return response.data 12 | } catch (e) { 13 | return {} 14 | } 15 | } 16 | ] 17 | }) 18 | } 19 | -------------------------------------------------------------------------------- /packages/nuxt-auth/README.md: -------------------------------------------------------------------------------- 1 | # NuxtAuth 2 | 3 | ## Install 4 | 5 | ```bash 6 | $ yarn install 7 | ``` 8 | 9 | ## Development 10 | 11 | ```bash 12 | # Development server with hot reload 13 | $ yarn watch 14 | 15 | # Tests in watch mode 16 | $ yarn test:watch 17 | ``` 18 | 19 | ## Build for production 20 | 21 | ```bash 22 | # Build project 23 | $ yarn build 24 | 25 | # Lint in auto-fix mode 26 | $ yarn lint:fix 27 | ``` 28 | 29 | Ensure to write proper commit message according to [Git Commit convention](https://www.conventionalcommits.org/) 30 | -------------------------------------------------------------------------------- /packages/dayjs/src/utils/string-format.js: -------------------------------------------------------------------------------- 1 | import { pathOr } from 'rambdax' 2 | 3 | function extractStringFormat(options) { 4 | const stringFormat = pathOr({}, 'stringFormat', options) 5 | 6 | return typeof stringFormat === 'string' 7 | ? { pattern: stringFormat } 8 | : stringFormat 9 | } 10 | 11 | export function normalizeStringFormat(defaults, globals, module) { 12 | return { 13 | ...defaults.stringFormat, 14 | ...extractStringFormat(globals), 15 | ...extractStringFormat(module) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /packages/nuxt-profile/README.md: -------------------------------------------------------------------------------- 1 | # NuxtProfile 2 | 3 | ## Install 4 | 5 | ```bash 6 | $ yarn install 7 | ``` 8 | 9 | ## Development 10 | 11 | ```bash 12 | # Development server with hot reload 13 | $ yarn watch 14 | 15 | # Tests in watch mode 16 | $ yarn test:watch 17 | ``` 18 | 19 | ## Build for production 20 | 21 | ```bash 22 | # Build project 23 | $ yarn build 24 | 25 | # Lint in auto-fix mode 26 | $ yarn lint:fix 27 | ``` 28 | 29 | Ensure to write proper commit message according to [Git Commit convention](https://www.conventionalcommits.org/) 30 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/plus-square.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/usermenu.css: -------------------------------------------------------------------------------- 1 | .aw-usermenu-mobile { 2 | @apply h-screen bg-surface fixed top-0 right-0; 3 | width: theme('spacing.64', 16rem); 4 | 5 | /* mobile transition */ 6 | transform: translateX(100%); 7 | opacity: 0; 8 | transition: 200ms transform, 0ms opacity 200ms; 9 | 10 | &.is-visible { 11 | transform: none; 12 | transition: 250ms transform ease-out-quad; 13 | opacity: 1; 14 | box-shadow: -5px 0 10px -3px rgba(0, 0, 0, 0.25), -2px 0 5px -2px rgba(0, 0, 0, 0.05); 15 | } 16 | } -------------------------------------------------------------------------------- /packages/vue-mc/rollup.config.js: -------------------------------------------------------------------------------- 1 | import babel from 'rollup-plugin-babel' 2 | 3 | const baseConfig = { 4 | input: 'src/index.js', 5 | plugins: [babel()], 6 | external: ['vue', 'vue-mc', 'rambdax'] 7 | } 8 | 9 | export default [ 10 | { 11 | ...baseConfig, 12 | output: { 13 | file: 'dist/index.js', 14 | format: 'cjs' 15 | } 16 | }, 17 | { 18 | ...baseConfig, 19 | output: { 20 | file: 'dist/index.esm.js', 21 | format: 'esm' 22 | } 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/credit-card.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/dayjs/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "example-dayjs", 3 | "version": "1.1.95", 4 | "description": "Example project with dayjs module", 5 | "author": "illjah42", 6 | "private": true, 7 | "scripts": { 8 | "dev": "nuxt", 9 | "build": "nuxt build", 10 | "start": "nuxt start", 11 | "generate": "nuxt generate", 12 | "lint": "eslint --ext .js,.vue --ignore-path .gitignore ." 13 | }, 14 | "dependencies": { 15 | "@awes-io/dayjs": "^0.3.4", 16 | "@awes-io/ui": "^1.111.1", 17 | "nuxt": "^2.0.0", 18 | "nuxt-i18n": "^6.5.0" 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /packages/nuxt-auth/docs/index.md: -------------------------------------------------------------------------------- 1 | # NuxtAuth 2 | 3 | ## Protect the page 4 | 5 | If you would like to close the page under auth. 6 | 7 | **Setting per route:** 8 | ```vue 9 | export default { 10 | middleware: 'auth' 11 | } 12 | ``` 13 | 14 | **Globally setting in `nuxt.config.js`:** 15 | ```vue 16 | router: { 17 | middleware: ['auth'] 18 | } 19 | ``` 20 | 21 | ## Disable auth module on the page 22 | 23 | **At the page:** 24 | ```vue 25 | export default { 26 | auth: false 27 | } 28 | ``` 29 | 30 | or: 31 | ```vue 32 | export default { 33 | auth: 'guest' 34 | } 35 | ``` 36 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-uploader-files.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: UploaderFiles сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwUploaderFiles /> component is used to render UploaderFiles - UI Vue component for Awes.io. 6 | title: UploaderFiles 7 | --- 8 | 9 | # AwUploaderFiles 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |files|-|`Array`|`false`|[]| 17 | |removeFile|-|`Function`|`true`|-| 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /packages/ui/assets/js/css.js: -------------------------------------------------------------------------------- 1 | export const camelCase = (str) => { 2 | return str.replace(/[-_]([a-z])/g, (m) => m[1].toUpperCase()) 3 | } 4 | 5 | /** 6 | * Create BEM-like clesses for given elements of the given block 7 | * @param {String} block block name 8 | * @param {Array} els element names 9 | * @return {Array} classnames 10 | */ 11 | export function getBemClasses(block, els = []) { 12 | let _cls = {} 13 | 14 | els.forEach((el) => { 15 | _cls[camelCase(el)] = `${block}__${el}` 16 | }) 17 | 18 | return _cls 19 | } 20 | -------------------------------------------------------------------------------- /examples/i18n/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "example-nuxt-i18n", 3 | "version": "1.4.86", 4 | "description": "Example of @awes-io/nuxt-i18n usage", 5 | "author": "illjah42", 6 | "private": true, 7 | "scripts": { 8 | "dev": "nuxt", 9 | "build": "nuxt build", 10 | "start": "nuxt start", 11 | "generate": "nuxt generate" 12 | }, 13 | "dependencies": { 14 | "@awes-io/dayjs": "^0.3.4", 15 | "@awes-io/nuxt-i18n": "^0.4.4", 16 | "@awes-io/ui": "^1.111.1", 17 | "express": "^4.17.1", 18 | "nuxt": "^2.0.0", 19 | "rambdax": "^7.0.1" 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/filter-month.css: -------------------------------------------------------------------------------- 1 | .aw-filter-month { 2 | @apply inline-flex; 3 | 4 | & > &__prev { 5 | @apply rounded-r-none; 6 | } 7 | 8 | & > &__next { 9 | @apply rounded-l-none; 10 | } 11 | 12 | & &__date { 13 | @apply px-4 self-stretch leading-none flex flex-col justify-center border-t border-b; 14 | border-color: theme('borderColor.default'); 15 | } 16 | 17 | &.default &__date { 18 | min-width: 114px; 19 | } 20 | 21 | & &__label { 22 | @apply text-xs text-mono-400; 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /packages/ui/assets/js/object.js: -------------------------------------------------------------------------------- 1 | import { is, isFalsy } from 'rambdax' 2 | 3 | /** 4 | * Removes empty values in object 5 | * 6 | * > Mutates given object 7 | * 8 | * @param {Object} obj dirty object 9 | * @return {Object} clean object 10 | */ 11 | export function clean(obj = {}) { 12 | // eslint-disable-next-line no-unused-vars 13 | for (let prop in obj) { 14 | if (isFalsy(obj[prop])) { 15 | delete obj[prop] 16 | } 17 | if (is(Object, obj[prop])) { 18 | clean(obj[prop]) 19 | } 20 | } 21 | 22 | return obj 23 | } 24 | -------------------------------------------------------------------------------- /packages/ui/nuxt/templates/core.plugin.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import { Notification } from '@awes-io/ui/assets/js/Notification' 3 | 4 | const _config = { 5 | default: JSON.parse('<%= JSON.stringify(options.default) %>'), 6 | dark: JSON.parse('<%= JSON.stringify(options.default) %>') 7 | } 8 | 9 | const $awes = { 10 | _config 11 | } 12 | 13 | Vue.prototype.$awes = $awes 14 | 15 | const Noty = new Notification() 16 | 17 | Vue.prototype.$notify = Noty.add.bind(Noty) 18 | 19 | export default ({ app }, inject) => { 20 | app.$awes = $awes 21 | inject('awes', $awes) 22 | } 23 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/arrow-from-right.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/align-justify.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/arrow-to-right.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/trash-alt.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/permissions/serverMiddleware/users.js: -------------------------------------------------------------------------------- 1 | export default [ 2 | { 3 | id: 1, 4 | email: 'employee@example.com', 5 | password: 'secret' 6 | // no permissions at all 7 | }, 8 | { 9 | id: 2, 10 | email: 'admin@example.com', 11 | password: 'secret', 12 | permissions: [ 13 | { 14 | action: 'manage', 15 | subject: 'Appointments' 16 | }, 17 | { 18 | action: 'view', 19 | subject: 'Settings' 20 | } 21 | ] 22 | } 23 | ] 24 | -------------------------------------------------------------------------------- /packages/ui/build/icons/icon-tpl.hbs: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: "{{fontName}}"; 3 | src: {{{src}}}; 4 | } 5 | 6 | {{baseSelector}} { 7 | display: inline-block; 8 | line-height: 1; 9 | {{!-- width: 1em; --}} 10 | vertical-align: middle; 11 | text-align: center; 12 | } 13 | 14 | {{baseSelector}}:before { 15 | font-family: {{fontName}} !important; 16 | font-style: normal; 17 | font-weight: normal !important; 18 | vertical-align: top; 19 | } 20 | 21 | {{#each codepoints}} 22 | .{{../classPrefix}}{{@key}}:before { 23 | content: "\\{{this}}"; 24 | } 25 | {{/each}} 26 | -------------------------------------------------------------------------------- /examples/basic-ui/api/index.js: -------------------------------------------------------------------------------- 1 | const express = require('express') 2 | const chart = require('./routes/chart') 3 | const managers = require('./routes/managers') 4 | const records = require('./routes/records') 5 | const gallery = require('./routes/gallery') 6 | 7 | const app = express() 8 | 9 | // Parse JSON bodies (as sent by API clients) 10 | app.use(express.json()) 11 | 12 | app.use(express.static(__dirname + '/static')) 13 | app.use(chart) 14 | app.use('/managers', managers) 15 | app.use('/records', records) 16 | app.use('/gallery', gallery) 17 | 18 | module.exports = { 19 | path: '/api', 20 | handler: app 21 | } 22 | -------------------------------------------------------------------------------- /examples/basic-ui/components/BuiColorCard.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 26 | -------------------------------------------------------------------------------- /packages/nuxt-localization/src/utils/options.js: -------------------------------------------------------------------------------- 1 | import { test, isType } from 'rambdax' 2 | 3 | const isAwesIoUiNamespace = test(/^@awes-io\/ui/) 4 | 5 | export const hasAwesIoUiModule = (modules = []) => 6 | modules.some(module => { 7 | const name = isType('Array', module) ? module[0] : module 8 | return isAwesIoUiNamespace(name) 9 | }) 10 | 11 | // const hasAwesIoUiCss = (css = []) => css.some(isAwesIoUiNamespace) 12 | 13 | // export function shouldAddCss(options) { 14 | // const { css, modules } = options 15 | 16 | // return !hasAwesIoUiModule(modules) && !hasAwesIoUiCss(css) 17 | // } 18 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/select.css: -------------------------------------------------------------------------------- 1 | .aw-select { 2 | & .not-searchable, 3 | & .not-searchable .aw-text-field__element { 4 | @apply cursor-pointer; 5 | } 6 | 7 | &__aw-dropdown { 8 | width: 100%; 9 | max-height: 75vh; 10 | } 11 | 12 | &--invert .aw-text-field__element { 13 | @apply bg-mono-100; 14 | } 15 | 16 | &--invert .aw-text-field__element:not(:focus) { 17 | @apply border-mono-100; 18 | } 19 | } 20 | 21 | @screen md { 22 | .aw-select { 23 | &__aw-dropdown { 24 | max-height: 50vh; 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/images.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/i18n/plugins/menu.js: -------------------------------------------------------------------------------- 1 | export default ({ app, store }) => { 2 | store.commit('awesIo/SET_MENU_ITEMS', { 3 | mock: { 4 | order: 1, 5 | text: 'statuses.new', 6 | icon: 'circle', 7 | href: '/' 8 | } 9 | }) 10 | 11 | store.commit('awesIo/SET_USER_MENU_ITEM', { 12 | key: 'mock', 13 | order: 1, 14 | item: { 15 | component: 'AwLink', 16 | props: { 17 | text: () => app.i18n.t('statuses.confirmed'), 18 | href: () => app.localePath({ path: '/' }) 19 | } 20 | } 21 | }) 22 | } 23 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/tags.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/vue-mc/src/Structures/Request.js: -------------------------------------------------------------------------------- 1 | import { Request as VueMCRequest } from 'vue-mc' 2 | import Response from './Response' 3 | 4 | export default class Request extends VueMCRequest { 5 | constructor(config, axios) { 6 | super(config) 7 | this.axios = axios 8 | } 9 | 10 | createResponse(axiosResponse) { 11 | return new Response(axiosResponse) 12 | } 13 | 14 | send() { 15 | return this.axios 16 | .request(this.config) 17 | .then(this.createResponse) 18 | .catch(error => { 19 | throw this.createError(error) 20 | }) 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /examples/basic-ui/pages/aw-calendar.vue: -------------------------------------------------------------------------------- 1 | 8 | 9 | 26 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/landmark-alt.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/permissions/CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Change Log 2 | 3 | All notable changes to this project will be documented in this file. 4 | See [Conventional Commits](https://conventionalcommits.org) for commit guidelines. 5 | 6 | ## [1.1.1](https://git.awescode.com/awes-io/client/compare/permissions-example@1.1.0...permissions-example@1.1.1) (2020-11-12) 7 | 8 | **Note:** Version bump only for package permissions-example 9 | 10 | 11 | 12 | 13 | 14 | # 1.1.0 (2020-05-05) 15 | 16 | 17 | ### Features 18 | 19 | * **nuxt-auth:** casl added globally to manage permissions ([58b0175](https://git.awescode.com/awes-io/client/commits/58b0175c5809b37d2669d425a3702eb8840603ea)) 20 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/collections/Role.js: -------------------------------------------------------------------------------- 1 | import { BaseModel } from '@awes-io/vue-mc' 2 | 3 | export default class Role extends BaseModel { 4 | defaults() { 5 | return { 6 | id: null, 7 | name: '', 8 | default_new: false, 9 | priority: null, 10 | description: '', 11 | permissions: [], 12 | } 13 | } 14 | 15 | routes() { 16 | return { 17 | fetch: `/api/admin/roles/{id}`, 18 | save: `/api/admin/roles`, 19 | update: `/api/admin/roles/{id}`, 20 | delete: `/api/admin/roles/{id}`, 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/credit-card.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/vue-mc/src/Structures/Model.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import { Model } from 'vue-mc' 3 | import Request from './Request' 4 | 5 | export default class BaseModel extends Model { 6 | createRequest(config) { 7 | return new Request(config, Vue.prototype.$nuxt.$axios) 8 | } 9 | 10 | options() { 11 | return { 12 | useFirstErrorOnly: true, 13 | methods: { 14 | fetch: 'GET', 15 | save: 'POST', 16 | update: 'PUT', 17 | create: 'POST', 18 | patch: 'PATCH', 19 | delete: 'DELETE' 20 | } 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /examples/admin/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "example-admin", 3 | "version": "1.4.7", 4 | "description": "@awes-io/admin installation example", 5 | "author": "", 6 | "private": true, 7 | "scripts": { 8 | "dev": "nuxt", 9 | "build": "nuxt build", 10 | "start": "nuxt start", 11 | "generate": "nuxt generate" 12 | }, 13 | "dependencies": { 14 | "@awes-io/nuxt-admin": "^0.7.32", 15 | "@awes-io/nuxt-auth": "^1.10.14", 16 | "@awes-io/ui": "^1.111.1", 17 | "@nuxtjs/axios": "^5.0.0", 18 | "express": "^4.17.1", 19 | "nuxt": "^2.0.0", 20 | "nuxt-i18n": "^6.6.0" 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /packages/dayjs/src/index.js: -------------------------------------------------------------------------------- 1 | import { resolve, join } from 'path' 2 | import { normalizeOptions } from './utils/options' 3 | 4 | const meta = require('../package.json') 5 | 6 | function AwesIoDayjs(_options = {}) { 7 | // Merge options 8 | const options = normalizeOptions(this.options, _options) 9 | 10 | // Add Nuxtjs plugin 11 | const { dst } = this.addTemplate({ 12 | src: resolve(__dirname, './plugins/dayjs.js'), 13 | fileName: join('awes-io', 'dayjs-plugin.js'), 14 | options 15 | }) 16 | 17 | this.options.plugins.push(join(this.options.buildDir, dst)) 18 | } 19 | 20 | AwesIoDayjs.meta = meta 21 | 22 | export default AwesIoDayjs 23 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/cropper.css: -------------------------------------------------------------------------------- 1 | @import 'croppie/croppie.css'; 2 | 3 | .aw-cropper { 4 | max-width: 100%; 5 | margin-left: auto; 6 | margin-right: auto; 7 | 8 | &__croppie { 9 | position: relative; 10 | } 11 | 12 | &__rotate { 13 | position: absolute; 14 | right: 0; 15 | top: 0; 16 | z-index: 2; 17 | } 18 | 19 | .croppie-container { 20 | .cr-viewport, 21 | .cr-resizer { 22 | border: none; 23 | box-shadow: 0 0 2000px 2000px var(--c-mono-600); 24 | } 25 | 26 | .cr-slider-wrap { 27 | width: 100%; 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /packages/nuxt-auth/.gitlab-ci.yml: -------------------------------------------------------------------------------- 1 | stages: 2 | - test 3 | - release 4 | 5 | test: 6 | before_script: 7 | - yarn install --frozen-lockfile 8 | image: node:8 9 | cache: 10 | key: ${CI_BUILD_REF_NAME} 11 | paths: 12 | - node_modules 13 | script: 14 | - yarn test 15 | stage: test 16 | 17 | release: 18 | before_script: 19 | - yarn install --frozen-lockfile 20 | image: node:8 21 | cache: 22 | key: ${CI_BUILD_REF_NAME} 23 | paths: 24 | - node_modules 25 | only: 26 | - master 27 | script: 28 | - NPM_TOKEN=${NPM_TOKEN} GITLAB_TOKEN=${GITLAB_TOKEN} npx semantic-release --branch master 29 | stage: release 30 | when: on_success 31 | -------------------------------------------------------------------------------- /packages/nuxt-profile/.gitlab-ci.yml: -------------------------------------------------------------------------------- 1 | stages: 2 | - test 3 | - release 4 | 5 | test: 6 | before_script: 7 | - yarn install --frozen-lockfile 8 | image: node:8 9 | cache: 10 | key: ${CI_BUILD_REF_NAME} 11 | paths: 12 | - node_modules 13 | script: 14 | - yarn test 15 | stage: test 16 | 17 | release: 18 | before_script: 19 | - yarn install --frozen-lockfile 20 | image: node:8 21 | cache: 22 | key: ${CI_BUILD_REF_NAME} 23 | paths: 24 | - node_modules 25 | only: 26 | - master 27 | script: 28 | - NPM_TOKEN=${NPM_TOKEN} GITLAB_TOKEN=${GITLAB_TOKEN} npx semantic-release --branch master 29 | stage: release 30 | when: on_success 31 | -------------------------------------------------------------------------------- /packages/ui/components/3_organisms/AwTable/_AwTableRowHidden.vue: -------------------------------------------------------------------------------- 1 | 14 | 15 | 28 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/percentage.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { 4 | node: true, 5 | browser: true, 6 | es6: true 7 | }, 8 | extends: [ 9 | 'plugin:prettier/recommended', 10 | 'plugin:vue/essential', 11 | 'eslint:recommended' 12 | ], 13 | plugins: ['vue', 'prettier'], 14 | rules: { 15 | 'prettier/prettier': 'error', 16 | 'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off', 17 | 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off' 18 | }, 19 | parserOptions: { 20 | parser: 'babel-eslint', 21 | ecmaVersion: 6, 22 | sourceType: 'module' 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-table-head.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: TableHead сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwTableHead /> component is used to render TableHead - UI Vue component for Awes.io. 6 | title: TableHead 7 | --- 8 | 9 | # AwTableHead 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |columns|-|`Array`|`false`|-| 17 | 18 | 19 | 20 | ## Slots 21 | 22 | 23 | |Name|Description|Default Slot Content| 24 | |---|---|---| 25 | |th|-|-| 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/smile-wink.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/university.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { 4 | node: true, 5 | browser: true, 6 | es6: true 7 | }, 8 | extends: [ 9 | 'plugin:prettier/recommended', 10 | 'plugin:vue/essential', 11 | 'eslint:recommended' 12 | ], 13 | plugins: ['vue', 'prettier'], 14 | rules: { 15 | 'prettier/prettier': 'error', 16 | 'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off', 17 | 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off' 18 | }, 19 | parserOptions: { 20 | parser: 'babel-eslint', 21 | ecmaVersion: 6, 22 | sourceType: 'module' 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/clock.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-auth/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { 4 | node: true, 5 | browser: true, 6 | es6: true 7 | }, 8 | extends: [ 9 | 'plugin:prettier/recommended', 10 | 'plugin:vue/essential', 11 | 'eslint:recommended' 12 | ], 13 | plugins: ['vue', 'prettier'], 14 | rules: { 15 | 'prettier/prettier': 'error', 16 | 'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off', 17 | 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off' 18 | }, 19 | parserOptions: { 20 | parser: 'babel-eslint', 21 | ecmaVersion: 6, 22 | sourceType: 'module' 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /packages/nuxt-profile/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | env: { 4 | node: true, 5 | browser: true, 6 | es6: true 7 | }, 8 | extends: [ 9 | 'plugin:prettier/recommended', 10 | 'plugin:vue/essential', 11 | 'eslint:recommended' 12 | ], 13 | plugins: ['vue', 'prettier'], 14 | rules: { 15 | 'prettier/prettier': 'error', 16 | 'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off', 17 | 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off' 18 | }, 19 | parserOptions: { 20 | parser: 'babel-eslint', 21 | ecmaVersion: 6, 22 | sourceType: 'module' 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/island-tropical.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/pages/aw-markdown-editor.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 32 | -------------------------------------------------------------------------------- /examples/permissions/plugins/menu.js: -------------------------------------------------------------------------------- 1 | export default ({ store }) => { 2 | // const can = store.getters.can 3 | 4 | store.commit('awesIo/SET_MENU_ITEM', [ 5 | { 6 | key: 'appointments', 7 | order: 0, 8 | props: { 9 | text: 'Appointments', 10 | href: '/', 11 | icon: 'schedule' 12 | } 13 | }, 14 | { 15 | key: 'admin', 16 | order: 1, 17 | props: { 18 | text: 'Admin', 19 | href: '/admin', 20 | icon: 'settings', 21 | show: () => store.getters.can('view', 'Settings') 22 | } 23 | } 24 | ]) 25 | } 26 | -------------------------------------------------------------------------------- /packages/dayjs/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@awes-io/dayjs", 3 | "version": "0.3.4", 4 | "description": "Date convertation module for Awes.io", 5 | "homepage": "https://www.awes.io", 6 | "bugs": { 7 | "url": "https://github.com/awes-io/client/issues" 8 | }, 9 | "repository": { 10 | "type": "git", 11 | "url": "git@github.com:awes-io/client.git" 12 | }, 13 | "license": "MIT", 14 | "author": "Awescode GmbH (https://www.awescode.de)", 15 | "contributors": [ 16 | "illjah42 " 17 | ], 18 | "main": "src/index.js", 19 | "dependencies": { 20 | "dayjs": "^1.8.26", 21 | "rambdax": "^7.0.1" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-dashboard-speed.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: DashboardSpeed сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwDashboardSpeed /> component is used to render DashboardSpeed - UI Vue component for Awes.io. 6 | title: DashboardSpeed 7 | --- 8 | 9 | # AwDashboardSpeed 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |sections|-|`Array`|`true`|-| 17 | 18 | 19 | 20 | 21 | ## MixIns 22 | 23 | 24 | |MixIn| 25 | |---| 26 | |dashboardMixin| 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /examples/admin/assets/sprite/svg/edit.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/browser.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/edit.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-calendar-nav.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: Calendar Nav | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwCalendarDays /> component is used to render Button - UI Vue component for Awes.io. 6 | title: Calendar Nav 7 | --- 8 | # Calendar Nav 9 | 10 | The `AwCalendarNav` component is used to render navigation for calendar. 11 | 12 | 13 | ## Props 14 | 15 | 16 | |Name|Description|Type|Required|Default| 17 | |---|---|---|---|---| 18 | |year|-|`Number`|`false`|-| 19 | |month|-|`Number`|`false`|-| 20 | |months|-|`Array`|`false`|-| 21 | |disabledPrev|-|`Boolean`|`false`|-| 22 | |disabledNext|-|`Boolean`|`false`|-| 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-dashboard-donut.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: DashboardDonut сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwDashboardDonut /> component is used to render DashboardDonut - UI Vue component for Awes.io. 6 | title: DashboardDonut 7 | --- 8 | 9 | # AwDashboardDonut 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |height|-|`Number`|`false`|200| 17 | 18 | 19 | 20 | 21 | ## MixIns 22 | 23 | 24 | |MixIn| 25 | |---| 26 | |dashboardMixin| 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /examples/admin/assets/sprite/svg/cloud-download.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/cloud-download.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-auth/jest.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | moduleFileExtensions: ['js', 'json', 'vue'], 3 | transform: { 4 | '^.+\\.vue$': 'vue-jest', 5 | '.+\\.(css|styl|less|sass|scss|svg|png|jpg|ttf|woff|woff2)$': 6 | 'jest-transform-stub', 7 | '^.+\\.js$': 'babel-jest' 8 | }, 9 | transformIgnorePatterns: ['/node_modules/'], 10 | moduleNameMapper: { 11 | '^@/(.*)$': '/src/$1' 12 | }, 13 | snapshotSerializers: ['jest-serializer-vue'], 14 | testMatch: ['**/tests/**/*.spec.js|**/__tests__/*.js'], 15 | testURL: 'http://localhost/' 16 | // watchPlugins: [ 17 | // 'jest-watch-typeahead/filename', 18 | // 'jest-watch-typeahead/testname' 19 | // ] 20 | } 21 | -------------------------------------------------------------------------------- /packages/ui/components/3_organisms/AwCalendar/_AwCalendarDay.vue: -------------------------------------------------------------------------------- 1 | 13 | 14 | 31 | -------------------------------------------------------------------------------- /packages/nuxt-profile/jest.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | moduleFileExtensions: ['js', 'json', 'vue'], 3 | transform: { 4 | '^.+\\.vue$': 'vue-jest', 5 | '.+\\.(css|styl|less|sass|scss|svg|png|jpg|ttf|woff|woff2)$': 6 | 'jest-transform-stub', 7 | '^.+\\.js$': 'babel-jest' 8 | }, 9 | transformIgnorePatterns: ['/node_modules/'], 10 | moduleNameMapper: { 11 | '^@/(.*)$': '/src/$1' 12 | }, 13 | snapshotSerializers: ['jest-serializer-vue'], 14 | testMatch: ['**/tests/**/*.spec.js|**/__tests__/*.js'], 15 | testURL: 'http://localhost/' 16 | // watchPlugins: [ 17 | // 'jest-watch-typeahead/filename', 18 | // 'jest-watch-typeahead/testname' 19 | // ] 20 | } 21 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/mobile-menu-item.css: -------------------------------------------------------------------------------- 1 | .aw-mobile-menu-item { 2 | @apply bg-surface; 3 | display: flex; 4 | align-items: center; 5 | width: 100%; 6 | 7 | &:hover, 8 | &:focus { 9 | oultine: none; 10 | text-decoration: none; 11 | } 12 | 13 | &--active { 14 | color: var(--c-accent); 15 | font-weight: bold; 16 | } 17 | 18 | & + & { 19 | border-top: 1px solid var(--c-mono-800); 20 | } 21 | 22 | &__icon { 23 | @apply -mr-1 ml-6; 24 | } 25 | 26 | &__text { 27 | @apply py-4 px-6 truncate; 28 | flex-grow: 1; 29 | } 30 | 31 | &__arrow { 32 | @apply my-3 mr-3; 33 | color: var(--c-on-surface); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/coins.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/hands-helping.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/palette.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/pages/aw-cropper.vue: -------------------------------------------------------------------------------- 1 | 8 | 9 | 27 | -------------------------------------------------------------------------------- /examples/basic-ui/pages/aw-link.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 28 | -------------------------------------------------------------------------------- /packages/ui/assets/css/additional/comma.css: -------------------------------------------------------------------------------- 1 | .comma:not(:first-child) { 2 | margin-left: -0.3em; 3 | } 4 | 5 | /* next 2 rules are for spacing when the first .comma is empty too */ 6 | .comma:first-child:empty ~ .comma:not(:empty) { 7 | margin-left: 0; 8 | } 9 | 10 | .comma:first-child:empty ~ .comma:not(:empty) ~ .comma:not(:empty) { 11 | margin-left: -0.3em; 12 | } 13 | 14 | .comma:empty { 15 | display: none; 16 | } 17 | 18 | .comma:not(:first-child):before { 19 | content: ", "; 20 | } 21 | 22 | .comma:not(:first-child):before { 23 | content: ", "; 24 | } 25 | 26 | .comma:empty + .comma:not(:empty):before { 27 | content : ""; 28 | } 29 | 30 | .comma:not(:empty) ~ .comma:empty + .comma:not(:empty):before { 31 | content : ", "; 32 | } 33 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-layout-default.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: LayoutDefault сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwLayoutDefault /> is a layout with left sidebar for Awes.io. 6 | title: LayoutDefault 7 | --- 8 | 9 | # AwLayoutDefault 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |menu|-|`Array`|`false`|[]| 17 | 18 | 19 | 20 | ## Slots 21 | 22 | 23 | |Name|Description|Default Slot Content| 24 | |---|---|---| 25 | |before-header|-|-| 26 | |navbar|navbar|-| 27 | |default|content|-| 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/shopping-cart.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/piggy-bank.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/check-circle.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/dropdown.css: -------------------------------------------------------------------------------- 1 | .aw-dropdown { 2 | @apply bg-surface; 3 | box-shadow: 0 7px 15px -3px rgba(0,0,0,.1), 0 4px 6px 0px rgba(0,0,0,0.1); 4 | min-width: 160px; 5 | overflow: auto; 6 | scrollbar-width: thin; 7 | } 8 | 9 | /** 10 | * Transition 11 | */ 12 | 13 | .fade { 14 | 15 | &-enter, 16 | &-leave-to { 17 | opacity: 0; 18 | } 19 | 20 | &-enter-active, 21 | &-leave-active { 22 | transition: opacity 200ms ease; 23 | } 24 | } 25 | 26 | .caret { 27 | transition: 200ms transform ease-out 28 | } 29 | 30 | .rotate-90 { 31 | transform: rotate(-90deg) 32 | } 33 | 34 | .rotate-180 { 35 | transform: rotate(-180deg) 36 | } 37 | 38 | .transition-200 { 39 | transition: 200ms transform 40 | } 41 | -------------------------------------------------------------------------------- /packages/nuxt-admin/src/pages/User.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 30 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/receipt.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-layout-frame-center.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: LayoutFrameCenter сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwLayoutFrameCenter /> is a layout for login or registration page for Awes.io. 6 | title: LayoutFrameCenter 7 | --- 8 | 9 | # AwLayoutFrameCenter 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |logo|-|`Object`|`false`|-| 17 | |background|-|`Object`|`false`|-| 18 | 19 | 20 | 21 | ## Slots 22 | 23 | 24 | |Name|Description|Default Slot Content| 25 | |---|---|---| 26 | |default|-|-| 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /lerna.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "independent", 3 | "npmClient": "yarn", 4 | "useWorkspaces": true, 5 | "conventionalCommits": true, 6 | "exact": false, 7 | "packages": ["packages/*"], 8 | "command": { 9 | "publish": { 10 | "npmClient": "yarn", 11 | "ignoreChanges": ["ignored-file", "*.md"], 12 | "message": "chore(release): new version [skiprelease]" 13 | }, 14 | "version": { 15 | "allowBranch": "master" 16 | } 17 | }, 18 | 19 | "changelog": { 20 | "labels": { 21 | "feat": "🚀 Features", 22 | "fix": "🐛 Bug Fixes", 23 | "docs": "📝 Documents", 24 | "perf": "🔥 Performance", 25 | "refactor": "💅 Refactors" 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/hand-paper.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/user-friends.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.gitlab-ci.yml: -------------------------------------------------------------------------------- 1 | stages: 2 | - release 3 | 4 | release: 5 | before_script: 6 | - yarn install --frozen-lockfile 7 | - apk add --no-cache git 8 | - git config --global user.email "yevhenlisovenko@gmail.com" 9 | - git config --global user.name "Yevhen L." 10 | - git fetch origin +refs/heads/master:refs/remotes/origin/master; 11 | - git checkout master; 12 | - git reset --hard "$CI_COMMIT_SHA"; 13 | image: node:12-alpine 14 | cache: 15 | key: ${CI_BUILD_REF_NAME} 16 | paths: 17 | - node_modules 18 | only: 19 | - master 20 | script: 21 | - HUSKY_BYPASS=true GL_TOKEN=${GITLAB_TOKEN} GL_API_URL=https://git.awescode.com/api/v4 yarn pkg 22 | stage: release 23 | except: 24 | variables: 25 | - $CI_COMMIT_MESSAGE =~ /\[skiprelease\]/i 26 | when: on_success 27 | 28 | -------------------------------------------------------------------------------- /packages/ui/components/1_atoms/AwIcon/AwIconSystemColor.vue: -------------------------------------------------------------------------------- 1 | 12 | 13 | 34 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/list-alt.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-i18n/src/template/header.js: -------------------------------------------------------------------------------- 1 | function toggleHeader($axios, locales, currentLocale) { 2 | const locale = locales.find(({ code }) => code === currentLocale) 3 | 4 | if (locale.iso) { 5 | $axios.defaults.headers.common['Accept-Language'] = locale.iso 6 | } else { 7 | delete $axios.defaults.headers.common['Accept-Language'] 8 | } 9 | } 10 | 11 | export default function({ app, $axios }) { 12 | // toggle first time 13 | toggleHeader($axios, app.i18n.locales, app.i18n.locale) 14 | 15 | // set listener on language switch 16 | const _oldBeforeLanguageSwitch = app.i18n.beforeLanguageSwitch 17 | app.i18n.beforeLanguageSwitch = async (oldLocale, newLocale) => { 18 | await _oldBeforeLanguageSwitch 19 | toggleHeader($axios, app.i18n.locales, newLocale) 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /packages/ui/assets/js/constants.js: -------------------------------------------------------------------------------- 1 | export const TABLE_PRIORITY_ATTR = 'data-priority' 2 | 3 | export const TABLE_TOGGLER_ATTR = 'data-toggle-hidden' 4 | 5 | export const TABLE_INDEX_ATTR = 'data-row-index' 6 | 7 | export const TABLE_ROW_CLICK_EVENT = 'click:row' 8 | 9 | export const TABLE_HEAD_CLICK_EVENT = 'click:head' 10 | 11 | export const TABLE_DATA_FETCHED = 'data-fetched' 12 | 13 | export const FORM_ENTER_SKIP_ATTR = 'data-enter-skip' 14 | 15 | export const COLORS = [ 16 | '#E0AB61', 17 | '#E29D5D', 18 | '#E68262', 19 | '#E45284', 20 | '#DF54BD', 21 | '#DA61D9', 22 | '#BF55CF', 23 | '#AF57DB', 24 | '#9C55D3', 25 | '#834EE3', 26 | '#634EE3', 27 | '#594FCF', 28 | '#6086E3', 29 | '#66B9E4', 30 | '#66C3D1', 31 | '#66C7B9', 32 | '#5CBC98', 33 | '#9A6F66' 34 | ] 35 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/chart-network.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/gift.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/money-bill-alt.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/assets/js/string.js: -------------------------------------------------------------------------------- 1 | import { split, reduce } from 'rambdax' 2 | 3 | export const ucFirst = (text = '') => { 4 | return text.charAt(0).toUpperCase() + text.substr(1) 5 | } 6 | 7 | export const toPascal = (text = '') => { 8 | return reduce( 9 | (str, chunk) => (chunk ? str + ucFirst(chunk) : str), 10 | '', 11 | split('-', text) 12 | ) 13 | } 14 | 15 | export const hashStringToIndex = (str, limit) => { 16 | limit = +limit || 0 17 | 18 | let hash = 0 19 | 20 | if (typeof str !== 'string' || !str.length) return null 21 | 22 | if (limit < 2) return 0 23 | 24 | for (var i = 0; i < str.length; i++) { 25 | hash = str.charCodeAt(i) + ((hash << 5) - hash) 26 | hash = hash & hash 27 | } 28 | 29 | hash = ((hash % limit) + limit) % limit 30 | 31 | return hash 32 | } 33 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-table-row.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: TableRow сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwTableRow /> component is used to render TableRow - UI Vue component for Awes.io. 6 | title: TableRow 7 | --- 8 | 9 | # AwTableRow 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |row|-|—|`false`|-| 17 | |rowIndex|-|—|`true`|-| 18 | |openedRow|-|`Number`|`false`|-| 19 | |showToggler|-|`Boolean`|`false`|-| 20 | |columns|-|`Array`|`true`|-| 21 | 22 | 23 | 24 | ## Events 25 | 26 | 27 | |Event Name|Description|Parameters| 28 | |---|---|---| 29 | |click:row|-|-| 30 | |click:toggle|-|-| 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/map-marker-check.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "basic-ui", 3 | "version": "1.82.2", 4 | "private": true, 5 | "scripts": { 6 | "build": "nuxt build", 7 | "dev": "nuxt", 8 | "dev:api": "nodemon ./api/dev.js", 9 | "post-update": "yarn upgrade --latest", 10 | "start": "nuxt start" 11 | }, 12 | "dependencies": { 13 | "@awes-io/ui": "^2.3.1", 14 | "@awes-io/vue-mc": "^0.3.3", 15 | "@fortawesome/fontawesome-free": "^5.13.1", 16 | "@nuxtjs/axios": "^5.0.0", 17 | "express": "^4.17.1", 18 | "express-fileupload": "^1.1.7-alpha.3", 19 | "nuxt": "^2.0.0", 20 | "nuxt-i18n": "^6.3.0", 21 | "vue-api-query": "^1.5.1", 22 | "vue-sweetalert2": "^2.1.1" 23 | }, 24 | "devDependencies": { 25 | "nodemon": "^2.0.2" 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-context-menu.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: ContextMenu сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwContextMenu /> component is used to render ContextMenu - UI Vue component for Awes.io. 6 | title: ContextMenu 7 | --- 8 | 9 | # AwContextMenu 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |options|Popper.js options. List of all options - https://popper.js.org/docs/v2/|`Object`|`false`|-| 17 | |buttonClass|Additional class for the button that opens list|`String`|`false`|-| 18 | 19 | 20 | 21 | 22 | ## MixIns 23 | 24 | 25 | |MixIn| 26 | |---| 27 | |arrowFocusMixin| 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/box-usd.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/vue-mc/.gitignore: -------------------------------------------------------------------------------- 1 | # Dependencies 2 | node_modules 3 | jspm_packages 4 | 5 | # Only keep yarn.lock in the root 6 | package-lock.json 7 | yarn.lock 8 | 9 | # Logs 10 | *.log 11 | 12 | # Other 13 | .cache 14 | 15 | # Dist folders 16 | dist 17 | 18 | # Junit reports 19 | reports 20 | 21 | # Coverage reports 22 | coverage 23 | *.lcov 24 | .nyc_output 25 | 26 | # VSCode 27 | .vscode 28 | 29 | # Intellij idea 30 | *.iml 31 | .idea 32 | 33 | # OSX 34 | .DS_Store 35 | .AppleDouble 36 | .LSOverride 37 | 38 | # Files that might appear in the root of a volume 39 | .DocumentRevisions-V100 40 | .fseventsd 41 | .Spotlight-V100 42 | .TemporaryItems 43 | .Trashes 44 | .VolumeIcon.icns 45 | .com.apple.timemachine.donotpresent 46 | 47 | # Directories potentially created on remote AFP share 48 | .AppleDB 49 | .AppleDesktop 50 | Network Trash Folder 51 | Temporary Items 52 | .apdisk 53 | -------------------------------------------------------------------------------- /packages/nuxt-auth/src/pages/VerifyEmail.vue: -------------------------------------------------------------------------------- 1 | 36 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/table-head.css: -------------------------------------------------------------------------------- 1 | .col-orderable { 2 | @apply relative pr-4; 3 | 4 | &::after, 5 | &::before { 6 | @apply absolute w-0 h-0; 7 | content: ''; 8 | right: 0; 9 | border-left: 4px solid transparent; 10 | border-right: 4px solid transparent; 11 | } 12 | 13 | &::after { 14 | top:50%; 15 | border-bottom: 4px solid theme('colors.disabled'); 16 | transform: translateY(calc(-50% - 3px)); 17 | } 18 | 19 | &::before { 20 | top: 50%; 21 | border-top: 4px solid theme('colors.disabled'); 22 | transform: translateY(2px); 23 | } 24 | 25 | &.col-orderable--asc::after { 26 | border-bottom-color: theme('colors.link'); 27 | } 28 | 29 | &.col-orderable--desc:before { 30 | border-top-color: theme('colors.link'); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-slider.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: Slider сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwSlider /> component is used to render Slider - UI Vue component for Awes.io. 6 | title: Slider 7 | --- 8 | 9 | # AwSlider 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |tag|-|`String`|`false`|div| 17 | 18 | 19 | 20 | 21 | ## Events 22 | 23 | 24 | |Event Name|Description|Parameters| 25 | |---|---|---| 26 | |resized|-|-| 27 | 28 | 29 | 30 | 31 | ## Slots 32 | 33 | 34 | |Name|Description|Default Slot Content| 35 | |---|---|---| 36 | |default|-|-| 37 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-dropdown-button.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: DropdownButton сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwDropdownButton /> component is used to render DropdownButton - UI Vue component for Awes.io. 6 | title: DropdownButton 7 | --- 8 | 9 | # AwDropdownButton 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |color|Color modification|'default' / 'success' / 'warning' / 'danger'|`false`|'default'| 17 | |active|Sets active state class|`Boolean`|`false`|-| 18 | 19 | 20 | 21 | 22 | ## Slots 23 | 24 | 25 | |Name|Description|Default Slot Content| 26 | |---|---|---| 27 | |default|-|{{ text }}| 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /examples/tabs-routing/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "tabs-routing", 3 | "version": "1.41.108", 4 | "private": true, 5 | "description": "Awes.io AwTabNav routing example", 6 | "author": "illjah42", 7 | "scripts": { 8 | "build": "nuxt build", 9 | "dev": "nuxt", 10 | "generate": "nuxt generate", 11 | "lint": "eslint --ext .js,.vue --ignore-path .gitignore .", 12 | "start": "nuxt start" 13 | }, 14 | "dependencies": { 15 | "nuxt": "^2.0.0", 16 | "nuxt-i18n": "^6.3.0" 17 | }, 18 | "devDependencies": { 19 | "@awes-io/ui": "^1.111.1", 20 | "@nuxtjs/eslint-config": "^1.0.1", 21 | "@nuxtjs/eslint-module": "^1.0.0", 22 | "babel-eslint": "^10.0.1", 23 | "eslint": "^6.1.0", 24 | "eslint-config-prettier": "^4.1.0", 25 | "eslint-plugin-nuxt": ">=0.4.2", 26 | "eslint-plugin-prettier": "^3.0.1", 27 | "prettier": "^1.16.4" 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/exchange.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-laravel/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@awes-io/nuxt-laravel", 3 | "version": "0.3.3", 4 | "description": "Awes.io module for connection with Laravel backend", 5 | "homepage": "https://www.awes.io", 6 | "bugs": { 7 | "url": "https://github.com/awes-io/client/issues" 8 | }, 9 | "keywords": [ 10 | "laravel", 11 | "nuxt", 12 | "awes-io" 13 | ], 14 | "repository": { 15 | "type": "git", 16 | "url": "git@github.com:awes-io/client.git" 17 | }, 18 | "license": "MIT", 19 | "author": "Awescode GmbH (https://www.awescode.de)", 20 | "contributors": [ 21 | "illjah42 " 22 | ], 23 | "main": "src/index.js", 24 | "dependencies": { 25 | "@nuxtjs/axios": "^5.9.2", 26 | "fs-extra": "^8.1.0", 27 | "rambdax": "^7.0.1" 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-dashboard-section.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: DashboardSection сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwDashboardSection /> component is used to render DashboardSection - UI Vue component for Awes.io. 6 | title: DashboardSection 7 | --- 8 | 9 | # AwDashboardSection 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |backgroundColor|fill color if present|`String`|`false`|-| 17 | |borderColor|Color of line|`String`|`false`|-| 18 | |showAxisLegend|If enabled shows bottom legend|`Boolean`|`false`|-| 19 | 20 | 21 | 22 | 23 | ## MixIns 24 | 25 | 26 | |MixIn| 27 | |---| 28 | |dashboardMixin| 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/tools.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/tags.css: -------------------------------------------------------------------------------- 1 | .aw-tags { 2 | display: inline-flex; 3 | flex-wrap: wrap; 4 | gap: theme('spacing.2', 0.5rem); 5 | } 6 | 7 | .aw-tag { 8 | color: var(--c-on-overlay); 9 | 10 | border-radius: 9999px; 11 | padding: theme('spacing.1', 0.25rem) theme('spacing.2', 0.5rem); 12 | min-width: calc(theme('spacing.2', 0.5rem) + theme('fontSize.xs', 0.625rem)); 13 | 14 | text-align: center; 15 | font-size: theme('fontSize.xs', 0.625rem); 16 | font-family: theme('fontFamily.heading'); 17 | font-weight: 700; 18 | line-height: 1; 19 | white-space: nowrap; 20 | text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1); /* TODO: --c-overlay with opacity */ 21 | 22 | &--clickable { 23 | &:focus:not(:focus-visible) { 24 | outline: none; 25 | } 26 | 27 | &:active { 28 | transform: translateY(1px); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-user-menu.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: UserMenu сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwUserMenu /> component is used to render UserMenu - UI Vue component for Awes.io. 6 | title: UserMenu 7 | --- 8 | 9 | # AwUserMenu 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |avatar|Path to user avatar image|`String`|`false`|-| 17 | |name|User name|`String`|`false`|-| 18 | |info|Additional info under user name|`String`|`false`|-| 19 | |darkTheme|Is dark mode enabled (for internal use)|`Boolean`|`false`|-| 20 | 21 | 22 | 23 | 24 | ## Slots 25 | 26 | 27 | |Name|Description|Default Slot Content| 28 | |---|---|---| 29 | |default|-|-| 30 | |default|-|-| 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/date.css: -------------------------------------------------------------------------------- 1 | .aw-date { 2 | position: relative; 3 | 4 | &__dropdown { 5 | max-height: unset; 6 | max-width: 100%; 7 | display: flex; 8 | flex-wrap: wrap; 9 | } 10 | 11 | &__calendar { 12 | max-width: theme('maxWidth.xs'); 13 | } 14 | 15 | &__range:before, 16 | &__range-start:before, 17 | &__range-end:before { 18 | @apply bg-success; 19 | opacity: 0.5; 20 | content: ''; 21 | display: block; 22 | position: absolute; 23 | top: calc(50% - theme('spacing.4')); 24 | left: 0; 25 | width: 100%; 26 | height: theme('spacing.8'); 27 | } 28 | 29 | &__range-start:before, 30 | &__range-end:before { 31 | width: 50%; 32 | } 33 | 34 | &__range-start:before { 35 | left: 50%; 36 | } 37 | 38 | & i { 39 | @apply not-italic; 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /packages/ui/mixins/arrow-focus.js: -------------------------------------------------------------------------------- 1 | export default { 2 | methods: { 3 | _arrowFocusItem(offset = 0, $event) { 4 | if (!this.isOpened) return 5 | 6 | const buttons = Array.from( 7 | this.$el.querySelectorAll('[data-arrow-focus]') 8 | ) 9 | const active = document.activeElement 10 | const activeIndex = buttons.indexOf(active) 11 | let nextIndex 12 | 13 | if (activeIndex < 0) { 14 | nextIndex = 0 15 | } else { 16 | nextIndex = activeIndex + offset 17 | } 18 | 19 | const button = buttons[nextIndex] 20 | 21 | if (button) { 22 | if ($event) { 23 | $event.preventDefault() 24 | $event.stopPropagation() 25 | } 26 | button.focus() 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /examples/basic-ui/pages/overview.vue: -------------------------------------------------------------------------------- 1 | 12 | 13 | 36 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/sack-dollar.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-badge.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: AwBadge | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwBadge /> component is used to render badges - UI Vue component for Awes.io. 6 | title: Badge 7 | --- 8 | # AwBadge 9 | 10 | ## Props 11 | 12 | 13 | |Name|Description|Type|Required|Default| 14 | |---|---|---|---|---| 15 | |text|Text inside badge|`String` / `Number`|`false`|-| 16 | |icon|Icon name inside badge. See AwIcon component for available names|`String`|`false`|-| 17 | |color|Badge background color|`String`|`false`|brand| 18 | |hideIfEmpty|When set to `true`, badge will hide if text is empty or 0|`Boolean`|`false`|-| 19 | 20 | 21 | 22 | 23 | ## Slots 24 | 25 | 26 | |Name|Description|Default Slot Content| 27 | |---|---|---| 28 | |default|Content passed to component|-| 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /packages/nuxt-auth/lang/en.js: -------------------------------------------------------------------------------- 1 | export default { 2 | AwesIoAuth: { 3 | loginTitle: 'Welcome back!', 4 | registerTitle: 'Getting Started With Us!', 5 | verifyTitle: 'Verification code', 6 | forgotTitleEmail: 'Enter your email', 7 | forgotTitlePassword: 'Enter new password', 8 | email: 'Email', 9 | fullName: 'Full Name', 10 | company: 'Company Name (optional)', 11 | password: 'Password', 12 | passwordConfirm: 'Confirm password', 13 | rememberMe: 'Remember me', 14 | forgotPassword: 'Reset password', 15 | noAccount: "Don't have an account?", 16 | haveAccount: 'Already have an account?', 17 | login: 'Sign In', 18 | logout: 'Logout', 19 | register: 'Create Account', 20 | continue: 'Continue', 21 | forgotPasswordSended: 22 | 'Great, we shot you an email! Please check your inbox and click the confirmation link.' 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /packages/nuxt-localization/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@awes-io/nuxt-localization", 3 | "version": "0.7.10", 4 | "description": "Admin panel for editing translations.", 5 | "homepage": "https://www.awes.io", 6 | "bugs": { 7 | "url": "https://github.com/awes-io/client/issues" 8 | }, 9 | "keywords": [ 10 | "translations", 11 | "localization", 12 | "admin", 13 | "nuxt", 14 | "awes-io" 15 | ], 16 | "repository": { 17 | "type": "git", 18 | "url": "git@github.com:awes-io/client.git" 19 | }, 20 | "license": "MIT", 21 | "author": "Awescode GmbH (https://www.awescode.de)", 22 | "contributors": [ 23 | "illjah42 " 24 | ], 25 | "main": "src/index.js", 26 | "dependencies": { 27 | "@awes-io/ui": "^2.3.1", 28 | "rambdax": "^7.0.1" 29 | }, 30 | "gitHead": "ec175d6d8344f0189930163e96bb5626c4e1481d" 31 | } 32 | -------------------------------------------------------------------------------- /examples/admin/pages/fake-auth/_service.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 41 | -------------------------------------------------------------------------------- /examples/i18n/pages/index.vue: -------------------------------------------------------------------------------- 1 | 29 | 30 | 35 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/sync-alt.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/tabs-routing/nuxt.config.js: -------------------------------------------------------------------------------- 1 | export default { 2 | mode: 'spa', 3 | 4 | head: { 5 | title: process.env.npm_package_name || '', 6 | meta: [ 7 | { charset: 'utf-8' }, 8 | { 9 | name: 'viewport', 10 | content: 'width=device-width, initial-scale=1' 11 | }, 12 | { 13 | hid: 'description', 14 | name: 'description', 15 | content: process.env.npm_package_description || '' 16 | } 17 | ], 18 | link: [{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }] 19 | }, 20 | 21 | modules: ['@awes-io/ui/nuxt', 'nuxt-i18n'], 22 | 23 | pageTransition: { 24 | name: 'fade', 25 | mode: 'out-in' 26 | }, 27 | 28 | i18n: { 29 | vueI18n: { 30 | fallbackLocale: 'en' 31 | }, 32 | locales: [{ code: 'en', iso: 'en-US' }], 33 | defaultLocale: 'en' 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /packages/nuxt-auth/lang/ru.js: -------------------------------------------------------------------------------- 1 | export default { 2 | AwesIoAuth: { 3 | loginTitle: 'Вход в систему', 4 | registerTitle: 'Создать новый аккаунт', 5 | verifyTitle: 'Код подтверждения', 6 | forgotTitleEmail: 'Введите адрес электронной почты', 7 | forgotTitlePassword: 'Введите новый пароль', 8 | email: 'Емайл', 9 | fullName: 'Полное имя', 10 | company: 'Имя компании (не обязательно)', 11 | password: 'Пароль', 12 | passwordConfirm: 'Подтвердите пароль', 13 | rememberMe: 'Запомнить меня', 14 | forgotPassword: 'Сбросить пароль', 15 | noAccount: 'У Вас нет аккаунта?', 16 | haveAccount: 'Уже есть аккаунт?', 17 | login: 'Войти в систему', 18 | logout: 'Выйти', 19 | register: 'Регистрация', 20 | continue: 'Продолжить', 21 | forgotPasswordSended: 22 | 'На указанный адрес электронной почты отправлено письмо со ссылкой для сброса пароля.' 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-dashboard-progress.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: DashboardProgress сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwDashboardProgress /> component is used to render DashboardProgress - UI Vue component for Awes.io. 6 | title: DashboardProgress 7 | --- 8 | 9 | # AwDashboardProgress 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |hideCounter|If true - hide counter and description on small version|`Boolean`|`false`|-| 17 | |hidePercent|If true - hide percent value on chart on small version|`Boolean`|`false`|-| 18 | |emptyColor|-|`String`|`false`|#E8E9EB| 19 | |fillColor|-|`String`|`false`|#594FCF| 20 | 21 | 22 | 23 | 24 | ## MixIns 25 | 26 | 27 | |MixIn| 28 | |---| 29 | |dashboardMixin| 30 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /packages/ui/components/3_organisms/AwCalendar/_AwCalendarWeekdays.vue: -------------------------------------------------------------------------------- 1 | 38 | -------------------------------------------------------------------------------- /packages/dayjs/src/utils/options.js: -------------------------------------------------------------------------------- 1 | import { pathOr } from 'rambdax' 2 | import { normalizeStringFormat } from './string-format' 3 | import { normalizePlugins } from './plugins' 4 | import { extractLocales } from './locales' 5 | 6 | export const DEFAULT_OPTIONS = { 7 | stringFormat: { 8 | pattern: null, 9 | format: true 10 | }, 11 | plugins: ['dayjs/plugin/customParseFormat', 'dayjs/plugin/localizedFormat'] 12 | } 13 | 14 | export function normalizeOptions(globals, module) { 15 | const globalDayjsOptions = pathOr({}, 'awesIo.dayjs', globals) 16 | 17 | return { 18 | stringFormat: normalizeStringFormat( 19 | DEFAULT_OPTIONS, 20 | globalDayjsOptions, 21 | module 22 | ), 23 | plugins: normalizePlugins([ 24 | ...DEFAULT_OPTIONS.plugins, 25 | ...(globalDayjsOptions.plugins || []), 26 | ...(module.plugins || []) 27 | ]), 28 | locales: extractLocales(globals) 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /packages/nuxt-auth/lang/uk.js: -------------------------------------------------------------------------------- 1 | export default { 2 | AwesIoAuth: { 3 | loginTitle: 'Вхід в систему', 4 | registerTitle: 'Створити новий акаунт', 5 | verifyTitle: 'Код підтвердження', 6 | forgotTitleEmail: 'Введіть адресу електронної пошти', 7 | forgotTitlePassword: 'Введіть новий пароль', 8 | email: 'Емайл', 9 | fullName: "Повне ім'я", 10 | company: "Ім'я компанії (не обов'язково)", 11 | password: 'Пароль', 12 | passwordConfirm: 'Підтвердіть пароль', 13 | rememberMe: "Запам'ятати мене", 14 | forgotPassword: 'Скинути пароль', 15 | noAccount: 'У Вас немає облікового запису?', 16 | haveAccount: 'Вже є аккаунт?', 17 | login: 'Увійти в систему', 18 | logout: 'Вийти', 19 | register: 'Реєстрація', 20 | continue: 'Продовжити', 21 | forgotPasswordSended: 22 | 'На вказану адресу електронної пошти надісланий лист з посиланням для скидання пароля.' 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /packages/nuxt-i18n/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@awes-io/nuxt-i18n", 3 | "version": "0.4.4", 4 | "description": "Nuxt i18n module for loading translations from API endpoint", 5 | "homepage": "https://www.awes.io", 6 | "bugs": { 7 | "url": "https://github.com/awes-io/client/issues" 8 | }, 9 | "keywords": [ 10 | "translations", 11 | "i18n", 12 | "nuxt", 13 | "awes-io" 14 | ], 15 | "repository": { 16 | "type": "git", 17 | "url": "git@github.com:awes-io/client.git" 18 | }, 19 | "license": "MIT", 20 | "author": "Awescode GmbH (https://www.awescode.de)", 21 | "contributors": [ 22 | "illjah42 " 23 | ], 24 | "main": "src/index.js", 25 | "files": [ 26 | "src/utils/*", 27 | "src/template/*" 28 | ], 29 | "dependencies": { 30 | "axios": "^0.19.2", 31 | "nuxt-i18n": "^6.12.0", 32 | "rambdax": "^7.0.1" 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /packages/vue-mc/README.md: -------------------------------------------------------------------------------- 1 | # Awes.io Models and Collections abstract layer 2 | 3 | Based on [VueMC](https://vuemc.io/) 4 | 5 | ## Basic usage 6 | 7 | 1. Ensure you are using [@nuxtjs/axios](https://axios.nuxtjs.org/) in your project 8 | 2. Install the module `yarn add @awes-io/vue-mc` 9 | 3. Now you are ready to build models and collections 10 | 4. Import your `BaseModel` and `BaseCollection` from this package 11 | 12 | ```javascript 13 | import { BaseModel, BaseCollection } from '@awes-io/vue-mc' 14 | 15 | class Todo extends BaseModel { 16 | defaults() { 17 | return { 18 | id: null, 19 | done: true 20 | } 21 | } 22 | } 23 | 24 | class Todos extends BaseCollection { 25 | model() { 26 | return Todo 27 | } 28 | } 29 | 30 | export default Todos 31 | ``` 32 | 33 | ## Build for production 34 | 35 | ```bash 36 | $ yarn build 37 | ``` 38 | 39 | Ensure to write proper commit message according to [Git Commit convention](https://www.conventionalcommits.org/) 40 | -------------------------------------------------------------------------------- /examples/permissions/serverMiddleware/api.js: -------------------------------------------------------------------------------- 1 | import express from 'express' 2 | import { omit } from 'rambdax' 3 | import USERS from './users' 4 | 5 | const app = express() 6 | 7 | let USER 8 | 9 | app.post('/login', express.json(), (req, res) => { 10 | const { email, password } = req.body 11 | 12 | USER = USERS.find( 13 | user => user.email === email && user.password === password 14 | ) 15 | 16 | if (USER) { 17 | return res.json(USER) 18 | } 19 | 20 | res.status(422).json({ 21 | errors: { 22 | email: ['These credentials do not match our records.'] 23 | } 24 | }) 25 | }) 26 | 27 | app.post('/logout', (req, res) => { 28 | USER = null 29 | 30 | res.end() 31 | }) 32 | 33 | app.get('/me', (req, res) => { 34 | if (USER) { 35 | return res.json({ 36 | data: omit('password', USER) 37 | }) 38 | } 39 | 40 | res.status(401).end() 41 | }) 42 | 43 | export default { 44 | handler: app, 45 | path: '/api' 46 | } 47 | -------------------------------------------------------------------------------- /packages/nuxt-auth/lang/de.js: -------------------------------------------------------------------------------- 1 | export default { 2 | AwesIoAuth: { 3 | loginTitle: 'Anmelden!', 4 | registerTitle: 'Konto erstellen', 5 | verifyTitle: 'Verification code', 6 | forgotTitleEmail: 'E-Mail-Adresse', 7 | forgotTitlePassword: 'Neues Passwort eingeben', 8 | email: 'E-Mail', 9 | fullName: 'Vorname Nachname', 10 | company: 'Unternehmensnahme (Optional)', 11 | password: 'Passwort', 12 | passwordConfirm: 'Passwort nochmals eingeben', 13 | rememberMe: 'Angemeldet bleiben.', 14 | forgotPassword: 'Passwort zurücksetzen', 15 | noAccount: 'Sie haben kein Konto?', 16 | haveAccount: 'Hast du schon ein Konto?', 17 | login: 'Anmelden', 18 | logout: 'Abmelden', 19 | register: 'Registrieren', 20 | continue: 'Weiter', 21 | forgotPasswordSended: 22 | 'Eine E-Mail mit einem Link zum Zurücksetzen Ihres Kennworts wurde an die angegebene E-Mail-Adresse gesendet.' 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-toggler.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: Toggler сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwToggler /> component is used to render Toggler - UI Vue component for Awes.io. 6 | title: Toggler 7 | --- 8 | 9 | # AwToggler 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |show|Indicates if toggler is open or closed|`Boolean`|`false`|-| 17 | 18 | 19 | 20 | 21 | ## Events 22 | 23 | 24 | |Event Name|Description|Parameters| 25 | |---|---|---| 26 | |open|Fire when the toggler is opened|-| 27 | |close|Fire when the toggler is closed|-| 28 | 29 | 30 | 31 | 32 | ## Slots 33 | 34 | 35 | |Name|Description|Default Slot Content| 36 | |---|---|---| 37 | |default|Content passed to component|-| 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /commitlint.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | rules: { 3 | 'body-leading-blank': [1, 'always'], 4 | 'footer-leading-blank': [1, 'always'], 5 | 'header-max-length': [2, 'always', 72], 6 | 'scope-case': [2, 'always', 'lower-case'], 7 | 'subject-case': [ 8 | 2, 9 | 'never', 10 | ['sentence-case', 'start-case', 'pascal-case', 'upper-case'] 11 | ], 12 | 'subject-empty': [2, 'never'], 13 | 'subject-full-stop': [2, 'never', '.'], 14 | 'type-case': [2, 'always', 'lower-case'], 15 | 'type-empty': [2, 'never'], 16 | 'type-enum': [ 17 | 2, 18 | 'always', 19 | [ 20 | 'build', 21 | 'chore', 22 | 'docs', 23 | 'feat', 24 | 'fix', 25 | 'perf', 26 | 'refactor', 27 | 'revert', 28 | 'style', 29 | 'test' 30 | ] 31 | ] 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /packages/ui/components/1_atoms/AwAccordionFold.vue: -------------------------------------------------------------------------------- 1 | 14 | 15 | 43 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Dependencies 2 | node_modules 3 | jspm_packages 4 | 5 | # Only keep yarn.lock in the root 6 | package-lock.json 7 | */**/yarn.lock 8 | 9 | # Logs 10 | *.log 11 | 12 | # Packages 13 | packages/*/LICENSE 14 | 15 | # Distributions 16 | examples/*/LICENSE 17 | examples/easyweek 18 | 19 | # Other 20 | .nuxt* 21 | !.nuxtignore 22 | .cache 23 | 24 | # Dist folders 25 | dist 26 | 27 | # Temporary folders 28 | tmp 29 | 30 | # Junit reports 31 | reports 32 | 33 | # Coverage reports 34 | coverage 35 | *.lcov 36 | .nyc_output 37 | 38 | # VSCode 39 | .vscode 40 | 41 | # Intellij idea 42 | *.iml 43 | .idea 44 | 45 | # OSX 46 | .DS_Store 47 | .AppleDouble 48 | .LSOverride 49 | 50 | # Files that might appear in the root of a volume 51 | .DocumentRevisions-V100 52 | .fseventsd 53 | .Spotlight-V100 54 | .TemporaryItems 55 | .Trashes 56 | .VolumeIcon.icns 57 | .com.apple.timemachine.donotpresent 58 | 59 | # Directories potentially created on remote AFP share 60 | .AppleDB 61 | .AppleDesktop 62 | Network Trash Folder 63 | Temporary Items 64 | .apdisk 65 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/question-square.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/page-headline.css: -------------------------------------------------------------------------------- 1 | .aw-page-headline { 2 | display: flex; 3 | align-items: center; 4 | @apply py-6; 5 | 6 | &__title { 7 | @apply py-1 font-heading; 8 | flex-grow: 1; 9 | display: flex; 10 | flex-wrap: wrap; 11 | align-items: center; 12 | font-size: theme('fontSize.2xl'); 13 | 14 | svg { 15 | @apply mr-3; 16 | flex-shrink: 0; 17 | } 18 | } 19 | 20 | &__title ~ * { 21 | flex-shrink: 0; 22 | } 23 | 24 | &__back { 25 | display: inline-flex; 26 | align-items: center; 27 | @apply text-accent; 28 | transition: 120ms color; 29 | 30 | &:hover, 31 | &:focus-visible { 32 | @apply text-link; 33 | text-decoration: none; 34 | } 35 | 36 | &:focus:not(:focus-visible) { 37 | outline: none; 38 | } 39 | } 40 | 41 | &__heading { 42 | @apply text-2xl; 43 | margin: 0; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-content-wrapper.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: ContentWrapper сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwContentWrapper /> component is used to render ContentWrapper - UI Vue component for Awes.io. 6 | title: ContentWrapper 7 | --- 8 | 9 | # AwContentWrapper 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |tag|The tag of parent node|`String`|`false`|div| 17 | |url|POST request url for fetching data from a server|`String`|`true`|-| 18 | 19 | 20 | 21 | 22 | ## Slots 23 | 24 | 25 | |Name|Description|Default Slot Content| 26 | |---|---|---| 27 | |default|any external component|-| 28 | 29 | 30 | 31 | 32 | ## MixIns 33 | 34 | 35 | |MixIn| 36 | |---| 37 | |WatchParams| 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-page.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: Page сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwPage /> general container for internal pages in Awes.io. 6 | title: Page 7 | --- 8 | 9 | # AwPage 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |title|Main headline on the page|`String`|`false`|-| 17 | |titleTag|-|`String`|`false`|-| 18 | |className|-|`String`|`false`|-| 19 | |subnav|Subnavigation for the page|`Array`|`false`|[]| 20 | |breadcrumb|Breadcrumb object with title and href to return back|`Object`|`false`|-| 21 | 22 | 23 | 24 | ## Slots 25 | 26 | 27 | |Name|Description|Default Slot Content| 28 | |---|---|---| 29 | |breadcrumb|Breadcrumb link back to catalog|if prop breadctumb is empty, block is empty too| 30 | |title|Title of the page|Empty string| 31 | |buttons|-|-| 32 | |subnav|-|-| 33 | |default|-|-| 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /packages/nuxt-admin/commitlint.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | rules: { 3 | 'body-leading-blank': [1, 'always'], 4 | 'footer-leading-blank': [1, 'always'], 5 | 'header-max-length': [2, 'always', 72], 6 | 'scope-case': [2, 'always', 'lower-case'], 7 | 'subject-case': [ 8 | 2, 9 | 'never', 10 | ['sentence-case', 'start-case', 'pascal-case', 'upper-case'] 11 | ], 12 | 'subject-empty': [2, 'never'], 13 | 'subject-full-stop': [2, 'never', '.'], 14 | 'type-case': [2, 'always', 'lower-case'], 15 | 'type-empty': [2, 'never'], 16 | 'type-enum': [ 17 | 2, 18 | 'always', 19 | [ 20 | 'build', 21 | 'chore', 22 | 'docs', 23 | 'feat', 24 | 'fix', 25 | 'perf', 26 | 'refactor', 27 | 'revert', 28 | 'style', 29 | 'test' 30 | ] 31 | ] 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /packages/nuxt-auth/commitlint.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | rules: { 3 | 'body-leading-blank': [1, 'always'], 4 | 'footer-leading-blank': [1, 'always'], 5 | 'header-max-length': [2, 'always', 72], 6 | 'scope-case': [2, 'always', 'lower-case'], 7 | 'subject-case': [ 8 | 2, 9 | 'never', 10 | ['sentence-case', 'start-case', 'pascal-case', 'upper-case'] 11 | ], 12 | 'subject-empty': [2, 'never'], 13 | 'subject-full-stop': [2, 'never', '.'], 14 | 'type-case': [2, 'always', 'lower-case'], 15 | 'type-empty': [2, 'never'], 16 | 'type-enum': [ 17 | 2, 18 | 'always', 19 | [ 20 | 'build', 21 | 'chore', 22 | 'docs', 23 | 'feat', 24 | 'fix', 25 | 'perf', 26 | 'refactor', 27 | 'revert', 28 | 'style', 29 | 'test' 30 | ] 31 | ] 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /packages/nuxt-localization/src/pages/Localization.vue: -------------------------------------------------------------------------------- 1 | 24 | 25 | 38 | -------------------------------------------------------------------------------- /packages/nuxt-profile/commitlint.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | rules: { 3 | 'body-leading-blank': [1, 'always'], 4 | 'footer-leading-blank': [1, 'always'], 5 | 'header-max-length': [2, 'always', 72], 6 | 'scope-case': [2, 'always', 'lower-case'], 7 | 'subject-case': [ 8 | 2, 9 | 'never', 10 | ['sentence-case', 'start-case', 'pascal-case', 'upper-case'] 11 | ], 12 | 'subject-empty': [2, 'never'], 13 | 'subject-full-stop': [2, 'never', '.'], 14 | 'type-case': [2, 'always', 'lower-case'], 15 | 'type-empty': [2, 'never'], 16 | 'type-enum': [ 17 | 2, 18 | 'always', 19 | [ 20 | 'build', 21 | 'chore', 22 | 'docs', 23 | 'feat', 24 | 'fix', 25 | 'perf', 26 | 'refactor', 27 | 'revert', 28 | 'style', 29 | 'test' 30 | ] 31 | ] 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /packages/ui/nuxt/templates/screen.plugin.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import { pathOr, fromPairs } from 'rambdax' 3 | 4 | const screens = JSON.parse('<%= JSON.stringify(options.screens) %>') 5 | 6 | const matchers = Object.keys(screens).map((name) => { 7 | const item = screens[name] 8 | let media = item.raw 9 | 10 | if (!media) { 11 | const min = pathOr(item, 'min', item) 12 | const max = pathOr(null, 'max', item) 13 | 14 | media = max 15 | ? `(min-width: ${min} and max-width: ${max})` 16 | : `(min-width: ${min})` 17 | } 18 | 19 | return { name, matcher: window.matchMedia(media) } 20 | }) 21 | 22 | const $screen = new Vue.observable({ 23 | ...fromPairs(matchers.map((m) => [m.name, m.matcher.matches])) 24 | }) 25 | 26 | for (const i in matchers) { 27 | matchers[i].matcher.addListener((e) => { 28 | $screen[matchers[i].name] = e.matches 29 | }) 30 | } 31 | 32 | Vue.prototype.$screen = $screen 33 | 34 | export default (ctx, inject) => { 35 | inject('screen', $screen) 36 | } 37 | -------------------------------------------------------------------------------- /packages/nuxt-auth/src/pages/LoginOAuth.vue: -------------------------------------------------------------------------------- 1 | 38 | -------------------------------------------------------------------------------- /packages/ui/components/4_pages/_AwPageButtons.vue: -------------------------------------------------------------------------------- 1 | 19 | 20 | 43 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/hand-holding-usd.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/components/5_layouts/AwLayoutScreen.vue: -------------------------------------------------------------------------------- 1 | 24 | 25 | 36 | -------------------------------------------------------------------------------- /packages/nuxt-profile/lang/en.js: -------------------------------------------------------------------------------- 1 | export default { 2 | AwesIoProfile: { 3 | title: 'Settings', 4 | profileTab: 'Profile', 5 | securityTab: 'Security', 6 | update: 'Update', 7 | changeAvatar: 'Change', 8 | removeAvatar: 'Remove', 9 | changePassword: 'Change password', 10 | oldPassword: 'Old password', 11 | newPassword: 'New password', 12 | passwordConfirm: 'Confirm password', 13 | submitPassword: 'Save', 14 | twoFactorAuth: 'Two-factor authentication', 15 | phone: 'Please enter your phone', 16 | enable: 'Enable', 17 | verifyToken: 'Please enter authorization token', 18 | showInfo: 'Activation info', 19 | disable: 'Disable', 20 | infoTitle: 'Scan QR Code', 21 | infoText: 22 | 'To enable the method please to scan the QR code using the Google Authenticator', 23 | infoInstall: 24 | 'If you do not have Google Authenticator, you can easily install it by clicking on the link below', 25 | loading: 'Loading...' 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /packages/vue-mc/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@awes-io/vue-mc", 3 | "version": "0.3.3", 4 | "description": "Models and collections abstract layer.", 5 | "homepage": "https://www.awes.io", 6 | "bugs": { 7 | "url": "https://github.com/awes-io/client/issues" 8 | }, 9 | "repository": { 10 | "type": "git", 11 | "url": "git@github.com:awes-io/client.git" 12 | }, 13 | "license": "MIT", 14 | "author": "Awescode GmbH (https://www.awescode.de)", 15 | "contributors": [ 16 | "illjah42 " 17 | ], 18 | "main": "dist/index.js", 19 | "module": "dist/index.esm.js", 20 | "scripts": { 21 | "build": "rollup -c" 22 | }, 23 | "dependencies": { 24 | "rambdax": "^7.0.1", 25 | "vue-mc": "^0.6.0" 26 | }, 27 | "devDependencies": { 28 | "@babel/core": "^7.8.4", 29 | "@babel/preset-env": "^7.8.4", 30 | "rollup": "^1.30.1", 31 | "rollup-plugin-babel": "^4.3.3" 32 | }, 33 | "gitHead": "291b901b106c2699ccb31ec7eb746ccba47bb864" 34 | } 35 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/analytics.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/permissions/nuxt.config.js: -------------------------------------------------------------------------------- 1 | export default { 2 | mode: 'spa', 3 | 4 | head: { 5 | title: process.env.npm_package_name || '', 6 | meta: [ 7 | { charset: 'utf-8' }, 8 | { 9 | name: 'viewport', 10 | content: 'width=device-width, initial-scale=1' 11 | }, 12 | { 13 | hid: 'description', 14 | name: 'description', 15 | content: process.env.npm_package_description || '' 16 | } 17 | ], 18 | link: [{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }] 19 | }, 20 | 21 | i18n: { 22 | defaultLocale: 'en', 23 | locales: [ 24 | { 25 | code: 'en', 26 | iso: 'en-US' 27 | } 28 | ] 29 | }, 30 | 31 | modules: [ 32 | '@nuxtjs/axios', 33 | '@awes-io/ui/nuxt', 34 | '@awes-io/nuxt-auth', 35 | 'nuxt-i18n' 36 | ], 37 | 38 | plugins: ['~/plugins/menu'], 39 | 40 | serverMiddleware: ['~/serverMiddleware/api'] 41 | } 42 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/page-buttons.css: -------------------------------------------------------------------------------- 1 | .aw-page-buttons { 2 | &--stacked { 3 | display: flex; 4 | gap: theme('spacing.4', 1rem); 5 | } 6 | 7 | &--fixed { 8 | position: fixed; 9 | right: theme('spacing.4', 1rem); 10 | bottom: var(--page-buttons-bottom, theme('spacing.4', 1rem)); 11 | z-index: 2; 12 | } 13 | 14 | &__aw-context-menu { 15 | 16 | & > .aw-button { 17 | border-radius: 50%; 18 | background: var(--c-mono-700); 19 | color: var(--c-on-mono-700); 20 | /* box-shadow: theme('boxShadow.default'); */ 21 | } 22 | 23 | & > .aw-dropdown { 24 | background: none; 25 | box-shadow: none; 26 | min-width: 0; 27 | 28 | .aw-cm-item { 29 | display: flex; 30 | justify-content: flex-end; 31 | } 32 | } 33 | 34 | .aw-context-menu__list { 35 | display: flex; 36 | flex-direction: column; 37 | gap-y: theme('spacing.2', 0.5rem); 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /packages/ui/components/1_atoms/AwIcon/AwIcon.vue: -------------------------------------------------------------------------------- 1 | 44 | -------------------------------------------------------------------------------- /examples/dayjs/pages/index.vue: -------------------------------------------------------------------------------- 1 | 31 | 32 | 37 | -------------------------------------------------------------------------------- /packages/ui/assets/css/main.css: -------------------------------------------------------------------------------- 1 | /** 2 | * Tailwind reset and base styles 3 | */ 4 | /* @import 'tailwindcss/base'; */ 5 | 6 | @import '@awes-io/ui/assets/css/base'; 7 | @import '@awes-io/ui/assets/css/typography'; 8 | 9 | /** 10 | * Tailwind components 11 | */ 12 | @import 'tailwindcss/components'; 13 | 14 | /** 15 | * Awes UI components 16 | */ 17 | @import './components/_index.css'; 18 | 19 | /** 20 | * Comma helpers 21 | */ 22 | @import './additional/_index.css'; 23 | 24 | /** 25 | * Tailwind utilities, MUST be last 26 | */ 27 | @import 'tailwindcss/utilities'; 28 | 29 | /** 30 | * Prism highlight 31 | */ 32 | @import 'prismjs/themes/prism.css'; 33 | [data-dark="true"] { 34 | pre[class*="language-"] { 35 | background-color: theme('darkTheme.colors.surface'); 36 | } 37 | code[class*="language-"] { 38 | color: theme('darkTheme.onColors.surface'); 39 | text-shadow: 0 1px theme('darkTheme.colors.mono-500'); 40 | } 41 | } 42 | pre[class*="language-"] { 43 | margin-top: 0; 44 | margin-bottom: 0; 45 | } 46 | 47 | /* Reset styles */ 48 | .content i { 49 | font-style: normal; 50 | } 51 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-dashboard-card.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: DashboardCard сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwDashboardCard /> component is used to render DashboardCard - UI Vue component for Awes.io. 6 | title: DashboardCard 7 | --- 8 | 9 | # AwDashboardCard 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |color|Color of left border and backgrond|`String`|`false`|info| 17 | |title|-|`String`|`false`|-| 18 | |number|-|`String`|`false`|-| 19 | |description|-|`String`|`false`|-| 20 | |footer|-|`String`|`false`|-| 21 | |icon|Icon to diplay inside toggle button|`String`|`false`|graph-alt| 22 | |hideButton|if true hides toggle button for hidden content|`Boolean`|`false`|-| 23 | 24 | 25 | 26 | 27 | ## Slots 28 | 29 | 30 | |Name|Description|Default Slot Content| 31 | |---|---|---| 32 | |default|Default slot|-| 33 | |content|Slot for hidden content|-| 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /packages/nuxt-profile/lang/ru.js: -------------------------------------------------------------------------------- 1 | export default { 2 | AwesIoProfile: { 3 | title: 'Настройки', 4 | profileTab: 'Профиль', 5 | securityTab: 'Безопасность', 6 | update: 'Обновить', 7 | changeAvatar: 'Изменить', 8 | removeAvatar: 'Удалить', 9 | changePassword: 'Изменить пароль', 10 | oldPassword: 'Старый пароль', 11 | newPassword: 'Новый пароль', 12 | passwordConfirm: 'Подтвердить пароль', 13 | submitPassword: 'Сохранить', 14 | twoFactorAuth: 'Двухфакторная аутентификация', 15 | phone: 'Пожалуйста, введите свой телефон', 16 | enable: 'Активировать', 17 | verifyToken: 'Пожалуйста, введите код авторизации', 18 | showInfo: 'Информация об активации', 19 | disable: 'Отключить', 20 | infoTitle: 'Сканировать QR-код', 21 | infoText: 22 | 'Чтобы включить метод, просканируйте QR-код с помощью Google Authenticator.', 23 | infoInstall: 24 | 'Если у вас нет Google Authenticator, вы можете легко установить его, нажав на ссылку ниже.', 25 | loading: 'Загрузка...' 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /packages/nuxt-profile/lang/uk.js: -------------------------------------------------------------------------------- 1 | export default { 2 | AwesIoProfile: { 3 | title: 'Налаштування', 4 | profileTab: 'Профіль', 5 | securityTab: 'Безпека', 6 | update: 'Оновити', 7 | changeAvatar: 'Змінити', 8 | removeAvatar: 'Видалити', 9 | changePassword: 'Змінити пароль', 10 | oldPassword: 'Старий пароль', 11 | newPassword: 'Новий пароль', 12 | passwordConfirm: 'Підтвердити пароль', 13 | submitPassword: 'Зберегти', 14 | twoFactorAuth: 'Двухфакторная аутентифікація', 15 | phone: 'Будь ласка, введіть код авторизації', 16 | enable: 'Активувати', 17 | verifyToken: 'Будь ласка, введіть код авторизації', 18 | showInfo: 'Інформація про активацію', 19 | disable: 'Відключити', 20 | infoTitle: 'Сканувати QR-код', 21 | infoText: 22 | 'Щоб включити метод, проскануйте QR-код за допомогою Google Authenticator.', 23 | infoInstall: 24 | 'Якщо у вас немає Google Authenticator, ви можете легко встановити його, натиснувши на посилання нижче.', 25 | loading: 'Завантаження...' 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /examples/admin/assets/sprite/svg/engine-warning.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/engine-warning.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/ui/mixins/watch-params.js: -------------------------------------------------------------------------------- 1 | export default { 2 | props: { 3 | watchParams: { 4 | type: Array, 5 | default: null 6 | } 7 | }, 8 | 9 | methods: { 10 | _fetchFromWatcher() {}, 11 | fetchQuery() { 12 | const params = {} 13 | 14 | if (this.watchParams) { 15 | this.watchParams.forEach((name) => { 16 | const value = this.$route.query[name] 17 | if (value) { 18 | params[name] = value 19 | } 20 | }) 21 | } 22 | 23 | return params 24 | } 25 | }, 26 | 27 | created() { 28 | if (this.watchParams) { 29 | const unwatcher = this.$watch(() => { 30 | const vars = this.watchParams.map((param) => { 31 | return this.$route.query[param] 32 | }) 33 | return vars.join(', ') 34 | }, this._fetchFromWatcher) 35 | 36 | this.$once('hook:beforeDestroy', () => { 37 | unwatcher() 38 | }) 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /packages/ui/docs/aw-chip-select.md: -------------------------------------------------------------------------------- 1 | --- 2 | metaTitle: ChipSelect сomponent | Awes.io 3 | meta: 4 | - name: description 5 | content: The <AwChipSelect /> component is used to render ChipSelect - UI Vue component for Awes.io. 6 | title: ChipSelect 7 | --- 8 | # AwChipSelect 9 | 10 | 11 | ## Props 12 | 13 | 14 | |Name|Description|Type|Required|Default| 15 | |---|---|---|---|---| 16 | |value|-|`Number`|`true`|-| 17 | |options|-|`Array`|`true`|-| 18 | |readonly|-|`Boolean`|`false`|-| 19 | |noText|-|`Boolean`|`false`|-| 20 | |loading|-|`Boolean`|`false`|-| 21 | |disabled|-|`Boolean`|`false`|-| 22 | |filled|-|`Boolean`|`false`|-| 23 | 24 | 25 | 26 | 27 | ## Events 28 | 29 | 30 | |Event Name|Description|Parameters| 31 | |---|---|---| 32 | |input|-|-| 33 | 34 | 35 | 36 | 37 | 38 | ## Slots 39 | 40 | |Name|Description|Default Slot Content| 41 | |---|---|---| 42 | |selected|-|-| 43 | |option|-|-| 44 | 45 | 46 | -------------------------------------------------------------------------------- /packages/ui/nuxt/awes.config.js: -------------------------------------------------------------------------------- 1 | import styles from '../assets/js/styles' 2 | 3 | export default { 4 | logo: { 5 | src: 'https://static.awes.io/logo-blue_white.svg', 6 | alt: 'Awes.io' 7 | }, 8 | 9 | background: { 10 | src: 'https://static.awes.io/demo/awes-background.svg' 11 | }, 12 | 13 | googleFont: 14 | 'https://fonts.googleapis.com/css?family=Roboto:400,700|Ubuntu:400,500&display=swap', 15 | 16 | style: styles.default 17 | } 18 | 19 | export const dark = { 20 | logo: { 21 | src: 'https://static.awes.io/logo-blue.svg', 22 | alt: 'Awes.io' 23 | }, 24 | 25 | background: { 26 | src: 'https://static.awes.io/demo/awes-background.svg' 27 | }, 28 | 29 | style: styles.dark 30 | } 31 | 32 | export const lang = { 33 | locales: ['en'], 34 | locale: 'en', 35 | silentTranslationWarn: true, 36 | silentFallbackWarn: true, 37 | // own props 38 | fetchTranslation: false, 39 | langCookie: 'i18n_redirected' 40 | } 41 | 42 | export const dayjs = { 43 | stringFormat: { 44 | pattern: null, 45 | format: true 46 | }, 47 | plugins: [] 48 | } 49 | -------------------------------------------------------------------------------- /packages/ui/assets/css/components/user-menu.css: -------------------------------------------------------------------------------- 1 | .aw-user-menu { 2 | position: relative; 3 | font-size: theme('fontSize.sm', 0.875rem); 4 | 5 | &__user { 6 | cursor: pointer; 7 | } 8 | 9 | &__header { 10 | padding: theme('spacing.5', 1,25rem); 11 | border-bottom-width: 1px; 12 | } 13 | 14 | &__theme-switcher { 15 | padding: theme('spacing.3', 0,75rem) theme('spacing.5', 1,25rem); 16 | border-bottom-width: 1px; 17 | } 18 | 19 | &__menu { 20 | background-color: var(--c-surface); 21 | color: var(--c-on-surface); 22 | min-width: 250px; 23 | max-height: auto; 24 | box-shadow: theme('boxShadow.default'); 25 | border-radius: theme('borderRadius.md'); 26 | } 27 | 28 | &__nav-item { 29 | @apply bg-surface; 30 | padding: theme('spacing.3', 0,75rem) theme('spacing.5', 1,25rem); 31 | display: block; 32 | width: 100%; 33 | 34 | &:focus { 35 | outline: none; 36 | } 37 | 38 | &:hover, 39 | &:focus-visible { 40 | background-color: var(--c-mono-900); 41 | } 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/cash-register.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/clipboard-list-check.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/hotel.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /examples/basic-ui/assets/sprite/svg/duotone/cog.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /packages/nuxt-auth/src/assets/js/strategy.js: -------------------------------------------------------------------------------- 1 | import { pathOr } from 'rambdax' 2 | import Local from '@nuxtjs/auth/lib/schemes/local' 3 | 4 | export default class extends Local { 5 | mounted() { 6 | if (this.options.tokenRequired) { 7 | const token = this.$auth.syncToken(this.name) 8 | this._setToken(token) 9 | } 10 | 11 | return this.$auth 12 | .fetchUserOnce() 13 | .then(res => res) 14 | .catch(this._handleTwoFactorError) 15 | } 16 | 17 | async login(endpoint) { 18 | try { 19 | await super.login(endpoint) 20 | } catch (error) { 21 | this._handleTwoFactorError(error) 22 | } 23 | } 24 | 25 | _handleTwoFactorError(error) { 26 | const status = pathOr(500, 'response.status', error) 27 | // const token = pathOr(false, 'response.data.meta.token', error) 28 | 29 | if (status === 403 /* && token */) { 30 | // this.$auth.setToken(this.name, token) 31 | // this._setToken(token) 32 | this.$auth.ctx.redirect('/twofactor-verify') 33 | } else { 34 | throw error 35 | } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /packages/nuxt-profile/lang/de.js: -------------------------------------------------------------------------------- 1 | export default { 2 | AwesIoProfile: { 3 | title: 'Einstellungen', 4 | profileTab: 'Profil', 5 | securityTab: 'Sicherheit', 6 | update: 'Aktualisieren', 7 | changeAvatar: 'Änderung', 8 | removeAvatar: 'Löschen', 9 | changePassword: 'Passwort ändern', 10 | oldPassword: 'Altes Passwort', 11 | newPassword: 'Neues Passwort', 12 | passwordConfirm: 'Passwort bestätigen', 13 | submitPassword: 'Speichern', 14 | twoFactorAuth: 'Zwei-Faktor-Authentifizierung', 15 | phone: 'Bitte geben Sie Ihre Telefonnummer ein', 16 | enable: 'Aktivieren', 17 | verifyToken: 'Bitte Autorisierungstoken eingeben', 18 | showInfo: 'Aktivierungsinfo', 19 | disable: 'Deaktivieren', 20 | infoTitle: 'QR Code scannen', 21 | infoText: 22 | 'Um die Methode zu aktivieren, scannen Sie bitte den QR-Code mit dem Google Authenticator.', 23 | infoInstall: 24 | 'Wenn Sie nicht über Google Authenticator verfügen, können Sie es einfach installieren, indem Sie auf den unten stehenden Link klicken.', 25 | loading: 'Laden...' 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /packages/ui/components/3_organisms/AwCalendar/AwCalendarView.vue: -------------------------------------------------------------------------------- 1 | 17 | 18 | 44 | --------------------------------------------------------------------------------