Git Product home page Git Product logo

kopilio's Introduction

Introduction

Koplio is a simple clone of Trello, built entirely using vanilla Javascript and Web Components without external libraries. The API server used for the backend is a json-server that is watching a json file: db.json.

Some scripts are added to package.json to allow easy starting and running the application. See Installation for more information.

Installation

Basic Start

To start the server on a Mac, run npm start in your terminal console.

For other Operating Systems, see below:

  • Mac: npm run startMac
  • Windows: npm run startWindows
  • Linux: npm run startLinux
Serve on Network (with Web Server)

To serve the server on your machine, listening to 0.0.0.0, port 8000, run npm run serve in your terminal console. Note: Modify host.js to point to your API server if it is not running on http://localhost:3000

API Server on Network

To serve the json-server over network, run npm run startServer in your terminal console.

It will open the index.html file on your default browser, and start the json-server API server. Starting the server might take some time as it is scripted to use npx to download and run immediately so there will be some download time involved.

Features

Columns

Trello Columns within a board are implemented in a similar but simplified manner. Basic CRUD operations on the columns are supported.

Parameters of Columns:

  • title (required): Title of the column. Empty title will default to 'Untitled Column'

Supported Operations:

  • List all columns
  • Add/Create card column
  • Modify column
  • Delete column
Cards

Cards can be managed within columns. Basic CRUD operations on the cards as well as some extended operations are supported.

Parameters of Cards:

  • title (required): Title of the card. Empty title will default to 'Untitled Card'
  • description (optional): Multiline description of the card

Supported Operations:

  • List all cards
  • Add/Create new card
  • Modify card
  • Delete card
  • Move card to another column (Drag and Drop)
  • Search/Filter cards (based on title and description, case-insensitive)

Components

Container Label

The Title Label for Koplio

Container Searchbar

The Web component for the searchbar to search and filter cards.

Attributes

onSearchText:(text) => {}: Callback method triggered on textbox text change.

Card Container

The body for columns and cards. This container is horizontally scrollable with custom-styled scrollbar.

Attributes

columns:Array - Array of Container Column components.

Methods

search(text) - Search and Filter content within component

Container Column

A column container to store card data. This container has a width of 250px and expands vertically as more data are added to the container, allowing a seamless view on mobile.

Methods

search(text) - Search and Filter content within component

Column Adder

A temporary column used to add new columns.

Attributes

onAddColumn:(title) => {} - Callback method on column add

Column Data

Data column with card components inside.

Attributes

columnId:Number - Id of the column ondelete:() => {} - Callback method on column delete

Methods

search(text) - Search and Filter content within component

Column Data Title

Title Label for the column. This title comes from column.title.

Card Item

Component to display card information. This component allows click to expand for card data modification.

Attributes

card:Object - Card data as obtained by API, see Cards onsave:(card) => {} - Callback method on card information change save ondelete:(card) => {} - Callback method on card delete

Methods

searchOk(text) - Search and Filter card content (title and description) within component, case-insensitive

Card Item Adder

A temporary card used to add new cards

Attributes

onadd:(card) => {} - Callback method on card add

Data Structure

Columns

{
    id: Number,
    title: String
}

Cards

{
    id: Number,
    title: String,
    description: String,
    columnId: Number (key for Column object)
}

kopilio's People

Contributors

yhpoh91 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.