Code Monkey home page Code Monkey logo

bedrock's Introduction

Bedrock

Welcome to Bedrock.

Bedrock Release

Bedrock is a powerful tool that lets you prototype complex web applications and document design systems.

For the full documentation, please check out the Bedrock website.

Demo

See https://bedrock-monocompany.vercel.app/ . Try to hit Ctrl + M to see the page tree; and navigate to https://bedrock-monocompany.vercel.app/styleguide/docs/introduction.html

Basic requirements

  • First, make sure you have Node 14 or later installed. You can find the latest version of Node at Nodejs.org. Go for the LTS version.

Create your first prototype

We recommend using degit to be able to grab a Bedrock install without actually cloning the project repository (see: Contributing to Bedrock).

Here is the series of commands to use:

npx degit usebedrock/bedrock my-bedrock-project
cd my-bedrock-project/
npm install
npm start

Contributing to the Bedrock project

Read the active issues on Github.

Clone this repository:

git clone [email protected]:usebedrock/bedrock.git

The latest development usually happen in feature branches or in the development branch.

Make sure to make a branch for yourself - and if you have something meaningful to contribute, send us a PR!

Contact the authors

Major commands

  • npm start: runs the prototype
  • npm run build: create a build (which ends up in the dist folder) that can be deployed to a web server

Upgrading bedrock

Upgrading your Bedrock prototype is done through a CLI tool, which you install globally.

npm i -g bedrock-cli
bedrock upgrade

To upgrade to the development branch:

bedrock upgrade --dev

See the README at https://github.com/mono-company/bedrock-cli .

Using icon fonts

Icon font generation is optional. Set icons.generateIconFont to true in bedrock.config.js to activate icon fonts.

Windows

Windows usage is not supported at the moment.

We have used Bedrock on Windows successfully though. If you encounter any Windows related bugs, please log them under issues.

License

Bedrock is MIT licensed.

Credits

Bedrock was made by the team at Mono. Bedrock was initially written by Thomas Tuts.

bedrock's People

Contributors

bosschaertb avatar haroenv avatar heldtogether avatar simonwuyts avatar skrivle avatar tdurand avatar thomastuts avatar thusc avatar wolfr avatar xavez 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  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

bedrock's Issues

Copy [bootstrap/foundation/whatever] to its own folder

What is the problem?

I cannot easily view the bootstrap source files / search for a certain line of code that is responsible for a certain output.

Why do we want this?

Because you sometimes want to see the line of code that is responsible for a certain result, even if it comes from bootstrap or foundation core.

What is the issue?

.node_modules is ignored in my editor – it is probably also ignored in many other people’s editors because a search or file switch within a project would be slower and return more irrelevant results.

Proposed solution

We can:

  • Create a new directory /vendor and add a .gitignore file in it.
  • Create a gulp task to copy the toolkit we load via npm from .node_modules to this folder.
  • Adjust the paths in the scss files.

Added some test patterns, and the styleguide nav is bugged

The styleguide/pattern nav doesn't look so great (left side of screenshot, the nav).

screen shot 2015-11-19 at 14 08 25

What I entered was a structure like this:

.
├── avatar-checked.jade
├── icons.jade
├── table
│   └── table.jade
├── tags
│   ├── tags-remove.jade
│   ├── tags-simple.jade
│   ├── tags-subtle.jade
│   └── tags.jade
├── test.jade
├── testinclude.jade
├── textarea-monospace.jade
├── textarea.jade
├── tooltip-small.jade
├── tooltip.jade
└── ul.jade

I feel that the tree that is rendered in the styleguide should reflect the tree in the file system, but with pretty names.

Prototype nav covers part of the UI

When the prototype nav is open, all content should be visible.

At the moment, the prototype nav is an absolutely positioned div. It covers the content beneath it when open.

In Monoboot 1 there was a class that added a padding-left of the width of the prototype nav to the body, to kind of "push it away". Let's replicate this behavior again so we don't hide parts of the UI when the prototype nav is open.

Path for colors should be a setting

This is hardcoded now:

colorsDefinition: path.join(contentPath, 'scss/settings/_colors.scss'),

But maybe should be a setting, because we shouldn't determine how authors want to structure their CSS folders.

Come up with a decent way to create HTML builds without breaking Express

Right now the compiled HTML files (that are used to upload the prototype to a server or something) end up in the dist/ folder. This means that Express will pick these up as static assets, and serve those files instead of our Jade templates.

Since the express-static middleware doesn't provide a way to blacklist certain files, we should either tinker with a custom-written middleware that solves this issue, or (the fastest solution) generate a standalone build in a separate directory (which will pretty much copy the dist/ folder and add the compiled HTML there).

Installing SCSS frameworks and HTML components

I thought about this some more.

We have to define what is what:

  • An SCSS framework is a collection of stylesheets, javascript files, and possibly an icon font
  • An HTML component is an HTML pattern that works together with an SCSS framework (its correct rendering depends on the SCSS and dependencies e.g. images)

External SCSS frameworks are already npm modules e.g. bootstrap-sass, foundation. We should leverage that.

The paths to SCSS, images, icon fonts of these external module could be specified in a config file that makes the "link" between Bedrock and the "content template".

This way you can "install" an SCSS framework in a project.

We could hardcode this for bootstrap, foundation and our empty starter project to begin with. So the installer asks:

* Which SCSS framework do you want to use?
   * 1. Bootstrap
   * 2. Foundation
   * 3. Monoboot
   * 4. None

Then I would have another script to install "HTML component" examples. This basically pulls in jade files + images from an external repo. This is the "content" that lives in the styleguide.

* Which content examples do you want to install?
   * 1. Bootstrap
   * 2. Foundation
   * 3. Monoboot
   * 4. None

We could maintain collections of HTML components in codebases that run Monoboot but where the only files that are versioned are those in /content/examples . So we could for example make sets of examples based on Bootstrap, and then sets of examples based on Monoboot (Monoboot in this case being my modifications to Bootstrap).

Completely decouple styleguide additions

There should be some way to keep the main CSS file clean from project-specific prototype CSS additions (e.g. classes to adjust the styleguide), while still keeping core upgradeable.

A better solution would be to separately link to the compiled content prototype.scss in the Jade template to completely decouple it from the main SCSS (since that is what's supposed to be delivered as output). This way you'd have to reference three SCSS files in your Jade template: something like bedrock-prototype.css, prototype.css and main.css.

Documentation

This issue will list what needs to be documented.

  • How to use icon font
  • How to use SVG icons
  • How to use sample JSON data
  • Examples of Jade vs. HTML, links to jade documentation
  • Example of displaying state in a prototype
  • Using the global navigation
  • Starter templates (Bedrock Bootstrap starter templates)

Be able to reference images in patterns

If you try to reference an image in a pattern, it doesn't work.

Steps to reproduce:

  1. Add an avatar.svg image in /content/images/

  2. Add a test.jade in /patterns/ with contents:

    include /images/avatar.svg

You will get an error:

 ENOENT: no such file or directory, open 'content/images/avatar.svg'

The links in the prototype nav don't work

The prototype nav is broken if I try to use it from the latest commit 1842fc2 .

Try to click the links in the prototype nav. They don't work. The styleguide link refers to http://styleguide.html/.

Also, the labels are wrong: instead of listing the page name "Index", it lists "/index".

Maybe this has something to do with a global setting with relative paths that has been activated for #14 ?

Weird errors

I am leaving my weird errors I get in this thread until I know how to reproduce them.

  1. [17:27:15] Error: ENOENT: no such file or directory, chmod '/Users/johanronsse/Sites/gearjot-bedrock/dist/styleguide.html'
    at Error (native)

Index.js contents

In the base template, there is a file called index.js that contains:

require('../../core/js/index');

I imagine some people who will use Monoboot might be unfamiliar with require and/or browserify.

I guess this is needed to load all the prototype JS, right?

Feedback from call 4 dec

Gear detail

  • On a piece of gear, add an index of the oil samples taken (list) -- by component
    • Engine, Transmission, Converter
    • Every 500 hours you get samples: so dates are for example X weeks apart
    • Severity level might be on of the columns

Service issue

  • Service issue from fault code
    • Ask David for example

Service issue from form

Admin > Gear import

  • Allow the user to download an example CSV --> to edit

Feed

  • For every feed, link a username to /modules/users/detail.html

CSV: unit number, type, manufacturer, model, hours, mileage

User

General navigation

Gear overview

  • Gear - Full map view should be implemented
  • Gear list: vary the color on the 4th level --> last one is the one you an click,
  • add expand all button

Dashboard

Name column on dashboard doesn't need to be there (tasks widget)

  • Add group page
  • Capitalize "My Groups" and check across the platform for capitalization

Tasks overview

  • Assignee should be a column
  • This icon is really light: http://cl.ly/image/2D103V0c3I3w/Screen%20Shot%202015-12-04%20at%2015.43.05.png it should be darker
  • 2 ways of working:
    • 1 is me-centric: tasks assigned to me, tasks I've created, tasks I'm mentioned in
    • Other is "other person centric":
      • Current list of people (checkboxes) should be a dropdown
  • Think the filter logic through on tasks, because now it's bad

Group overview

http://localhost:3000/modules/groups/dashboard.html

modules/groups/dashboard.html --> gear widget: add expand all button

Discussions

http://localhost:3000/modules/groups/discussions.html

Notifications

Notifications: Have # in front of number http://cl.ly/image/2s1Q1n442E2a/Screen%20Shot%202015-12-04%20at%2016.10.02.png

Add example:

  • Assigned a task
  • Shared a discussion with you
  • Add some context: "in group" "in company"

Add discussion

http://localhost:3000/modules/discussions/add

  • Add discussion should be a modal
  • Looks too bare, needs "Add" button to add the discussion, also a cancel button
  • You need to select who to notify

Discussion view

  • Add an example of a third party coming in to comment on a discussion

ENOENT errors during duplicate Jade compilation

As noted in #30, it seems that the build system is throwing a bunch of ENOENT errors when compiling Jade while a previous Jade compilation is still running. The solution to this would have two aspects:

  • Try and fix the Jade live reload issue, alleviating the need to remove the files before recompiling them
  • Making the Jade template step faster in general

Divide styleguide in separate pages

The styleguide is too slow. I think we can fix it by dividing into separate pages. We need division anyway for a clearer separation of the different parts.

Speeding up the generation is also a possible solution.

Side menu that remembers state

The side menu should have the following features:

  • collapse and expand the items
  • remembers its own state (Like in Monoboot).

The reason I need this is because the menu gets too wieldy when you have a large prototype (e.g. Gearjot). I want to keep the side menu open and check every page. Now that interaction kind of sucks compared to Monoboot2.

This actually counts for both the component styleguide and the pages.

Bedrock logo

Bedrock needs a logo. Let's sketch a bit and get to something basic :)

Ping @xavez .

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.