Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions assets/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,9 @@ li {
font-size: 19px;
}

span.feature-studied {
margin-right: 5px;
color: #0BE370;
}

span.algorithm-studied {
span.feature-studied,
span.algorithm-studied,
span.data-structure-studied {
margin-right: 5px;
color: #0BE370;
}
Expand Down
15 changes: 12 additions & 3 deletions assets/js/algorithms_controller.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
var app = angular.module('algorithm', []);

app.controller('CppFeaturesController', ['$scope', function($scope) {

$scope.cppFeatures = [
{
'title': 'C++ Vector: A pretty simple guide',
Expand Down Expand Up @@ -39,11 +38,9 @@ app.controller('CppFeaturesController', ['$scope', function($scope) {
'studied': false
},
];

}]);

app.controller('AlgorithmsController', ['$scope', function($scope) {

$scope.algorithms = [
{
'title': 'Bubble Sort',
Expand Down Expand Up @@ -81,5 +78,17 @@ app.controller('AlgorithmsController', ['$scope', function($scope) {
'studied': true
},
];
}]);

app.controller('DataStructuresController', ['$scope', function($scope) {
$scope.dataStructures = [
{
'title': 'Trees',
'hasMediumPost': true,
'mediumPostUrl': 'https://medium.freecodecamp.org/all-you-need-to-know-about-tree-data-structures-bceacb85490c',
'hasGithubCode': true,
'githubCodeUrl': 'https://github.com/LeandroTk/algorithms/tree/master/data_structures/binary_search_tree',
'studied': true
}
];
}]);
16 changes: 16 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,22 @@ <h2>Algorithms</h2>
</ul>
</div>

<div ng-controller='DataStructuresController'>
<ul>
<h2>Data Structures</h2>
<li ng-repeat="dataStructure in dataStructures">
<span class='data-structure-studied' ng-if='dataStructure.studied'><i class="fa fa-check"></i></span>
<b>{{dataStructure.title}}</b>
<span class="medium-post" ng-if='dataStructure.hasMediumPost'>
<a href="{{dataStructure.mediumPostUrl}}" target="_blank"><i class='fa fa-medium'></i></a>
</span>
<span class="github-code" ng-if='dataStructure.hasGithubCode'>
<a href="{{dataStructure.githubCodeUrl}}" target="_blank"><i class='fa fa-github'></i></a>
</span>
</li>
</ul>
</div>

<div ng-controller='CppFeaturesController'>
<ul>
<h2>C++ Features</h2>
Expand Down