Git Product home page Git Product logo

orgenic-ui's Introduction

travis status npm version

ORGENIC UI

Getting Started

With these instructions you will get ORGENIC UI integrated in your project.

Installing

npm i @orgenic/orgenic-ui

Angular

Integrate ORGENIC UI in your angular application

main.ts

import { enableProdMode } from '@angular/core';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';

import { AppModule } from './app/app.module';
import { environment } from './environments/environment';

// add line: import orgenic ui loader
import { defineCustomElements } from '@orgenic/orgenic-ui/dist/loader';

if (environment.production) {
  enableProdMode();
}

platformBrowserDynamic().bootstrapModule(AppModule)
  .catch(err => console.error(err));

// add line: register custom elements
defineCustomElements(window);

app/app.module.ts

// ...
// add line: import custom elements schema
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';

@NgModule({
    declarations: [
        // ...
    imports: [
        // ...
    ],
    providers: [
        // ...
    ],
    bootstrap: [AppComponent],
// add line: add custom elements schema to NgModule
    schemas: [CUSTOM_ELEMENTS_SCHEMA]
})
export class AppModule { }

React

Integrate ORGENIC UI in your react application

src/index.js

import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import App from './App';
import * as serviceWorker from './serviceWorker';
// add line: import orgenic ui loader
import { defineCustomElements } from '@orgenic/orgenic-ui/dist/loader';

ReactDOM.render(<App />, document.getElementById('root'));

// add line: register custom elements
defineCustomElements(window);

serviceWorker.unregister();

Vue

Integrate ORGENIC UI in your vue application

src/main.js

import Vue from 'vue';

// ...

// add line: import orgenic ui loader
import { defineCustomElements } from '@orgenic/orgenic-ui/dist/loader';

// add line: register custom elements
defineCustomElements(window);

Vue.config.productionTip = false;
// add line: configure vue to ignore orgenic-ui components
Vue.config.ignoredElements = [/og-\w*/];

const router = new VueRouter({
    // ...
})

Vue.use(VueRouter);

new Vue({
    el: '#app',
    router,
    render: (h) => h(App)
});

Vanilla JS

Integrating ORGENIC-UI in a plain JS application.

index.html

<!DOCTYPE html>
<html>
    <head>
        <link rel="stylesheet" type="text/css" href="orgenic-ui/dist/themes/dark.theme.css" />
        <script src="orgenic-ui/dist/orgenic-ui.js"></script>
        <style>
            body {
                font-family: Roboto;
            }
        </style>
    </head>
    <body class="og-theme--dark">
        <og-card name="Hello ORGENIC-UI">
            <div slot="content">
                <og-button label="Default Button"></og-button>
            </div>
        </og-card>
    </body>
</html>

Documentation

Find the full documentation of ORGENIC UI at https://docs.orgenic.org.

Versioning

We use Semantic Versioning.

License

This project is licensed under the MIT License - see the LICENSE file for details.

orgenic-ui's People

Contributors

andi-d avatar christianotto avatar cr45hcode avatar demkani avatar dependabot[bot] avatar jfu-maximago avatar m4cx avatar orgenic-team avatar pmoule avatar tikri avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

orgenic-ui's Issues

Missing moment package

Describe the bug
The following error occurs when running an angular app which is using orgenic-ui:

ERROR in node_modules/@orgenic/orgenic-ui/dist/types/components/og-internal-calendar/interfaces/og-calendar-date-decorator.d.ts(1,24): error TS2307: Cannot find module 'moment'.

moving the moment from devDependencies to dependencies in package.json should fix that error.

To Reproduce

  1. ng new my-angular-app
  2. cd my-angular-app
  3. npm i @orgenic/orgenic-ui
  4. include orgenic-ui in main.ts like stated in the docs
  5. ng serve

Expected behavior
app should compile

Screenshots
Screenshot_20190622_004342

Desktop (please complete the following information):

  • OS: Arch Linux

Linting stage errors

Describe the bug
Everytime i use an orgenic-ui button, i get linting errors in the build pipeline and in my Webstorm IDE, which is fairly annoying, because i have to use @ts-ignore. Which is of course not a great workaround.
So is there a config, where i can tell my IDE and the GitLab CI how to properly lint the og-button?
Errors like this:

Warning:(36, 8) Unknown html tag og-button
Error:(40, 9) Event clicked is not emitted by any applicable directives nor by og-button element

Steps to reproduce the behavior

  1. Implement an Orgenic-UI Button e.g.
      <og-button
        i18n-label="@@web.contact.button"
        class="button"
        label="Jetzt kontaktieren"
        (clicked)="send()"
      ></og-button>
  1. See linting errors in Webstorm

Expected behavior
As the code compiles and works just fine, the linting error is just annoying, but the code is not fundamentally broken. So i would expect to not see any linting errors for the og-button if used properly.

Screenshots
image

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser: Chrome
  • IDE: WebStorm

Data Table sorting

Make the sorted column in a DataTable more visible, e.g. highlighting it with a special color.

og-card: header should be hidden when neither title is nor the header slot is set

Describe the bug
when neither the name property, nor the header slot is set, the space is nevertheless occupied with empty space

To Reproduce
Steps to reproduce the behavior:

  1. Create an og-card instance without the name attribute or header slot
  2. Open in the browser
  3. See error

Expected behavior
As before, the card should not reserve space for the header.

Screenshots
57610531-4459c980-7571-11e9-9983-ae4c87d6d739

Desktop (please complete the following information):

  • OS: all
  • Browser: all
  • Version: all

Smartphone (please complete the following information):

  • Device: all
  • OS: all
  • Browser: all
  • Version all

Navigate through months and years in Datepicker

Is your feature request related to a problem? Please describe.

When for example using this control for a field entering the date of birth or other information way back in the past or due dates in the far future. You have to step through each month using the arrow buttons.

Describe the solution you'd like
By clicking on the year or the month an aditional selection view could be displayed.
image
image
image

For further information you can look into the handling in https://material.angular.io/components/datepicker/overview

Describe alternatives you've considered
Directly entering the value is also a solution I thought about. But using a neat ui is quite appealing.

Handle TabContainer Overflow

What happens when a TabContainer holds more elements, than displayable?
Should we display scrollbuttons, a "more"-button, or linebreaking?
Maybe all of them and provide an option for choosing between the solutions?

og-card: complete header text on hover

Is your feature request related to a problem? Please describe.
when the text ist too long, it gets shortened with ellipses and you can't see the whole title.

Describe the solution you'd like
it would be nice if the text gets shown on hovering over it

rgb-Selector

Design and implement a rgb-selector component, which lets users pick a color from a color-map and provides an input field with the corresponding rgb hex value.

Later: Let the user choose which type of output should be generated (rgb/rgba/cmyk/etc).

Calendar component

Is your feature request related to a problem? Please describe.
Why isn't calendar built in as a native input type?! Also, I haven't seen any date range pickers.

Describe the solution you'd like
I want a clean, extensible, responsive web-component calendar. It could be used to select single dates or date ranges. It could also be used to simply display information, but maybe that's getting too far into specific use-cases.

Describe alternatives you've considered
There are too many to name!

Additional context
Add any other context or screenshots about the feature request here.

Screen Shot 2019-05-07 at 12 28 34 PM

Screen Shot 2019-05-07 at 12 27 22 PM

Layout-Container Component

Design and implement an easy to use LayoutContainer, letting users manage the layout of their site and/or component content.

Card: Hide header when title is not set

Is your feature request related to a problem? Please describe.
I was trying to use the card component as a way to organize content, without the need for a title. Against my expectation, the title part of the component still was shown.

Describe the solution you'd like
As with the empty footer, don't take up space.

Additional context
empty-card-title

Placeholder text is shown behind date value.

Describe the bug
The placeholder text is not displayed on top of the entered value but is still shown as placeholder behind the entered value.

To Reproduce
Steps to reproduce the behavior:

  1. Select a value through the flyout.
  2. Click on the datepicker again to reopen the flyout.
  3. Close the flyout by clicking again on the control. NOT THE FLYOUT.
  4. See error (like described and shown in the picture)

Expected behavior
The placeholder text should be displayed on top of the entered value.

Screenshots

image

Desktop (please complete the following information):

  • OS: Windows
  • Browser Chrome
  • Version 74.0.3729.169

URL parameter for LinkButton

Add a URL parameter for Link Buttons, which should behave just like the href parameter of HTMLs default anchor tags.

Chart component

Design and implement chart components various chart types.
For example:
- Pie Charts
- Vertical Bar Charts
- Stacked Bar Charts
- Horizontal Bar Charts
- Histograms
- Line Charts
- Area Charts

Using v-model

Hello, I see you ad in the magazin and the docs looks great!

But I'm seeing you don't support v-model vor vue.js yet. Is it planning to support this feature?

If not i'll try to add this feature too and create than a pull request, but it can take a time.

Tag component

Design and implement a Tag component for displaying simple Tags (text surrounded by a small box)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.