This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# include this module in your controller to respond with a remote modal | |
# if the request is a turbo frame request with a turbo_frame_id="modal" | |
# then the response will use the modal layout (wraps the content into a self opening modal) | |
# | |
module RemoteModal | |
extend ActiveSupport::Concern | |
DEFAULT_ALLOWED_ACTIONS = %i[new show edit index].freeze | |
included do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# syntax = docker/dockerfile:1 | |
# Make sure RUBY_VERSION matches the Ruby version in .ruby-version and Gemfile | |
ARG RUBY_VERSION=3.2.2 | |
FROM registry.docker.com/library/ruby:$RUBY_VERSION-slim as base | |
# Rails app lives here | |
WORKDIR /rails | |
# Set production environment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# frozen_string_literal: true | |
class VideosController < ApplicationController | |
include ActionView::RecordIdentifier | |
before_action :authenticate_user!, only: %i[edit update create upvote downvote bookmark watchlist complete featured] | |
before_action :current_search, only: %i[index] | |
before_action :set_video, only: %i[show edit update destroy hide upvote downvote bookmark watchlist complete featured] | |
before_action :check_for_clear, only: [:index] | |
after_action :track_action |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Controller } from '@hotwired/stimulus'; | |
export default class extends Controller { | |
static values = { event: String }; | |
declare readonly eventValue?: string; | |
connect(): void { | |
this.element.addEventListener(this.eventName, this.onChange); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tangotube on ξ dockerize [$!?] is π¦ v0.1.0 via π v3.0.3 on π³ v20.10.13 took 59s | |
β docker-compose up | |
[+] Running 3/0 | |
β Ώ Container tangotube-redis-1 Created 0.0s | |
β Ώ Container tangotube-db-1 Created 0.0s | |
β Ώ Container tangotube-web-1 Created 0.0s | |
Attaching to tangotube-db-1, tangotube-redis-1, tangotube-web-1 | |
tangotube-redis-1 | 1:C 25 Mar 2022 16:39:35.087 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo | |
tangotube-redis-1 | 1:C 25 Mar 2022 16:39:35.087 # Redis version=6.2.6, bits=64, commit=00000000, modified=0, pid=1, just started | |
tangotube-redis-1 | 1:C 25 Mar 2022 16:39:35.087 # Warning: no config file sp |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
beast_mode on ξ master [!?] is π¦ v1.0.0 via π v2.7.3 on π³ v20.10.13 took 6s | |
β rails s | |
=> Booting Puma | |
=> Rails 6.1.4.7 application starting in development | |
=> Run `bin/rails server --help` for more startup options | |
Puma starting in single mode... | |
* Puma version: 5.5.2 (ruby 2.7.3-p183) ("Zawgyi") | |
* Min threads: 5 | |
* Max threads: 5 | |
* Environment: development |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<%= render 'layouts/head' %> | |
</head> | |
<body class="no-js <%= "page-#{controller.controller_name}" %> <%= content_for(:body_classes) %>"> | |
<%= render 'layouts/header' %> | |
<div class="main-page <%= 'with-hero' if content_for?(:hero) %>"> | |
<% if content_for?(:hero) %> | |
<div class="jumbotron hero-tron"> |
This file has been truncated, but you can view the full file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"results":[{"uid":8585,"indexUid":"Video_development","status":"enqueued","type":"settingsUpdate","details":{"filterableAttributes":["follower","genre","leader","orchestra","year"],"sortableAttributes":["channel_title","liked_count","orchestra","performance_date","song_title","view_count","year"]},"duration":null,"enqueuedAt":"2022-03-20T10:28:27.751898Z","startedAt":null,"finishedAt":null},{"uid":8584,"indexUid":"Video_development","status":"enqueued","type":"indexCreation","details":{"primaryKey":"id"},"duration":null,"enqueuedAt":"2022-03-20T10:28:27.748905Z","startedAt":null,"finishedAt":null},{"uid":8583,"indexUid":"Video_development","status":"enqueued","type":"settingsUpdate","details":{"filterableAttributes":["follower","genre","leader","orchestra","year"],"sortableAttributes":["channel_title","liked_count","orchestra","performance_date","song_title","view_count","year"]},"duration":null,"enqueuedAt":"2022-03-20T10:28:05.182412Z","startedAt":null,"finishedAt":null},{"uid":8582,"indexUid":"Video_devel |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="load-more-container" id="load-more-container"> | |
<div class="load-more-results"> | |
<%= "Displaying #{@search.displayed_videos_count} / #{number_with_delimiter(@search.videos.size)} Results" %> | |
</div> | |
<% if @search.next_page? %> | |
<%= link_to "Load More", | |
video_query_params.merge(page: @page + 1), | |
class: "load-more-link", | |
data: { disable_with: "<div class='loading-animation'> | |
<i class='fas fa-spinner fa-spin fa-3x'></i> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import "@shoelace-style/shoelace/dist/themes/light.css"; | |
@import "@shoelace-style/shoelace/dist/themes/dark.css"; | |
.content { | |
flex: 1; | |
display: flex; | |
flex-direction: column; | |
align-items: center; | |
background-color: #f9f9f9; | |
width: 100%; | |
height: 100%; |
NewerOlder