Skip to content

Commit 4dad7be

Browse files
authored
Merge pull request #54 from blocknotes/signatures/update-rbs-signatures-2
chore: Update RBS signatures (2)
2 parents 2ca7cad + d2b62cd commit 4dad7be

16 files changed

+110
-9
lines changed

sig/tiny_admin/actions/basic_action.rbs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
module TinyAdmin
22
module Actions
33
class BasicAction
4+
include Utils
5+
46
def attribute_options: (Array[untyped]?) -> Hash[untyped, untyped]?
57
end
68
end

sig/tiny_admin/actions/index.rbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module TinyAdmin
22
module Actions
3-
class Index
3+
class Index < BasicAction
44
attr_reader context: untyped
55
attr_reader current_page: Integer
66
attr_reader fields_options: untyped
@@ -12,7 +12,7 @@ module TinyAdmin
1212
attr_reader query_string: String
1313
attr_reader repository: untyped
1414

15-
def call: (app: BasicApp, context: Context, options: Hash[Symbol, untyped]) -> void
15+
def call: (app: BasicApp, context: Context, options: Hash[Symbol, untyped]) -> untyped
1616

1717
private
1818

sig/tiny_admin/actions/show.rbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
module TinyAdmin
22
module Actions
3-
class Show
4-
def call: (app: BasicApp, context: Context, options: Hash[Symbol, untyped]) -> void
3+
class Show < BasicAction
4+
def call: (app: BasicApp, context: Context, options: Hash[Symbol, untyped]) -> untyped
55
end
66
end
77
end

sig/tiny_admin/field.rbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ module TinyAdmin
55
attr_reader title: String
66
attr_reader type: Symbol
77

8-
def initialize: (name: String, title: String, type: Symbol, ?options: Hash[Symbol, String]) -> void
8+
def initialize: (name: String, title: String, type: Symbol, ?options: Hash[Symbol, untyped]) -> void
99

10-
def apply_call_option: (untyped) -> void
10+
def apply_call_option: (untyped) -> untyped
1111

1212
def translate_value: (untyped) -> untyped
1313

sig/tiny_admin/plugins/active_record_repository.rbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module TinyAdmin
22
module Plugins
3-
class ActiveRecordRepository
3+
class ActiveRecordRepository < BaseRepository
44
def apply_filters: (untyped, Enumerable[untyped]) -> untyped
55

66
def collection: () -> untyped

sig/tiny_admin/plugins/base_repository.rbs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
module TinyAdmin
22
module Plugins
33
class BaseRepository
4-
RecordNotFound: untyped
4+
class RecordNotFound < StandardError
5+
end
56

67
attr_reader model: untyped
78

sig/tiny_admin/settings.rbs

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,38 @@ module TinyAdmin
77

88
attr_reader store: Store
99

10+
# Dynamically defined accessors for OPTIONS
11+
def authentication: () -> untyped
12+
def authentication=: (untyped) -> untyped
13+
def authorization_class: () -> untyped
14+
def authorization_class=: (untyped) -> untyped
15+
def components: () -> untyped
16+
def components=: (untyped) -> untyped
17+
def content_page: () -> untyped
18+
def content_page=: (untyped) -> untyped
19+
def extra_styles: () -> untyped
20+
def extra_styles=: (untyped) -> untyped
21+
def helper_class: () -> untyped
22+
def helper_class=: (untyped) -> untyped
23+
def page_not_allowed: () -> untyped
24+
def page_not_allowed=: (untyped) -> untyped
25+
def page_not_found: () -> untyped
26+
def page_not_found=: (untyped) -> untyped
27+
def record_not_found: () -> untyped
28+
def record_not_found=: (untyped) -> untyped
29+
def repository: () -> untyped
30+
def repository=: (untyped) -> untyped
31+
def root: () -> untyped
32+
def root=: (untyped) -> untyped
33+
def root_path: () -> untyped
34+
def root_path=: (untyped) -> untyped
35+
def sections: () -> untyped
36+
def sections=: (untyped) -> untyped
37+
def scripts: () -> untyped
38+
def scripts=: (untyped) -> untyped
39+
def style_links: () -> untyped
40+
def style_links=: (untyped) -> untyped
41+
1042
def []: (*String | Symbol) -> untyped
1143

1244
def []=: (*String | Symbol, untyped) -> untyped

sig/tiny_admin/store.rbs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
module TinyAdmin
22
class Store
3+
include Utils
4+
35
attr_reader navbar: Array[Section?]
46
attr_reader pages: Hash[String, Hash[Symbol, untyped]]
57
attr_reader resources: Hash[String, Hash[Symbol, untyped]]

sig/tiny_admin/views/basic_layout.rbs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
module TinyAdmin
22
module Views
33
class BasicLayout
4+
include Utils
5+
46
attr_accessor content: untyped
57
attr_accessor params: untyped
68
attr_accessor widgets: untyped

sig/tiny_admin/views/default_layout.rbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module TinyAdmin
22
module Views
3-
class DefaultLayout
3+
class DefaultLayout < BasicLayout
44
attr_accessor flash_component: untyped?
55
attr_accessor head_component: untyped?
66
attr_accessor messages: Hash[Symbol, Array[String]?]?

0 commit comments

Comments
 (0)