diff --git a/build.gradle b/build.gradle index aea4cac316..b608212359 100644 --- a/build.gradle +++ b/build.gradle @@ -26,14 +26,6 @@ buildscript { google() mavenCentral() maven { url "https://jitpack.io" } - maven { - name = "GitHubPackages" - url = uri("https://maven.pkg.github.com/anytypeio/go-anytype-middleware") - credentials { - username = githubProperties['gpr.usr'] - password = githubProperties['gpr.key'] - } - } } if (ext.onCi) { diff --git a/docs/Setup_For_Middleware.md b/docs/Setup_For_Middleware.md index 0590a84240..d822439f54 100644 --- a/docs/Setup_For_Middleware.md +++ b/docs/Setup_For_Middleware.md @@ -5,7 +5,7 @@ - Remove all other golang installations (`which go` should report that nothing found) - Make a dir for golang `mkdir -p $HOME/golang` - Update brew by `brew update` -- Install from brew only a golang version mentioned here: [here](https://github.com/anytypeio/go-anytype-middleware#build-from-source) +- Install from brew only a golang version mentioned here: [here](https://github.com/anyproto/anytype-heart#build-from-source) For example: `brew install go@1.xx` - Remember a golang install path (`//go@1.xx/`) reported by brew diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 751ac2b281..f9322d1cf4 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,5 +1,5 @@ [versions] -middlewareVersion = "v0.26.2" +middlewareVersion = "v0.26.4" kotlinVersion = '1.7.10' androidxCoreVersion = "1.9.0" androidxComposeVersion1 = '1.3.1' @@ -67,7 +67,7 @@ coilComposeVersion = '2.2.2' sentryVersion = '5.0.1' [libraries] -middleware = { module = "io.anytype:android-mw", version.ref = "middlewareVersion" } +middleware = { module = "io.anyproto:anytype-heart-android", version.ref = "middlewareVersion" } androidxCore = { module = "androidx.core:core-ktx", version.ref = "androidxCoreVersion" } kotlin = { module = "org.jetbrains.kotlin:kotlin-stdlib", version.ref = "kotlinVersion" } kotlinTest = { module = "org.jetbrains.kotlin:kotlin-test-junit", version.ref = "kotlinVersion" } diff --git a/libs/build.gradle b/libs/build.gradle index 3d1ceced19..dfbd52c128 100644 --- a/libs/build.gradle +++ b/libs/build.gradle @@ -7,8 +7,8 @@ afterEvaluate { publications { myLocalPublication(MavenPublication) { artifact(file('lib.aar')) - groupId 'io.anytype' - artifactId 'android-mw' + groupId 'io.anyproto' + artifactId 'anytype-heart-android' version = '2.3.0' } } diff --git a/protocol/src/main/proto/commands.proto b/protocol/src/main/proto/commands.proto index f464091a3c..ee868bf418 100644 --- a/protocol/src/main/proto/commands.proto +++ b/protocol/src/main/proto/commands.proto @@ -3055,6 +3055,7 @@ message Rpc { anytype.model.Block block = 3; anytype.model.Block.Position position = 4; anytype.model.Block.Content.Widget.Layout widgetLayout = 5; + int32 objectLimit = 6; } message Response { @@ -5106,6 +5107,80 @@ message Rpc { } } + message BlockWidget { + message SetTargetId { + message Request { + string contextId = 1; + string blockId = 2; + string targetId = 3; + } + + message Response { + Error error = 1; + ResponseEvent event = 2; + + message Error { + Code code = 1; + string description = 2; + + enum Code { + NULL = 0; + UNKNOWN_ERROR = 1; + BAD_INPUT = 2; + } + } + } + } + + message SetLayout { + message Request { + string contextId = 1; + string blockId = 2; + anytype.model.Block.Content.Widget.Layout layout = 3; + } + + message Response { + Error error = 1; + ResponseEvent event = 2; + + message Error { + Code code = 1; + string description = 2; + + enum Code { + NULL = 0; + UNKNOWN_ERROR = 1; + BAD_INPUT = 2; + } + } + } + } + + message SetLimit { + message Request { + string contextId = 1; + string blockId = 2; + int32 limit = 3; + } + + message Response { + Error error = 1; + ResponseEvent event = 2; + + message Error { + Code code = 1; + string description = 2; + + enum Code { + NULL = 0; + UNKNOWN_ERROR = 1; + BAD_INPUT = 2; + } + } + } + } + } + message Debug { message TreeInfo { diff --git a/protocol/src/main/proto/events.proto b/protocol/src/main/proto/events.proto index a55d3454e3..23e037de57 100644 --- a/protocol/src/main/proto/events.proto +++ b/protocol/src/main/proto/events.proto @@ -494,10 +494,15 @@ message Event { message Widget { string id = 1; Layout layout = 2; + Limit limit = 3; message Layout { anytype.model.Block.Content.Widget.Layout value = 1; } + + message Limit { + int32 value = 1; + } } } diff --git a/protocol/src/main/proto/models.proto b/protocol/src/main/proto/models.proto index 38c705e016..2a5de9a51b 100644 --- a/protocol/src/main/proto/models.proto +++ b/protocol/src/main/proto/models.proto @@ -496,6 +496,7 @@ message Block { message Widget { Layout layout = 1; + int32 limit = 2; enum Layout { Link = 0; diff --git a/settings.gradle b/settings.gradle index ab562671bf..6ef9e31488 100644 --- a/settings.gradle +++ b/settings.gradle @@ -24,7 +24,7 @@ dependencyResolutionManagement { maven { url "https://jitpack.io" } maven { name = "GitHubPackages" - url = uri("https://maven.pkg.github.com/anytypeio/go-anytype-middleware") + url = uri("https://maven.pkg.github.com/anyproto/anytype-heart") credentials { username = githubProperties['gpr.usr'] password = githubProperties['gpr.key']