mirror of
https://github.com/livebook-dev/livebook.git
synced 2025-10-29 14:56:26 +08:00
Update notebooks
This commit is contained in:
parent
e98fa825f6
commit
e32d52599c
8 changed files with 25 additions and 18 deletions
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
```elixir
|
||||
Mix.install([
|
||||
{:kino, "~> 0.12.0"}
|
||||
{:kino, "~> 0.13.0"}
|
||||
])
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
```elixir
|
||||
Mix.install([
|
||||
{:kino_explorer, "~> 0.1.18"}
|
||||
{:kino_explorer, "~> 0.1.20"}
|
||||
])
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
```elixir
|
||||
Mix.install([
|
||||
{:vega_lite, "~> 0.1.6"},
|
||||
{:kino_vega_lite, "~> 0.1.10"}
|
||||
{:kino_vega_lite, "~> 0.1.11"}
|
||||
])
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
```elixir
|
||||
Mix.install([
|
||||
{:kino, "~> 0.12.0"}
|
||||
{:kino, "~> 0.13.0"}
|
||||
])
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
```elixir
|
||||
Mix.install([
|
||||
{:kino, "~> 0.12.0"}
|
||||
{:kino, "~> 0.13.0"}
|
||||
])
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
```elixir
|
||||
Mix.install([
|
||||
{:kino, "~> 0.12.0"},
|
||||
{:kino, "~> 0.13.0"},
|
||||
{:jason, "~> 1.4"}
|
||||
])
|
||||
```
|
||||
|
|
@ -177,8 +177,10 @@ defmodule KinoGuide.ShellCell do
|
|||
use Kino.SmartCell, name: "Shell script"
|
||||
|
||||
@impl true
|
||||
def init(_attrs, ctx) do
|
||||
{:ok, ctx, editor: [attribute: "source"]}
|
||||
def init(attrs, ctx) do
|
||||
source = attrs["source"] || ""
|
||||
|
||||
{:ok, assign(ctx, source: source), editor: [source: source]}
|
||||
end
|
||||
|
||||
@impl true
|
||||
|
|
@ -187,8 +189,13 @@ defmodule KinoGuide.ShellCell do
|
|||
end
|
||||
|
||||
@impl true
|
||||
def to_attrs(_ctx) do
|
||||
%{}
|
||||
def handle_editor_change(source, ctx) do
|
||||
{:ok, assign(ctx, source: source)}
|
||||
end
|
||||
|
||||
@impl true
|
||||
def to_attrs(ctx) do
|
||||
%{"source" => ctx.assigns.source}
|
||||
end
|
||||
|
||||
@impl true
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@
|
|||
|
||||
```elixir
|
||||
Mix.install([
|
||||
{:kino, "~> 0.12.0"},
|
||||
{:kino_vega_lite, "~> 0.1.10"}
|
||||
{:kino, "~> 0.13.0"},
|
||||
{:kino_vega_lite, "~> 0.1.11"}
|
||||
])
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
defmodule Livebook.Runtime.Definitions do
|
||||
@kino_requirement "~> 0.12.0"
|
||||
@kino_requirement "~> 0.13.0"
|
||||
|
||||
def kino_requirement do
|
||||
@kino_requirement
|
||||
|
|
@ -17,12 +17,12 @@ defmodule Livebook.Runtime.Definitions do
|
|||
|
||||
kino_db = %{
|
||||
name: "kino_db",
|
||||
dependency: %{dep: {:kino_db, "~> 0.2.5"}, config: []}
|
||||
dependency: %{dep: {:kino_db, "~> 0.2.8"}, config: []}
|
||||
}
|
||||
|
||||
exqlite = %{
|
||||
name: "exqlite",
|
||||
dependency: %{dep: {:exqlite, "~> 0.11.0"}, config: []}
|
||||
dependency: %{dep: {:exqlite, "~> 0.23.0"}, config: []}
|
||||
}
|
||||
|
||||
kino_maplibre = %{
|
||||
|
|
@ -52,7 +52,7 @@ defmodule Livebook.Runtime.Definitions do
|
|||
|
||||
kino_explorer = %{
|
||||
name: "kino_explorer",
|
||||
dependency: %{dep: {:kino_explorer, "~> 0.1.18"}, config: []}
|
||||
dependency: %{dep: {:kino_explorer, "~> 0.1.20"}, config: []}
|
||||
}
|
||||
|
||||
jason = %{
|
||||
|
|
@ -62,12 +62,12 @@ defmodule Livebook.Runtime.Definitions do
|
|||
|
||||
stb_image = %{
|
||||
name: "stb_image",
|
||||
dependency: %{dep: {:stb_image, "~> 0.6.2"}, config: []}
|
||||
dependency: %{dep: {:stb_image, "~> 0.6.9"}, config: []}
|
||||
}
|
||||
|
||||
xlsx_reader = %{
|
||||
name: "xlsx_reader",
|
||||
dependency: %{dep: {:xlsx_reader, "~> 0.8.4"}, config: []}
|
||||
dependency: %{dep: {:xlsx_reader, "~> 0.8.5"}, config: []}
|
||||
}
|
||||
|
||||
windows? = match?({:win32, _}, :os.type())
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue