Giter Site home page Giter Site logo

gradient-table's Introduction

gradient table

Working Demo

Working Demo on Firebase

Task description

Given an integer input N between decimal values 2 and 100, create a two-dimensional table of N x N size.

Table columns should be marked with capital letters of the English alphabet, much like in an Excel or Google Spreadsheet: letter “A” through “Z”, then “AA”, “AB”, etc. Table rows should be marked with the ordinal value representing the number of row, starting from 1.

A table cell should be filled with a single solid color representing a linear gradient color value calculated as follows:

  • The top left cell has a fixed RGB value of (255, 255, 255).
  • The bottom right cell has a fixed RGB value of (255, 0, 0).
  • Any other cell color should be calculated as a linear gradient value based on the cell’s distance from the top left and the bottom right anchor cells.

The user should be able to enter the N value into an input field, and create the corresponding table by pressing a button. N should be validated to match the following conditions: N is integer, 2 <= N <= 100.

The resulting table should reasonably fit the screen - if the screen is too small to display the characters in column or row headers, scrolling is permitted.

Other requirements

The task shall be implemented with Dart (version >= 2.0.0) programming language and Angular Dart (version >= 5.0.0) framework, as a web project.

The program shall behave identically in all modern browsers (last two versions of Chrome, Firefox and Safari + latest Edge).

Submitted code should adhere to Dart and Angular best practices and style guides.

The solution should be submitted as a public Github repository url.

Further possible development

  • Remove bootstrap.css and add custom css instead
  • Separate width and height inputs
  • Changeable color based on color picker input
  • Form instead on a single input
  • Routing
  • Landing page, header, navigation, etc.

Base App Info

A web app that uses AngularDart and AngularDart Components.

Created from templates made available by Stagehand under a BSD-style license.

gradient-table's People

Contributors

galcsaba avatar

Watchers

James Cloos avatar  avatar

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.