Skip to content

Commit

Permalink
chore: updated elixir and erlang
Browse files Browse the repository at this point in the history
actually I was trying to update `supabase_potion` to `0.5`, but there is some error with the updated `supabase_storage` (something related to streams). as I had already updated elixir and erlang, I kept it and discarded all changes related to supabase
  • Loading branch information
endoooo committed Jan 7, 2025
1 parent afea763 commit 789967c
Show file tree
Hide file tree
Showing 55 changed files with 137 additions and 137 deletions.
4 changes: 2 additions & 2 deletions .tool-versions
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
elixir 1.15.4
erlang 26.0.2
elixir 1.18.1-otp-27
erlang 27.2
2 changes: 1 addition & 1 deletion lib/lanttern/assessments/assessment_point.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Assessments.AssessmentPoint do
use Ecto.Schema
import Ecto.Changeset
import Ecto.Query, only: [from: 2]
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Repo

Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/attachments/attachment.ex
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ defmodule Lanttern.Attachments.Attachment do

use Ecto.Schema
import Ecto.Changeset
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Assessments.AssessmentPointEntry
alias Lanttern.Assessments.AssessmentPointEntryEvidence
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/curricula/curriculum_component.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Curricula.CurriculumComponent do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

schema "curriculum_components" do
field :code, :string
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/filters/profile_report_card_filter.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Filters.ProfileReportCardFilter do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Identity.Profile
alias Lanttern.Reporting.ReportCard
Expand Down
6 changes: 3 additions & 3 deletions lib/lanttern_web/gettext.ex → lib/lanttern/gettext.ex
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
defmodule LantternWeb.Gettext do
defmodule Lanttern.Gettext do
@moduledoc """
A module providing Internationalization with a gettext-based API.
By using [Gettext](https://hexdocs.pm/gettext),
your module gains a set of macros for translations, for example:
import LantternWeb.Gettext
import Lanttern.Gettext
# Simple translation
gettext("Here is the string to translate")
Expand All @@ -20,5 +20,5 @@ defmodule LantternWeb.Gettext do
See the [Gettext Docs](https://hexdocs.pm/gettext) for detailed usage.
"""
use Gettext, otp_app: :lanttern
use Gettext.Backend, otp_app: :lanttern
end
2 changes: 1 addition & 1 deletion lib/lanttern/grades_reports/grades_report.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.GradesReports.GradesReport do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.GradesReports.GradesReportCycle
alias Lanttern.GradesReports.GradesReportSubject
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/grades_reports/grades_report_cycle.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.GradesReports.GradesReportCycle do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.GradesReports.GradesReport
alias Lanttern.Schools.Cycle
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/grades_reports/grades_report_subject.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.GradesReports.GradesReportSubject do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.GradesReports.GradesReport
alias Lanttern.Taxonomy.Subject
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/learning_context.ex
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ defmodule Lanttern.LearningContext do
import Lanttern.RepoHelpers
alias Lanttern.RepoHelpers.Page
alias Lanttern.Repo
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Assessments.AssessmentPointEntry
alias Lanttern.LearningContext.Strand
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/learning_context/moment.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.LearningContext.Moment do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext
import Lanttern.SchemaHelpers

alias Lanttern.Curricula.CurriculumItem
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/learning_context/strand.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.LearningContext.Strand do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext
import Lanttern.SchemaHelpers

alias Lanttern.LearningContext.Moment
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/notes/moment_note_relationship.ex
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ defmodule Lanttern.Notes.MomentNoteRelationship do

use Ecto.Schema
import Ecto.Changeset
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

@primary_key false
schema "moments_notes" do
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/personalization/profile_settings.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Personalization.ProfileSettings do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Identity.Profile
alias Lanttern.Personalization
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/repo_helpers.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.RepoHelpers do
alias Lanttern.Repo
import Ecto.Query, only: [from: 2]

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

defmodule Page do
@moduledoc "General pagination page struct and related utils"
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/reporting/strand_report.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Reporting.StrandReport do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Reporting.ReportCard
alias Lanttern.LearningContext.Strand
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/reporting/student_report_card.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Reporting.StudentReportCard do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Reporting.ReportCard
alias Lanttern.Schools.Student
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/schools.ex
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ defmodule Lanttern.Schools do

import Ecto.Query, warn: false
import Lanttern.RepoHelpers
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext
alias Lanttern.Repo
alias Lanttern.Schools.School
alias Lanttern.Schools.Cycle
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/schools/class.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Schools.Class do
use Ecto.Schema
import Ecto.Changeset
import Ecto.Query, only: [from: 2]
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Repo

Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/schools/cycle.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Schools.Cycle do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext
alias Lanttern.Schools.Class
alias Lanttern.Schools.School

Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/schools/school.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.Schools.School do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

@type t :: %__MODULE__{
id: pos_integer(),
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/students_cycle_info/student_cycle_info.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.StudentsCycleInfo.StudentCycleInfo do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Schools.Cycle
alias Lanttern.Schools.School
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/students_records/student_record.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.StudentsRecords.StudentRecord do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.StudentsRecords.StudentRecordClassRelationship
alias Lanttern.StudentsRecords.StudentRecordRelationship
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/students_records/student_record_status.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.StudentsRecords.StudentRecordStatus do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Schools.School

Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern/students_records/student_record_type.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule Lanttern.StudentsRecords.StudentRecordType do
use Ecto.Schema
import Ecto.Changeset

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

alias Lanttern.Schools.School

Expand Down
4 changes: 2 additions & 2 deletions lib/lanttern_web.ex
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ defmodule LantternWeb do
layouts: [html: LantternWeb.Layouts]

import Plug.Conn
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

unquote(verified_routes())
end
Expand Down Expand Up @@ -98,7 +98,7 @@ defmodule LantternWeb do
import LantternWeb.NavigationComponents
import LantternWeb.FormComponents
import LantternWeb.OverlayComponents
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

# Shortcut for generating JS commands
alias Phoenix.LiveView.JS
Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern_web/components/assessments_components.ex
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ defmodule LantternWeb.AssessmentsComponents do

use Phoenix.Component

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext
import LantternWeb.CoreComponents
import LantternWeb.OverlayComponents

Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern_web/components/attachments_components.ex
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ defmodule LantternWeb.AttachmentsComponents do

use Phoenix.Component

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext
import LantternWeb.CoreComponents
import LantternWeb.OverlayComponents

Expand Down
6 changes: 3 additions & 3 deletions lib/lanttern_web/components/core_components.ex
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ defmodule LantternWeb.CoreComponents do

alias Phoenix.LiveView.JS
import Phoenix.HTML, only: [raw: 1]
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

import LantternWeb.SchoolsHelpers, only: [class_with_cycle: 2]

Expand Down Expand Up @@ -1826,9 +1826,9 @@ defmodule LantternWeb.CoreComponents do
# with our gettext backend as first argument. Translations are
# available in the errors.po file (as we use the "errors" domain).
if count = opts[:count] do
Gettext.dngettext(LantternWeb.Gettext, "errors", msg, msg, count, opts)
Gettext.dngettext(Lanttern.Gettext, "errors", msg, msg, count, opts)
else
Gettext.dgettext(LantternWeb.Gettext, "errors", msg, opts)
Gettext.dgettext(Lanttern.Gettext, "errors", msg, opts)
end
end

Expand Down
2 changes: 1 addition & 1 deletion lib/lanttern_web/components/form_components.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule LantternWeb.FormComponents do

import LantternWeb.CoreComponents
alias Phoenix.LiveView.JS
import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext

@doc """
Renders a simple form.
Expand Down
14 changes: 7 additions & 7 deletions lib/lanttern_web/components/grades_reports_components.ex
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ defmodule LantternWeb.GradesReportsComponents do
use Phoenix.Component
alias Phoenix.LiveView.JS

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext
import LantternWeb.CoreComponents

alias Lanttern.GradesReports.GradesReport
Expand Down Expand Up @@ -141,7 +141,7 @@ defmodule LantternWeb.GradesReportsComponents do
>
<div class="sticky left-0 p-4 rounded bg-white shadow-lg">
<%= Gettext.dgettext(
LantternWeb.Gettext,
Lanttern.Gettext,
"taxonomy",
grades_report_subject.subject.name
) %>
Expand Down Expand Up @@ -483,15 +483,15 @@ defmodule LantternWeb.GradesReportsComponents do
class="flex items-center justify-center w-20 min-w-full p-2 border-b-2 border-ltrn-subtle mt-px bg-white last:border-r-2 last:border-ltrn-subtle"
title={
Gettext.dgettext(
LantternWeb.Gettext,
Lanttern.Gettext,
"taxonomy",
grades_report_subject.subject.name
)
}
>
<div class="truncate">
<%= Gettext.dgettext(
LantternWeb.Gettext,
Lanttern.Gettext,
"taxonomy",
grades_report_subject.subject.short_name || grades_report_subject.subject.name
) %>
Expand All @@ -504,15 +504,15 @@ defmodule LantternWeb.GradesReportsComponents do
class="flex items-center justify-center gap-2 w-20 min-w-full py-2 px-1 border-b-2 border-ltrn-subtle mt-px text-white bg-ltrn-dark"
title={
Gettext.dgettext(
LantternWeb.Gettext,
Lanttern.Gettext,
"taxonomy",
grades_report_subject.subject.name
)
}
>
<div class="flex-1 text-center truncate">
<%= Gettext.dgettext(
LantternWeb.Gettext,
Lanttern.Gettext,
"taxonomy",
grades_report_subject.subject.short_name || grades_report_subject.subject.name
) %>
Expand Down Expand Up @@ -768,7 +768,7 @@ defmodule LantternWeb.GradesReportsComponents do
>
<span class="flex-1 truncate">
<%= Gettext.dgettext(
LantternWeb.Gettext,
Lanttern.Gettext,
"taxonomy",
grades_report_subject.subject.name
) %>
Expand Down
10 changes: 5 additions & 5 deletions lib/lanttern_web/components/learning_context_components.ex
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ defmodule LantternWeb.LearningContextComponents do

use Phoenix.Component

import LantternWeb.Gettext
use Gettext, backend: Lanttern.Gettext
import LantternWeb.CoreComponents
import Lanttern.SupabaseHelpers, only: [object_url_to_render_url: 2]

Expand Down Expand Up @@ -95,10 +95,10 @@ defmodule LantternWeb.LearningContextComponents do
</div>
<div class="flex flex-wrap gap-2">
<.badge :for={subject <- @strand.subjects}>
<%= Gettext.dgettext(LantternWeb.Gettext, "taxonomy", subject.name) %>
<%= Gettext.dgettext(Lanttern.Gettext, "taxonomy", subject.name) %>
</.badge>
<.badge :for={year <- @strand.years}>
<%= Gettext.dgettext(LantternWeb.Gettext, "taxonomy", year.name) %>
<%= Gettext.dgettext(Lanttern.Gettext, "taxonomy", year.name) %>
</.badge>
</div>
<div :if={!@hide_description} class="line-clamp-3">
Expand Down Expand Up @@ -141,10 +141,10 @@ defmodule LantternWeb.LearningContextComponents do
</p>
<div class="flex flex-wrap gap-2 mt-4">
<.badge :for={subject <- @strand.subjects}>
<%= Gettext.dgettext(LantternWeb.Gettext, "taxonomy", subject.name) %>
<%= Gettext.dgettext(Lanttern.Gettext, "taxonomy", subject.name) %>
</.badge>
<.badge :for={year <- @strand.years}>
<%= Gettext.dgettext(LantternWeb.Gettext, "taxonomy", year.name) %>
<%= Gettext.dgettext(Lanttern.Gettext, "taxonomy", year.name) %>
</.badge>
</div>
</div>
Expand Down
Loading

0 comments on commit 789967c

Please sign in to comment.