Skip to content

Commit

Permalink
[CHORE] Add home page and badges
Browse files Browse the repository at this point in the history
  • Loading branch information
lvegerano committed Jul 15, 2019
1 parent 75ac564 commit b50485e
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 18 deletions.
2 changes: 2 additions & 0 deletions README.md
@@ -1,5 +1,7 @@
ember-sortablejs
==============================================================================
[![Build Status](https://travis-ci.org/SortableJS/ember-sortablejs.svg?branch=master)](https://travis-ci.org/SortableJS/ember-sortablejs)
[![Ember Observer Score](https://emberobserver.com/badges/ember-sortablejs.svg)](https://emberobserver.com/addons/ember-sortablejs)

This addon allows you to use drag and drop in your ember application using [SortableJS/Sortable](https://github.com/SortableJS/Sortable)

Expand Down
22 changes: 5 additions & 17 deletions tests/dummy/app/controllers/application.js
@@ -1,22 +1,10 @@
import Controller from '@ember/controller';
import { A } from '@ember/array';
import { computed } from '@ember/object';
import { equal } from '@ember/object/computed';
import { inject as service } from '@ember/service';

export default Controller.extend({
actionStack: null,
router: service(),

init() {
this._super(...arguments);
this.set('actionStack', A([]));
},

actions: {
trigger(actionName) {

if (actionName === 'onChoose') {
this.set('actionStack', A([]));
}

this.get('actionStack').pushObject(actionName);
}
}
inHomeRoute: equal('router.currentRouteName', 'index'),
});
16 changes: 15 additions & 1 deletion tests/dummy/app/templates/application.hbs
Expand Up @@ -30,5 +30,19 @@
</div>
</nav>
<div class="container-fluid">
{{outlet}}
{{#if this.inHomeRoute}}
<div class="position-relative overflow-hidden p-3 p-md-5 m-md-3 text-center bg-light">
<div class="col-md-5 p-lg-5 mx-auto my-5">
<h1 class="display-4 font-weight-normal">Ember-SortableJS</h1>
<p class="lead font-weight-normal">Drag and Drop with sort for ambitious applications</p>
{{#link-to "simple" class="btn btn-outline-secondary"}}
Get Started
{{/link-to}}
</div>
<div class="product-device shadow-sm d-none d-md-block"></div>
<div class="product-device product-device-2 shadow-sm d-none d-md-block"></div>
</div>
{{else}}
{{outlet}}
{{/if}}
</div>

0 comments on commit b50485e

Please sign in to comment.