\ No newline at end of file
diff --git a/app/views/playlists/show.html.erb b/app/views/playlists/show.html.erb
index fe3cf4d..fbccaa3 100644
--- a/app/views/playlists/show.html.erb
+++ b/app/views/playlists/show.html.erb
@@ -6,10 +6,10 @@
\ No newline at end of file
diff --git a/app/views/stories/partials/_story_play.html.erb b/app/views/stories/partials/_story_play.html.erb
index 76d93b7..40b0104 100644
--- a/app/views/stories/partials/_story_play.html.erb
+++ b/app/views/stories/partials/_story_play.html.erb
@@ -31,7 +31,7 @@
playlist_add
-
Lagre
+
<%= t('.add') %>
@@ -69,8 +69,8 @@
-
-
+
+
diff --git a/config/initializers/i18.rb b/config/initializers/i18.rb
deleted file mode 100644
index 7cbf2da..0000000
--- a/config/initializers/i18.rb
+++ /dev/null
@@ -1 +0,0 @@
-I18n.default_locale = :nb
\ No newline at end of file
diff --git a/config/locales/device.en.yml b/config/locales/device.en.yml
index 0dce5fe..5a992bd 100644
--- a/config/locales/device.en.yml
+++ b/config/locales/device.en.yml
@@ -62,4 +62,12 @@ en:
not_locked: "was not locked"
not_saved:
one: "1 error prohibited this %{resource} from being saved:"
- other: "%{count} errors prohibited this %{resource} from being saved:"
\ No newline at end of file
+ other: "%{count} errors prohibited this %{resource} from being saved:"
+ stories:
+ partials:
+ audio_controls:
+ autoplay_next: ""
+ playlists:
+ partials:
+ story_card:
+ uploaded: ""
\ No newline at end of file
diff --git a/config/locales/devise.nb.yml b/config/locales/devise.nb.yml
index b1f908c..490362c 100644
--- a/config/locales/devise.nb.yml
+++ b/config/locales/devise.nb.yml
@@ -63,3 +63,11 @@ nb:
not_saved:
one: "1 feil forhindret dette %{resource} i å bli lagret:"
other: "%{count} feil forhindrer dette %{resource} i å bli lagret:"
+ stories:
+ partials:
+ audio_controls:
+ autoplay_next: ""
+ playlists:
+ partials:
+ story_card:
+ uploaded: ""
diff --git a/config/locales/en.yml b/config/locales/en.yml
index 32e21a9..4f200db 100644
--- a/config/locales/en.yml
+++ b/config/locales/en.yml
@@ -44,6 +44,7 @@ en:
registrations:
edit:
title: "Edit account"
+ profile_picture: "Profile picture"
username: "Username"
new_password: "New password"
leave_empty: "(leave empty if you dont want to change)"
@@ -57,6 +58,7 @@ en:
new:
username: "Username"
password: "Password"
+ letters_minimum: "letters minimum"
confirm_password: "Confirm Password"
already_have_an_account: "Already have an account?"
log_in: "Log in"
@@ -79,7 +81,7 @@ en:
ago: "ago"
remove_from_favourites: "Remove from favourites"
favourites_counter:
- videoes: "videoes"
+ videoes: "videos"
index:
title: "Favourites"
@@ -91,24 +93,61 @@ en:
sidebar:
home: "Home"
new_story: "New story"
+ my_playlists: "My Playlists"
my_stories: "My stories"
- favorites: "Favorites"
+ welcome_alert:
+ welcome_alert_text: "Storytime is an app where users can share and listen to funny stories.
+ Be nice and have fun!"
+
+ playlists:
+ partials:
+ new_playlist_btn:
+ create_new_playlist: "Create new playlist"
+ story_card:
+ uploaded: "Uploaded"
+ ago: "ago"
+ show:
+ play_all: "Play all"
+ this_playlist_is_empty: "This playlist is empty"
+ discorver stories: "Discover stories"
+
+ profiles:
+ partials:
+ nav_items:
+ playlists: "Playlists"
+ playlists:
+ playlists: "Playlists"
+ profile_navbar:
+ edit_my_account: "Edit my account"
stories:
+ partials:
+ audio_controls:
+ autoplay_next: "Autoplay next"
+ story_card:
+ uploaded: "Uploaded"
+ ago: "ago"
+ story_play:
+ edit_story: "Edit Story"
+ add: "Add"
+ show_more: "Show more"
+ show_less: "Show less"
form:
title: "Title"
+ add_a_title_to_your_story: "Add a title to your story"
description: "Description"
choose_file: "Choose file"
+ choose_image_file: "Choose image file"
create_story: "Create story"
+ choose_one_or_more_categories: "Choose one or more categories"
story:
edit_story: "Edit story"
- story_card:
- uploaded: "Uploaded"
- ago: "ago"
edit:
delete_story: "Delete story"
show_story: "Show story"
back_to_stories: "Back to stories"
+ index:
+ search_for_stories: "Search for stories"
my_stories:
title: "My stories"
new:
diff --git a/config/locales/nb.yml b/config/locales/nb.yml
index d329d0f..6031544 100644
--- a/config/locales/nb.yml
+++ b/config/locales/nb.yml
@@ -44,6 +44,7 @@ nb:
registrations:
edit:
title: "Endre konto"
+ profile_picture: "Profilbilde"
username: "Brukernavn"
new_password: "Nytt passord"
leave_empty: "(la stå tom viss du ikke vil endre)"
@@ -57,6 +58,7 @@ nb:
new:
username: "Brukernavn"
password: "Passord"
+ letters_minimum: "tegn minimum"
confirm_password: "Bekreft passord"
already_have_an_account: "Har du allerede en konto?"
log_in: "Logg inn"
@@ -91,24 +93,61 @@ nb:
sidebar:
home: "Hjem"
new_story: "Ny story"
+ my_playlists: "Mine spillelister"
my_stories: "Mine stories"
- favorites: "Favoritter"
+ welcome_alert:
+ welcome_alert_text: "Storytime er en app hvor brukere kan dele og høre på morsomme historier.
+ Vær hyggelig og ha det gøy!"
+
+ playlists:
+ partials:
+ new_playlist_btn:
+ create_new_playlist: "Lag ny spilleliste"
+ story_card:
+ uploaded: "Lastet opp for"
+ ago: "siden"
+ show:
+ play_all: "Spill av spilleliste"
+ this_playlist_is_empty: "Denne spillelisten er tom"
+ discorver stories: "Utforsk stories"
+
+ profiles:
+ partials:
+ nav_items:
+ playlists: "Spillelister"
+ playlists:
+ playlists: "Spillelister"
+ profile_navbar:
+ edit_my_account: "Endre min konto"
stories:
+ partials:
+ audio_controls:
+ autoplay_next: "Spill av neste automatisk"
+ story_card:
+ uploaded: "Lastet opp for"
+ ago: "siden"
+ story_play:
+ edit_story: "Endre Story"
+ add: "Lagre"
+ show_more: "Vis mer"
+ show_less: "Vis mindre"
form:
title: "Tittel"
+ add_a_title_to_your_story: "Legg til en tittel for ditt innlegg"
description: "Beskrivelse"
choose_file: "Velg fil"
+ choose_image_file: "Velg bildefil"
create_story: "Opprett story"
+ choose_one_or_more_categories: "Velg en til flere kategorier"
story:
edit_story: "Endre story"
- story_card:
- uploaded: "Lastet opp for"
- ago: "siden"
edit:
delete_story: "Slett story"
show_story: "Vis story"
back_to_stories: "Tilbake"
+ index:
+ search_for_stories: "Søk i stories"
my_stories:
title: "Mine stories"
new:
diff --git a/config/routes.rb b/config/routes.rb
index a23e332..f794ef4 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -22,6 +22,26 @@
get 'playlist/:playlist_id/:id', to: 'playlist_stories#play', as: 'playlist_play_story'
scope '(:locale)' do
+
+ resources :languages do
+ member do
+ post :change
+ end
+ end
+
+ resources :playlists, only: [:create, :destroy, :index, :new, :show] do
+ member do
+ post :new
+ end
+ end
+
+ post "cancel_playlist_form", to:"playlists#cancel", as: 'cancel_playlist_form'
+ resources :playlist_stories, only: [:create, :destroy]
+ get 'my_stories', to: 'playlists#my_stories', as: "my_stories"
+ get 'my_favourites', to: 'playlists#my_favourites', as: "my_favourites"
+ get 'playlist/play/:id', to: 'playlists#play', as: 'playlist_play'
+ get 'playlist/:playlist_id/:id', to: 'playlist_stories#play', as: 'playlist_play_story'
+
resources :favourites
devise_for :users, :controllers => { :registrations => 'registrations' }
resources :stories
@@ -36,6 +56,6 @@
# Defines the root path route ("/")
root "stories#index"
-
end
+
end