network-for-good / nfg_ui Goto Github PK
View Code? Open in Web Editor NEWNFG design system UI gem for powering front-end code.
License: MIT License
NFG design system UI gem for powering front-end code.
License: MIT License
After 0.9.13 release getting log output:
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/muted.rb:8: warning: already initialized constant NfgUi::Components::Traits::Muted::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/muted.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/active.rb:6: warning: already initialized constant NfgUi::Components::Traits::Active::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/active.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/alert.rb:8: warning: already initialized constant NfgUi::Components::Traits::Alert::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/alert.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/progress_bar.rb:6: warning: already initialized constant NfgUi::Components::Traits::ProgressBar::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/progress_bar.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/dropdown_toggle.rb:6: warning: already initialized constant NfgUi::Components::Traits::DropdownToggle::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/dropdown_toggle.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/button_group.rb:8: warning: already initialized constant NfgUi::Components::Traits::ButtonGroup::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/button_group.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/nav.rb:8: warning: already initialized constant NfgUi::Components::Traits::Nav::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/nav.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/step.rb:6: warning: already initialized constant NfgUi::Components::Traits::Step::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/step.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/dismiss.rb:8: warning: already initialized constant NfgUi::Components::Traits::Dismiss::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/dismiss.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/card.rb:8: warning: already initialized constant NfgUi::Components::Traits::Card::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/card.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/disable.rb:8: warning: already initialized constant NfgUi::Components::Traits::Disable::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/disable.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/pill.rb:6: warning: already initialized constant NfgUi::Components::Traits::Pill::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/pill.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/button.rb:8: warning: already initialized constant NfgUi::Components::Traits::Button::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/button.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/collapse.rb:8: warning: already initialized constant NfgUi::Components::Traits::Collapse::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/collapse.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/navbar.rb:8: warning: already initialized constant NfgUi::Components::Traits::Navbar::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/navbar.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/nav_item.rb:8: warning: already initialized constant NfgUi::Components::Traits::NavItem::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/nav_item.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/size.rb:6: warning: already initialized constant NfgUi::Components::Traits::Size::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/size.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/list_group.rb:8: warning: already initialized constant NfgUi::Components::Traits::ListGroup::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/list_group.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/illustration.rb:6: warning: already initialized constant NfgUi::Components::Traits::Illustration::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/illustration.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/remote.rb:6: warning: already initialized constant NfgUi::Components::Traits::Remote::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/remote.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/disable_with.rb:6: warning: already initialized constant NfgUi::Components::Traits::DisableWith::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/disable_with.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/slat_item.rb:6: warning: already initialized constant NfgUi::Components::Traits::SlatItem::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/slat_item.rb:6: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/typeface.rb:8: warning: already initialized constant NfgUi::Components::Traits::Typeface::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/typeface.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/alignment.rb:8: warning: already initialized constant NfgUi::Components::Traits::Alignment::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/alignment.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/page_header.rb:8: warning: already initialized constant NfgUi::Components::Traits::PageHeader::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/page_header.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/theme.rb:8: warning: already initialized constant NfgUi::Components::Traits::Theme::COLOR_TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/theme.rb:8: warning: previous definition of COLOR_TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/theme.rb:18: warning: already initialized constant NfgUi::Components::Traits::Theme::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/theme.rb:18: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/vertical.rb:8: warning: already initialized constant NfgUi::Components::Traits::Vertical::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/vertical.rb:8: warning: previous definition of TRAITS was here
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/icon.rb:8: warning: already initialized constant NfgUi::Components::Traits::Icon::TRAITS
/Users/jonathanroehm/.rvm/gems/ruby-2.3.7/gems/nfg_ui-0.9.13/lib/nfg_ui/components/traits/icon.rb:8: warning: previous definition of TRAITS was here
Issue: tooltips do not show up on a NavItem
(and NavStep
, inheriting from NavItem
) that have both :disabled
and :tooltip
options activated.
Bootstrap NavItem
docs: https://getbootstrap.com/docs/4.3/components/navs/#base-nav
Need to investigate that the disabled attributes are being placed on the nav-link and not the nav-item.
Ensure that the tooltip is added to the nav-item when disabled.
Figure out best way to ensure NavLink
(child of NavItem
) passes the correct options to NavLink
when NavItem
generates a NavLink
automatically.
Additional thoughts:
Situation:
It is not possible to dual-theme a :link
Button
component. Example:
<%= ui.nfg :button, :link, :danger, body: 'Delete' %>
Desired outcome:
A btn-link
theme button with a text-danger
theme class.
Currently, it defers to whichever theme comes last (:link, :danger
outputs a btn-danger
version of the button)
= ui.nfg :nav_link, href: destroy_user_session_path, data: { method: :delete } do
is the only solution for method: :delete
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.