Git Product home page Git Product logo

admin-ui-components's People

Contributors

dependabot[bot] avatar dhartunian avatar koorosh avatar vladlos avatar

Stargazers

 avatar  avatar

Watchers

 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

admin-ui-components's Issues

Notifications Components :: Notification Message

Notification Message

notification-widget

notification-full

notification-active

The main repeating component in any listing context is the NotificationMessage component with can seem to adapt to a couple of display contexts. This may be a function of responsiveness or a display prop that is passed when notifications are rendered. This seems to be a purely presentational component that renders the data of a notification and may collect or house actions like opening a side bar or redirecting to a view in the admin ui or to docs. Whether or not we use the read / unread functionality, building in a prop for this purpose seems reasonable.

API (WIP)

<NotificationMessage
  key={string}
  title={string}
  description={string}
  docsLink={ReactNode}
  priority={Enum}
  read={boolean}
/>

Notifications Components :: NotificationsWidget

NotificationsWidget

Screen Shot 2020-07-22 at 16 21 50

The NotificationsWidget component will house a list of notifications (which will most likely be made of sub components) and some visual indications of the state of the unread notifications. In this way the widget's primary function will be the controller for unread/read state for notifications.

API (draft)

This component is going to be a connected a container component that will be self-contained in the application. Before that happens I guess this issue should define a presentational component that can be "connected" to a data store.

<NotificationsWidget 
  notifications={Array<Notification>}
  notificationsRead={Array<NotificationsIds>}
  markNotificationRead={Function}
  markAllNotificationsRead={Function}
  notificationCenterLink={ReactNode}
/>

Notifications Components :: NotificationsAnchor

NotificationsAnchor

Screen Shot 2020-07-22 at 16 19 14

repo: cockroachdb/admin-ui-components

API (rough draft)

<NotificationsAnchor
   unread={ Number }
   onActivate={ Function }
   onDeactivate={ Function}
   activateEvent={ "hover" | "click" | "focus" }
/>

The NotificationsAnchor component will be used as an anchor to the popover notifications widget while providing an indication of the number of unread messages as well as a visual indication of the widget being "open" or "closed".

Give the simplicity of this component and it's partnership with other component state, I think this component should be purely presentational and contain no state of its own. The API above is a rough guess at what the component might need to know. The activateEvent represents not having a final decision as to what events this component might respond to. For instance, will the widget open and close on hover and by clicking, the user will be taken to the Notification Center? Or will the widget be opened and closed by clicking, and the user will get to the Notification Center by interacting with individual Notifications? Time will tell.

On thing is clear, and that is that this component will display a number of unread notifications. For this prop, I have imagined it as a Number where if the number is greater than zero then a numeric pimple will be rendered. If the number is less than one, or null, or undefined, or NaN then a numeric indicator will not be rendered. The may also be an upper limit to the how large this numeric indicator could be, in which case the limit would probably be shown (something like "99+" if there were 127 notifications if the upper limit was 99)

ui: barChart is 50% filled for zero values

It is regression issue introduced in fc5ee71 when d3 package was replaced by d3-scale package.
d3-scale package contains following breaking change described here d3/d3-scale#117
Now, for closed domain range like [0. 0] the scaling result for 0 will be 50 instead of 0 (as was before).
This makes bar charts render half filled bars for zero values.

Can be reproduced on statements or transactions tables, retry column with no retries

Screen Shot 2020-11-20 at 4 59 46 PM 1

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.