diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..783c54e5 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,74 @@ +# To get started with Dependabot version updates, you'll need to specify which +# package ecosystems to update and where the package manifests are located. +# Please see the documentation for all configuration options: +# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file + +version: 2 +updates: + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "monthly" + groups: + "GitHub Actions updates": + patterns: + - "*" + - package-ecosystem: "gomod" + directory: "/backend" + schedule: + interval: "monthly" + groups: + "Go modules updates": + dependency-type: "production" + - package-ecosystem: "gomod" + directory: "/backend/_example/memory_store" + schedule: + interval: "monthly" + groups: + "Go modules updates": + dependency-type: "production" + - package-ecosystem: "npm" + directory: "/frontend" + schedule: + interval: "monthly" + groups: + "NPM modules updates": + dependency-type: "production" + "NPM modules updates for tests": + dependency-type: "development" + - package-ecosystem: "npm" + directory: "/frontend/packages/api" + schedule: + interval: "monthly" + groups: + "NPM modules updates": + dependency-type: "production" + "NPM modules updates for tests": + dependency-type: "development" + - package-ecosystem: "npm" + directory: "/frontend/e2e" + schedule: + interval: "monthly" + groups: + "NPM modules updates": + dependency-type: "production" + "NPM modules updates for tests": + dependency-type: "development" + - package-ecosystem: "npm" + directory: "/frontend/apps/remark42" + schedule: + interval: "monthly" + groups: + "NPM modules updates": + dependency-type: "production" + "NPM modules updates for tests": + dependency-type: "development" + - package-ecosystem: "npm" + directory: "/site" + schedule: + interval: "monthly" + groups: + "NPM modules updates": + dependency-type: "production" + "NPM modules updates for tests": + dependency-type: "development" diff --git a/.github/workflows/ci-backend.yml b/.github/workflows/ci-backend.yml index 90784bcc..1cfc5c6a 100644 --- a/.github/workflows/ci-backend.yml +++ b/.github/workflows/ci-backend.yml @@ -32,7 +32,7 @@ jobs: - name: install go uses: actions/setup-go@v5 with: - go-version: "1.21" + go-version: "1.23" - name: test and build backend run: | @@ -52,15 +52,15 @@ jobs: TZ: "America/Chicago" - name: golangci-lint - uses: golangci/golangci-lint-action@v3 + uses: golangci/golangci-lint-action@v6 with: - version: v1.58 + version: v1.61.0 working-directory: backend/app - name: golangci-lint on example directory - uses: golangci/golangci-lint-action@v3 + uses: golangci/golangci-lint-action@v6 with: - version: v1.58 + version: v1.61.0 args: --config ../../.golangci.yml working-directory: backend/_example/memory_store diff --git a/.github/workflows/ci-frontend-api.yml b/.github/workflows/ci-frontend-api.yml index 2aaf0676..929ed887 100644 --- a/.github/workflows/ci-frontend-api.yml +++ b/.github/workflows/ci-frontend-api.yml @@ -20,7 +20,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [16.20.2] + node: [ 16 ] steps: - name: Checkout @@ -32,7 +32,7 @@ jobs: node-version: ${{ matrix.node }} - name: Install pnpm - uses: pnpm/action-setup@v2.4.0 + uses: pnpm/action-setup@v4.0.0 id: pnpm-install with: version: 7 @@ -44,7 +44,7 @@ jobs: echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" - name: Setup pnpm cache - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} @@ -64,7 +64,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [16.20.2] + node: [ 16 ] steps: - name: Checkout @@ -76,7 +76,7 @@ jobs: node-version: ${{ matrix.node }} - name: Install pnpm - uses: pnpm/action-setup@v2.4.0 + uses: pnpm/action-setup@v4.0.0 id: pnpm-install with: version: 7 @@ -88,7 +88,7 @@ jobs: echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" - name: Setup pnpm cache - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} @@ -108,7 +108,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [16.20.2] + node: [ 16 ] steps: - name: Checkout @@ -120,7 +120,7 @@ jobs: node-version: ${{ matrix.node }} - name: Install pnpm - uses: pnpm/action-setup@v2.4.0 + uses: pnpm/action-setup@v4.0.0 id: pnpm-install with: version: 7 @@ -132,7 +132,7 @@ jobs: echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" - name: Setup pnpm cache - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} @@ -147,7 +147,9 @@ jobs: run: pnpm coverage:api working-directory: ./frontend - - name: Submit coverage - run: ${{ github.workspace }}/frontend/apps/remark42/node_modules/.bin/codecov - env: - CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} + - name: Upload coverage to Codecov + uses: codecov/codecov-action@v4 + with: + token: ${{ secrets.CODECOV_TOKEN }} + working-directory: ./frontend + codecov_yml_path: ./frontend/apps/remark42/codecov.yml diff --git a/.github/workflows/ci-frontend.yml b/.github/workflows/ci-frontend.yml index e7b2a9d3..e279f9eb 100644 --- a/.github/workflows/ci-frontend.yml +++ b/.github/workflows/ci-frontend.yml @@ -20,7 +20,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [16.20.2] + node: [16] steps: - name: Checkout @@ -32,7 +32,7 @@ jobs: node-version: ${{ matrix.node }} - name: Install pnpm - uses: pnpm/action-setup@v2.4.0 + uses: pnpm/action-setup@v4.0.0 id: pnpm-install with: version: 7 @@ -44,7 +44,7 @@ jobs: echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" - name: Setup pnpm cache - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} @@ -64,7 +64,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [16.20.2] + node: [16] steps: - name: Checkout @@ -76,7 +76,7 @@ jobs: node-version: ${{ matrix.node }} - name: Install pnpm - uses: pnpm/action-setup@v2.4.0 + uses: pnpm/action-setup@v4.0.0 id: pnpm-install with: version: 7 @@ -88,7 +88,7 @@ jobs: echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" - name: Setup pnpm cache - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} @@ -108,7 +108,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [16.20.2] + node: [16] steps: - name: Checkout @@ -120,7 +120,7 @@ jobs: node-version: ${{ matrix.node }} - name: Install pnpm - uses: pnpm/action-setup@v2.4.0 + uses: pnpm/action-setup@v4.0.0 id: pnpm-install with: version: 7 @@ -132,7 +132,7 @@ jobs: echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" - name: Setup pnpm cache - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} @@ -158,14 +158,14 @@ jobs: uses: actions/checkout@v4 - name: Install pnpm - uses: pnpm/action-setup@v2.4.0 + uses: pnpm/action-setup@v4.0.0 id: pnpm-install with: version: 7 run_install: false - name: Check bundle size - uses: andresz1/size-limit-action@7313b26c76b3666c1dc41e2ca05370e201a9b7de + uses: andresz1/size-limit-action@94bc357df29c36c8f8d50ea497c3e225c3c95d1d with: github_token: ${{ secrets.GITHUB_TOKEN }} directory: ./frontend/apps/remark42 @@ -176,7 +176,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [16.20.2] + node: [16] steps: - name: Checkout @@ -188,7 +188,7 @@ jobs: node-version: ${{ matrix.node }} - name: Install pnpm - uses: pnpm/action-setup@v2.4.0 + uses: pnpm/action-setup@v4.0.0 id: pnpm-install with: version: 7 @@ -200,7 +200,7 @@ jobs: echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" - name: Setup pnpm cache - uses: actions/cache@v3 + uses: actions/cache@v4 with: path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} @@ -215,7 +215,9 @@ jobs: run: pnpm coverage working-directory: ./frontend/apps/remark42 - - name: Submit coverage - run: ${{ github.workspace }}/frontend/apps/remark42/node_modules/.bin/codecov - env: - CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} + - name: Upload coverage to Codecov + uses: codecov/codecov-action@v4 + with: + token: ${{ secrets.CODECOV_TOKEN }} + working-directory: ./frontend/apps/remark42 + codecov_yml_path: ./frontend/apps/remark42/codecov.yml diff --git a/.github/workflows/e2e-tests.yml b/.github/workflows/e2e-tests.yml index 69e3379c..37c8f2a0 100644 --- a/.github/workflows/e2e-tests.yml +++ b/.github/workflows/e2e-tests.yml @@ -28,7 +28,7 @@ jobs: id: tests run: COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose -f compose-e2e-test.yml up --build --quiet-pull --exit-code-from tests - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v4 if: always() with: name: playwright-report diff --git a/Dockerfile b/Dockerfile index 01e0e06f..a79fae89 100644 --- a/Dockerfile +++ b/Dockerfile @@ -45,7 +45,7 @@ RUN \ echo 'Skip frontend build'; \ fi -FROM umputun/baseimage:buildgo-v1.13.0 as build-backend +FROM umputun/baseimage:buildgo-v1.14.0 AS build-backend ARG CI ARG GITHUB_REF @@ -81,7 +81,7 @@ RUN \ echo "version=$version" && \ go build -o remark42 -ldflags "-X main.revision=${version} -s -w" ./app -FROM umputun/baseimage:app-v1.13.0 +FROM umputun/baseimage:app-v1.14.0 ARG GITHUB_SHA diff --git a/Dockerfile.artifacts b/Dockerfile.artifacts index 35737da9..2a6ee60d 100644 --- a/Dockerfile.artifacts +++ b/Dockerfile.artifacts @@ -1,4 +1,4 @@ -FROM node:16.20.2-alpine AS frontend-deps +FROM node:16-alpine AS frontend-deps ENV CI=true @@ -19,7 +19,7 @@ WORKDIR /srv/frontend/apps/remark42/ COPY ./frontend/apps/remark42/ /srv/frontend/apps/remark42/ RUN pnpm build -FROM umputun/baseimage:buildgo-v1.13.0 as build-backend +FROM umputun/baseimage:buildgo-v1.14.0 AS build-backend ARG GITHUB_TOKEN ARG GITHUB_REF diff --git a/Makefile b/Makefile index 68071776..620dc372 100644 --- a/Makefile +++ b/Makefile @@ -39,15 +39,15 @@ race_test: cd backend/app && go test -race -timeout=60s -count 1 ./... backend: - docker-compose -f compose-dev-backend.yml build + docker compose -f compose-dev-backend.yml build frontend: - docker-compose -f compose-dev-frontend.yml build + docker compose -f compose-dev-frontend.yml build rundev: SKIP_BACKEND_TEST=true SKIP_FRONTEND_TEST=true GITHUB_REF=$(GITHUB_REF) GITHUB_SHA=$(GITHUB_SHA) CI=true \ - docker-compose -f compose-private.yml build - docker-compose -f compose-private.yml up + docker compose -f compose-private.yml build + docker compose -f compose-private.yml up e2e: docker compose -f compose-e2e-test.yml up --build --quiet-pull --exit-code-from tests diff --git a/README.md b/README.md index 3ea32b9e..79aa3045 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ Remark42 is a self-hosted, lightweight and simple (yet functional) comment engine, which doesn't spy on users. It can be embedded into blogs, articles, or any other place where readers add comments. -* Social login via Google, Twitter, Facebook, Microsoft, GitHub, Yandex, Patreon, Discord and Telegram +* Social login via Google, Facebook, Microsoft, GitHub, Apple, Yandex, Patreon, Discord and Telegram * Login via email * Optional anonymous access * Multi-level nested comments with both tree and plain presentations diff --git a/backend/.golangci.yml b/backend/.golangci.yml index 5a9ed665..e6929d67 100644 --- a/backend/.golangci.yml +++ b/backend/.golangci.yml @@ -26,8 +26,8 @@ linters-settings: linters: enable: - bodyclose + - copyloopvar - dupl - - exportloopref - gochecknoinits - gocritic - gocyclo diff --git a/backend/_example/memory_store/Dockerfile b/backend/_example/memory_store/Dockerfile index d9abf6fa..3f1fd996 100644 --- a/backend/_example/memory_store/Dockerfile +++ b/backend/_example/memory_store/Dockerfile @@ -1,11 +1,11 @@ -FROM umputun/baseimage:buildgo-v1.13.0 as build-backend +FROM umputun/baseimage:buildgo-v1.14.0 AS build-backend ADD backend /build/backend WORKDIR /build/backend/_example/memory_store RUN go build -o /build/bin/memory_store -ldflags "-X main.revision=0.0.0 -s -w" -FROM umputun/baseimage:app-v1.13.0 +FROM umputun/baseimage:app-v1.14.0 ARG GITHUB_SHA diff --git a/backend/_example/memory_store/README.md b/backend/_example/memory_store/README.md index 8e0654a6..2dd978c5 100644 --- a/backend/_example/memory_store/README.md +++ b/backend/_example/memory_store/README.md @@ -4,9 +4,9 @@ In order to run remark42 with memory_store copy provided `compose-dev-memstore.yml` to the root directory and run: -1. `docker-compose -f compose-dev-memstore.yml build` -1. `docker-compose -f compose-dev-memstore.yml up` +1. `docker compose -f compose-dev-memstore.yml build` +1. `docker compose -f compose-dev-memstore.yml up` As usual, demo site will run on http://127.0.0.1:8080/web/ -note: in order to work with the latest (current) version of master `go.mod` uses replacement directive for the backend package. In real-life usage `replace github.com/umputun/remark42/backend => ../../` should not be used. \ No newline at end of file +note: in order to work with the latest (current) version of master `go.mod` uses replacement directive for the backend package. In real-life usage `replace github.com/umputun/remark42/backend => ../../` should not be used. diff --git a/backend/_example/memory_store/go.mod b/backend/_example/memory_store/go.mod index 99a47968..f3a3e83e 100644 --- a/backend/_example/memory_store/go.mod +++ b/backend/_example/memory_store/go.mod @@ -1,6 +1,6 @@ module github.com/umputun/remark42/memory_store -go 1.21 +go 1.23 require ( github.com/go-pkgz/jrpc v0.3.0 @@ -12,9 +12,9 @@ require ( require ( github.com/Depado/bfchroma/v2 v2.0.0 // indirect - github.com/PuerkitoBio/goquery v1.9.2 // indirect + github.com/PuerkitoBio/goquery v1.10.0 // indirect github.com/ajg/form v1.5.1 // indirect - github.com/alecthomas/chroma/v2 v2.13.0 // indirect + github.com/alecthomas/chroma/v2 v2.14.0 // indirect github.com/andybalholm/cascadia v1.3.2 // indirect github.com/aymerick/douceur v0.2.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect @@ -30,13 +30,12 @@ require ( github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/microcosm-cc/bluemonday v1.0.27 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect - github.com/rs/xid v1.5.0 // indirect + github.com/rs/xid v1.6.0 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect - go.etcd.io/bbolt v1.3.10 // indirect - golang.org/x/image v0.18.0 // indirect - golang.org/x/net v0.27.0 // indirect - golang.org/x/sys v0.22.0 // indirect - gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect + go.etcd.io/bbolt v1.3.11 // indirect + golang.org/x/image v0.22.0 // indirect + golang.org/x/net v0.29.0 // indirect + golang.org/x/sys v0.25.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/backend/_example/memory_store/go.sum b/backend/_example/memory_store/go.sum index f9c642cb..93cbf3be 100644 --- a/backend/_example/memory_store/go.sum +++ b/backend/_example/memory_store/go.sum @@ -1,13 +1,13 @@ github.com/Depado/bfchroma/v2 v2.0.0 h1:IRpN9BPkNwEpR6w1ectIcNWOuhDSLx+8f1pn83fzxx8= github.com/Depado/bfchroma/v2 v2.0.0/go.mod h1:wFwW/Pw8Tnd0irzgO9Zxtxgzp3aPS8qBWlyadxujxmw= -github.com/PuerkitoBio/goquery v1.9.2 h1:4/wZksC3KgkQw7SQgkKotmKljk0M6V8TUvA8Wb4yPeE= -github.com/PuerkitoBio/goquery v1.9.2/go.mod h1:GHPCaP0ODyyxqcNoFGYlAprUFH81NuRPd0GX3Zu2Mvk= +github.com/PuerkitoBio/goquery v1.10.0 h1:6fiXdLuUvYs2OJSvNRqlNPoBm6YABE226xrbavY5Wv4= +github.com/PuerkitoBio/goquery v1.10.0/go.mod h1:TjZZl68Q3eGHNBA8CWaxAN7rOU1EbDz3CWuolcO5Yu4= github.com/ajg/form v1.5.1 h1:t9c7v8JUKu/XxOGBU0yjNpaMloxGEJhUkqFRq0ibGeU= github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= -github.com/alecthomas/assert/v2 v2.6.0 h1:o3WJwILtexrEUk3cUVal3oiQY2tfgr/FHWiz/v2n4FU= -github.com/alecthomas/assert/v2 v2.6.0/go.mod h1:Bze95FyfUr7x34QZrjL+XP+0qgp/zg8yS+TtBj1WA3k= -github.com/alecthomas/chroma/v2 v2.13.0 h1:VP72+99Fb2zEcYM0MeaWJmV+xQvz5v5cxRHd+ooU1lI= -github.com/alecthomas/chroma/v2 v2.13.0/go.mod h1:BUGjjsD+ndS6eX37YgTchSEG+Jg9Jv1GiZs9sqPqztk= +github.com/alecthomas/assert/v2 v2.7.0 h1:QtqSACNS3tF7oasA8CU6A6sXZSBDqnm7RfpLl9bZqbE= +github.com/alecthomas/assert/v2 v2.7.0/go.mod h1:Bze95FyfUr7x34QZrjL+XP+0qgp/zg8yS+TtBj1WA3k= +github.com/alecthomas/chroma/v2 v2.14.0 h1:R3+wzpnUArGcQz7fCETQBzO5n9IMNi13iIs46aU4V9E= +github.com/alecthomas/chroma/v2 v2.14.0/go.mod h1:QolEbTfmUHIMVpBqxeDnNBj2uoeI4EbYP4i6n68SG4I= github.com/alecthomas/repr v0.4.0 h1:GhI2A8MACjfegCPVq9f1FLvIBS+DrQ2KQBFZP1iFzXc= github.com/alecthomas/repr v0.4.0/go.mod h1:Fr0507jx4eOXV7AlPV6AVZLYrLIuIeSOWtW57eE/O/4= github.com/andybalholm/cascadia v1.3.2 h1:3Xi6Dw5lHF15JtdcmAHD3i1+T8plmv7BQ/nsViSLyss= @@ -63,8 +63,8 @@ github.com/microcosm-cc/bluemonday v1.0.27/go.mod h1:jFi9vgW+H7c3V0lb6nR74Ib/DIB github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/rs/xid v1.5.0 h1:mKX4bl4iPYJtEIxp6CYiUuLQ/8DYMoz0PUdtGgMFRVc= -github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= +github.com/rs/xid v1.6.0 h1:fV591PaemRlL6JfRxGDEPl69wICngIQ3shQtzfy2gxU= +github.com/rs/xid v1.6.0/go.mod h1:7XoLgs4eV+QndskICGsho+ADou8ySMSjJKDIan90Nz0= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= @@ -75,12 +75,12 @@ github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= -go.etcd.io/bbolt v1.3.10 h1:+BqfJTcCzTItrop8mq/lbzL8wSGtj94UO/3U31shqG0= -go.etcd.io/bbolt v1.3.10/go.mod h1:bK3UQLPJZly7IlNmV7uVHJDxfe5aK9Ll93e/74Y9oEQ= +go.etcd.io/bbolt v1.3.11 h1:yGEzV1wPz2yVCLsD8ZAiGHhHVlczyC9d1rP43/VCRJ0= +go.etcd.io/bbolt v1.3.11/go.mod h1:dksAq7YMXoljX0xu6VF5DMZGbhYYoLUalEiSySYAS4I= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/image v0.18.0 h1:jGzIakQa/ZXI1I0Fxvaa9W7yP25TqT6cHIHn+6CqvSQ= -golang.org/x/image v0.18.0/go.mod h1:4yyo5vMFQjVjUcVk4jEQcU9MGy/rulF5WvUILseCM2E= +golang.org/x/image v0.22.0 h1:UtK5yLUzilVrkjMAZAZ34DXGpASN8i8pj8g+O+yd10g= +golang.org/x/image v0.22.0/go.mod h1:9hPFhljd4zZ1GNSIZJ49sqbp45GKK9t6w+iXvGqZUz4= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -88,13 +88,13 @@ golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.9.0/go.mod h1:d48xBJpPfHeWQsugry2m+kC02ZBRGRgulfHnEXEuWns= -golang.org/x/net v0.27.0 h1:5K3Njcw06/l2y9vpGCSdcxWOYHOUk3dVNGDXN+FvAys= -golang.org/x/net v0.27.0/go.mod h1:dDi0PyhWNoiUOrAS8uXv/vnScO4wnHQO4mj9fn/RytE= +golang.org/x/net v0.29.0 h1:5ORfpBpCs4HzDYoodCDBbwHzdR5UrLBZ3sOnUJmFoHo= +golang.org/x/net v0.29.0/go.mod h1:gLkgy8jTGERgjzMic6DS9+SP0ajcu6Xu3Orq/SpETg0= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M= -golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.9.0 h1:fEo0HyrW1GIgZdpbhCRO0PkJajUS5H9IFUztCgEo2jQ= +golang.org/x/sync v0.9.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -102,8 +102,8 @@ golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.7.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.22.0 h1:RI27ohtqKCnwULzJLqkv897zojh5/DwS/ENaMzUOaWI= -golang.org/x/sys v0.22.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34= +golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= @@ -119,9 +119,8 @@ golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 h1:qIbj1fsPNlZgppZ+VLlY7N33q108Sa+fhmuc+sWQYwY= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/backend/app/cmd/cleanup_test.go b/backend/app/cmd/cleanup_test.go index 05bbd678..4a102874 100644 --- a/backend/app/cmd/cleanup_test.go +++ b/backend/app/cmd/cleanup_test.go @@ -46,7 +46,6 @@ func TestCleanup_IsSpam(t *testing.T) { } for n, tt := range tbl { - tt := tt checkName := fmt.Sprintf("check-%d-%s", n, tt.name) t.Run(checkName, func(t *testing.T) { c := store.Comment{ID: checkName, Text: tt.text, Score: tt.score} diff --git a/backend/app/cmd/server.go b/backend/app/cmd/server.go index ef7ee611..3810c5ca 100644 --- a/backend/app/cmd/server.go +++ b/backend/app/cmd/server.go @@ -85,7 +85,7 @@ type ServerCommand struct { EnableEmoji bool `long:"emoji" env:"EMOJI" description:"enable emoji"` SimpleView bool `long:"simple-view" env:"SIMPLE_VIEW" description:"minimal comment editor mode"` ProxyCORS bool `long:"proxy-cors" env:"PROXY_CORS" description:"disable internal CORS and delegate it to proxy"` - AllowedHosts []string `long:"allowed-hosts" env:"ALLOWED_HOSTS" description:"limit hosts/sources allowed to embed comments" env-delim:","` + AllowedHosts []string `long:"allowed-hosts" env:"ALLOWED_HOSTS" description:"limit hosts/sources allowed to embed comments via CSP 'frame-ancestors''" env-delim:","` SubscribersOnly bool `long:"subscribers-only" env:"SUBSCRIBERS_ONLY" description:"enable commenting only for Patreon subscribers"` DisableSignature bool `long:"disable-signature" env:"DISABLE_SIGNATURE" description:"disable server signature in headers"` DisableFancyTextFormatting bool `long:"disable-fancy-text-formatting" env:"DISABLE_FANCY_TEXT_FORMATTING" description:"disable fancy comments text formatting (replacement of quotes, dashes, fractions, etc)"` @@ -105,7 +105,7 @@ type ServerCommand struct { Facebook AuthGroup `group:"facebook" namespace:"facebook" env-namespace:"FACEBOOK" description:"Facebook OAuth"` Microsoft AuthGroup `group:"microsoft" namespace:"microsoft" env-namespace:"MICROSOFT" description:"Microsoft OAuth"` Yandex AuthGroup `group:"yandex" namespace:"yandex" env-namespace:"YANDEX" description:"Yandex OAuth"` - Twitter AuthGroup `group:"twitter" namespace:"twitter" env-namespace:"TWITTER" description:"Twitter OAuth"` + Twitter AuthGroup `group:"twitter" namespace:"twitter" env-namespace:"TWITTER" description:"[deprecated, doesn't work] Twitter OAuth"` Patreon AuthGroup `group:"patreon" namespace:"patreon" env-namespace:"PATREON" description:"Patreon OAuth"` Discord AuthGroup `group:"discord" namespace:"discord" env-namespace:"DISCORD" description:"Discord OAuth"` Telegram bool `long:"telegram" env:"TELEGRAM" description:"Enable Telegram auth (using token from telegram.token)"` @@ -314,6 +314,7 @@ func (s *ServerCommand) Execute(_ []string) error { log.Printf("[INFO] start server on port %s:%d", s.Address, s.Port) resetEnv( "SECRET", + "AUTH_APPLE_KID", "AUTH_GOOGLE_CSEC", "AUTH_GITHUB_CSEC", "AUTH_FACEBOOK_CSEC", @@ -408,6 +409,12 @@ func (s *ServerCommand) HandleDeprecatedFlags() (result []DeprecatedFlag) { if s.Notify.Telegram.API != "https://api.telegram.org/bot" { result = append(result, DeprecatedFlag{Old: "notify.telegram.api", Version: "1.9"}) } + if s.Auth.Twitter.CID != "" { + result = append(result, DeprecatedFlag{Old: "auth.twitter.cid", Version: "1.14"}) + } + if s.Auth.Twitter.CSEC != "" { + result = append(result, DeprecatedFlag{Old: "auth.twitter.csec", Version: "1.14"}) + } return append(result, s.findDeprecatedFlagsCollisions()...) } diff --git a/backend/app/cmd/server_test.go b/backend/app/cmd/server_test.go index 977af0ca..7ff6ac03 100644 --- a/backend/app/cmd/server_test.go +++ b/backend/app/cmd/server_test.go @@ -457,6 +457,8 @@ func TestServerApp_DeprecatedArgs(t *testing.T) { "--notify.telegram.token=abcd", "--notify.telegram.timeout=3m", "--notify.telegram.api=http://example.org", + "--auth.twitter.cid=123", + "--auth.twitter.csec=456", } assert.Empty(t, s.SMTP.Host) assert.Empty(t, s.SMTP.Port) @@ -482,6 +484,8 @@ func TestServerApp_DeprecatedArgs(t *testing.T) { {Old: "notify.telegram.token", New: "telegram.token", Version: "1.9"}, {Old: "notify.telegram.timeout", New: "telegram.timeout", Version: "1.9"}, {Old: "notify.telegram.api", Version: "1.9"}, + {Old: "auth.twitter.cid", Version: "1.14"}, + {Old: "auth.twitter.csec", Version: "1.14"}, }, deprecatedFlags) assert.Equal(t, "smtp.example.org", s.SMTP.Host) @@ -697,7 +701,6 @@ func TestServerCommand_parseSameSite(t *testing.T) { cmd := ServerCommand{} for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { assert.Equal(t, tt.res, cmd.parseSameSite(tt.inp)) }) diff --git a/backend/app/notify/email_test.go b/backend/app/notify/email_test.go index 622882d0..87f42ad4 100644 --- a/backend/app/notify/email_test.go +++ b/backend/app/notify/email_test.go @@ -88,7 +88,6 @@ func Test_initTemplatesErr(t *testing.T) { } for _, d := range testSet { - d := d t.Run(d.name, func(t *testing.T) { e, err := NewEmail(d.emailParams, ntf.SMTPParams{}) require.Error(t, err) diff --git a/backend/app/rest/api/rest.go b/backend/app/rest/api/rest.go index 9f38e45b..293e793d 100644 --- a/backend/app/rest/api/rest.go +++ b/backend/app/rest/api/rest.go @@ -624,9 +624,9 @@ func cacheControl(expiration time.Duration, version string) func(http.Handler) h func securityHeadersMiddleware(imageProxyEnabled bool, allowedAncestors []string) func(http.Handler) http.Handler { return func(next http.Handler) http.Handler { return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { - imgSrc := "'self'" + imgSrc := "*" if imageProxyEnabled { - imgSrc = "*" + imgSrc = "'self'" } frameAncestors := "*" if len(allowedAncestors) > 0 { diff --git a/backend/app/rest/api/rest_private_test.go b/backend/app/rest/api/rest_private_test.go index b9ba503d..cea721fb 100644 --- a/backend/app/rest/api/rest_private_test.go +++ b/backend/app/rest/api/rest_private_test.go @@ -916,7 +916,6 @@ func TestRest_EmailAndTelegram(t *testing.T) { client := http.Client{} defer client.CloseIdleConnections() for _, x := range testData { - x := x t.Run(x.description, func(t *testing.T) { reqBody := io.NopCloser(strings.NewReader(x.body)) if x.body == "" { diff --git a/backend/app/rest/api/rest_test.go b/backend/app/rest/api/rest_test.go index 63f19e34..804e2c21 100644 --- a/backend/app/rest/api/rest_test.go +++ b/backend/app/rest/api/rest_test.go @@ -227,7 +227,6 @@ func Test_URLKey(t *testing.T) { } for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { r, err := http.NewRequest("GET", tt.url, http.NoBody) require.NoError(t, err) @@ -252,7 +251,6 @@ func Test_URLKeyWithUser(t *testing.T) { } for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { r, err := http.NewRequest("GET", tt.url, http.NoBody) require.NoError(t, err) @@ -279,7 +277,6 @@ func TestRest_parseError(t *testing.T) { } for n, tt := range tbl { - tt := tt t.Run(strconv.Itoa(n), func(t *testing.T) { res := parseError(tt.err, rest.ErrInternal) assert.Equal(t, tt.res, res) @@ -302,7 +299,6 @@ func TestRest_cacheControl(t *testing.T) { } for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { req := httptest.NewRequest("GET", tt.url, http.NoBody) w := httptest.NewRecorder() @@ -345,6 +341,31 @@ func TestRest_frameAncestors(t *testing.T) { assert.Contains(t, resp.Header.Get("Content-Security-Policy"), "frame-ancestors *;") } +// check CSP, img-src should be 'self' with proxy enabled and * without it +func TestRest_securityHeaders(t *testing.T) { + ts, _, teardown := startupT(t) + + // with proxy disabled + client := http.Client{} + resp, err := client.Get(ts.URL + "/web/index.html") + require.NoError(t, err) + defer resp.Body.Close() + assert.Equal(t, http.StatusOK, resp.StatusCode) + assert.Contains(t, resp.Header.Get("Content-Security-Policy"), "img-src *;") + teardown() + + // check CSP with proxy enabled + ts, _, teardown = startupT(t, func(srv *Rest) { + srv.ExternalImageProxy = true + }) + defer teardown() + resp, err = client.Get(ts.URL + "/web/index.html") + require.NoError(t, err) + defer resp.Body.Close() + assert.Equal(t, http.StatusOK, resp.StatusCode) + assert.Contains(t, resp.Header.Get("Content-Security-Policy"), "img-src 'self';") +} + func TestRest_subscribersOnly(t *testing.T) { paidSubUser := &token.User{} paidSubUser.SetPaidSub(true) @@ -363,7 +384,6 @@ func TestRest_subscribersOnly(t *testing.T) { } for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { req := httptest.NewRequest("GET", "http://example.com", http.NoBody) if tt.setUser { diff --git a/backend/app/rest/proxy/image_test.go b/backend/app/rest/proxy/image_test.go index 0314b243..22c61f1b 100644 --- a/backend/app/rest/proxy/image_test.go +++ b/backend/app/rest/proxy/image_test.go @@ -77,7 +77,6 @@ func TestImage_Extract(t *testing.T) { img := Image{HTTP2HTTPS: true} for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { res, err := img.extract(tt.inp, func(src string) bool { return strings.HasPrefix(src, "http://") }) assert.NoError(t, err) diff --git a/backend/app/store/comment_test.go b/backend/app/store/comment_test.go index fe44817f..ce48d37e 100644 --- a/backend/app/store/comment_test.go +++ b/backend/app/store/comment_test.go @@ -209,7 +209,6 @@ func TestComment_Snippet(t *testing.T) { } for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { c := Comment{Text: tt.inp} out := c.Snippet(tt.limit) @@ -245,7 +244,6 @@ func TestComment_sanitizeAsURL(t *testing.T) { } for i, tt := range tbl { - tt := tt c := Comment{} t.Run(strconv.Itoa(i), func(t *testing.T) { assert.Equal(t, tt.out, c.SanitizeAsURL(tt.inp)) @@ -276,7 +274,6 @@ func TestComment_sanitizeText(t *testing.T) { } for i, tt := range tbl { - tt := tt c := Comment{} t.Run(strconv.Itoa(i), func(t *testing.T) { assert.Equal(t, tt.out, c.SanitizeText(tt.inp)) diff --git a/backend/app/store/engine/bolt.go b/backend/app/store/engine/bolt.go index 6e2abc7f..38b8e29b 100644 --- a/backend/app/store/engine/bolt.go +++ b/backend/app/store/engine/bolt.go @@ -865,7 +865,6 @@ func (b *BoltDB) deleteUser(bdb *bolt.DB, siteID, userID string, mode store.Dele // get list of commentID for all user's comment comments := []commentInfo{} for _, postInfo := range posts { - postInfo := postInfo err = bdb.View(func(tx *bolt.Tx) error { postsBkt := tx.Bucket([]byte(postsBucketName)) postBkt := postsBkt.Bucket([]byte(postInfo.URL)) diff --git a/backend/app/store/formatter_test.go b/backend/app/store/formatter_test.go index 0b954798..3e11f043 100644 --- a/backend/app/store/formatter_test.go +++ b/backend/app/store/formatter_test.go @@ -50,7 +50,6 @@ func TestFormatter_FormatText(t *testing.T) { } f := NewCommentFormatter(mockConverter{}) for _, tt := range tbl { - tt := tt t.Run(tt.name, func(t *testing.T) { raw := strings.HasPrefix(tt.in, `no_smartpants`) t.Logf("raw: %v", raw) @@ -146,7 +145,6 @@ func TestCommentFormatter_lazyImage(t *testing.T) { f := NewCommentFormatter(nil) for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { assert.Equal(t, tt.out, f.lazyImage(tt.inp)) }) diff --git a/backend/app/store/image/fs_store_test.go b/backend/app/store/image/fs_store_test.go index 1c5e564a..82083e4a 100644 --- a/backend/app/store/image/fs_store_test.go +++ b/backend/app/store/image/fs_store_test.go @@ -173,7 +173,6 @@ func TestFsStore_location(t *testing.T) { {0, "user/12345", "/tmp/user/12345"}, } for n, tt := range tbl { - tt := tt t.Run(strconv.Itoa(n), func(t *testing.T) { svc := FileSystem{Location: "/tmp", Partitions: tt.partitions} assert.Equal(t, tt.res, svc.location("/tmp", tt.id)) diff --git a/backend/app/store/image/image_test.go b/backend/app/store/image/image_test.go index baf9f9e5..edc616f4 100644 --- a/backend/app/store/image/image_test.go +++ b/backend/app/store/image/image_test.go @@ -259,7 +259,6 @@ func TestGetProportionalSizes(t *testing.T) { } for i, tt := range tbl { - tt := tt t.Run(strconv.Itoa(i), func(t *testing.T) { resW, resH := getProportionalSizes(tt.inpW, tt.inpH, tt.limitW, tt.limitH) assert.Equal(t, tt.resW, resW, "width") diff --git a/backend/app/store/service/service_test.go b/backend/app/store/service/service_test.go index 56ae8c10..1c203669 100644 --- a/backend/app/store/service/service_test.go +++ b/backend/app/store/service/service_test.go @@ -771,7 +771,6 @@ func TestService_Controversy(t *testing.T) { b := DataStore{} for i, tt := range tbl { - tt := tt t.Run(fmt.Sprintf("check-%d-%d:%d", i, tt.ups, tt.downs), func(t *testing.T) { assert.InDelta(t, tt.res, b.controversy(tt.ups, tt.downs), 0.01) }) diff --git a/backend/app/store/service/title_test.go b/backend/app/store/service/title_test.go index 5a949edd..3e362b33 100644 --- a/backend/app/store/service/title_test.go +++ b/backend/app/store/service/title_test.go @@ -31,7 +31,6 @@ func TestTitle_GetTitle(t *testing.T) { ex := NewTitleExtractor(http.Client{Timeout: 5 * time.Second}, []string{}) defer ex.Close() for i, tt := range tbl { - tt := tt t.Run(fmt.Sprintf("check-%d", i), func(t *testing.T) { title, ok := ex.getTitle(strings.NewReader(tt.page)) assert.Equal(t, tt.ok, ok) diff --git a/backend/go.mod b/backend/go.mod index e80fd222..a40d7f54 100644 --- a/backend/go.mod +++ b/backend/go.mod @@ -1,11 +1,13 @@ module github.com/umputun/remark42/backend -go 1.21 +go 1.23 + +toolchain go1.23.3 require ( github.com/Depado/bfchroma/v2 v2.0.0 - github.com/PuerkitoBio/goquery v1.9.2 - github.com/alecthomas/chroma/v2 v2.13.0 + github.com/PuerkitoBio/goquery v1.10.0 + github.com/alecthomas/chroma/v2 v2.14.0 github.com/didip/tollbooth/v7 v7.0.2 github.com/didip/tollbooth_chi v0.0.0-20220719025231-d662a7f6928f github.com/go-chi/chi/v5 v5.1.0 @@ -15,8 +17,8 @@ require ( github.com/go-pkgz/jrpc v0.3.0 github.com/go-pkgz/lcw/v2 v2.0.0 github.com/go-pkgz/lgr v0.11.1 - github.com/go-pkgz/notify v1.1.1 - github.com/go-pkgz/repeater v1.1.3 + github.com/go-pkgz/notify v1.2.0 + github.com/go-pkgz/repeater v1.2.0 github.com/go-pkgz/rest v1.19.0 github.com/go-pkgz/syncs v1.3.2 github.com/golang-jwt/jwt v3.2.2+incompatible @@ -26,15 +28,15 @@ require ( github.com/jessevdk/go-flags v1.6.1 github.com/kyokomi/emoji/v2 v2.2.13 github.com/microcosm-cc/bluemonday v1.0.27 - github.com/rs/xid v1.5.0 + github.com/rs/xid v1.6.0 github.com/russross/blackfriday/v2 v2.1.0 github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e github.com/stretchr/testify v1.9.0 - go.etcd.io/bbolt v1.3.10 + go.etcd.io/bbolt v1.3.11 go.uber.org/goleak v1.3.0 - golang.org/x/crypto v0.25.0 - golang.org/x/image v0.18.0 - golang.org/x/net v0.27.0 + golang.org/x/crypto v0.27.0 + golang.org/x/image v0.22.0 + golang.org/x/net v0.29.0 ) require ( @@ -60,15 +62,15 @@ require ( github.com/pmezard/go-difflib v1.0.0 // indirect github.com/redis/go-redis/v9 v9.4.0 // indirect github.com/rrivera/identicon v0.0.0-20240116195454-d5ba35832c0d // indirect - github.com/slack-go/slack v0.12.5 // indirect + github.com/slack-go/slack v0.14.0 // indirect github.com/xdg-go/pbkdf2 v1.0.0 // indirect github.com/xdg-go/scram v1.1.2 // indirect github.com/xdg-go/stringprep v1.0.4 // indirect github.com/youmark/pkcs8 v0.0.0-20240726163527-a2c0da244d78 // indirect go.mongodb.org/mongo-driver v1.16.0 // indirect golang.org/x/oauth2 v0.21.0 // indirect - golang.org/x/sync v0.7.0 // indirect - golang.org/x/sys v0.22.0 // indirect - golang.org/x/text v0.16.0 // indirect + golang.org/x/sync v0.9.0 // indirect + golang.org/x/sys v0.25.0 // indirect + golang.org/x/text v0.20.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/backend/go.sum b/backend/go.sum index 3e304e8e..d054239c 100644 --- a/backend/go.sum +++ b/backend/go.sum @@ -3,14 +3,14 @@ cloud.google.com/go/compute/metadata v0.5.0 h1:Zr0eK8JbFv6+Wi4ilXAR8FJ3wyNdpxHKJ cloud.google.com/go/compute/metadata v0.5.0/go.mod h1:aHnloV2TPI38yx4s9+wAZhHykWvVCfu7hQbF+9CWoiY= github.com/Depado/bfchroma/v2 v2.0.0 h1:IRpN9BPkNwEpR6w1ectIcNWOuhDSLx+8f1pn83fzxx8= github.com/Depado/bfchroma/v2 v2.0.0/go.mod h1:wFwW/Pw8Tnd0irzgO9Zxtxgzp3aPS8qBWlyadxujxmw= -github.com/PuerkitoBio/goquery v1.9.2 h1:4/wZksC3KgkQw7SQgkKotmKljk0M6V8TUvA8Wb4yPeE= -github.com/PuerkitoBio/goquery v1.9.2/go.mod h1:GHPCaP0ODyyxqcNoFGYlAprUFH81NuRPd0GX3Zu2Mvk= +github.com/PuerkitoBio/goquery v1.10.0 h1:6fiXdLuUvYs2OJSvNRqlNPoBm6YABE226xrbavY5Wv4= +github.com/PuerkitoBio/goquery v1.10.0/go.mod h1:TjZZl68Q3eGHNBA8CWaxAN7rOU1EbDz3CWuolcO5Yu4= github.com/ajg/form v1.5.1 h1:t9c7v8JUKu/XxOGBU0yjNpaMloxGEJhUkqFRq0ibGeU= github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= -github.com/alecthomas/assert/v2 v2.6.0 h1:o3WJwILtexrEUk3cUVal3oiQY2tfgr/FHWiz/v2n4FU= -github.com/alecthomas/assert/v2 v2.6.0/go.mod h1:Bze95FyfUr7x34QZrjL+XP+0qgp/zg8yS+TtBj1WA3k= -github.com/alecthomas/chroma/v2 v2.13.0 h1:VP72+99Fb2zEcYM0MeaWJmV+xQvz5v5cxRHd+ooU1lI= -github.com/alecthomas/chroma/v2 v2.13.0/go.mod h1:BUGjjsD+ndS6eX37YgTchSEG+Jg9Jv1GiZs9sqPqztk= +github.com/alecthomas/assert/v2 v2.7.0 h1:QtqSACNS3tF7oasA8CU6A6sXZSBDqnm7RfpLl9bZqbE= +github.com/alecthomas/assert/v2 v2.7.0/go.mod h1:Bze95FyfUr7x34QZrjL+XP+0qgp/zg8yS+TtBj1WA3k= +github.com/alecthomas/chroma/v2 v2.14.0 h1:R3+wzpnUArGcQz7fCETQBzO5n9IMNi13iIs46aU4V9E= +github.com/alecthomas/chroma/v2 v2.14.0/go.mod h1:QolEbTfmUHIMVpBqxeDnNBj2uoeI4EbYP4i6n68SG4I= github.com/alecthomas/repr v0.4.0 h1:GhI2A8MACjfegCPVq9f1FLvIBS+DrQ2KQBFZP1iFzXc= github.com/alecthomas/repr v0.4.0/go.mod h1:Fr0507jx4eOXV7AlPV6AVZLYrLIuIeSOWtW57eE/O/4= github.com/alicebob/gopher-json v0.0.0-20230218143504-906a9b012302 h1:uvdUDbHQHO85qeSydJtItA4T55Pw6BtAejd0APRJOCE= @@ -60,14 +60,6 @@ github.com/go-chi/render v1.0.3 h1:AsXqd2a1/INaIfUSKq3G5uA8weYx20FOsM7uSoCyyt4= github.com/go-chi/render v1.0.3/go.mod h1:/gr3hVkmYR0YlEy3LxCuVRFzEu9Ruok+gFqbIofjao0= github.com/go-oauth2/oauth2/v4 v4.5.2 h1:CuZhD3lhGuI6aNLyUbRHXsgG2RwGRBOuCBfd4WQKqBQ= github.com/go-oauth2/oauth2/v4 v4.5.2/go.mod h1:wk/2uLImWIa9VVQDgxz99H2GDbhmfi/9/Xr+GvkSUSQ= -github.com/go-pkgz/auth v1.24.0 h1:jo7Ke18nFGTWHdzmMKeF8zqXIC383Ptu/OXCkcQOZmI= -github.com/go-pkgz/auth v1.24.0/go.mod h1:xmnzq6g8mhemW1nHnkuByXkBXsHrNf9/qkiVwJugWIs= -github.com/go-pkgz/auth v1.24.1-0.20240919232608-9e446b888187 h1:1oHLySWdk0HfDIFzXFNqA6dEK7sTgZ/7s+l/YxYql7Q= -github.com/go-pkgz/auth v1.24.1-0.20240919232608-9e446b888187/go.mod h1:xmnzq6g8mhemW1nHnkuByXkBXsHrNf9/qkiVwJugWIs= -github.com/go-pkgz/auth v1.24.1 h1:izSFGxwNEZ2MujKJWXddKc+lUW+kVP02JBXouQIW8b4= -github.com/go-pkgz/auth v1.24.1/go.mod h1:xmnzq6g8mhemW1nHnkuByXkBXsHrNf9/qkiVwJugWIs= -github.com/go-pkgz/auth v1.24.2-0.20240921022538-30916c085e04 h1:DZzcdFb/EzXjQex8lDq/NqubVqwCXeyGxU5swYEVAYk= -github.com/go-pkgz/auth v1.24.2-0.20240921022538-30916c085e04/go.mod h1:xmnzq6g8mhemW1nHnkuByXkBXsHrNf9/qkiVwJugWIs= github.com/go-pkgz/auth v1.24.2 h1:imMjUvTM0c8iOvP/GNGcuNcB/7gF3jFTF9dIPzlAOqI= github.com/go-pkgz/auth v1.24.2/go.mod h1:xmnzq6g8mhemW1nHnkuByXkBXsHrNf9/qkiVwJugWIs= github.com/go-pkgz/email v0.5.0 h1:fdtMDGJ8NwyBACLR0LYHaCIK/OeUwZHMhH7Q0+oty9U= @@ -81,10 +73,10 @@ github.com/go-pkgz/lcw/v2 v2.0.0 h1:gTwXpiJBhQeA1rXuqkRuLcV79uATFna8CckH8ZBBrH0= github.com/go-pkgz/lcw/v2 v2.0.0/go.mod h1:yxJHOn+IbQBQHxUqkCtMrbGjIfdYcsBAZcVCBaL1Va8= github.com/go-pkgz/lgr v0.11.1 h1:hXFhZcznehI6imLhEa379oMOKFz7TQUmisAqb3oLOSM= github.com/go-pkgz/lgr v0.11.1/go.mod h1:tgDF4RXQnBfIgJqjgkv0yOeTQ3F1yewWIZkpUhHnAkU= -github.com/go-pkgz/notify v1.1.1 h1:xjd5r0a9WUIKutrHkHfuNWdoXZsm84WNAoG35MD8QZA= -github.com/go-pkgz/notify v1.1.1/go.mod h1:8ri5Zx+IAjc87HB9kF9+KnVTm0yO5agsphvPbcRo54U= -github.com/go-pkgz/repeater v1.1.3 h1:q6+JQF14ESSy28Dd7F+wRelY4F+41HJ0LEy/szNnMiE= -github.com/go-pkgz/repeater v1.1.3/go.mod h1:hVTavuO5x3Gxnu8zW7d6sQBfAneKV8X2FjU48kGfpKw= +github.com/go-pkgz/notify v1.2.0 h1:jqbsbWkodCDB9ffyI9fCG1bTSgidWJRS5UWD/twjU44= +github.com/go-pkgz/notify v1.2.0/go.mod h1:BTHj9ly7xZpaxg91lBdxCxSmkpVQ9R6q5QviX/upeYo= +github.com/go-pkgz/repeater v1.2.0 h1:oJFvjyKdTDd5RCzpzxlzYIZFFj6Zfl17rE1aUfu6UjQ= +github.com/go-pkgz/repeater v1.2.0/go.mod h1:vypP6xamA53MFmafnGUucqOmALKk36xgKu2hSG73LHM= github.com/go-pkgz/rest v1.15.6/go.mod h1:KUWAqbDteYGS/CiXftomQsKjtEOifXsJ36Ka0skYbmk= github.com/go-pkgz/rest v1.19.0 h1:FNMi5QX5dDIkuC+/e0r+CWsTuOTwUiWMRSA16Ou+9+A= github.com/go-pkgz/rest v1.19.0/go.mod h1:Po+W6zQzpMPP6XDGLdAN2aW7UKk1IyrLSb48Lp1N3oQ= @@ -176,8 +168,8 @@ github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZV github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rrivera/identicon v0.0.0-20240116195454-d5ba35832c0d h1:l3+2LWCbVxn5itfvXAfH9n4YL9jh8l1g5zcncbIc1cs= github.com/rrivera/identicon v0.0.0-20240116195454-d5ba35832c0d/go.mod h1:TbpErkob6SY7cyozRVSGoB3OlO2qOAgVN8O3KAJ4fMI= -github.com/rs/xid v1.5.0 h1:mKX4bl4iPYJtEIxp6CYiUuLQ/8DYMoz0PUdtGgMFRVc= -github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= +github.com/rs/xid v1.6.0 h1:fV591PaemRlL6JfRxGDEPl69wICngIQ3shQtzfy2gxU= +github.com/rs/xid v1.6.0/go.mod h1:7XoLgs4eV+QndskICGsho+ADou8ySMSjJKDIan90Nz0= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/sclevine/agouti v3.0.0+incompatible/go.mod h1:b4WX9W9L1sfQKXeJf1mUTLZKJ48R1S7H23Ji7oFO5Bw= @@ -185,8 +177,8 @@ github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e h1:MRM5ITcdelLK2j1vwZ3Je0FKVCfqOLp5zO6trqMLYs0= github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e/go.mod h1:XV66xRDqSt+GTGFMVlhk3ULuV0y9ZmzeVGR4mloJI3M= -github.com/slack-go/slack v0.12.5 h1:ddZ6uz6XVaB+3MTDhoW04gG+Vc/M/X1ctC+wssy2cqs= -github.com/slack-go/slack v0.12.5/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQdlMQKOw= +github.com/slack-go/slack v0.14.0 h1:6c0UTfbRnvRssZUsZ2qe0Iu07VAMPjRqOa6oX8ewF4k= +github.com/slack-go/slack v0.14.0/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQdlMQKOw= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= @@ -255,8 +247,8 @@ github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZ github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yuin/gopher-lua v1.1.1 h1:kYKnWBjvbNP4XLT3+bPEwAXJx262OhaHDWDVOPjL46M= github.com/yuin/gopher-lua v1.1.1/go.mod h1:GBR0iDaNXjAgGg9zfCvksxSRnQx76gclCIb7kdAd1Pw= -go.etcd.io/bbolt v1.3.10 h1:+BqfJTcCzTItrop8mq/lbzL8wSGtj94UO/3U31shqG0= -go.etcd.io/bbolt v1.3.10/go.mod h1:bK3UQLPJZly7IlNmV7uVHJDxfe5aK9Ll93e/74Y9oEQ= +go.etcd.io/bbolt v1.3.11 h1:yGEzV1wPz2yVCLsD8ZAiGHhHVlczyC9d1rP43/VCRJ0= +go.etcd.io/bbolt v1.3.11/go.mod h1:dksAq7YMXoljX0xu6VF5DMZGbhYYoLUalEiSySYAS4I= go.mongodb.org/mongo-driver v1.16.0 h1:tpRsfBJMROVHKpdGyc1BBEzzjDUWjItxbVSZ8Ls4BQ4= go.mongodb.org/mongo-driver v1.16.0/go.mod h1:oB6AhJQvFQL4LEHyXi6aJzQJtBiTQHiAd83l0GdFaiw= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= @@ -264,10 +256,10 @@ go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220214200702-86341886e292/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.25.0 h1:ypSNr+bnYL2YhwoMt2zPxHFmbAN1KZs/njMG3hxUp30= -golang.org/x/crypto v0.25.0/go.mod h1:T+wALwcMOSE0kXgUAnPAHqTLW+XHgcELELW8VaDgm/M= -golang.org/x/image v0.18.0 h1:jGzIakQa/ZXI1I0Fxvaa9W7yP25TqT6cHIHn+6CqvSQ= -golang.org/x/image v0.18.0/go.mod h1:4yyo5vMFQjVjUcVk4jEQcU9MGy/rulF5WvUILseCM2E= +golang.org/x/crypto v0.27.0 h1:GXm2NjJrPaiv/h1tb2UH8QfgC/hOf/+z0p6PT8o1w7A= +golang.org/x/crypto v0.27.0/go.mod h1:1Xngt8kV6Dvbssa53Ziq6Eqn0HqbZi5Z6R0ZpwQzt70= +golang.org/x/image v0.22.0 h1:UtK5yLUzilVrkjMAZAZ34DXGpASN8i8pj8g+O+yd10g= +golang.org/x/image v0.22.0/go.mod h1:9hPFhljd4zZ1GNSIZJ49sqbp45GKK9t6w+iXvGqZUz4= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -283,8 +275,8 @@ golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.9.0/go.mod h1:d48xBJpPfHeWQsugry2m+kC02ZBRGRgulfHnEXEuWns= -golang.org/x/net v0.27.0 h1:5K3Njcw06/l2y9vpGCSdcxWOYHOUk3dVNGDXN+FvAys= -golang.org/x/net v0.27.0/go.mod h1:dDi0PyhWNoiUOrAS8uXv/vnScO4wnHQO4mj9fn/RytE= +golang.org/x/net v0.29.0 h1:5ORfpBpCs4HzDYoodCDBbwHzdR5UrLBZ3sOnUJmFoHo= +golang.org/x/net v0.29.0/go.mod h1:gLkgy8jTGERgjzMic6DS9+SP0ajcu6Xu3Orq/SpETg0= golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.21.0 h1:tsimM75w1tF/uws5rbeHzIWxEqElMehnc+iW793zsZs= golang.org/x/oauth2 v0.21.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= @@ -293,8 +285,8 @@ golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M= -golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.9.0 h1:fEo0HyrW1GIgZdpbhCRO0PkJajUS5H9IFUztCgEo2jQ= +golang.org/x/sync v0.9.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -313,8 +305,8 @@ golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.7.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.22.0 h1:RI27ohtqKCnwULzJLqkv897zojh5/DwS/ENaMzUOaWI= -golang.org/x/sys v0.22.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34= +golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= @@ -327,8 +319,8 @@ golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= -golang.org/x/text v0.16.0 h1:a94ExnEXNtEwYLGJSIUxnWoxoRz/ZcCsV63ROupILh4= -golang.org/x/text v0.16.0/go.mod h1:GhwF1Be+LQoKShO3cGOHzqOgRrGaYc9AvblQOmPVHnI= +golang.org/x/text v0.20.0 h1:gK/Kv2otX8gz+wn7Rmb3vT96ZwuoxnQlY+HlJVj7Qug= +golang.org/x/text v0.20.0/go.mod h1:D4IsuqiFMhST5bX19pQ9ikHC2GsaKyk/oF+pn3ducp4= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= diff --git a/backend/vendor/github.com/PuerkitoBio/goquery/README.md b/backend/vendor/github.com/PuerkitoBio/goquery/README.md index 767a0e11..6f4619d8 100644 --- a/backend/vendor/github.com/PuerkitoBio/goquery/README.md +++ b/backend/vendor/github.com/PuerkitoBio/goquery/README.md @@ -22,7 +22,13 @@ Syntax-wise, it is as close as possible to jQuery, with the same function names ## Installation -Please note that starting with version `v1.9.0` of goquery, Go 1.18+ is required due to the use of generics. For previous goquery versions, a Go version of 1.1+ was required because of the `net/html` dependency. Ongoing goquery development is tested on the latest 2 versions of Go. +Required Go version: + +* Starting with version `v1.10.0` of goquery, Go 1.23+ is required due to the use of function-based iterators. +* For `v1.9.0` of goquery, Go 1.18+ is required due to the use of generics. +* For previous goquery versions, a Go version of 1.1+ was required because of the `net/html` dependency. + +Ongoing goquery development is tested on the latest 2 versions of Go. $ go get github.com/PuerkitoBio/goquery @@ -40,6 +46,8 @@ Please note that starting with version `v1.9.0` of goquery, Go 1.18+ is required **Note that goquery's API is now stable, and will not break.** +* **2024-09-06 (v1.10.0)** : Add `EachIter` which provides an iterator that can be used in `for..range` loops on the `*Selection` object. **goquery now requires Go version 1.23+** (thanks [@amikai](https://github.com/amikai)). +* **2024-09-06 (v1.9.3)** : Update `go.mod` dependencies. * **2024-04-29 (v1.9.2)** : Update `go.mod` dependencies. * **2024-02-29 (v1.9.1)** : Improve allocation and performance of the `Map` function and `Selection.Map` method, better document the cascadia differences (thanks [@jwilsson](https://github.com/jwilsson)). * **2024-02-22 (v1.9.0)** : Add a generic `Map` function, **goquery now requires Go version 1.18+** (thanks [@Fesaa](https://github.com/Fesaa)). @@ -161,6 +169,7 @@ func main() { - [goskyr](https://github.com/jakopako/goskyr), an easily configurable command-line scraper written in Go. - [goGetJS](https://github.com/davemolk/goGetJS), a tool for extracting, searching, and saving JavaScript files (with optional headless browser). - [fitter](https://github.com/PxyUp/fitter), a tool for selecting values from JSON, XML, HTML and XPath formatted pages. +- [seltabl](github.com/conneroisu/seltabl), an orm-like package and supporting language server for extracting values from HTML ## Support @@ -183,15 +192,15 @@ There are a number of ways you can support the project: The [BSD 3-Clause license][bsd], the same as the [Go language][golic]. Cascadia's license is [here][caslic]. -[jquery]: http://jquery.com/ -[go]: http://golang.org/ +[jquery]: https://jquery.com/ +[go]: https://go.dev/ [cascadia]: https://github.com/andybalholm/cascadia [cascadiacli]: https://github.com/suntong/cascadia -[bsd]: http://opensource.org/licenses/BSD-3-Clause -[golic]: http://golang.org/LICENSE +[bsd]: https://opensource.org/licenses/BSD-3-Clause +[golic]: https://go.dev/LICENSE [caslic]: https://github.com/andybalholm/cascadia/blob/master/LICENSE [doc]: https://pkg.go.dev/github.com/PuerkitoBio/goquery -[index]: http://api.jquery.com/index/ +[index]: https://api.jquery.com/index/ [gonet]: https://github.com/golang/net/ [html]: https://pkg.go.dev/golang.org/x/net/html [wiki]: https://github.com/PuerkitoBio/goquery/wiki/Tips-and-tricks diff --git a/backend/vendor/github.com/PuerkitoBio/goquery/expand.go b/backend/vendor/github.com/PuerkitoBio/goquery/expand.go index 7caade53..af54acf5 100644 --- a/backend/vendor/github.com/PuerkitoBio/goquery/expand.go +++ b/backend/vendor/github.com/PuerkitoBio/goquery/expand.go @@ -62,7 +62,7 @@ func (s *Selection) AddBackFiltered(selector string) *Selection { } // AddBackMatcher reduces the previous set of elements on the stack to those that match -// the mateher, and adds them to the curernt set. +// the matcher, and adds them to the current set. // It returns a new Selection object containing the current Selection combined // with the filtered previous one func (s *Selection) AddBackMatcher(m Matcher) *Selection { diff --git a/backend/vendor/github.com/PuerkitoBio/goquery/iteration.go b/backend/vendor/github.com/PuerkitoBio/goquery/iteration.go index 1c98158b..1ca52454 100644 --- a/backend/vendor/github.com/PuerkitoBio/goquery/iteration.go +++ b/backend/vendor/github.com/PuerkitoBio/goquery/iteration.go @@ -1,5 +1,7 @@ package goquery +import "iter" + // Each iterates over a Selection object, executing a function for each // matched element. It returns the current Selection object. The function // f is called for each element in the selection with the index of the @@ -12,6 +14,18 @@ func (s *Selection) Each(f func(int, *Selection)) *Selection { return s } +// EachIter returns an iterator that yields the Selection object in order. +// The implementation is similar to Each, but it returns an iterator instead. +func (s *Selection) EachIter() iter.Seq2[int, *Selection] { + return func(yield func(int, *Selection) bool) { + for i, n := range s.Nodes { + if !yield(i, newSingleSelection(n, s.document)) { + return + } + } + } +} + // EachWithBreak iterates over a Selection object, executing a function for each // matched element. It is identical to Each except that it is possible to break // out of the loop by returning false in the callback function. It returns the diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/cue.xml b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/cue.xml index d6c3ea71..2a12f395 100644 --- a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/cue.xml +++ b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/cue.xml @@ -49,7 +49,7 @@ - + diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/gleam.xml b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/gleam.xml new file mode 100644 index 00000000..c706e962 --- /dev/null +++ b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/gleam.xml @@ -0,0 +1,117 @@ + + + Gleam + gleam> + *.gleam + text/x-gleam + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/org_mode.xml b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/org_mode.xml index 3f227ad8..259e54ef 100644 --- a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/org_mode.xml +++ b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/org_mode.xml @@ -228,42 +228,42 @@ - + - + - + - + - + - + diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/python.xml b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/python.xml index 3c6af86e..a58686ff 100644 --- a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/python.xml +++ b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/python.xml @@ -19,6 +19,10 @@ BUILD BUILD.bazel WORKSPACE + WORKSPACE.bzlmod + WORKSPACE.bazel + MODULE.bazel + REPO.bazel *.tac text/x-python application/x-python @@ -586,4 +590,4 @@ - \ No newline at end of file + diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/typescript.xml b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/typescript.xml index d49241e6..9828e92f 100644 --- a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/typescript.xml +++ b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/typescript.xml @@ -51,10 +51,13 @@ + + + - + @@ -77,12 +80,25 @@ + + + + + + + + + + + + + @@ -200,7 +216,7 @@ - + diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/vue.xml b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/vue.xml index 75180207..ec350835 100644 --- a/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/vue.xml +++ b/backend/vendor/github.com/alecthomas/chroma/v2/lexers/embedded/vue.xml @@ -83,9 +83,10 @@ - + + @@ -104,9 +105,10 @@ - + + @@ -258,14 +260,14 @@ - + - + diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-day.xml b/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-day.xml new file mode 100644 index 00000000..c20d9a41 --- /dev/null +++ b/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-day.xml @@ -0,0 +1,83 @@ + \ No newline at end of file diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-moon.xml b/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-moon.xml new file mode 100644 index 00000000..3312f029 --- /dev/null +++ b/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-moon.xml @@ -0,0 +1,83 @@ + diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-night.xml b/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-night.xml new file mode 100644 index 00000000..c798bad4 --- /dev/null +++ b/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-night.xml @@ -0,0 +1,83 @@ + \ No newline at end of file diff --git a/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-storm.xml b/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-storm.xml new file mode 100644 index 00000000..c0811524 --- /dev/null +++ b/backend/vendor/github.com/alecthomas/chroma/v2/styles/tokyonight-storm.xml @@ -0,0 +1,83 @@ + \ No newline at end of file diff --git a/backend/vendor/github.com/go-pkgz/notify/telegram.go b/backend/vendor/github.com/go-pkgz/notify/telegram.go index a8a412a9..f2704e6c 100644 --- a/backend/vendor/github.com/go-pkgz/notify/telegram.go +++ b/backend/vendor/github.com/go-pkgz/notify/telegram.go @@ -131,13 +131,16 @@ func (t *Telegram) Send(ctx context.Context, destination, text string) error { // TelegramSupportedHTML returns HTML with only tags allowed in Telegram HTML message payload, also trims ending newlines // -// https://core.telegram.org/bots/api#html-style +// https://core.telegram.org/bots/api#html-style, https://core.telegram.org/api/entities#allowed-entities func TelegramSupportedHTML(htmlText string) string { adjustedHTMLText := adjustHTMLTags(htmlText) p := bluemonday.NewPolicy() - p.AllowElements("b", "strong", "i", "em", "u", "ins", "s", "strike", "del", "a", "code", "pre") + p.AllowElements("b", "strong", "i", "em", "u", "ins", "s", "strike", "del", "a", "code", "pre", "tg-spoiler", "tg-emoji", "blockquote") p.AllowAttrs("href").OnElements("a") p.AllowAttrs("class").OnElements("code") + p.AllowAttrs("title").OnElements("tg-spoiler") + p.AllowAttrs("emoji-id").OnElements("tg-emoji") + p.AllowAttrs("language").OnElements("pre") return strings.TrimRight(p.Sanitize(adjustedHTMLText), "\n") } diff --git a/backend/vendor/github.com/go-pkgz/notify/webhook.go b/backend/vendor/github.com/go-pkgz/notify/webhook.go index 6cdffeed..1f26027c 100644 --- a/backend/vendor/github.com/go-pkgz/notify/webhook.go +++ b/backend/vendor/github.com/go-pkgz/notify/webhook.go @@ -69,7 +69,7 @@ func (wh *Webhook) Send(ctx context.Context, destination, text string) error { } defer resp.Body.Close() - if resp.StatusCode != http.StatusOK { + if resp.StatusCode < http.StatusOK || resp.StatusCode >= http.StatusMultipleChoices { errMsg := fmt.Sprintf("webhook request failed with non-OK status code: %d", resp.StatusCode) respBody, e := io.ReadAll(resp.Body) if e != nil { diff --git a/backend/vendor/github.com/go-pkgz/repeater/.golangci.yml b/backend/vendor/github.com/go-pkgz/repeater/.golangci.yml index 989af86e..192d484a 100644 --- a/backend/vendor/github.com/go-pkgz/repeater/.golangci.yml +++ b/backend/vendor/github.com/go-pkgz/repeater/.golangci.yml @@ -2,7 +2,7 @@ linters-settings: govet: check-shadowing: true golint: - min-confidence: 0 + min-confidence: 0.6 gocyclo: min-complexity: 15 maligned: @@ -23,38 +23,61 @@ linters-settings: - experimental disabled-checks: - wrapperFunc + - hugeParam + - rangeValCopy linters: disable-all: true enable: - megacheck + - revive - govet - unconvert - - megacheck - - structcheck - gas - - gocyclo - - dupl - misspell - - unparam - - varcheck - - deadcode + - unused - typecheck - ineffassign - - varcheck + - stylecheck + - gochecknoinits + - exportloopref + - nakedret + - gosimple + - prealloc + fast: false run: -# modules-download-mode: vendor + # modules-download-mode: vendor skip-dirs: - vendor + concurrency: 4 issues: exclude-rules: + - text: "should have a package comment, unless it's in another file for this package" + linters: + - golint + - text: "exitAfterDefer:" + linters: + - gocritic + - text: "whyNoLint: include an explanation for nolint directive" + linters: + - gocritic + - text: "go.mongodb.org/mongo-driver/bson/primitive.E" + linters: + - govet - text: "weak cryptographic primitive" linters: - gosec - -service: - golangci-lint-version: 1.16.x \ No newline at end of file + - text: "at least one file in a package should have a package comment" + linters: + - stylecheck + - text: "should have a package comment" + linters: + - revive + - text: 'Deferring unsafe method "Close" on type "io.ReadCloser"' + linters: + - gosec + exclude-use-default: false diff --git a/backend/vendor/github.com/go-pkgz/repeater/.travis.yml b/backend/vendor/github.com/go-pkgz/repeater/.travis.yml deleted file mode 100644 index 697ce97f..00000000 --- a/backend/vendor/github.com/go-pkgz/repeater/.travis.yml +++ /dev/null @@ -1,20 +0,0 @@ -language: go - -go: - - "1.12.x" - -install: true - -before_install: - - export TZ=America/Chicago - - curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.13.2 - - go get github.com/mattn/goveralls - - export PATH=$(pwd)/bin:$PATH - -script: - - GO111MODULE=on go get ./... - - GO111MODULE=on go mod vendor - - GO111MODULE=on go test -v -mod=vendor -covermode=count -coverprofile=profile.cov ./... || travis_terminate 1; - - GO111MODULE=on go test -v -covermode=count -coverprofile=profile.cov ./... || travis_terminate 1; - - golangci-lint run || travis_terminate 1; - - $GOPATH/bin/goveralls -coverprofile=profile.cov -service=travis-ci diff --git a/backend/vendor/github.com/go-pkgz/repeater/LICENSE b/backend/vendor/github.com/go-pkgz/repeater/LICENSE index ac540250..dc0ae1a1 100644 --- a/backend/vendor/github.com/go-pkgz/repeater/LICENSE +++ b/backend/vendor/github.com/go-pkgz/repeater/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2019 Umputun +Copyright (c) 2023 Umputun Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/backend/vendor/github.com/go-pkgz/repeater/README.md b/backend/vendor/github.com/go-pkgz/repeater/README.md index 76d8c906..421cd8e5 100644 --- a/backend/vendor/github.com/go-pkgz/repeater/README.md +++ b/backend/vendor/github.com/go-pkgz/repeater/README.md @@ -1,4 +1,4 @@ -# Repeater [![Build Status](https://travis-ci.org/go-pkgz/repeater.svg?branch=master)](https://travis-ci.org/go-pkgz/repeater) [![Go Report Card](https://goreportcard.com/badge/github.com/go-pkgz/repeater)](https://goreportcard.com/report/github.com/go-pkgz/repeater) [![Coverage Status](https://coveralls.io/repos/github/go-pkgz/repeater/badge.svg?branch=master)](https://coveralls.io/github/go-pkgz/repeater?branch=master) +# Repeater [![Build Status](https://github.com/go-pkgz/repeater/workflows/build/badge.svg)](https://github.com/go-pkgz/repeater/actions) [![Go Report Card](https://goreportcard.com/badge/github.com/go-pkgz/repeater)](https://goreportcard.com/report/github.com/go-pkgz/repeater) [![Coverage Status](https://coveralls.io/repos/github/go-pkgz/repeater/badge.svg?branch=master)](https://coveralls.io/github/go-pkgz/repeater?branch=master) Repeater calls a function until it returns no error, up to some number of iterations and delays defined by strategy. It terminates immediately on err from the provided (optional) list of critical errors. @@ -8,9 +8,9 @@ Repeater calls a function until it returns no error, up to some number of iterat ## How to use -New Repeater created by `New(strtg strategy.Interface)` or shortcut for defaults - `NewDefault(repeats int, delay time.Duration) *Repeater`. +New Repeater created by `New(strtg strategy.Interface)` or shortcut for default - `NewDefault(repeats int, delay time.Duration) *Repeater`. -To activate invoke `Do` method. `Do` repeats func until no error returned. Predefined (optional) errors terminates the loop immediately. +To activate invoke `Do` method. `Do` repeats func until no error returned. Predefined (optional) errors terminate the loop immediately. `func (r Repeater) Do(ctx context.Context, fun func() error, errors ...error) (err error)` @@ -24,12 +24,10 @@ type Interface interface { } ``` -Returned channels used as "ticks," i.e., for each repeat or initial operation one read from this channel needed. Closing this channel indicates "done with retries." It is pretty much the same idea as `time.Timer` or `time.Tick` implements. Note - the first (technically not-repeated-yet) call won't happen **until something sent to the channel**. For this reason, the typical strategy sends the first "tick" before the first wait/sleep. - -Three most common strategies provided by package and ready to use: -1. **Fixed delay**, up to max number of attempts - `NewFixedDelay(repeats int, delay time.Duration)`. -It is the default strategy used by `repeater.NewDefault` constructor -2. **BackOff** with jitter provides exponential backoff. It starts from 100ms interval and goes in steps with `last * math.Pow(factor, attempt)`. Optional jitter randomizes intervals a little bit. The strategy created by `NewBackoff(repeats int, factor float64, jitter bool)`. _Factor = 1 effectively makes this strategy fixed with 100ms delay._ -3. **Once** strategy does not do any repeats and mainly used for tests/mocks - `NewOnce()` +Returned channels used as "ticks," i.e., for each repeat or initial operation one read from this channel needed. Closing the channel indicates "done with retries." It is pretty much the same idea as `time.Timer` or `time.Tick` implements. Note - the first (technically not-repeated-yet) call won't happen **until something sent to the channel**. For this reason, the typical strategy sends the first "tick" before the first wait/sleep. +Three strategies provided byt the package: +1. **Fixed delay**, up to max number of attempts. It is the default strategy used by `repeater.NewDefault` constructor. +2. **BackOff** with jitter provides an exponential backoff. It starts from `Duration` interval and goes in steps with `last * math.Pow(factor, attempt)`. Optional jitter randomizes intervals a little. _Factor = 1 effectively makes this strategy fixed with `Duration` delay._ +3. **Once** strategy does not do any repeats and mainly used for tests/mocks`. diff --git a/backend/vendor/github.com/go-pkgz/repeater/repeater.go b/backend/vendor/github.com/go-pkgz/repeater/repeater.go index e6370ce5..4203427b 100644 --- a/backend/vendor/github.com/go-pkgz/repeater/repeater.go +++ b/backend/vendor/github.com/go-pkgz/repeater/repeater.go @@ -5,6 +5,7 @@ package repeater import ( "context" + "errors" "time" "github.com/go-pkgz/repeater/strategy" @@ -12,7 +13,12 @@ import ( // Repeater is the main object, should be made by New or NewDefault, embeds strategy type Repeater struct { - strategy.Interface + Strategy +} + +// Strategy interface for repeater strategy +type Strategy interface { + Start(ctx context.Context) <-chan struct{} // returns channel with repeater ticks } // New repeater with a given strategy. If strategy=nil initializes with FixedDelay 5sec, 10 times. @@ -20,7 +26,7 @@ func New(strtg strategy.Interface) *Repeater { if strtg == nil { strtg = &strategy.FixedDelay{Repeats: 10, Delay: time.Second * 5} } - result := Repeater{Interface: strtg} + result := Repeater{Strategy: strtg} return &result } @@ -30,14 +36,13 @@ func NewDefault(repeats int, delay time.Duration) *Repeater { } // Do repeats fun till no error. Predefined (optional) errors terminate immediately -func (r Repeater) Do(ctx context.Context, fun func() error, errors ...error) (err error) { - +func (r Repeater) Do(ctx context.Context, fun func() error, errs ...error) (err error) { ctx, cancelFunc := context.WithCancel(ctx) defer cancelFunc() // ensure strategy's channel termination inErrors := func(err error) bool { - for _, e := range errors { - if e == err { + for _, e := range errs { + if errors.Is(err, e) { return true } } diff --git a/backend/vendor/github.com/go-pkgz/repeater/strategy/backoff.go b/backend/vendor/github.com/go-pkgz/repeater/strategy/backoff.go index 12f53b69..e52f7924 100644 --- a/backend/vendor/github.com/go-pkgz/repeater/strategy/backoff.go +++ b/backend/vendor/github.com/go-pkgz/repeater/strategy/backoff.go @@ -40,7 +40,7 @@ func (b *Backoff) Start(ctx context.Context) <-chan struct{} { ch := make(chan struct{}) go func() { defer close(ch) - rnd := rand.New(rand.NewSource(int64(time.Now().Nanosecond()))) + rnd := rand.New(rand.NewSource(int64(time.Now().Nanosecond()))) //nolint:gosec for i := 0; i < b.Repeats; i++ { select { case <-ctx.Done(): diff --git a/backend/vendor/github.com/go-pkgz/repeater/strategy/strategy.go b/backend/vendor/github.com/go-pkgz/repeater/strategy/strategy.go index 75af12ba..da497341 100644 --- a/backend/vendor/github.com/go-pkgz/repeater/strategy/strategy.go +++ b/backend/vendor/github.com/go-pkgz/repeater/strategy/strategy.go @@ -16,7 +16,7 @@ type Interface interface { type Once struct{} // Start returns closed channel with a single element to prevent any repeats -func (s *Once) Start(ctx context.Context) <-chan struct{} { +func (s *Once) Start(_ context.Context) <-chan struct{} { ch := make(chan struct{}) go func() { ch <- struct{}{} diff --git a/backend/vendor/github.com/rs/xid/.gitignore b/backend/vendor/github.com/rs/xid/.gitignore new file mode 100644 index 00000000..81be9277 --- /dev/null +++ b/backend/vendor/github.com/rs/xid/.gitignore @@ -0,0 +1,3 @@ +/.idea +/.vscode +.DS_Store \ No newline at end of file diff --git a/backend/vendor/github.com/rs/xid/README.md b/backend/vendor/github.com/rs/xid/README.md index 974e67d2..1bf45bd1 100644 --- a/backend/vendor/github.com/rs/xid/README.md +++ b/backend/vendor/github.com/rs/xid/README.md @@ -4,7 +4,7 @@ Package xid is a globally unique id generator library, ready to safely be used directly in your server code. -Xid uses the Mongo Object ID algorithm to generate globally unique ids with a different serialization (base64) to make it shorter when transported as a string: +Xid uses the Mongo Object ID algorithm to generate globally unique ids with a different serialization ([base32hex](https://datatracker.ietf.org/doc/html/rfc4648#page-10)) to make it shorter when transported as a string: https://docs.mongodb.org/manual/reference/object-id/ - 4-byte value representing the seconds since the Unix epoch, @@ -13,7 +13,7 @@ https://docs.mongodb.org/manual/reference/object-id/ - 3-byte counter, starting with a random value. The binary representation of the id is compatible with Mongo 12 bytes Object IDs. -The string representation is using base32 hex (w/o padding) for better space efficiency +The string representation is using [base32hex](https://datatracker.ietf.org/doc/html/rfc4648#page-10) (w/o padding) for better space efficiency when stored in that form (20 bytes). The hex variant of base32 is used to retain the sortable property of the id. @@ -71,8 +71,10 @@ References: - Java port by [0xShamil](https://github.com/0xShamil/): https://github.com/0xShamil/java-xid - Dart port by [Peter Bwire](https://github.com/pitabwire): https://pub.dev/packages/xid - PostgreSQL port by [Rasmus Holm](https://github.com/crholm): https://github.com/modfin/pg-xid -- Swift port by [Uditha Atukorala](https://github.com/uditha-atukorala): https://github.com/uditha-atukorala/swift-xid -- C++ port by [Uditha Atukorala](https://github.com/uditha-atukorala): https://github.com/uditha-atukorala/libxid +- Swift port by [Uditha Atukorala](https://github.com/uatuko): https://github.com/uatuko/swift-xid +- C++ port by [Uditha Atukorala](https://github.com/uatuko): https://github.com/uatuko/libxid +- Typescript & Javascript port by [Yiwen AI](https://github.com/yiwen-ai): https://github.com/yiwen-ai/xid-ts +- Gleam port by [Alexandre Del Vecchio](https://github.com/defgenx): https://github.com/defgenx/gxid ## Install diff --git a/backend/vendor/github.com/rs/xid/hostid_darwin.go b/backend/vendor/github.com/rs/xid/hostid_darwin.go index 08351ff7..17351563 100644 --- a/backend/vendor/github.com/rs/xid/hostid_darwin.go +++ b/backend/vendor/github.com/rs/xid/hostid_darwin.go @@ -2,8 +2,33 @@ package xid -import "syscall" +import ( + "errors" + "os/exec" + "strings" +) func readPlatformMachineID() (string, error) { - return syscall.Sysctl("kern.uuid") + ioreg, err := exec.LookPath("ioreg") + if err != nil { + return "", err + } + + cmd := exec.Command(ioreg, "-rd1", "-c", "IOPlatformExpertDevice") + out, err := cmd.CombinedOutput() + if err != nil { + return "", err + } + + for _, line := range strings.Split(string(out), "\n") { + if strings.Contains(line, "IOPlatformUUID") { + parts := strings.SplitAfter(line, `" = "`) + if len(parts) == 2 { + uuid := strings.TrimRight(parts[1], `"`) + return strings.ToLower(uuid), nil + } + } + } + + return "", errors.New("cannot find host id") } diff --git a/backend/vendor/github.com/rs/xid/hostid_windows.go b/backend/vendor/github.com/rs/xid/hostid_windows.go index ec2593ee..a4d98ab0 100644 --- a/backend/vendor/github.com/rs/xid/hostid_windows.go +++ b/backend/vendor/github.com/rs/xid/hostid_windows.go @@ -11,11 +11,17 @@ import ( func readPlatformMachineID() (string, error) { // source: https://github.com/shirou/gopsutil/blob/master/host/host_syscall.go var h syscall.Handle - err := syscall.RegOpenKeyEx(syscall.HKEY_LOCAL_MACHINE, syscall.StringToUTF16Ptr(`SOFTWARE\Microsoft\Cryptography`), 0, syscall.KEY_READ|syscall.KEY_WOW64_64KEY, &h) + + regKeyCryptoPtr, err := syscall.UTF16PtrFromString(`SOFTWARE\Microsoft\Cryptography`) + if err != nil { + return "", fmt.Errorf(`error reading registry key "SOFTWARE\Microsoft\Cryptography": %w`, err) + } + + err = syscall.RegOpenKeyEx(syscall.HKEY_LOCAL_MACHINE, regKeyCryptoPtr, 0, syscall.KEY_READ|syscall.KEY_WOW64_64KEY, &h) if err != nil { return "", err } - defer syscall.RegCloseKey(h) + defer func() { _ = syscall.RegCloseKey(h) }() const syscallRegBufLen = 74 // len(`{`) + len(`abcdefgh-1234-456789012-123345456671` * 2) + len(`}`) // 2 == bytes/UTF16 const uuidLen = 36 @@ -23,9 +29,15 @@ func readPlatformMachineID() (string, error) { var regBuf [syscallRegBufLen]uint16 bufLen := uint32(syscallRegBufLen) var valType uint32 - err = syscall.RegQueryValueEx(h, syscall.StringToUTF16Ptr(`MachineGuid`), nil, &valType, (*byte)(unsafe.Pointer(®Buf[0])), &bufLen) + + mGuidPtr, err := syscall.UTF16PtrFromString(`MachineGuid`) if err != nil { - return "", err + return "", fmt.Errorf("error reading machine GUID: %w", err) + } + + err = syscall.RegQueryValueEx(h, mGuidPtr, nil, &valType, (*byte)(unsafe.Pointer(®Buf[0])), &bufLen) + if err != nil { + return "", fmt.Errorf("error parsing ") } hostID := syscall.UTF16ToString(regBuf[:]) diff --git a/backend/vendor/github.com/rs/xid/id.go b/backend/vendor/github.com/rs/xid/id.go index fcd7a041..e88984d9 100644 --- a/backend/vendor/github.com/rs/xid/id.go +++ b/backend/vendor/github.com/rs/xid/id.go @@ -54,7 +54,6 @@ import ( "sort" "sync/atomic" "time" - "unsafe" ) // Code inspired from mgo/bson ObjectId @@ -172,7 +171,7 @@ func FromString(id string) (ID, error) { func (id ID) String() string { text := make([]byte, encodedLen) encode(text, id[:]) - return *(*string)(unsafe.Pointer(&text)) + return string(text) } // Encode encodes the id using base32 encoding, writing 20 bytes to dst and return it. @@ -206,23 +205,23 @@ func encode(dst, id []byte) { dst[19] = encoding[(id[11]<<4)&0x1F] dst[18] = encoding[(id[11]>>1)&0x1F] - dst[17] = encoding[(id[11]>>6)&0x1F|(id[10]<<2)&0x1F] + dst[17] = encoding[(id[11]>>6)|(id[10]<<2)&0x1F] dst[16] = encoding[id[10]>>3] dst[15] = encoding[id[9]&0x1F] dst[14] = encoding[(id[9]>>5)|(id[8]<<3)&0x1F] dst[13] = encoding[(id[8]>>2)&0x1F] dst[12] = encoding[id[8]>>7|(id[7]<<1)&0x1F] - dst[11] = encoding[(id[7]>>4)&0x1F|(id[6]<<4)&0x1F] + dst[11] = encoding[(id[7]>>4)|(id[6]<<4)&0x1F] dst[10] = encoding[(id[6]>>1)&0x1F] - dst[9] = encoding[(id[6]>>6)&0x1F|(id[5]<<2)&0x1F] + dst[9] = encoding[(id[6]>>6)|(id[5]<<2)&0x1F] dst[8] = encoding[id[5]>>3] dst[7] = encoding[id[4]&0x1F] dst[6] = encoding[id[4]>>5|(id[3]<<3)&0x1F] dst[5] = encoding[(id[3]>>2)&0x1F] dst[4] = encoding[id[3]>>7|(id[2]<<1)&0x1F] - dst[3] = encoding[(id[2]>>4)&0x1F|(id[1]<<4)&0x1F] + dst[3] = encoding[(id[2]>>4)|(id[1]<<4)&0x1F] dst[2] = encoding[(id[1]>>1)&0x1F] - dst[1] = encoding[(id[1]>>6)&0x1F|(id[0]<<2)&0x1F] + dst[1] = encoding[(id[1]>>6)|(id[0]<<2)&0x1F] dst[0] = encoding[id[0]>>3] } diff --git a/backend/vendor/github.com/slack-go/slack/.gitignore b/backend/vendor/github.com/slack-go/slack/.gitignore index ac6f3eeb..027f4de5 100644 --- a/backend/vendor/github.com/slack-go/slack/.gitignore +++ b/backend/vendor/github.com/slack-go/slack/.gitignore @@ -1,3 +1,4 @@ *.test *~ .idea/ +/vendor/ \ No newline at end of file diff --git a/backend/vendor/github.com/slack-go/slack/apps.go b/backend/vendor/github.com/slack-go/slack/apps.go index 10d42975..7322b15b 100644 --- a/backend/vendor/github.com/slack-go/slack/apps.go +++ b/backend/vendor/github.com/slack-go/slack/apps.go @@ -19,11 +19,15 @@ type EventAuthorization struct { IsEnterpriseInstall bool `json:"is_enterprise_install"` } +// ListEventAuthorizations lists authed users and teams for the given event_context. +// You must provide an app-level token to the client using OptionAppLevelToken. +// For more details, see ListEventAuthorizationsContext documentation. func (api *Client) ListEventAuthorizations(eventContext string) ([]EventAuthorization, error) { return api.ListEventAuthorizationsContext(context.Background(), eventContext) } -// ListEventAuthorizationsContext lists authed users and teams for the given event_context. You must provide an app-level token to the client using OptionAppLevelToken. More info: https://api.slack.com/methods/apps.event.authorizations.list +// ListEventAuthorizationsContext lists authed users and teams for the given event_context with a custom context. +// Slack API docs: https://api.slack.com/methods/apps.event.authorizations.list func (api *Client) ListEventAuthorizationsContext(ctx context.Context, eventContext string) ([]EventAuthorization, error) { resp := &listEventAuthorizationsResponse{} @@ -43,10 +47,14 @@ func (api *Client) ListEventAuthorizationsContext(ctx context.Context, eventCont return resp.Authorizations, nil } +// UninstallApp uninstalls your app from a workspace. +// For more details, see UninstallAppContext documentation. func (api *Client) UninstallApp(clientID, clientSecret string) error { return api.UninstallAppContext(context.Background(), clientID, clientSecret) } +// UninstallAppContext uninstalls your app from a workspace with a custom context. +// Slack API docs: https://api.slack.com/methods/apps.uninstall func (api *Client) UninstallAppContext(ctx context.Context, clientID, clientSecret string) error { values := url.Values{ "client_id": {clientID}, diff --git a/backend/vendor/github.com/slack-go/slack/auth.go b/backend/vendor/github.com/slack-go/slack/auth.go index bf6e80d3..7fff1a16 100644 --- a/backend/vendor/github.com/slack-go/slack/auth.go +++ b/backend/vendor/github.com/slack-go/slack/auth.go @@ -22,12 +22,14 @@ func (api *Client) authRequest(ctx context.Context, path string, values url.Valu return response, response.Err() } -// SendAuthRevoke will send a revocation for our token +// SendAuthRevoke will send a revocation for our token. +// For more details, see SendAuthRevokeContext documentation. func (api *Client) SendAuthRevoke(token string) (*AuthRevokeResponse, error) { return api.SendAuthRevokeContext(context.Background(), token) } -// SendAuthRevokeContext will send a revocation request for our token to api.revoke with context +// SendAuthRevokeContext will send a revocation request for our token to api.revoke with a custom context. +// Slack API docs: https://api.slack.com/methods/auth.revoke func (api *Client) SendAuthRevokeContext(ctx context.Context, token string) (*AuthRevokeResponse, error) { if token == "" { token = api.token @@ -50,12 +52,13 @@ type ListTeamsParameters struct { } // ListTeams returns all workspaces a token can access. -// More info: https://api.slack.com/methods/admin.teams.list +// For more details, see ListTeamsContext documentation. func (api *Client) ListTeams(params ListTeamsParameters) ([]Team, string, error) { return api.ListTeamsContext(context.Background(), params) } -// ListTeams returns all workspaces a token can access with a custom context. +// ListTeamsContext returns all workspaces a token can access with a custom context. +// Slack API docs: https://api.slack.com/methods/auth.teams.list func (api *Client) ListTeamsContext(ctx context.Context, params ListTeamsParameters) ([]Team, string, error) { values := url.Values{ "token": {api.token}, diff --git a/backend/vendor/github.com/slack-go/slack/block_image.go b/backend/vendor/github.com/slack-go/slack/block_image.go index 90cbd14e..b3d2cb8c 100644 --- a/backend/vendor/github.com/slack-go/slack/block_image.go +++ b/backend/vendor/github.com/slack-go/slack/block_image.go @@ -4,11 +4,21 @@ package slack // // More Information: https://api.slack.com/reference/messaging/blocks#image type ImageBlock struct { - Type MessageBlockType `json:"type"` - ImageURL string `json:"image_url"` - AltText string `json:"alt_text"` - BlockID string `json:"block_id,omitempty"` - Title *TextBlockObject `json:"title,omitempty"` + Type MessageBlockType `json:"type"` + ImageURL string `json:"image_url,omitempty"` + AltText string `json:"alt_text"` + BlockID string `json:"block_id,omitempty"` + Title *TextBlockObject `json:"title,omitempty"` + SlackFile *SlackFileObject `json:"slack_file,omitempty"` +} + +// SlackFileObject Defines an object containing Slack file information to be used in an +// image block or image element. +// +// More Information: https://api.slack.com/reference/block-kit/composition-objects#slack_file +type SlackFileObject struct { + ID string `json:"id,omitempty"` + URL string `json:"url,omitempty"` } // BlockType returns the type of the block diff --git a/backend/vendor/github.com/slack-go/slack/block_object.go b/backend/vendor/github.com/slack-go/slack/block_object.go index b39ff228..a3e78d4e 100644 --- a/backend/vendor/github.com/slack-go/slack/block_object.go +++ b/backend/vendor/github.com/slack-go/slack/block_object.go @@ -147,6 +147,16 @@ func (s TextBlockObject) Validate() error { return errors.New("emoji cannot be true in mrkdown") } + // https://api.slack.com/reference/block-kit/composition-objects#text__fields + if len(s.Text) == 0 { + return errors.New("text must have a minimum length of 1") + } + + // https://api.slack.com/reference/block-kit/composition-objects#text__fields + if len(s.Text) > 3000 { + return errors.New("text cannot be longer than 3000 characters") + } + return nil } diff --git a/backend/vendor/github.com/slack-go/slack/bookmarks.go b/backend/vendor/github.com/slack-go/slack/bookmarks.go index 78753507..1f07e59b 100644 --- a/backend/vendor/github.com/slack-go/slack/bookmarks.go +++ b/backend/vendor/github.com/slack-go/slack/bookmarks.go @@ -55,12 +55,14 @@ type listBookmarksResponse struct { SlackResponse } -// AddBookmark adds a bookmark in a channel +// AddBookmark adds a bookmark in a channel. +// For more details, see AddBookmarkContext documentation. func (api *Client) AddBookmark(channelID string, params AddBookmarkParameters) (Bookmark, error) { return api.AddBookmarkContext(context.Background(), channelID, params) } -// AddBookmarkContext adds a bookmark in a channel with a custom context +// AddBookmarkContext adds a bookmark in a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/bookmarks.add func (api *Client) AddBookmarkContext(ctx context.Context, channelID string, params AddBookmarkParameters) (Bookmark, error) { values := url.Values{ "channel_id": {channelID}, @@ -89,12 +91,14 @@ func (api *Client) AddBookmarkContext(ctx context.Context, channelID string, par return response.Bookmark, response.Err() } -// RemoveBookmark removes a bookmark from a channel +// RemoveBookmark removes a bookmark from a channel. +// For more details, see RemoveBookmarkContext documentation. func (api *Client) RemoveBookmark(channelID, bookmarkID string) error { return api.RemoveBookmarkContext(context.Background(), channelID, bookmarkID) } -// RemoveBookmarkContext removes a bookmark from a channel with a custom context +// RemoveBookmarkContext removes a bookmark from a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/bookmarks.remove func (api *Client) RemoveBookmarkContext(ctx context.Context, channelID, bookmarkID string) error { values := url.Values{ "channel_id": {channelID}, @@ -111,11 +115,13 @@ func (api *Client) RemoveBookmarkContext(ctx context.Context, channelID, bookmar } // ListBookmarks returns all bookmarks for a channel. +// For more details, see ListBookmarksContext documentation. func (api *Client) ListBookmarks(channelID string) ([]Bookmark, error) { return api.ListBookmarksContext(context.Background(), channelID) } // ListBookmarksContext returns all bookmarks for a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/bookmarks.edit func (api *Client) ListBookmarksContext(ctx context.Context, channelID string) ([]Bookmark, error) { values := url.Values{ "channel_id": {channelID}, @@ -130,10 +136,14 @@ func (api *Client) ListBookmarksContext(ctx context.Context, channelID string) ( return response.Bookmarks, response.Err() } +// EditBookmark edits a bookmark in a channel. +// For more details, see EditBookmarkContext documentation. func (api *Client) EditBookmark(channelID, bookmarkID string, params EditBookmarkParameters) (Bookmark, error) { return api.EditBookmarkContext(context.Background(), channelID, bookmarkID, params) } +// EditBookmarkContext edits a bookmark in a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/bookmarks.edit func (api *Client) EditBookmarkContext(ctx context.Context, channelID, bookmarkID string, params EditBookmarkParameters) (Bookmark, error) { values := url.Values{ "channel_id": {channelID}, diff --git a/backend/vendor/github.com/slack-go/slack/bots.go b/backend/vendor/github.com/slack-go/slack/bots.go index da21ba0c..1ab94696 100644 --- a/backend/vendor/github.com/slack-go/slack/bots.go +++ b/backend/vendor/github.com/slack-go/slack/bots.go @@ -35,19 +35,30 @@ func (api *Client) botRequest(ctx context.Context, path string, values url.Value return response, nil } -// GetBotInfo will retrieve the complete bot information -func (api *Client) GetBotInfo(bot string) (*Bot, error) { - return api.GetBotInfoContext(context.Background(), bot) +type GetBotInfoParameters struct { + Bot string + TeamID string } -// GetBotInfoContext will retrieve the complete bot information using a custom context -func (api *Client) GetBotInfoContext(ctx context.Context, bot string) (*Bot, error) { +// GetBotInfo will retrieve the complete bot information. +// For more details, see GetBotInfoContext documentation. +func (api *Client) GetBotInfo(parameters GetBotInfoParameters) (*Bot, error) { + return api.GetBotInfoContext(context.Background(), parameters) +} + +// GetBotInfoContext will retrieve the complete bot information using a custom context. +// Slack API docs: https://api.slack.com/methods/bots.info +func (api *Client) GetBotInfoContext(ctx context.Context, parameters GetBotInfoParameters) (*Bot, error) { values := url.Values{ "token": {api.token}, } - if bot != "" { - values.Add("bot", bot) + if parameters.Bot != "" { + values.Add("bot", parameters.Bot) + } + + if parameters.TeamID != "" { + values.Add("team_id", parameters.TeamID) } response, err := api.botRequest(ctx, "bots.info", values) diff --git a/backend/vendor/github.com/slack-go/slack/channels.go b/backend/vendor/github.com/slack-go/slack/channels.go index 2fca8b92..88d567bf 100644 --- a/backend/vendor/github.com/slack-go/slack/channels.go +++ b/backend/vendor/github.com/slack-go/slack/channels.go @@ -19,10 +19,11 @@ type channelResponseFull struct { // Channel contains information about the channel type Channel struct { GroupConversation - IsChannel bool `json:"is_channel"` - IsGeneral bool `json:"is_general"` - IsMember bool `json:"is_member"` - Locale string `json:"locale"` + IsChannel bool `json:"is_channel"` + IsGeneral bool `json:"is_general"` + IsMember bool `json:"is_member"` + Locale string `json:"locale"` + Properties *Properties `json:"properties"` } func (api *Client) channelRequest(ctx context.Context, path string, values url.Values) (*channelResponseFull, error) { diff --git a/backend/vendor/github.com/slack-go/slack/chat.go b/backend/vendor/github.com/slack-go/slack/chat.go index 35ffbbcf..18f8e933 100644 --- a/backend/vendor/github.com/slack-go/slack/chat.go +++ b/backend/vendor/github.com/slack-go/slack/chat.go @@ -4,7 +4,7 @@ import ( "bytes" "context" "encoding/json" - "io/ioutil" + "io" "net/http" "net/url" "regexp" @@ -37,7 +37,7 @@ type chatResponseFull struct { SlackResponse } -// getMessageTimestamp will inspect the `chatResponseFull` to ruturn a timestamp value +// getMessageTimestamp will inspect the `chatResponseFull` to return a timestamp value // in `chat.postMessage` its under `ts` // in `chat.postEphemeral` its under `message_ts` func (c chatResponseFull) getMessageTimestamp() string { @@ -88,12 +88,14 @@ func NewPostMessageParameters() PostMessageParameters { } } -// DeleteMessage deletes a message in a channel +// DeleteMessage deletes a message in a channel. +// For more details, see DeleteMessageContext documentation. func (api *Client) DeleteMessage(channel, messageTimestamp string) (string, string, error) { return api.DeleteMessageContext(context.Background(), channel, messageTimestamp) } -// DeleteMessageContext deletes a message in a channel with a custom context +// DeleteMessageContext deletes a message in a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.delete func (api *Client) DeleteMessageContext(ctx context.Context, channel, messageTimestamp string) (string, string, error) { respChannel, respTimestamp, _, err := api.SendMessageContext( ctx, @@ -106,13 +108,13 @@ func (api *Client) DeleteMessageContext(ctx context.Context, channel, messageTim // ScheduleMessage sends a message to a channel. // Message is escaped by default according to https://api.slack.com/docs/formatting // Use http://davestevens.github.io/slack-message-builder/ to help crafting your message. +// For more details, see ScheduleMessageContext documentation. func (api *Client) ScheduleMessage(channelID, postAt string, options ...MsgOption) (string, string, error) { return api.ScheduleMessageContext(context.Background(), channelID, postAt, options...) } -// ScheduleMessageContext sends a message to a channel with a custom context -// -// For more details, see ScheduleMessage documentation. +// ScheduleMessageContext sends a message to a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.scheduleMessage func (api *Client) ScheduleMessageContext(ctx context.Context, channelID, postAt string, options ...MsgOption) (string, string, error) { respChannel, respTimestamp, _, err := api.SendMessageContext( ctx, @@ -126,12 +128,13 @@ func (api *Client) ScheduleMessageContext(ctx context.Context, channelID, postAt // PostMessage sends a message to a channel. // Message is escaped by default according to https://api.slack.com/docs/formatting // Use http://davestevens.github.io/slack-message-builder/ to help crafting your message. +// For more details, see PostMessageContext documentation. func (api *Client) PostMessage(channelID string, options ...MsgOption) (string, string, error) { return api.PostMessageContext(context.Background(), channelID, options...) } -// PostMessageContext sends a message to a channel with a custom context -// For more details, see PostMessage documentation. +// PostMessageContext sends a message to a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.postMessage func (api *Client) PostMessageContext(ctx context.Context, channelID string, options ...MsgOption) (string, string, error) { respChannel, respTimestamp, _, err := api.SendMessageContext( ctx, @@ -145,12 +148,13 @@ func (api *Client) PostMessageContext(ctx context.Context, channelID string, opt // PostEphemeral sends an ephemeral message to a user in a channel. // Message is escaped by default according to https://api.slack.com/docs/formatting // Use http://davestevens.github.io/slack-message-builder/ to help crafting your message. +// For more details, see PostEphemeralContext documentation. func (api *Client) PostEphemeral(channelID, userID string, options ...MsgOption) (string, error) { return api.PostEphemeralContext(context.Background(), channelID, userID, options...) } -// PostEphemeralContext sends an ephemeal message to a user in a channel with a custom context -// For more details, see PostEphemeral documentation +// PostEphemeralContext sends an ephemeral message to a user in a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.postEphemeral func (api *Client) PostEphemeralContext(ctx context.Context, channelID, userID string, options ...MsgOption) (timestamp string, err error) { _, timestamp, _, err = api.SendMessageContext( ctx, @@ -161,12 +165,14 @@ func (api *Client) PostEphemeralContext(ctx context.Context, channelID, userID s return timestamp, err } -// UpdateMessage updates a message in a channel +// UpdateMessage updates a message in a channel. +// For more details, see UpdateMessageContext documentation. func (api *Client) UpdateMessage(channelID, timestamp string, options ...MsgOption) (string, string, string, error) { return api.UpdateMessageContext(context.Background(), channelID, timestamp, options...) } -// UpdateMessageContext updates a message in a channel +// UpdateMessageContext updates a message in a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.update func (api *Client) UpdateMessageContext(ctx context.Context, channelID, timestamp string, options ...MsgOption) (string, string, string, error) { return api.SendMessageContext( ctx, @@ -176,38 +182,38 @@ func (api *Client) UpdateMessageContext(ctx context.Context, channelID, timestam ) } -// UnfurlMessage unfurls a message in a channel +// UnfurlMessage unfurls a message in a channel. +// For more details, see UnfurlMessageContext documentation. func (api *Client) UnfurlMessage(channelID, timestamp string, unfurls map[string]Attachment, options ...MsgOption) (string, string, string, error) { return api.UnfurlMessageContext(context.Background(), channelID, timestamp, unfurls, options...) } -// UnfurlMessageContext unfurls a message in a channel with a custom context +// UnfurlMessageContext unfurls a message in a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.unfurl func (api *Client) UnfurlMessageContext(ctx context.Context, channelID, timestamp string, unfurls map[string]Attachment, options ...MsgOption) (string, string, string, error) { return api.SendMessageContext(ctx, channelID, MsgOptionUnfurl(timestamp, unfurls), MsgOptionCompose(options...)) } -// UnfurlMessageWithAuthURL sends an unfurl request containing an -// authentication URL. -// For more details see: -// https://api.slack.com/reference/messaging/link-unfurling#authenticated_unfurls +// UnfurlMessageWithAuthURL sends an unfurl request containing an authentication URL. +// For more details, see UnfurlMessageWithAuthURLContext documentation. func (api *Client) UnfurlMessageWithAuthURL(channelID, timestamp string, userAuthURL string, options ...MsgOption) (string, string, string, error) { return api.UnfurlMessageWithAuthURLContext(context.Background(), channelID, timestamp, userAuthURL, options...) } -// UnfurlMessageWithAuthURLContext sends an unfurl request containing an -// authentication URL. -// For more details see: -// https://api.slack.com/reference/messaging/link-unfurling#authenticated_unfurls +// UnfurlMessageWithAuthURLContext sends an unfurl request containing an authentication URL with a custom context. +// For more details see: https://api.slack.com/reference/messaging/link-unfurling#authenticated_unfurls func (api *Client) UnfurlMessageWithAuthURLContext(ctx context.Context, channelID, timestamp string, userAuthURL string, options ...MsgOption) (string, string, string, error) { return api.SendMessageContext(ctx, channelID, MsgOptionUnfurlAuthURL(timestamp, userAuthURL), MsgOptionCompose(options...)) } // SendMessage more flexible method for configuring messages. +// For more details, see SendMessageContext documentation. func (api *Client) SendMessage(channel string, options ...MsgOption) (string, string, string, error) { return api.SendMessageContext(context.Background(), channel, options...) } // SendMessageContext more flexible method for configuring messages with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.postMessage func (api *Client) SendMessageContext(ctx context.Context, channelID string, options ...MsgOption) (_channel string, _timestamp string, _text string, err error) { var ( req *http.Request @@ -220,11 +226,11 @@ func (api *Client) SendMessageContext(ctx context.Context, channelID string, opt } if api.Debug() { - reqBody, err := ioutil.ReadAll(req.Body) + reqBody, err := io.ReadAll(req.Body) if err != nil { return "", "", "", err } - req.Body = ioutil.NopCloser(bytes.NewBuffer(reqBody)) + req.Body = io.NopCloser(bytes.NewBuffer(reqBody)) api.Debugf("Sending request: %s", redactToken(reqBody)) } @@ -696,6 +702,14 @@ func MsgOptionMetadata(metadata SlackMetadata) MsgOption { } } +// MsgOptionLinkNames finds and links user groups. Does not support linking individual users +func MsgOptionLinkNames(linkName bool) MsgOption { + return func(config *sendConfig) error { + config.values.Set("link_names", strconv.FormatBool(linkName)) + return nil + } +} + // UnsafeMsgOptionEndpoint deliver the message to the specified endpoint. // NOTE: USE AT YOUR OWN RISK: No issues relating to the use of this Option // will be supported by the library, it is subject to change without notice that @@ -763,22 +777,21 @@ func MsgOptionPostMessageParameters(params PostMessageParameters) MsgOption { } } -// PermalinkParameters are the parameters required to get a permalink to a -// message. Slack documentation can be found here: -// https://api.slack.com/methods/chat.getPermalink +// PermalinkParameters are the parameters required to get a permalink to a message. type PermalinkParameters struct { Channel string Ts string } -// GetPermalink returns the permalink for a message. It takes -// PermalinkParameters and returns a string containing the permalink. It -// returns an error if unable to retrieve the permalink. +// GetPermalink returns the permalink for a message. It takes PermalinkParameters and returns a string containing the +// permalink. It returns an error if unable to retrieve the permalink. +// For more details, see GetPermalinkContext documentation. func (api *Client) GetPermalink(params *PermalinkParameters) (string, error) { return api.GetPermalinkContext(context.Background(), params) } // GetPermalinkContext returns the permalink for a message using a custom context. +// Slack API docs: https://api.slack.com/methods/chat.getPermalink func (api *Client) GetPermalinkContext(ctx context.Context, params *PermalinkParameters) (string, error) { values := url.Values{ "channel": {params.Channel}, @@ -799,18 +812,21 @@ func (api *Client) GetPermalinkContext(ctx context.Context, params *PermalinkPar type GetScheduledMessagesParameters struct { Channel string + TeamID string Cursor string Latest string Limit int Oldest string } -// GetScheduledMessages returns the list of scheduled messages based on params +// GetScheduledMessages returns the list of scheduled messages based on params. +// For more details, see GetScheduledMessagesContext documentation. func (api *Client) GetScheduledMessages(params *GetScheduledMessagesParameters) (channels []ScheduledMessage, nextCursor string, err error) { return api.GetScheduledMessagesContext(context.Background(), params) } -// GetScheduledMessagesContext returns the list of scheduled messages in a Slack team with a custom context +// GetScheduledMessagesContext returns the list of scheduled messages based on params with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.getScheduledMessages.list func (api *Client) GetScheduledMessagesContext(ctx context.Context, params *GetScheduledMessagesParameters) (channels []ScheduledMessage, nextCursor string, err error) { values := url.Values{ "token": {api.token}, @@ -818,6 +834,9 @@ func (api *Client) GetScheduledMessagesContext(ctx context.Context, params *GetS if params.Channel != "" { values.Add("channel", params.Channel) } + if params.TeamID != "" { + values.Add("team_id", params.TeamID) + } if params.Cursor != "" { values.Add("cursor", params.Cursor) } @@ -850,12 +869,14 @@ type DeleteScheduledMessageParameters struct { AsUser bool } -// DeleteScheduledMessage returns the list of scheduled messages based on params +// DeleteScheduledMessage deletes a pending scheduled message. +// For more details, see DeleteScheduledMessageContext documentation. func (api *Client) DeleteScheduledMessage(params *DeleteScheduledMessageParameters) (bool, error) { return api.DeleteScheduledMessageContext(context.Background(), params) } -// DeleteScheduledMessageContext returns the list of scheduled messages in a Slack team with a custom context +// DeleteScheduledMessageContext deletes a pending scheduled message with a custom context. +// Slack API docs: https://api.slack.com/methods/chat.deleteScheduledMessage func (api *Client) DeleteScheduledMessageContext(ctx context.Context, params *DeleteScheduledMessageParameters) (bool, error) { values := url.Values{ "token": {api.token}, diff --git a/backend/vendor/github.com/slack-go/slack/conversation.go b/backend/vendor/github.com/slack-go/slack/conversation.go index 787a9614..bfc17fd3 100644 --- a/backend/vendor/github.com/slack-go/slack/conversation.go +++ b/backend/vendor/github.com/slack-go/slack/conversation.go @@ -25,6 +25,7 @@ type Conversation struct { IsGlobalShared bool `json:"is_global_shared"` IsPendingExtShared bool `json:"is_pending_ext_shared"` IsPrivate bool `json:"is_private"` + IsReadOnly bool `json:"is_read_only"` IsMpIM bool `json:"is_mpim"` Unlinked int `json:"unlinked"` NameNormalized string `json:"name_normalized"` @@ -64,6 +65,17 @@ type Purpose struct { LastSet JSONTime `json:"last_set"` } +// Properties contains the Canvas associated to the channel. +type Properties struct { + Canvas Canvas `json:"canvas"` +} + +type Canvas struct { + FileId string `json:"file_id"` + IsEmpty bool `json:"is_empty"` + QuipThreadId string `json:"quip_thread_id"` +} + type GetUsersInConversationParameters struct { ChannelID string Cursor string @@ -83,12 +95,14 @@ type responseMetaData struct { NextCursor string `json:"next_cursor"` } -// GetUsersInConversation returns the list of users in a conversation +// GetUsersInConversation returns the list of users in a conversation. +// For more details, see GetUsersInConversationContext documentation. func (api *Client) GetUsersInConversation(params *GetUsersInConversationParameters) ([]string, string, error) { return api.GetUsersInConversationContext(context.Background(), params) } -// GetUsersInConversationContext returns the list of users in a conversation with a custom context +// GetUsersInConversationContext returns the list of users in a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.members func (api *Client) GetUsersInConversationContext(ctx context.Context, params *GetUsersInConversationParameters) ([]string, string, error) { values := url.Values{ "token": {api.token}, @@ -118,12 +132,14 @@ func (api *Client) GetUsersInConversationContext(ctx context.Context, params *Ge return response.Members, response.ResponseMetaData.NextCursor, nil } -// GetConversationsForUser returns the list conversations for a given user +// GetConversationsForUser returns the list conversations for a given user. +// For more details, see GetConversationsForUserContext documentation. func (api *Client) GetConversationsForUser(params *GetConversationsForUserParameters) (channels []Channel, nextCursor string, err error) { return api.GetConversationsForUserContext(context.Background(), params) } // GetConversationsForUserContext returns the list conversations for a given user with a custom context +// Slack API docs: https://api.slack.com/methods/users.conversations func (api *Client) GetConversationsForUserContext(ctx context.Context, params *GetConversationsForUserParameters) (channels []Channel, nextCursor string, err error) { values := url.Values{ "token": {api.token}, @@ -160,12 +176,14 @@ func (api *Client) GetConversationsForUserContext(ctx context.Context, params *G return response.Channels, response.ResponseMetaData.NextCursor, response.Err() } -// ArchiveConversation archives a conversation +// ArchiveConversation archives a conversation. +// For more details, see ArchiveConversationContext documentation. func (api *Client) ArchiveConversation(channelID string) error { return api.ArchiveConversationContext(context.Background(), channelID) } -// ArchiveConversationContext archives a conversation with a custom context +// ArchiveConversationContext archives a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.archive func (api *Client) ArchiveConversationContext(ctx context.Context, channelID string) error { values := url.Values{ "token": {api.token}, @@ -181,12 +199,14 @@ func (api *Client) ArchiveConversationContext(ctx context.Context, channelID str return response.Err() } -// UnArchiveConversation reverses conversation archival +// UnArchiveConversation reverses conversation archival. +// For more details, see UnArchiveConversationContext documentation. func (api *Client) UnArchiveConversation(channelID string) error { return api.UnArchiveConversationContext(context.Background(), channelID) } -// UnArchiveConversationContext reverses conversation archival with a custom context +// UnArchiveConversationContext reverses conversation archival with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.unarchive func (api *Client) UnArchiveConversationContext(ctx context.Context, channelID string) error { values := url.Values{ "token": {api.token}, @@ -201,12 +221,14 @@ func (api *Client) UnArchiveConversationContext(ctx context.Context, channelID s return response.Err() } -// SetTopicOfConversation sets the topic for a conversation +// SetTopicOfConversation sets the topic for a conversation. +// For more details, see SetTopicOfConversationContext documentation. func (api *Client) SetTopicOfConversation(channelID, topic string) (*Channel, error) { return api.SetTopicOfConversationContext(context.Background(), channelID, topic) } -// SetTopicOfConversationContext sets the topic for a conversation with a custom context +// SetTopicOfConversationContext sets the topic for a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.setTopic func (api *Client) SetTopicOfConversationContext(ctx context.Context, channelID, topic string) (*Channel, error) { values := url.Values{ "token": {api.token}, @@ -225,12 +247,14 @@ func (api *Client) SetTopicOfConversationContext(ctx context.Context, channelID, return response.Channel, response.Err() } -// SetPurposeOfConversation sets the purpose for a conversation +// SetPurposeOfConversation sets the purpose for a conversation. +// For more details, see SetPurposeOfConversationContext documentation. func (api *Client) SetPurposeOfConversation(channelID, purpose string) (*Channel, error) { return api.SetPurposeOfConversationContext(context.Background(), channelID, purpose) } -// SetPurposeOfConversationContext sets the purpose for a conversation with a custom context +// SetPurposeOfConversationContext sets the purpose for a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.setPurpose func (api *Client) SetPurposeOfConversationContext(ctx context.Context, channelID, purpose string) (*Channel, error) { values := url.Values{ "token": {api.token}, @@ -250,12 +274,14 @@ func (api *Client) SetPurposeOfConversationContext(ctx context.Context, channelI return response.Channel, response.Err() } -// RenameConversation renames a conversation +// RenameConversation renames a conversation. +// For more details, see RenameConversationContext documentation. func (api *Client) RenameConversation(channelID, channelName string) (*Channel, error) { return api.RenameConversationContext(context.Background(), channelID, channelName) } -// RenameConversationContext renames a conversation with a custom context +// RenameConversationContext renames a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.rename func (api *Client) RenameConversationContext(ctx context.Context, channelID, channelName string) (*Channel, error) { values := url.Values{ "token": {api.token}, @@ -275,12 +301,14 @@ func (api *Client) RenameConversationContext(ctx context.Context, channelID, cha return response.Channel, response.Err() } -// InviteUsersToConversation invites users to a channel +// InviteUsersToConversation invites users to a channel. +// For more details, see InviteUsersToConversation documentation. func (api *Client) InviteUsersToConversation(channelID string, users ...string) (*Channel, error) { return api.InviteUsersToConversationContext(context.Background(), channelID, users...) } -// InviteUsersToConversationContext invites users to a channel with a custom context +// InviteUsersToConversationContext invites users to a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.invite func (api *Client) InviteUsersToConversationContext(ctx context.Context, channelID string, users ...string) (*Channel, error) { values := url.Values{ "token": {api.token}, @@ -300,22 +328,26 @@ func (api *Client) InviteUsersToConversationContext(ctx context.Context, channel return response.Channel, response.Err() } -// InviteSharedEmailsToConversation invites users to a shared channels by email +// InviteSharedEmailsToConversation invites users to a shared channels by email. +// For more details, see InviteSharedEmailsToConversationContext documentation. func (api *Client) InviteSharedEmailsToConversation(channelID string, emails ...string) (string, bool, error) { return api.inviteSharedToConversationHelper(context.Background(), channelID, emails, nil) } -// InviteSharedEmailsToConversationContext invites users to a shared channels by email using context +// InviteSharedEmailsToConversationContext invites users to a shared channels by email using context. +// For more details, see inviteSharedToConversationHelper documentation. func (api *Client) InviteSharedEmailsToConversationContext(ctx context.Context, channelID string, emails ...string) (string, bool, error) { return api.inviteSharedToConversationHelper(ctx, channelID, emails, nil) } -// InviteSharedUserIDsToConversation invites users to a shared channels by user id +// InviteSharedUserIDsToConversation invites users to a shared channels by user id. +// For more details, see InviteSharedUserIDsToConversationContext documentation. func (api *Client) InviteSharedUserIDsToConversation(channelID string, userIDs ...string) (string, bool, error) { return api.inviteSharedToConversationHelper(context.Background(), channelID, nil, userIDs) } -// InviteSharedUserIDsToConversationContext invites users to a shared channels by user id with context +// InviteSharedUserIDsToConversationContext invites users to a shared channels by user id with context. +// For more details, see inviteSharedToConversationHelper documentation. func (api *Client) InviteSharedUserIDsToConversationContext(ctx context.Context, channelID string, userIDs ...string) (string, bool, error) { return api.inviteSharedToConversationHelper(ctx, channelID, nil, userIDs) } @@ -323,6 +355,7 @@ func (api *Client) InviteSharedUserIDsToConversationContext(ctx context.Context, // inviteSharedToConversationHelper invites emails or userIDs to a channel with a custom context. // This is a helper function for InviteSharedEmailsToConversation and InviteSharedUserIDsToConversation. // It accepts either emails or userIDs, but not both. +// Slack API docs: https://api.slack.com/methods/conversations.inviteShared func (api *Client) inviteSharedToConversationHelper(ctx context.Context, channelID string, emails []string, userIDs []string) (string, bool, error) { values := url.Values{ "token": {api.token}, @@ -347,12 +380,14 @@ func (api *Client) inviteSharedToConversationHelper(ctx context.Context, channel return response.InviteID, response.IsLegacySharedChannel, response.Err() } -// KickUserFromConversation removes a user from a conversation +// KickUserFromConversation removes a user from a conversation. +// For more details, see KickUserFromConversationContext documentation. func (api *Client) KickUserFromConversation(channelID string, user string) error { return api.KickUserFromConversationContext(context.Background(), channelID, user) } -// KickUserFromConversationContext removes a user from a conversation with a custom context +// KickUserFromConversationContext removes a user from a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.kick func (api *Client) KickUserFromConversationContext(ctx context.Context, channelID string, user string) error { values := url.Values{ "token": {api.token}, @@ -369,12 +404,14 @@ func (api *Client) KickUserFromConversationContext(ctx context.Context, channelI return response.Err() } -// CloseConversation closes a direct message or multi-person direct message +// CloseConversation closes a direct message or multi-person direct message. +// For more details, see CloseConversationContext documentation. func (api *Client) CloseConversation(channelID string) (noOp bool, alreadyClosed bool, err error) { return api.CloseConversationContext(context.Background(), channelID) } -// CloseConversationContext closes a direct message or multi-person direct message with a custom context +// CloseConversationContext closes a direct message or multi-person direct message with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.close func (api *Client) CloseConversationContext(ctx context.Context, channelID string) (noOp bool, alreadyClosed bool, err error) { values := url.Values{ "token": {api.token}, @@ -400,12 +437,14 @@ type CreateConversationParams struct { TeamID string } -// CreateConversation initiates a public or private channel-based conversation +// CreateConversation initiates a public or private channel-based conversation. +// For more details, see CreateConversationContext documentation. func (api *Client) CreateConversation(params CreateConversationParams) (*Channel, error) { return api.CreateConversationContext(context.Background(), params) } -// CreateConversationContext initiates a public or private channel-based conversation with a custom context +// CreateConversationContext initiates a public or private channel-based conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.create func (api *Client) CreateConversationContext(ctx context.Context, params CreateConversationParams) (*Channel, error) { values := url.Values{ "token": {api.token}, @@ -430,12 +469,14 @@ type GetConversationInfoInput struct { IncludeNumMembers bool } -// GetConversationInfo retrieves information about a conversation +// GetConversationInfo retrieves information about a conversation. +// For more details, see GetConversationInfoContext documentation. func (api *Client) GetConversationInfo(input *GetConversationInfoInput) (*Channel, error) { return api.GetConversationInfoContext(context.Background(), input) } -// GetConversationInfoContext retrieves information about a conversation with a custom context +// GetConversationInfoContext retrieves information about a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.info func (api *Client) GetConversationInfoContext(ctx context.Context, input *GetConversationInfoInput) (*Channel, error) { if input == nil { return nil, errors.New("GetConversationInfoInput must not be nil") @@ -459,12 +500,14 @@ func (api *Client) GetConversationInfoContext(ctx context.Context, input *GetCon return &response.Channel, response.Err() } -// LeaveConversation leaves a conversation +// LeaveConversation leaves a conversation. +// For more details, see LeaveConversationContext documentation. func (api *Client) LeaveConversation(channelID string) (bool, error) { return api.LeaveConversationContext(context.Background(), channelID) } -// LeaveConversationContext leaves a conversation with a custom context +// LeaveConversationContext leaves a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.leave func (api *Client) LeaveConversationContext(ctx context.Context, channelID string) (bool, error) { values := url.Values{ "token": {api.token}, @@ -490,12 +533,14 @@ type GetConversationRepliesParameters struct { IncludeAllMetadata bool } -// GetConversationReplies retrieves a thread of messages posted to a conversation +// GetConversationReplies retrieves a thread of messages posted to a conversation. +// For more details, see GetConversationRepliesContext documentation. func (api *Client) GetConversationReplies(params *GetConversationRepliesParameters) (msgs []Message, hasMore bool, nextCursor string, err error) { return api.GetConversationRepliesContext(context.Background(), params) } -// GetConversationRepliesContext retrieves a thread of messages posted to a conversation with a custom context +// GetConversationRepliesContext retrieves a thread of messages posted to a conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.replies func (api *Client) GetConversationRepliesContext(ctx context.Context, params *GetConversationRepliesParameters) (msgs []Message, hasMore bool, nextCursor string, err error) { values := url.Values{ "token": {api.token}, @@ -549,12 +594,14 @@ type GetConversationsParameters struct { TeamID string } -// GetConversations returns the list of channels in a Slack team +// GetConversations returns the list of channels in a Slack team. +// For more details, see GetConversationsContext documentation. func (api *Client) GetConversations(params *GetConversationsParameters) (channels []Channel, nextCursor string, err error) { return api.GetConversationsContext(context.Background(), params) } -// GetConversationsContext returns the list of channels in a Slack team with a custom context +// GetConversationsContext returns the list of channels in a Slack team with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.list func (api *Client) GetConversationsContext(ctx context.Context, params *GetConversationsParameters) (channels []Channel, nextCursor string, err error) { values := url.Values{ "token": {api.token}, @@ -595,12 +642,14 @@ type OpenConversationParameters struct { Users []string } -// OpenConversation opens or resumes a direct message or multi-person direct message +// OpenConversation opens or resumes a direct message or multi-person direct message. +// For more details, see OpenConversationContext documentation. func (api *Client) OpenConversation(params *OpenConversationParameters) (*Channel, bool, bool, error) { return api.OpenConversationContext(context.Background(), params) } -// OpenConversationContext opens or resumes a direct message or multi-person direct message with a custom context +// OpenConversationContext opens or resumes a direct message or multi-person direct message with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.open func (api *Client) OpenConversationContext(ctx context.Context, params *OpenConversationParameters) (*Channel, bool, bool, error) { values := url.Values{ "token": {api.token}, @@ -627,12 +676,14 @@ func (api *Client) OpenConversationContext(ctx context.Context, params *OpenConv return response.Channel, response.NoOp, response.AlreadyOpen, response.Err() } -// JoinConversation joins an existing conversation +// JoinConversation joins an existing conversation. +// For more details, see JoinConversationContext documentation. func (api *Client) JoinConversation(channelID string) (*Channel, string, []string, error) { return api.JoinConversationContext(context.Background(), channelID) } -// JoinConversationContext joins an existing conversation with a custom context +// JoinConversationContext joins an existing conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.join func (api *Client) JoinConversationContext(ctx context.Context, channelID string) (*Channel, string, []string, error) { values := url.Values{"token": {api.token}, "channel": {channelID}} response := struct { @@ -679,12 +730,14 @@ type GetConversationHistoryResponse struct { Messages []Message `json:"messages"` } -// GetConversationHistory joins an existing conversation +// GetConversationHistory joins an existing conversation. +// For more details, see GetConversationHistoryContext documentation. func (api *Client) GetConversationHistory(params *GetConversationHistoryParameters) (*GetConversationHistoryResponse, error) { return api.GetConversationHistoryContext(context.Background(), params) } -// GetConversationHistoryContext joins an existing conversation with a custom context +// GetConversationHistoryContext joins an existing conversation with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.history func (api *Client) GetConversationHistoryContext(ctx context.Context, params *GetConversationHistoryParameters) (*GetConversationHistoryResponse, error) { values := url.Values{"token": {api.token}, "channel": {params.ChannelID}} if params.Cursor != "" { @@ -720,12 +773,14 @@ func (api *Client) GetConversationHistoryContext(ctx context.Context, params *Ge return &response, response.Err() } -// MarkConversation sets the read mark of a conversation to a specific point +// MarkConversation sets the read mark of a conversation to a specific point. +// For more details, see MarkConversationContext documentation. func (api *Client) MarkConversation(channel, ts string) (err error) { return api.MarkConversationContext(context.Background(), channel, ts) } -// MarkConversationContext sets the read mark of a conversation to a specific point with a custom context +// MarkConversationContext sets the read mark of a conversation to a specific point with a custom context. +// Slack API docs: https://api.slack.com/methods/conversations.mark func (api *Client) MarkConversationContext(ctx context.Context, channel, ts string) error { values := url.Values{ "token": {api.token}, diff --git a/backend/vendor/github.com/slack-go/slack/dnd.go b/backend/vendor/github.com/slack-go/slack/dnd.go index a3aa680c..81eaf502 100644 --- a/backend/vendor/github.com/slack-go/slack/dnd.go +++ b/backend/vendor/github.com/slack-go/slack/dnd.go @@ -45,12 +45,14 @@ func (api *Client) dndRequest(ctx context.Context, path string, values url.Value return response, response.Err() } -// EndDND ends the user's scheduled Do Not Disturb session +// EndDND ends the user's scheduled Do Not Disturb session. +// For more information see the EndDNDContext documentation. func (api *Client) EndDND() error { return api.EndDNDContext(context.Background()) } -// EndDNDContext ends the user's scheduled Do Not Disturb session with a custom context +// EndDNDContext ends the user's scheduled Do Not Disturb session with a custom context. +// Slack API docs: https://api.slack.com/methods/dnd.endDnd func (api *Client) EndDNDContext(ctx context.Context) error { values := url.Values{ "token": {api.token}, @@ -65,12 +67,14 @@ func (api *Client) EndDNDContext(ctx context.Context) error { return response.Err() } -// EndSnooze ends the current user's snooze mode +// EndSnooze ends the current user's snooze mode. +// For more information see the EndSnoozeContext documentation. func (api *Client) EndSnooze() (*DNDStatus, error) { return api.EndSnoozeContext(context.Background()) } -// EndSnoozeContext ends the current user's snooze mode with a custom context +// EndSnoozeContext ends the current user's snooze mode with a custom context. +// Slack API docs: https://api.slack.com/methods/dnd.endSnooze func (api *Client) EndSnoozeContext(ctx context.Context) (*DNDStatus, error) { values := url.Values{ "token": {api.token}, @@ -84,11 +88,13 @@ func (api *Client) EndSnoozeContext(ctx context.Context) (*DNDStatus, error) { } // GetDNDInfo provides information about a user's current Do Not Disturb settings. +// For more information see the GetDNDInfoContext documentation. func (api *Client) GetDNDInfo(user *string) (*DNDStatus, error) { return api.GetDNDInfoContext(context.Background(), user) } // GetDNDInfoContext provides information about a user's current Do Not Disturb settings with a custom context. +// Slack API docs: https://api.slack.com/methods/dnd.info func (api *Client) GetDNDInfoContext(ctx context.Context, user *string) (*DNDStatus, error) { values := url.Values{ "token": {api.token}, @@ -105,11 +111,13 @@ func (api *Client) GetDNDInfoContext(ctx context.Context, user *string) (*DNDSta } // GetDNDTeamInfo provides information about a user's current Do Not Disturb settings. +// For more information see the GetDNDTeamInfoContext documentation. func (api *Client) GetDNDTeamInfo(users []string) (map[string]DNDStatus, error) { return api.GetDNDTeamInfoContext(context.Background(), users) } // GetDNDTeamInfoContext provides information about a user's current Do Not Disturb settings with a custom context. +// Slack API docs: https://api.slack.com/methods/dnd.teamInfo func (api *Client) GetDNDTeamInfoContext(ctx context.Context, users []string) (map[string]DNDStatus, error) { values := url.Values{ "token": {api.token}, @@ -128,15 +136,16 @@ func (api *Client) GetDNDTeamInfoContext(ctx context.Context, users []string) (m return response.Users, nil } -// SetSnooze adjusts the snooze duration for a user's Do Not Disturb -// settings. If a snooze session is not already active for the user, invoking -// this method will begin one for the specified duration. +// SetSnooze adjusts the snooze duration for a user's Do Not Disturb settings. +// For more information see the SetSnoozeContext documentation. func (api *Client) SetSnooze(minutes int) (*DNDStatus, error) { return api.SetSnoozeContext(context.Background(), minutes) } -// SetSnoozeContext adjusts the snooze duration for a user's Do Not Disturb settings with a custom context. -// For more information see the SetSnooze docs +// SetSnoozeContext adjusts the snooze duration for a user's Do Not Disturb settings. +// If a snooze session is not already active for the user, invoking this method will +// begin one for the specified duration. +// Slack API docs: https://api.slack.com/methods/dnd.setSnooze func (api *Client) SetSnoozeContext(ctx context.Context, minutes int) (*DNDStatus, error) { values := url.Values{ "token": {api.token}, diff --git a/backend/vendor/github.com/slack-go/slack/emoji.go b/backend/vendor/github.com/slack-go/slack/emoji.go index b2b0c6c9..139df0fd 100644 --- a/backend/vendor/github.com/slack-go/slack/emoji.go +++ b/backend/vendor/github.com/slack-go/slack/emoji.go @@ -10,12 +10,14 @@ type emojiResponseFull struct { SlackResponse } -// GetEmoji retrieves all the emojis +// GetEmoji retrieves all the emojis. +// For more details see GetEmojiContext documentation. func (api *Client) GetEmoji() (map[string]string, error) { return api.GetEmojiContext(context.Background()) } -// GetEmojiContext retrieves all the emojis with a custom context +// GetEmojiContext retrieves all the emojis with a custom context. +// Slack API docs: https://api.slack.com/methods/emoji.list func (api *Client) GetEmojiContext(ctx context.Context) (map[string]string, error) { values := url.Values{ "token": {api.token}, diff --git a/backend/vendor/github.com/slack-go/slack/files.go b/backend/vendor/github.com/slack-go/slack/files.go index 35628442..6844edd5 100644 --- a/backend/vendor/github.com/slack-go/slack/files.go +++ b/backend/vendor/github.com/slack-go/slack/files.go @@ -11,7 +11,7 @@ import ( ) const ( - // Add here the defaults in the siten + // Add here the defaults in the site DEFAULT_FILES_USER = "" DEFAULT_FILES_CHANNEL = "" DEFAULT_FILES_TS_FROM = 0 @@ -129,6 +129,7 @@ type FileUploadParameters struct { type GetFilesParameters struct { User string Channel string + TeamID string TimestampFrom JSONTime TimestampTo JSONTime Types string @@ -142,6 +143,7 @@ type ListFilesParameters struct { Limit int User string Channel string + TeamID string Types string Cursor string } @@ -232,12 +234,14 @@ func (api *Client) fileRequest(ctx context.Context, path string, values url.Valu return response, response.Err() } -// GetFileInfo retrieves a file and related comments +// GetFileInfo retrieves a file and related comments. +// For more details, see GetFileInfoContext documentation. func (api *Client) GetFileInfo(fileID string, count, page int) (*File, []Comment, *Paging, error) { return api.GetFileInfoContext(context.Background(), fileID, count, page) } -// GetFileInfoContext retrieves a file and related comments with a custom context +// GetFileInfoContext retrieves a file and related comments with a custom context. +// Slack API docs: https://api.slack.com/methods/files.info func (api *Client) GetFileInfoContext(ctx context.Context, fileID string, count, page int) (*File, []Comment, *Paging, error) { values := url.Values{ "token": {api.token}, @@ -253,24 +257,25 @@ func (api *Client) GetFileInfoContext(ctx context.Context, fileID string, count, return &response.File, response.Comments, &response.Paging, nil } -// GetFile retreives a given file from its private download URL +// GetFile retrieves a given file from its private download URL. func (api *Client) GetFile(downloadURL string, writer io.Writer) error { return api.GetFileContext(context.Background(), downloadURL, writer) } -// GetFileContext retreives a given file from its private download URL with a custom context -// +// GetFileContext retrieves a given file from its private download URL with a custom context. // For more details, see GetFile documentation. func (api *Client) GetFileContext(ctx context.Context, downloadURL string, writer io.Writer) error { return downloadFile(ctx, api.httpclient, api.token, downloadURL, writer, api) } -// GetFiles retrieves all files according to the parameters given +// GetFiles retrieves all files according to the parameters given. +// For more details, see GetFilesContext documentation. func (api *Client) GetFiles(params GetFilesParameters) ([]File, *Paging, error) { return api.GetFilesContext(context.Background(), params) } -// GetFilesContext retrieves all files according to the parameters given with a custom context +// GetFilesContext retrieves all files according to the parameters given with a custom context. +// Slack API docs: https://api.slack.com/methods/files.list func (api *Client) GetFilesContext(ctx context.Context, params GetFilesParameters) ([]File, *Paging, error) { values := url.Values{ "token": {api.token}, @@ -281,6 +286,9 @@ func (api *Client) GetFilesContext(ctx context.Context, params GetFilesParameter if params.Channel != DEFAULT_FILES_CHANNEL { values.Add("channel", params.Channel) } + if params.TeamID != "" { + values.Add("team_id", params.TeamID) + } if params.TimestampFrom != DEFAULT_FILES_TS_FROM { values.Add("ts_from", strconv.FormatInt(int64(params.TimestampFrom), 10)) } @@ -308,13 +316,13 @@ func (api *Client) GetFilesContext(ctx context.Context, params GetFilesParameter } // ListFiles retrieves all files according to the parameters given. Uses cursor based pagination. +// For more details, see ListFilesContext documentation. func (api *Client) ListFiles(params ListFilesParameters) ([]File, *ListFilesParameters, error) { return api.ListFilesContext(context.Background(), params) } // ListFilesContext retrieves all files according to the parameters given with a custom context. -// -// For more details, see ListFiles documentation. +// Slack API docs: https://api.slack.com/methods/files.list func (api *Client) ListFilesContext(ctx context.Context, params ListFilesParameters) ([]File, *ListFilesParameters, error) { values := url.Values{ "token": {api.token}, @@ -326,6 +334,9 @@ func (api *Client) ListFilesContext(ctx context.Context, params ListFilesParamet if params.Channel != DEFAULT_FILES_CHANNEL { values.Add("channel", params.Channel) } + if params.TeamID != "" { + values.Add("team_id", params.TeamID) + } if params.Limit != DEFAULT_FILES_COUNT { values.Add("limit", strconv.Itoa(params.Limit)) } @@ -343,12 +354,16 @@ func (api *Client) ListFilesContext(ctx context.Context, params ListFilesParamet return response.Files, ¶ms, nil } -// UploadFile uploads a file +// UploadFile uploads a file. +// DEPRECATED: Use UploadFileV2 instead. This will stop functioning on March 11, 2025. +// For more details, see: https://api.slack.com/methods/files.upload#markdown func (api *Client) UploadFile(params FileUploadParameters) (file *File, err error) { return api.UploadFileContext(context.Background(), params) } -// UploadFileContext uploads a file and setting a custom context +// UploadFileContext uploads a file and setting a custom context. +// DEPRECATED: Use UploadFileV2Context instead. This will stop functioning on March 11, 2025. +// For more details, see: https://api.slack.com/methods/files.upload#markdown func (api *Client) UploadFileContext(ctx context.Context, params FileUploadParameters) (file *File, err error) { // Test if user token is valid. This helps because client.Do doesn't like this for some reason. XXX: More // investigation needed, but for now this will do. @@ -396,12 +411,14 @@ func (api *Client) UploadFileContext(ctx context.Context, params FileUploadParam return &response.File, response.Err() } -// DeleteFileComment deletes a file's comment +// DeleteFileComment deletes a file's comment. +// For more details, see DeleteFileCommentContext documentation. func (api *Client) DeleteFileComment(commentID, fileID string) error { return api.DeleteFileCommentContext(context.Background(), fileID, commentID) } -// DeleteFileCommentContext deletes a file's comment with a custom context +// DeleteFileCommentContext deletes a file's comment with a custom context. +// Slack API docs: https://api.slack.com/methods/files.comments.delete func (api *Client) DeleteFileCommentContext(ctx context.Context, fileID, commentID string) (err error) { if fileID == "" || commentID == "" { return ErrParametersMissing @@ -416,12 +433,14 @@ func (api *Client) DeleteFileCommentContext(ctx context.Context, fileID, comment return err } -// DeleteFile deletes a file +// DeleteFile deletes a file. +// For more details, see DeleteFileContext documentation. func (api *Client) DeleteFile(fileID string) error { return api.DeleteFileContext(context.Background(), fileID) } -// DeleteFileContext deletes a file with a custom context +// DeleteFileContext deletes a file with a custom context. +// Slack API docs: https://api.slack.com/methods/files.delete func (api *Client) DeleteFileContext(ctx context.Context, fileID string) (err error) { values := url.Values{ "token": {api.token}, @@ -432,12 +451,14 @@ func (api *Client) DeleteFileContext(ctx context.Context, fileID string) (err er return err } -// RevokeFilePublicURL disables public/external sharing for a file +// RevokeFilePublicURL disables public/external sharing for a file. +// For more details, see RevokeFilePublicURLContext documentation. func (api *Client) RevokeFilePublicURL(fileID string) (*File, error) { return api.RevokeFilePublicURLContext(context.Background(), fileID) } -// RevokeFilePublicURLContext disables public/external sharing for a file with a custom context +// RevokeFilePublicURLContext disables public/external sharing for a file with a custom context. +// Slack API docs: https://api.slack.com/methods/files.revokePublicURL func (api *Client) RevokeFilePublicURLContext(ctx context.Context, fileID string) (*File, error) { values := url.Values{ "token": {api.token}, @@ -451,12 +472,14 @@ func (api *Client) RevokeFilePublicURLContext(ctx context.Context, fileID string return &response.File, nil } -// ShareFilePublicURL enabled public/external sharing for a file +// ShareFilePublicURL enabled public/external sharing for a file. +// For more details, see ShareFilePublicURLContext documentation. func (api *Client) ShareFilePublicURL(fileID string) (*File, []Comment, *Paging, error) { return api.ShareFilePublicURLContext(context.Background(), fileID) } -// ShareFilePublicURLContext enabled public/external sharing for a file with a custom context +// ShareFilePublicURLContext enabled public/external sharing for a file with a custom context. +// Slack API docs: https://api.slack.com/methods/files.sharedPublicURL func (api *Client) ShareFilePublicURLContext(ctx context.Context, fileID string) (*File, []Comment, *Paging, error) { values := url.Values{ "token": {api.token}, @@ -470,7 +493,7 @@ func (api *Client) ShareFilePublicURLContext(ctx context.Context, fileID string) return &response.File, response.Comments, &response.Paging, nil } -// getUploadURLExternal gets a URL and fileID from slack which can later be used to upload a file +// getUploadURLExternal gets a URL and fileID from slack which can later be used to upload a file. func (api *Client) getUploadURLExternal(ctx context.Context, params getUploadURLExternalParameters) (*getUploadURLExternalResponse, error) { values := url.Values{ "token": {api.token}, @@ -496,9 +519,8 @@ func (api *Client) getUploadURLExternal(ctx context.Context, params getUploadURL func (api *Client) uploadToURL(ctx context.Context, params uploadToURLParameters) (err error) { values := url.Values{} if params.Content != "" { - values.Add("content", params.Content) - values.Add("token", api.token) - err = postForm(ctx, api.httpclient, params.UploadURL, values, nil, api) + contentReader := strings.NewReader(params.Content) + err = postWithMultipartResponse(ctx, api.httpclient, params.UploadURL, params.Filename, "file", api.token, values, contentReader, nil, api) } else if params.File != "" { err = postLocalWithMultipartResponse(ctx, api.httpclient, params.UploadURL, params.File, "file", api.token, values, nil, api) } else if params.Reader != nil { @@ -515,11 +537,13 @@ func (api *Client) completeUploadExternal(ctx context.Context, fileID string, pa return nil, err } values := url.Values{ - "token": {api.token}, - "files": {string(requestBytes)}, - "channel_id": {params.channel}, + "token": {api.token}, + "files": {string(requestBytes)}, } + if params.channel != "" { + values.Add("channel_id", params.channel) + } if params.initialComment != "" { values.Add("initial_comment", params.initialComment) } @@ -537,18 +561,18 @@ func (api *Client) completeUploadExternal(ctx context.Context, fileID string, pa return response, nil } -// UploadFileV2 uploads file to a given slack channel using 3 steps - -// 1. Get an upload URL using files.getUploadURLExternal API -// 2. Send the file as a post to the URL provided by slack -// 3. Complete the upload and share it to the specified channel using files.completeUploadExternal +// UploadFileV2 uploads file to a given slack channel using 3 steps. +// For more details, see UploadFileV2Context documentation. func (api *Client) UploadFileV2(params UploadFileV2Parameters) (*FileSummary, error) { return api.UploadFileV2Context(context.Background(), params) } -// UploadFileV2 uploads file to a given slack channel using 3 steps with a custom context - +// UploadFileV2Context uploads file to a given slack channel using 3 steps - // 1. Get an upload URL using files.getUploadURLExternal API // 2. Send the file as a post to the URL provided by slack // 3. Complete the upload and share it to the specified channel using files.completeUploadExternal +// +// Slack Docs: https://api.slack.com/messaging/files#uploading_files func (api *Client) UploadFileV2Context(ctx context.Context, params UploadFileV2Parameters) (file *FileSummary, err error) { if params.Filename == "" { return nil, fmt.Errorf("file.upload.v2: filename cannot be empty") @@ -556,9 +580,7 @@ func (api *Client) UploadFileV2Context(ctx context.Context, params UploadFileV2P if params.FileSize == 0 { return nil, fmt.Errorf("file.upload.v2: file size cannot be 0") } - if params.Channel == "" { - return nil, fmt.Errorf("file.upload.v2: channel cannot be empty") - } + u, err := api.getUploadURLExternal(ctx, getUploadURLExternalParameters{ altText: params.AltTxt, fileName: params.Filename, diff --git a/backend/vendor/github.com/slack-go/slack/manifests.go b/backend/vendor/github.com/slack-go/slack/manifests.go index 0041bf24..0a972a25 100644 --- a/backend/vendor/github.com/slack-go/slack/manifests.go +++ b/backend/vendor/github.com/slack-go/slack/manifests.go @@ -15,12 +15,14 @@ type Manifest struct { OAuthConfig OAuthConfig `json:"oauth_config,omitempty" yaml:"oauth_config,omitempty"` } -// CreateManifest creates an app from an app manifest +// CreateManifest creates an app from an app manifest. +// For more details, see CreateManifestContext documentation. func (api *Client) CreateManifest(manifest *Manifest, token string) (*ManifestResponse, error) { return api.CreateManifestContext(context.Background(), manifest, token) } -// CreateManifestContext creates an app from an app manifest with a custom context +// CreateManifestContext creates an app from an app manifest with a custom context. +// Slack API docs: https://api.slack.com/methods/apps.manifest.create func (api *Client) CreateManifestContext(ctx context.Context, manifest *Manifest, token string) (*ManifestResponse, error) { if token == "" { token = api.configToken @@ -45,12 +47,14 @@ func (api *Client) CreateManifestContext(ctx context.Context, manifest *Manifest return response, response.Err() } -// DeleteManifest permanently deletes an app created through app manifests +// DeleteManifest permanently deletes an app created through app manifests. +// For more details, see DeleteManifestContext documentation. func (api *Client) DeleteManifest(token string, appId string) (*SlackResponse, error) { return api.DeleteManifestContext(context.Background(), token, appId) } -// DeleteManifestContext permanently deletes an app created through app manifests with a custom context +// DeleteManifestContext permanently deletes an app created through app manifests with a custom context. +// Slack API docs: https://api.slack.com/methods/apps.manifest.delete func (api *Client) DeleteManifestContext(ctx context.Context, token string, appId string) (*SlackResponse, error) { if token == "" { token = api.configToken @@ -70,12 +74,14 @@ func (api *Client) DeleteManifestContext(ctx context.Context, token string, appI return response, response.Err() } -// ExportManifest exports an app manifest from an existing app +// ExportManifest exports an app manifest from an existing app. +// For more details, see ExportManifestContext documentation. func (api *Client) ExportManifest(token string, appId string) (*Manifest, error) { return api.ExportManifestContext(context.Background(), token, appId) } -// ExportManifestContext exports an app manifest from an existing app with a custom context +// ExportManifestContext exports an app manifest from an existing app with a custom context. +// Slack API docs: https://api.slack.com/methods/apps.manifest.export func (api *Client) ExportManifestContext(ctx context.Context, token string, appId string) (*Manifest, error) { if token == "" { token = api.configToken @@ -95,12 +101,14 @@ func (api *Client) ExportManifestContext(ctx context.Context, token string, appI return &response.Manifest, response.Err() } -// UpdateManifest updates an app from an app manifest +// UpdateManifest updates an app from an app manifest. +// For more details, see UpdateManifestContext documentation. func (api *Client) UpdateManifest(manifest *Manifest, token string, appId string) (*UpdateManifestResponse, error) { return api.UpdateManifestContext(context.Background(), manifest, token, appId) } -// UpdateManifestContext updates an app from an app manifest with a custom context +// UpdateManifestContext updates an app from an app manifest with a custom context. +// Slack API docs: https://api.slack.com/methods/apps.manifest.update func (api *Client) UpdateManifestContext(ctx context.Context, manifest *Manifest, token string, appId string) (*UpdateManifestResponse, error) { if token == "" { token = api.configToken @@ -126,12 +134,14 @@ func (api *Client) UpdateManifestContext(ctx context.Context, manifest *Manifest return response, response.Err() } -// ValidateManifest sends a request to apps.manifest.validate to validate your app manifest +// ValidateManifest sends a request to apps.manifest.validate to validate your app manifest. +// For more details, see ValidateManifestContext documentation. func (api *Client) ValidateManifest(manifest *Manifest, token string, appId string) (*ManifestResponse, error) { return api.ValidateManifestContext(context.Background(), manifest, token, appId) } -// ValidateManifestContext sends a request to apps.manifest.validate to validate your app manifest with a custom context +// ValidateManifestContext sends a request to apps.manifest.validate to validate your app manifest with a custom context. +// Slack API docs: https://api.slack.com/methods/apps.manifest.validate func (api *Client) ValidateManifestContext(ctx context.Context, manifest *Manifest, token string, appId string) (*ManifestResponse, error) { if token == "" { token = api.configToken diff --git a/backend/vendor/github.com/slack-go/slack/misc.go b/backend/vendor/github.com/slack-go/slack/misc.go index 7e5a8d54..df779c1a 100644 --- a/backend/vendor/github.com/slack-go/slack/misc.go +++ b/backend/vendor/github.com/slack-go/slack/misc.go @@ -7,7 +7,6 @@ import ( "errors" "fmt" "io" - "io/ioutil" "mime" "mime/multipart" "net/http" @@ -63,13 +62,12 @@ func (e *RateLimitedError) Retryable() bool { return true } -func fileUploadReq(ctx context.Context, path string, values url.Values, r io.Reader) (*http.Request, error) { +func fileUploadReq(ctx context.Context, path string, r io.Reader) (*http.Request, error) { req, err := http.NewRequestWithContext(ctx, http.MethodPost, path, r) if err != nil { return nil, err } - req.URL.RawQuery = values.Encode() return req, nil } @@ -127,7 +125,7 @@ func jsonReq(ctx context.Context, endpoint string, body interface{}) (req *http. } func parseResponseBody(body io.ReadCloser, intf interface{}, d Debug) error { - response, err := ioutil.ReadAll(body) + response, err := io.ReadAll(body) if err != nil { return err } @@ -156,9 +154,16 @@ func postLocalWithMultipartResponse(ctx context.Context, client httpClient, meth func postWithMultipartResponse(ctx context.Context, client httpClient, path, name, fieldname, token string, values url.Values, r io.Reader, intf interface{}, d Debug) error { pipeReader, pipeWriter := io.Pipe() wr := multipart.NewWriter(pipeWriter) + errc := make(chan error) go func() { defer pipeWriter.Close() + defer wr.Close() + err := createFormFields(wr, values) + if err != nil { + errc <- err + return + } ioWriter, err := wr.CreateFormFile(fieldname, name) if err != nil { errc <- err @@ -174,7 +179,8 @@ func postWithMultipartResponse(ctx context.Context, client httpClient, path, nam return } }() - req, err := fileUploadReq(ctx, path, values, pipeReader) + + req, err := fileUploadReq(ctx, path, pipeReader) if err != nil { return err } @@ -200,6 +206,20 @@ func postWithMultipartResponse(ctx context.Context, client httpClient, path, nam } } +func createFormFields(mw *multipart.Writer, values url.Values) error { + for key, value := range values { + writer, err := mw.CreateFormField(key) + if err != nil { + return err + } + _, err = writer.Write([]byte(value[0])) + if err != nil { + return err + } + } + return nil +} + func doPost(ctx context.Context, client httpClient, req *http.Request, parser responseParser, d Debug) error { resp, err := client.Do(req) if err != nil { @@ -316,7 +336,7 @@ func newJSONParser(dst interface{}) responseParser { func newTextParser(dst interface{}) responseParser { return func(resp *http.Response) error { - b, err := ioutil.ReadAll(resp.Body) + b, err := io.ReadAll(resp.Body) if err != nil { return err } diff --git a/backend/vendor/github.com/slack-go/slack/oauth.go b/backend/vendor/github.com/slack-go/slack/oauth.go index ded8c73a..0c77eca4 100644 --- a/backend/vendor/github.com/slack-go/slack/oauth.go +++ b/backend/vendor/github.com/slack-go/slack/oauth.go @@ -79,12 +79,14 @@ type OpenIDConnectResponse struct { SlackResponse } -// GetOAuthToken retrieves an AccessToken +// GetOAuthToken retrieves an AccessToken. +// For more details, see GetOAuthTokenContext documentation. func GetOAuthToken(client httpClient, clientID, clientSecret, code, redirectURI string) (accessToken string, scope string, err error) { return GetOAuthTokenContext(context.Background(), client, clientID, clientSecret, code, redirectURI) } -// GetOAuthTokenContext retrieves an AccessToken with a custom context +// GetOAuthTokenContext retrieves an AccessToken with a custom context. +// For more details, see GetOAuthResponseContext documentation. func GetOAuthTokenContext(ctx context.Context, client httpClient, clientID, clientSecret, code, redirectURI string) (accessToken string, scope string, err error) { response, err := GetOAuthResponseContext(ctx, client, clientID, clientSecret, code, redirectURI) if err != nil { @@ -94,11 +96,13 @@ func GetOAuthTokenContext(ctx context.Context, client httpClient, clientID, clie } // GetBotOAuthToken retrieves top-level and bot AccessToken - https://api.slack.com/legacy/oauth#bot_user_access_tokens +// For more details, see GetBotOAuthTokenContext documentation. func GetBotOAuthToken(client httpClient, clientID, clientSecret, code, redirectURI string) (accessToken string, scope string, bot OAuthResponseBot, err error) { return GetBotOAuthTokenContext(context.Background(), client, clientID, clientSecret, code, redirectURI) } -// GetBotOAuthTokenContext retrieves top-level and bot AccessToken with a custom context +// GetBotOAuthTokenContext retrieves top-level and bot AccessToken with a custom context. +// For more details, see GetOAuthResponseContext documentation. func GetBotOAuthTokenContext(ctx context.Context, client httpClient, clientID, clientSecret, code, redirectURI string) (accessToken string, scope string, bot OAuthResponseBot, err error) { response, err := GetOAuthResponseContext(ctx, client, clientID, clientSecret, code, redirectURI) if err != nil { @@ -107,12 +111,14 @@ func GetBotOAuthTokenContext(ctx context.Context, client httpClient, clientID, c return response.AccessToken, response.Scope, response.Bot, nil } -// GetOAuthResponse retrieves OAuth response +// GetOAuthResponse retrieves OAuth response. +// For more details, see GetOAuthResponseContext documentation. func GetOAuthResponse(client httpClient, clientID, clientSecret, code, redirectURI string) (resp *OAuthResponse, err error) { return GetOAuthResponseContext(context.Background(), client, clientID, clientSecret, code, redirectURI) } -// GetOAuthResponseContext retrieves OAuth response with custom context +// GetOAuthResponseContext retrieves OAuth response with custom context. +// Slack API docs: https://api.slack.com/methods/oauth.access func GetOAuthResponseContext(ctx context.Context, client httpClient, clientID, clientSecret, code, redirectURI string) (resp *OAuthResponse, err error) { values := url.Values{ "client_id": {clientID}, @@ -127,12 +133,14 @@ func GetOAuthResponseContext(ctx context.Context, client httpClient, clientID, c return response, response.Err() } -// GetOAuthV2Response gets a V2 OAuth access token response - https://api.slack.com/methods/oauth.v2.access +// GetOAuthV2Response gets a V2 OAuth access token response. +// For more details, see GetOAuthV2ResponseContext documentation. func GetOAuthV2Response(client httpClient, clientID, clientSecret, code, redirectURI string) (resp *OAuthV2Response, err error) { return GetOAuthV2ResponseContext(context.Background(), client, clientID, clientSecret, code, redirectURI) } -// GetOAuthV2ResponseContext with a context, gets a V2 OAuth access token response +// GetOAuthV2ResponseContext with a context, gets a V2 OAuth access token response. +// Slack API docs: https://api.slack.com/methods/oauth.v2.access func GetOAuthV2ResponseContext(ctx context.Context, client httpClient, clientID, clientSecret, code, redirectURI string) (resp *OAuthV2Response, err error) { values := url.Values{ "client_id": {clientID}, @@ -147,12 +155,14 @@ func GetOAuthV2ResponseContext(ctx context.Context, client httpClient, clientID, return response, response.Err() } -// RefreshOAuthV2Token with a context, gets a V2 OAuth access token response +// RefreshOAuthV2Token with a context, gets a V2 OAuth access token response. +// For more details, see RefreshOAuthV2TokenContext documentation. func RefreshOAuthV2Token(client httpClient, clientID, clientSecret, refreshToken string) (resp *OAuthV2Response, err error) { return RefreshOAuthV2TokenContext(context.Background(), client, clientID, clientSecret, refreshToken) } -// RefreshOAuthV2TokenContext with a context, gets a V2 OAuth access token response +// RefreshOAuthV2TokenContext with a context, gets a V2 OAuth access token response. +// Slack API docs: https://api.slack.com/methods/oauth.v2.access func RefreshOAuthV2TokenContext(ctx context.Context, client httpClient, clientID, clientSecret, refreshToken string) (resp *OAuthV2Response, err error) { values := url.Values{ "client_id": {clientID}, @@ -168,12 +178,13 @@ func RefreshOAuthV2TokenContext(ctx context.Context, client httpClient, clientID } // GetOpenIDConnectToken exchanges a temporary OAuth verifier code for an access token for Sign in with Slack. -// see: https://api.slack.com/methods/openid.connect.token +// For more details, see GetOpenIDConnectTokenContext documentation. func GetOpenIDConnectToken(client httpClient, clientID, clientSecret, code, redirectURI string) (resp *OpenIDConnectResponse, err error) { return GetOpenIDConnectTokenContext(context.Background(), client, clientID, clientSecret, code, redirectURI) } // GetOpenIDConnectTokenContext with a context, gets an access token for Sign in with Slack. +// Slack API docs: https://api.slack.com/methods/openid.connect.token func GetOpenIDConnectTokenContext(ctx context.Context, client httpClient, clientID, clientSecret, code, redirectURI string) (resp *OpenIDConnectResponse, err error) { values := url.Values{ "client_id": {clientID}, diff --git a/backend/vendor/github.com/slack-go/slack/pins.go b/backend/vendor/github.com/slack-go/slack/pins.go index ef97c8df..5e6cf0c7 100644 --- a/backend/vendor/github.com/slack-go/slack/pins.go +++ b/backend/vendor/github.com/slack-go/slack/pins.go @@ -12,12 +12,14 @@ type listPinsResponseFull struct { SlackResponse } -// AddPin pins an item in a channel +// AddPin pins an item in a channel. +// For more details, see AddPinContext documentation. func (api *Client) AddPin(channel string, item ItemRef) error { return api.AddPinContext(context.Background(), channel, item) } -// AddPinContext pins an item in a channel with a custom context +// AddPinContext pins an item in a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/pins.add func (api *Client) AddPinContext(ctx context.Context, channel string, item ItemRef) error { values := url.Values{ "channel": {channel}, @@ -41,12 +43,14 @@ func (api *Client) AddPinContext(ctx context.Context, channel string, item ItemR return response.Err() } -// RemovePin un-pins an item from a channel +// RemovePin un-pins an item from a channel. +// For more details, see RemovePinContext documentation. func (api *Client) RemovePin(channel string, item ItemRef) error { return api.RemovePinContext(context.Background(), channel, item) } -// RemovePinContext un-pins an item from a channel with a custom context +// RemovePinContext un-pins an item from a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/pins.remove func (api *Client) RemovePinContext(ctx context.Context, channel string, item ItemRef) error { values := url.Values{ "channel": {channel}, @@ -71,11 +75,13 @@ func (api *Client) RemovePinContext(ctx context.Context, channel string, item It } // ListPins returns information about the items a user reacted to. +// For more details, see ListPinsContext documentation. func (api *Client) ListPins(channel string) ([]Item, *Paging, error) { return api.ListPinsContext(context.Background(), channel) } // ListPinsContext returns information about the items a user reacted to with a custom context. +// Slack API docs: https://api.slack.com/methods/pins.list func (api *Client) ListPinsContext(ctx context.Context, channel string) ([]Item, *Paging, error) { values := url.Values{ "channel": {channel}, diff --git a/backend/vendor/github.com/slack-go/slack/reactions.go b/backend/vendor/github.com/slack-go/slack/reactions.go index 2a9bd42e..240f5ba9 100644 --- a/backend/vendor/github.com/slack-go/slack/reactions.go +++ b/backend/vendor/github.com/slack-go/slack/reactions.go @@ -67,10 +67,11 @@ const ( // ListReactionsParameters is the inputs to find all reactions by a user. type ListReactionsParameters struct { - User string - Count int - Page int - Full bool + User string + TeamID string + Count int + Page int + Full bool } // NewListReactionsParameters initializes the inputs to find all reactions @@ -128,11 +129,13 @@ func (res listReactionsResponseFull) extractReactedItems() []ReactedItem { } // AddReaction adds a reaction emoji to a message, file or file comment. +// For more details, see AddReactionContext documentation. func (api *Client) AddReaction(name string, item ItemRef) error { return api.AddReactionContext(context.Background(), name, item) } // AddReactionContext adds a reaction emoji to a message, file or file comment with a custom context. +// Slack API docs: https://api.slack.com/methods/reactions.add func (api *Client) AddReactionContext(ctx context.Context, name string, item ItemRef) error { values := url.Values{ "token": {api.token}, @@ -162,11 +165,13 @@ func (api *Client) AddReactionContext(ctx context.Context, name string, item Ite } // RemoveReaction removes a reaction emoji from a message, file or file comment. +// For more details, see RemoveReactionContext documentation. func (api *Client) RemoveReaction(name string, item ItemRef) error { return api.RemoveReactionContext(context.Background(), name, item) } // RemoveReactionContext removes a reaction emoji from a message, file or file comment with a custom context. +// Slack API docs: https://api.slack.com/methods/reactions.remove func (api *Client) RemoveReactionContext(ctx context.Context, name string, item ItemRef) error { values := url.Values{ "token": {api.token}, @@ -196,11 +201,13 @@ func (api *Client) RemoveReactionContext(ctx context.Context, name string, item } // GetReactions returns details about the reactions on an item. +// For more details, see GetReactionsContext documentation. func (api *Client) GetReactions(item ItemRef, params GetReactionsParameters) ([]ItemReaction, error) { return api.GetReactionsContext(context.Background(), item, params) } -// GetReactionsContext returns details about the reactions on an item with a custom context +// GetReactionsContext returns details about the reactions on an item with a custom context. +// Slack API docs: https://api.slack.com/methods/reactions.get func (api *Client) GetReactionsContext(ctx context.Context, item ItemRef, params GetReactionsParameters) ([]ItemReaction, error) { values := url.Values{ "token": {api.token}, @@ -234,11 +241,13 @@ func (api *Client) GetReactionsContext(ctx context.Context, item ItemRef, params } // ListReactions returns information about the items a user reacted to. +// For more details, see ListReactionsContext documentation. func (api *Client) ListReactions(params ListReactionsParameters) ([]ReactedItem, *Paging, error) { return api.ListReactionsContext(context.Background(), params) } // ListReactionsContext returns information about the items a user reacted to with a custom context. +// Slack API docs: https://api.slack.com/methods/reactions.list func (api *Client) ListReactionsContext(ctx context.Context, params ListReactionsParameters) ([]ReactedItem, *Paging, error) { values := url.Values{ "token": {api.token}, @@ -246,6 +255,9 @@ func (api *Client) ListReactionsContext(ctx context.Context, params ListReaction if params.User != DEFAULT_REACTIONS_USER { values.Add("user", params.User) } + if params.TeamID != "" { + values.Add("team_id", params.TeamID) + } if params.Count != DEFAULT_REACTIONS_COUNT { values.Add("count", strconv.Itoa(params.Count)) } diff --git a/backend/vendor/github.com/slack-go/slack/reminders.go b/backend/vendor/github.com/slack-go/slack/reminders.go index 53d67c03..e025bc9b 100644 --- a/backend/vendor/github.com/slack-go/slack/reminders.go +++ b/backend/vendor/github.com/slack-go/slack/reminders.go @@ -41,23 +41,18 @@ func (api *Client) doReminders(ctx context.Context, path string, values url.Valu // create an array of pointers to reminders var reminders = make([]*Reminder, 0, len(response.Reminders)) - for _, reminder := range response.Reminders { - reminders = append(reminders, reminder) - } - + reminders = append(reminders, response.Reminders...) return reminders, response.Err() } // ListReminders lists all the reminders created by or for the authenticated user -// -// See https://api.slack.com/methods/reminders.list +// For more details, see ListRemindersContext documentation. func (api *Client) ListReminders() ([]*Reminder, error) { return api.ListRemindersContext(context.Background()) } -// ListRemindersContext lists all the reminders created by or for the authenticated user with a custom context -// -// For more details, see ListReminders documentation. +// ListRemindersContext lists all the reminders created by or for the authenticated user with a custom context. +// Slack API docs: https://api.slack.com/methods/reminders.list func (api *Client) ListRemindersContext(ctx context.Context) ([]*Reminder, error) { values := url.Values{ "token": {api.token}, @@ -66,17 +61,14 @@ func (api *Client) ListRemindersContext(ctx context.Context) ([]*Reminder, error } // AddChannelReminder adds a reminder for a channel. -// -// See https://api.slack.com/methods/reminders.add (NOTE: the ability to set -// reminders on a channel is currently undocumented but has been tested to -// work) +// For more details, see AddChannelReminderContext documentation. func (api *Client) AddChannelReminder(channelID, text, time string) (*Reminder, error) { return api.AddChannelReminderContext(context.Background(), channelID, text, time) } // AddChannelReminderContext adds a reminder for a channel with a custom context -// -// For more details, see AddChannelReminder documentation. +// NOTE: the ability to set reminders on a channel is currently undocumented but has been tested to work. +// Slack API docs: https://api.slack.com/methods/reminders.add func (api *Client) AddChannelReminderContext(ctx context.Context, channelID, text, time string) (*Reminder, error) { values := url.Values{ "token": {api.token}, @@ -88,17 +80,13 @@ func (api *Client) AddChannelReminderContext(ctx context.Context, channelID, tex } // AddUserReminder adds a reminder for a user. -// -// See https://api.slack.com/methods/reminders.add (NOTE: the ability to set -// reminders on a channel is currently undocumented but has been tested to -// work) +// For more details, see AddUserReminderContext documentation. func (api *Client) AddUserReminder(userID, text, time string) (*Reminder, error) { return api.AddUserReminderContext(context.Background(), userID, text, time) } // AddUserReminderContext adds a reminder for a user with a custom context -// -// For more details, see AddUserReminder documentation. +// Slack API docs: https://api.slack.com/methods/reminders.add func (api *Client) AddUserReminderContext(ctx context.Context, userID, text, time string) (*Reminder, error) { values := url.Values{ "token": {api.token}, @@ -110,15 +98,13 @@ func (api *Client) AddUserReminderContext(ctx context.Context, userID, text, tim } // DeleteReminder deletes an existing reminder. -// -// See https://api.slack.com/methods/reminders.delete +// For more details, see DeleteReminderContext documentation. func (api *Client) DeleteReminder(id string) error { return api.DeleteReminderContext(context.Background(), id) } // DeleteReminderContext deletes an existing reminder with a custom context -// -// For more details, see DeleteReminder documentation. +// Slack API docs: https://api.slack.com/methods/reminders.delete func (api *Client) DeleteReminderContext(ctx context.Context, id string) error { values := url.Values{ "token": {api.token}, diff --git a/backend/vendor/github.com/slack-go/slack/remotefiles.go b/backend/vendor/github.com/slack-go/slack/remotefiles.go index 8a908a8f..42639a17 100644 --- a/backend/vendor/github.com/slack-go/slack/remotefiles.go +++ b/backend/vendor/github.com/slack-go/slack/remotefiles.go @@ -97,14 +97,13 @@ func (api *Client) remoteFileRequest(ctx context.Context, path string, values ur } // AddRemoteFile adds a remote file. Unlike regular files, remote files must be explicitly shared. -// For more details: -// https://api.slack.com/methods/files.remote.add +// For more details see the AddRemoteFileContext documentation. func (api *Client) AddRemoteFile(params RemoteFileParameters) (*RemoteFile, error) { return api.AddRemoteFileContext(context.Background(), params) } // AddRemoteFileContext adds a remote file and setting a custom context -// For more details see the AddRemoteFile documentation. +// Slack API docs: https://api.slack.com/methods/files.remote.add func (api *Client) AddRemoteFileContext(ctx context.Context, params RemoteFileParameters) (remotefile *RemoteFile, err error) { if params.ExternalID == "" || params.ExternalURL == "" || params.Title == "" { return nil, ErrParametersMissing @@ -138,14 +137,13 @@ func (api *Client) AddRemoteFileContext(ctx context.Context, params RemoteFilePa } // ListRemoteFiles retrieves all remote files according to the parameters given. Uses cursor based pagination. -// For more details: -// https://api.slack.com/methods/files.remote.list +// For more details see the ListRemoteFilesContext documentation. func (api *Client) ListRemoteFiles(params ListRemoteFilesParameters) ([]RemoteFile, error) { return api.ListRemoteFilesContext(context.Background(), params) } // ListRemoteFilesContext retrieves all remote files according to the parameters given with a custom context. Uses cursor based pagination. -// For more details see the ListRemoteFiles documentation. +// Slack API docs: https://api.slack.com/methods/files.remote.list func (api *Client) ListRemoteFilesContext(ctx context.Context, params ListRemoteFilesParameters) ([]RemoteFile, error) { values := url.Values{ "token": {api.token}, @@ -177,14 +175,13 @@ func (api *Client) ListRemoteFilesContext(ctx context.Context, params ListRemote } // GetRemoteFileInfo retrieves the complete remote file information. -// For more details: -// https://api.slack.com/methods/files.remote.info +// For more details see the GetRemoteFileInfoContext documentation. func (api *Client) GetRemoteFileInfo(externalID, fileID string) (remotefile *RemoteFile, err error) { return api.GetRemoteFileInfoContext(context.Background(), externalID, fileID) } // GetRemoteFileInfoContext retrieves the complete remote file information given with a custom context. -// For more details see the GetRemoteFileInfo documentation. +// Slack API docs: https://api.slack.com/methods/files.remote.info func (api *Client) GetRemoteFileInfoContext(ctx context.Context, externalID, fileID string) (remotefile *RemoteFile, err error) { if fileID == "" && externalID == "" { return nil, fmt.Errorf("either externalID or fileID is required") @@ -208,15 +205,14 @@ func (api *Client) GetRemoteFileInfoContext(ctx context.Context, externalID, fil return &response.RemoteFile, err } -// ShareRemoteFile shares a remote file to channels -// For more details: -// https://api.slack.com/methods/files.remote.share +// ShareRemoteFile shares a remote file to channels. +// For more details see the ShareRemoteFileContext documentation. func (api *Client) ShareRemoteFile(channels []string, externalID, fileID string) (file *RemoteFile, err error) { return api.ShareRemoteFileContext(context.Background(), channels, externalID, fileID) } // ShareRemoteFileContext shares a remote file to channels with a custom context. -// For more details see the ShareRemoteFile documentation. +// Slack API docs: https://api.slack.com/methods/files.remote.share func (api *Client) ShareRemoteFileContext(ctx context.Context, channels []string, externalID, fileID string) (file *RemoteFile, err error) { if channels == nil || len(channels) == 0 { return nil, ErrParametersMissing @@ -241,20 +237,17 @@ func (api *Client) ShareRemoteFileContext(ctx context.Context, channels []string return &response.RemoteFile, err } -// UpdateRemoteFile updates a remote file -// For more details: -// https://api.slack.com/methods/files.remote.update +// UpdateRemoteFile updates a remote file. +// For more details see the UpdateRemoteFileContext documentation. func (api *Client) UpdateRemoteFile(fileID string, params RemoteFileParameters) (remotefile *RemoteFile, err error) { return api.UpdateRemoteFileContext(context.Background(), fileID, params) } -// UpdateRemoteFileContext updates a remote file with a custom context -// For more details see the UpdateRemoteFile documentation. +// UpdateRemoteFileContext updates a remote file with a custom context. +// Slack API docs: https://api.slack.com/methods/files.remote.update func (api *Client) UpdateRemoteFileContext(ctx context.Context, fileID string, params RemoteFileParameters) (remotefile *RemoteFile, err error) { response := &remoteFileResponseFull{} - values := url.Values{ - "token": {api.token}, - } + values := url.Values{} if fileID != "" { values.Add("file", fileID) } @@ -276,6 +269,7 @@ func (api *Client) UpdateRemoteFileContext(ctx context.Context, fileID string, p if params.PreviewImageReader != nil { err = postWithMultipartResponse(ctx, api.httpclient, api.endpoint+"files.remote.update", "preview.png", "preview_image", api.token, values, params.PreviewImageReader, response, api) } else { + values.Add("token", api.token) response, err = api.remoteFileRequest(ctx, "files.remote.update", values) } @@ -287,14 +281,13 @@ func (api *Client) UpdateRemoteFileContext(ctx context.Context, fileID string, p } // RemoveRemoteFile removes a remote file. -// For more details: -// https://api.slack.com/methods/files.remote.remove +// For more information see the RemoveRemoteFileContext documentation. func (api *Client) RemoveRemoteFile(externalID, fileID string) (err error) { return api.RemoveRemoteFileContext(context.Background(), externalID, fileID) } // RemoveRemoteFileContext removes a remote file with a custom context -// For more information see the RemoveRemoteFiles documentation. +// Slack API docs: https://api.slack.com/methods/files.remote.remove func (api *Client) RemoveRemoteFileContext(ctx context.Context, externalID, fileID string) (err error) { if fileID == "" && externalID == "" { return fmt.Errorf("either externalID or fileID is required") diff --git a/backend/vendor/github.com/slack-go/slack/search.go b/backend/vendor/github.com/slack-go/slack/search.go index de6b40ac..d27497aa 100644 --- a/backend/vendor/github.com/slack-go/slack/search.go +++ b/backend/vendor/github.com/slack-go/slack/search.go @@ -15,6 +15,7 @@ const ( ) type SearchParameters struct { + TeamID string Sort string SortDirection string Highlight bool @@ -93,6 +94,9 @@ func (api *Client) _search(ctx context.Context, path, query string, params Searc "token": {api.token}, "query": {query}, } + if params.TeamID != "" { + values.Add("team_id", params.TeamID) + } if params.Sort != DEFAULT_SEARCH_SORT { values.Add("sort", params.Sort) } diff --git a/backend/vendor/github.com/slack-go/slack/stars.go b/backend/vendor/github.com/slack-go/slack/stars.go index 6e0ebbe3..51926854 100644 --- a/backend/vendor/github.com/slack-go/slack/stars.go +++ b/backend/vendor/github.com/slack-go/slack/stars.go @@ -36,12 +36,14 @@ func NewStarsParameters() StarsParameters { } } -// AddStar stars an item in a channel +// AddStar stars an item in a channel. +// For more information see the AddStarContext documentation. func (api *Client) AddStar(channel string, item ItemRef) error { return api.AddStarContext(context.Background(), channel, item) } -// AddStarContext stars an item in a channel with a custom context +// AddStarContext stars an item in a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/stars.add func (api *Client) AddStarContext(ctx context.Context, channel string, item ItemRef) error { values := url.Values{ "channel": {channel}, @@ -65,12 +67,14 @@ func (api *Client) AddStarContext(ctx context.Context, channel string, item Item return response.Err() } -// RemoveStar removes a starred item from a channel +// RemoveStar removes a starred item from a channel. +// For more information see the RemoveStarContext documentation. func (api *Client) RemoveStar(channel string, item ItemRef) error { return api.RemoveStarContext(context.Background(), channel, item) } -// RemoveStarContext removes a starred item from a channel with a custom context +// RemoveStarContext removes a starred item from a channel with a custom context. +// Slack API docs: https://api.slack.com/methods/stars.remove func (api *Client) RemoveStarContext(ctx context.Context, channel string, item ItemRef) error { values := url.Values{ "channel": {channel}, @@ -94,12 +98,14 @@ func (api *Client) RemoveStarContext(ctx context.Context, channel string, item I return response.Err() } -// ListStars returns information about the stars a user added +// ListStars returns information about the stars a user added. +// For more information see the ListStarsContext documentation. func (api *Client) ListStars(params StarsParameters) ([]Item, *Paging, error) { return api.ListStarsContext(context.Background(), params) } -// ListStarsContext returns information about the stars a user added with a custom context +// ListStarsContext returns information about the stars a user added with a custom context. +// Slack API docs: https://api.slack.com/methods/stars.list func (api *Client) ListStarsContext(ctx context.Context, params StarsParameters) ([]Item, *Paging, error) { values := url.Values{ "token": {api.token}, @@ -147,7 +153,6 @@ func (api *Client) GetStarred(params StarsParameters) ([]StarredItem, *Paging, e } // GetStarredContext returns a list of StarredItem items with a custom context -// // For more details see GetStarred func (api *Client) GetStarredContext(ctx context.Context, params StarsParameters) ([]StarredItem, *Paging, error) { items, paging, err := api.ListStarsContext(ctx, params) diff --git a/backend/vendor/github.com/slack-go/slack/team.go b/backend/vendor/github.com/slack-go/slack/team.go index d21a1b64..4e890c2b 100644 --- a/backend/vendor/github.com/slack-go/slack/team.go +++ b/backend/vendor/github.com/slack-go/slack/team.go @@ -74,8 +74,9 @@ type BillingActive struct { // AccessLogParameters contains all the parameters necessary (including the optional ones) for a GetAccessLogs() request type AccessLogParameters struct { - Count int - Page int + TeamID string + Count int + Page int } // NewAccessLogParameters provides an instance of AccessLogParameters with all the sane default values set @@ -124,12 +125,14 @@ func (api *Client) teamProfileRequest(ctx context.Context, client httpClient, pa return response, response.Err() } -// GetTeamInfo gets the Team Information of the user +// GetTeamInfo gets the Team Information of the user. +// For more information see the GetTeamInfoContext documentation. func (api *Client) GetTeamInfo() (*TeamInfo, error) { return api.GetTeamInfoContext(context.Background()) } -// GetOtherTeamInfoContext gets Team information for any team with a custom context +// GetOtherTeamInfoContext gets Team information for any team with a custom context. +// Slack API docs: https://api.slack.com/methods/team.info func (api *Client) GetOtherTeamInfoContext(ctx context.Context, team string) (*TeamInfo, error) { if team == "" { return api.GetTeamInfoContext(ctx) @@ -145,12 +148,14 @@ func (api *Client) GetOtherTeamInfoContext(ctx context.Context, team string) (*T return &response.Team, nil } -// GetOtherTeamInfo gets Team information for any team +// GetOtherTeamInfo gets Team information for any team. +// For more information see the GetOtherTeamInfoContext documentation. func (api *Client) GetOtherTeamInfo(team string) (*TeamInfo, error) { return api.GetOtherTeamInfoContext(context.Background(), team) } -// GetTeamInfoContext gets the Team Information of the user with a custom context +// GetTeamInfoContext gets the Team Information of the user with a custom context. +// Slack API docs: https://api.slack.com/methods/team.info func (api *Client) GetTeamInfoContext(ctx context.Context) (*TeamInfo, error) { values := url.Values{ "token": {api.token}, @@ -163,35 +168,44 @@ func (api *Client) GetTeamInfoContext(ctx context.Context) (*TeamInfo, error) { return &response.Team, nil } -// GetTeamProfile gets the Team Profile settings of the user -func (api *Client) GetTeamProfile() (*TeamProfile, error) { - return api.GetTeamProfileContext(context.Background()) +// GetTeamProfile gets the Team Profile settings of the user. +// For more information see the GetTeamProfileContext documentation. +func (api *Client) GetTeamProfile(teamID ...string) (*TeamProfile, error) { + return api.GetTeamProfileContext(context.Background(), teamID...) } -// GetTeamProfileContext gets the Team Profile settings of the user with a custom context -func (api *Client) GetTeamProfileContext(ctx context.Context) (*TeamProfile, error) { +// GetTeamProfileContext gets the Team Profile settings of the user with a custom context. +// Slack API docs: https://api.slack.com/methods/team.profile.get +func (api *Client) GetTeamProfileContext(ctx context.Context, teamID ...string) (*TeamProfile, error) { values := url.Values{ "token": {api.token}, } + if len(teamID) > 0 { + values["team_id"] = teamID + } response, err := api.teamProfileRequest(ctx, api.httpclient, "team.profile.get", values) if err != nil { return nil, err } return &response.Profile, nil - } -// GetAccessLogs retrieves a page of logins according to the parameters given +// GetAccessLogs retrieves a page of logins according to the parameters given. +// For more information see the GetAccessLogsContext documentation. func (api *Client) GetAccessLogs(params AccessLogParameters) ([]Login, *Paging, error) { return api.GetAccessLogsContext(context.Background(), params) } -// GetAccessLogsContext retrieves a page of logins according to the parameters given with a custom context +// GetAccessLogsContext retrieves a page of logins according to the parameters given with a custom context. +// Slack API docs: https://api.slack.com/methods/team.accessLogs func (api *Client) GetAccessLogsContext(ctx context.Context, params AccessLogParameters) ([]Login, *Paging, error) { values := url.Values{ "token": {api.token}, } + if params.TeamID != "" { + values.Add("team_id", params.TeamID) + } if params.Count != DEFAULT_LOGINS_COUNT { values.Add("count", strconv.Itoa(params.Count)) } @@ -206,31 +220,31 @@ func (api *Client) GetAccessLogsContext(ctx context.Context, params AccessLogPar return response.Logins, &response.Paging, nil } -// GetBillableInfo ... -func (api *Client) GetBillableInfo(user string) (map[string]BillingActive, error) { - return api.GetBillableInfoContext(context.Background(), user) +type GetBillableInfoParams struct { + User string + TeamID string } -// GetBillableInfoContext ... -func (api *Client) GetBillableInfoContext(ctx context.Context, user string) (map[string]BillingActive, error) { - values := url.Values{ - "token": {api.token}, - "user": {user}, - } - - return api.billableInfoRequest(ctx, "team.billableInfo", values) +// GetBillableInfo gets the billable users information of the team. +// For more information see the GetBillableInfoContext documentation. +func (api *Client) GetBillableInfo(params GetBillableInfoParams) (map[string]BillingActive, error) { + return api.GetBillableInfoContext(context.Background(), params) } -// GetBillableInfoForTeam returns the billing_active status of all users on the team. -func (api *Client) GetBillableInfoForTeam() (map[string]BillingActive, error) { - return api.GetBillableInfoForTeamContext(context.Background()) -} - -// GetBillableInfoForTeamContext returns the billing_active status of all users on the team with a custom context -func (api *Client) GetBillableInfoForTeamContext(ctx context.Context) (map[string]BillingActive, error) { +// GetBillableInfoContext gets the billable users information of the team with a custom context. +// Slack API docs: https://api.slack.com/methods/team.billableInfo +func (api *Client) GetBillableInfoContext(ctx context.Context, params GetBillableInfoParams) (map[string]BillingActive, error) { values := url.Values{ "token": {api.token}, } + if params.TeamID != "" { + values.Add("team_id", params.TeamID) + } + + if params.User != "" { + values.Add("user", params.User) + } + return api.billableInfoRequest(ctx, "team.billableInfo", values) } diff --git a/backend/vendor/github.com/slack-go/slack/tokens.go b/backend/vendor/github.com/slack-go/slack/tokens.go index 4b83beeb..49bbde9b 100644 --- a/backend/vendor/github.com/slack-go/slack/tokens.go +++ b/backend/vendor/github.com/slack-go/slack/tokens.go @@ -5,12 +5,14 @@ import ( "net/url" ) -// RotateTokens exchanges a refresh token for a new app configuration token +// RotateTokens exchanges a refresh token for a new app configuration token. +// For more information see the RotateTokensContext documentation. func (api *Client) RotateTokens(configToken string, refreshToken string) (*TokenResponse, error) { return api.RotateTokensContext(context.Background(), configToken, refreshToken) } -// RotateTokensContext exchanges a refresh token for a new app configuration token with a custom context +// RotateTokensContext exchanges a refresh token for a new app configuration token with a custom context. +// Slack API docs: https://api.slack.com/methods/tooling.tokens.rotate func (api *Client) RotateTokensContext(ctx context.Context, configToken string, refreshToken string) (*TokenResponse, error) { if configToken == "" { configToken = api.configToken diff --git a/backend/vendor/github.com/slack-go/slack/usergroups.go b/backend/vendor/github.com/slack-go/slack/usergroups.go index c5d7a176..0c2ec4c9 100644 --- a/backend/vendor/github.com/slack-go/slack/usergroups.go +++ b/backend/vendor/github.com/slack-go/slack/usergroups.go @@ -50,18 +50,24 @@ func (api *Client) userGroupRequest(ctx context.Context, path string, values url return response, response.Err() } -// CreateUserGroup creates a new user group +// CreateUserGroup creates a new user group. +// For more information see the CreateUserGroupContext documentation. func (api *Client) CreateUserGroup(userGroup UserGroup) (UserGroup, error) { return api.CreateUserGroupContext(context.Background(), userGroup) } -// CreateUserGroupContext creates a new user group with a custom context +// CreateUserGroupContext creates a new user group with a custom context. +// Slack API docs: https://api.slack.com/methods/usergroups.create func (api *Client) CreateUserGroupContext(ctx context.Context, userGroup UserGroup) (UserGroup, error) { values := url.Values{ "token": {api.token}, "name": {userGroup.Name}, } + if userGroup.TeamID != "" { + values["team_id"] = []string{userGroup.TeamID} + } + if userGroup.Handle != "" { values["handle"] = []string{userGroup.Handle} } @@ -81,12 +87,14 @@ func (api *Client) CreateUserGroupContext(ctx context.Context, userGroup UserGro return response.UserGroup, nil } -// DisableUserGroup disables an existing user group +// DisableUserGroup disables an existing user group. +// For more information see the DisableUserGroupContext documentation. func (api *Client) DisableUserGroup(userGroup string) (UserGroup, error) { return api.DisableUserGroupContext(context.Background(), userGroup) } -// DisableUserGroupContext disables an existing user group with a custom context +// DisableUserGroupContext disables an existing user group with a custom context. +// Slack API docs: https://api.slack.com/methods/usergroups.disable func (api *Client) DisableUserGroupContext(ctx context.Context, userGroup string) (UserGroup, error) { values := url.Values{ "token": {api.token}, @@ -100,12 +108,14 @@ func (api *Client) DisableUserGroupContext(ctx context.Context, userGroup string return response.UserGroup, nil } -// EnableUserGroup enables an existing user group +// EnableUserGroup enables an existing user group. +// For more information see the EnableUserGroupContext documentation. func (api *Client) EnableUserGroup(userGroup string) (UserGroup, error) { return api.EnableUserGroupContext(context.Background(), userGroup) } -// EnableUserGroupContext enables an existing user group with a custom context +// EnableUserGroupContext enables an existing user group with a custom context. +// Slack API docs: https://api.slack.com/methods/usergroups.enable func (api *Client) EnableUserGroupContext(ctx context.Context, userGroup string) (UserGroup, error) { values := url.Values{ "token": {api.token}, @@ -122,6 +132,12 @@ func (api *Client) EnableUserGroupContext(ctx context.Context, userGroup string) // GetUserGroupsOption options for the GetUserGroups method call. type GetUserGroupsOption func(*GetUserGroupsParams) +func GetUserGroupsOptionWithTeamID(teamID string) GetUserGroupsOption { + return func(params *GetUserGroupsParams) { + params.TeamID = teamID + } +} + // GetUserGroupsOptionIncludeCount include the number of users in each User Group (default: false) func GetUserGroupsOptionIncludeCount(b bool) GetUserGroupsOption { return func(params *GetUserGroupsParams) { @@ -145,17 +161,20 @@ func GetUserGroupsOptionIncludeUsers(b bool) GetUserGroupsOption { // GetUserGroupsParams contains arguments for GetUserGroups method call type GetUserGroupsParams struct { + TeamID string IncludeCount bool IncludeDisabled bool IncludeUsers bool } -// GetUserGroups returns a list of user groups for the team +// GetUserGroups returns a list of user groups for the team. +// For more information see the GetUserGroupsContext documentation. func (api *Client) GetUserGroups(options ...GetUserGroupsOption) ([]UserGroup, error) { return api.GetUserGroupsContext(context.Background(), options...) } -// GetUserGroupsContext returns a list of user groups for the team with a custom context +// GetUserGroupsContext returns a list of user groups for the team with a custom context. +// Slack API docs: https://api.slack.com/methods/usergroups.list func (api *Client) GetUserGroupsContext(ctx context.Context, options ...GetUserGroupsOption) ([]UserGroup, error) { params := GetUserGroupsParams{} @@ -166,6 +185,9 @@ func (api *Client) GetUserGroupsContext(ctx context.Context, options ...GetUserG values := url.Values{ "token": {api.token}, } + if params.TeamID != "" { + values.Add("team_id", params.TeamID) + } if params.IncludeCount { values.Add("include_count", "true") } @@ -222,12 +244,14 @@ type UpdateUserGroupsParams struct { Channels *[]string } -// UpdateUserGroup will update an existing user group +// UpdateUserGroup will update an existing user group. +// For more information see the UpdateUserGroupContext documentation. func (api *Client) UpdateUserGroup(userGroupID string, options ...UpdateUserGroupsOption) (UserGroup, error) { return api.UpdateUserGroupContext(context.Background(), userGroupID, options...) } -// UpdateUserGroupContext will update an existing user group with a custom context +// UpdateUserGroupContext will update an existing user group with a custom context. +// Slack API docs: https://api.slack.com/methods/usergroups.update func (api *Client) UpdateUserGroupContext(ctx context.Context, userGroupID string, options ...UpdateUserGroupsOption) (UserGroup, error) { params := UpdateUserGroupsParams{} @@ -263,12 +287,14 @@ func (api *Client) UpdateUserGroupContext(ctx context.Context, userGroupID strin return response.UserGroup, nil } -// GetUserGroupMembers will retrieve the current list of users in a group +// GetUserGroupMembers will retrieve the current list of users in a group. +// For more information see the GetUserGroupMembersContext documentation. func (api *Client) GetUserGroupMembers(userGroup string) ([]string, error) { return api.GetUserGroupMembersContext(context.Background(), userGroup) } -// GetUserGroupMembersContext will retrieve the current list of users in a group with a custom context +// GetUserGroupMembersContext will retrieve the current list of users in a group with a custom context. +// Slack API docs: https://api.slack.com/methods/usergroups.users.list func (api *Client) GetUserGroupMembersContext(ctx context.Context, userGroup string) ([]string, error) { values := url.Values{ "token": {api.token}, @@ -282,12 +308,14 @@ func (api *Client) GetUserGroupMembersContext(ctx context.Context, userGroup str return response.Users, nil } -// UpdateUserGroupMembers will update the members of an existing user group +// UpdateUserGroupMembers will update the members of an existing user group. +// For more information see the UpdateUserGroupMembersContext documentation. func (api *Client) UpdateUserGroupMembers(userGroup string, members string) (UserGroup, error) { return api.UpdateUserGroupMembersContext(context.Background(), userGroup, members) } -// UpdateUserGroupMembersContext will update the members of an existing user group with a custom context +// UpdateUserGroupMembersContext will update the members of an existing user group with a custom context. +// Slack API docs: https://api.slack.com/methods/usergroups.update func (api *Client) UpdateUserGroupMembersContext(ctx context.Context, userGroup string, members string) (UserGroup, error) { values := url.Values{ "token": {api.token}, diff --git a/backend/vendor/github.com/slack-go/slack/users.go b/backend/vendor/github.com/slack-go/slack/users.go index a3d32b24..b51b1721 100644 --- a/backend/vendor/github.com/slack-go/slack/users.go +++ b/backend/vendor/github.com/slack-go/slack/users.go @@ -227,11 +227,13 @@ func (api *Client) userRequest(ctx context.Context, path string, values url.Valu } // GetUserPresence will retrieve the current presence status of given user. +// For more information see the GetUserPresenceContext documentation. func (api *Client) GetUserPresence(user string) (*UserPresence, error) { return api.GetUserPresenceContext(context.Background(), user) } // GetUserPresenceContext will retrieve the current presence status of given user with a custom context. +// Slack API docs: https://api.slack.com/methods/users.getPresence func (api *Client) GetUserPresenceContext(ctx context.Context, user string) (*UserPresence, error) { values := url.Values{ "token": {api.token}, @@ -245,12 +247,14 @@ func (api *Client) GetUserPresenceContext(ctx context.Context, user string) (*Us return &response.UserPresence, nil } -// GetUserInfo will retrieve the complete user information +// GetUserInfo will retrieve the complete user information. +// For more information see the GetUserInfoContext documentation. func (api *Client) GetUserInfo(user string) (*User, error) { return api.GetUserInfoContext(context.Background(), user) } -// GetUserInfoContext will retrieve the complete user information with a custom context +// GetUserInfoContext will retrieve the complete user information with a custom context. +// Slack API docs: https://api.slack.com/methods/users.info func (api *Client) GetUserInfoContext(ctx context.Context, user string) (*User, error) { values := url.Values{ "token": {api.token}, @@ -265,12 +269,14 @@ func (api *Client) GetUserInfoContext(ctx context.Context, user string) (*User, return &response.User, nil } -// GetUsersInfo will retrieve the complete multi-users information +// GetUsersInfo will retrieve the complete multi-users information. +// For more information see the GetUsersInfoContext documentation. func (api *Client) GetUsersInfo(users ...string) (*[]User, error) { return api.GetUsersInfoContext(context.Background(), users...) } -// GetUsersInfoContext will retrieve the complete multi-users information with a custom context +// GetUsersInfoContext will retrieve the complete multi-users information with a custom context. +// Slack API docs: https://api.slack.com/methods/users.info func (api *Client) GetUsersInfoContext(ctx context.Context, users ...string) (*[]User, error) { values := url.Values{ "token": {api.token}, @@ -407,12 +413,14 @@ func (api *Client) GetUsersContext(ctx context.Context, options ...GetUsersOptio return results, p.Failure(err) } -// GetUserByEmail will retrieve the complete user information by email +// GetUserByEmail will retrieve the complete user information by email. +// For more information see the GetUserByEmailContext documentation. func (api *Client) GetUserByEmail(email string) (*User, error) { return api.GetUserByEmailContext(context.Background(), email) } -// GetUserByEmailContext will retrieve the complete user information by email with a custom context +// GetUserByEmailContext will retrieve the complete user information by email with a custom context. +// Slack API docs: https://api.slack.com/methods/users.lookupByEmail func (api *Client) GetUserByEmailContext(ctx context.Context, email string) (*User, error) { values := url.Values{ "token": {api.token}, @@ -425,12 +433,14 @@ func (api *Client) GetUserByEmailContext(ctx context.Context, email string) (*Us return &response.User, nil } -// SetUserAsActive marks the currently authenticated user as active +// SetUserAsActive marks the currently authenticated user as active. +// For more information see the SetUserAsActiveContext documentation. func (api *Client) SetUserAsActive() error { return api.SetUserAsActiveContext(context.Background()) } -// SetUserAsActiveContext marks the currently authenticated user as active with a custom context +// SetUserAsActiveContext marks the currently authenticated user as active with a custom context. +// Slack API docs: https://api.slack.com/methods/users.setActive func (api *Client) SetUserAsActiveContext(ctx context.Context) (err error) { values := url.Values{ "token": {api.token}, @@ -440,12 +450,14 @@ func (api *Client) SetUserAsActiveContext(ctx context.Context) (err error) { return err } -// SetUserPresence changes the currently authenticated user presence +// SetUserPresence changes the currently authenticated user presence. +// For more information see the SetUserPresenceContext documentation. func (api *Client) SetUserPresence(presence string) error { return api.SetUserPresenceContext(context.Background(), presence) } -// SetUserPresenceContext changes the currently authenticated user presence with a custom context +// SetUserPresenceContext changes the currently authenticated user presence with a custom context. +// Slack API docs: https://api.slack.com/methods/users.setPresence func (api *Client) SetUserPresenceContext(ctx context.Context, presence string) error { values := url.Values{ "token": {api.token}, @@ -456,12 +468,14 @@ func (api *Client) SetUserPresenceContext(ctx context.Context, presence string) return err } -// GetUserIdentity will retrieve user info available per identity scopes +// GetUserIdentity will retrieve user info available per identity scopes. +// For more information see the GetUserIdentityContext documentation. func (api *Client) GetUserIdentity() (*UserIdentityResponse, error) { return api.GetUserIdentityContext(context.Background()) } -// GetUserIdentityContext will retrieve user info available per identity scopes with a custom context +// GetUserIdentityContext will retrieve user info available per identity scopes with a custom context. +// Slack API docs: https://api.slack.com/methods/users.identity func (api *Client) GetUserIdentityContext(ctx context.Context) (response *UserIdentityResponse, err error) { values := url.Values{ "token": {api.token}, @@ -480,12 +494,14 @@ func (api *Client) GetUserIdentityContext(ctx context.Context) (response *UserId return response, nil } -// SetUserPhoto changes the currently authenticated user's profile image +// SetUserPhoto changes the currently authenticated user's profile image. +// For more information see the SetUserPhotoContext documentation. func (api *Client) SetUserPhoto(image string, params UserSetPhotoParams) error { return api.SetUserPhotoContext(context.Background(), image, params) } -// SetUserPhotoContext changes the currently authenticated user's profile image using a custom context +// SetUserPhotoContext changes the currently authenticated user's profile image using a custom context. +// Slack API docs: https://api.slack.com/methods/users.setPhoto func (api *Client) SetUserPhotoContext(ctx context.Context, image string, params UserSetPhotoParams) (err error) { response := &SlackResponse{} values := url.Values{} @@ -507,12 +523,14 @@ func (api *Client) SetUserPhotoContext(ctx context.Context, image string, params return response.Err() } -// DeleteUserPhoto deletes the current authenticated user's profile image +// DeleteUserPhoto deletes the current authenticated user's profile image. +// For more information see the DeleteUserPhotoContext documentation. func (api *Client) DeleteUserPhoto() error { return api.DeleteUserPhotoContext(context.Background()) } -// DeleteUserPhotoContext deletes the current authenticated user's profile image with a custom context +// DeleteUserPhotoContext deletes the current authenticated user's profile image with a custom context. +// Slack API docs: https://api.slack.com/methods/users.deletePhoto func (api *Client) DeleteUserPhotoContext(ctx context.Context) (err error) { response := &SlackResponse{} values := url.Values{ @@ -528,13 +546,13 @@ func (api *Client) DeleteUserPhotoContext(ctx context.Context) (err error) { } // SetUserRealName changes the currently authenticated user's realName -// -// For more information see SetUserRealNameContextWithUser +// For more information see the SetUserRealNameContextWithUser documentation. func (api *Client) SetUserRealName(realName string) error { return api.SetUserRealNameContextWithUser(context.Background(), "", realName) } -// SetUserRealNameContextWithUser will set a real name for the provided user with a custom context +// SetUserRealNameContextWithUser will set a real name for the provided user with a custom context. +// Slack API docs: https://api.slack.com/methods/users.profile.set func (api *Client) SetUserRealNameContextWithUser(ctx context.Context, user, realName string) error { profile, err := json.Marshal( &struct { @@ -566,20 +584,22 @@ func (api *Client) SetUserRealNameContextWithUser(ctx context.Context, user, rea return response.Err() } -// SetUserCustomFields sets Custom Profile fields on the provided users account. Due to the non-repeating elements -// within the request, a map fields is required. The key in the map signifies the field that will be updated. -// -// Note: You may need to change the way the custom field is populated within the Profile section of the Admin Console from -// SCIM or User Entered to API. -// -// See GetTeamProfile for information to retrieve possible fields for your account. +// SetUserCustomFields sets Custom Profile fields on the provided users account. +// For more information see the SetUserCustomFieldsContext documentation. func (api *Client) SetUserCustomFields(userID string, customFields map[string]UserProfileCustomField) error { return api.SetUserCustomFieldsContext(context.Background(), userID, customFields) } -// SetUserCustomFieldsContext will set a users custom profile field with context. +// SetUserCustomFieldsContext sets Custom Profile fields on the provided users account. +// Due to the non-repeating elements within the request, a map fields is required. +// The key in the map signifies the field that will be updated. // -// For more information see SetUserCustomFields +// Note: You may need to change the way the custom field is populated within the Profile section of the Admin Console +// from SCIM or User Entered to API. +// +// See GetTeamProfile for information to retrieve possible fields for your account. +// +// Slack API docs: https://api.slack.com/methods/users.profile.set func (api *Client) SetUserCustomFieldsContext(ctx context.Context, userID string, customFields map[string]UserProfileCustomField) error { // Convert data to data type with custom marshall / unmarshall @@ -615,32 +635,30 @@ func (api *Client) SetUserCustomFieldsContext(ctx context.Context, userID string } -// SetUserCustomStatus will set a custom status and emoji for the currently -// authenticated user. If statusEmoji is "" and statusText is not, the Slack API -// will automatically set it to ":speech_balloon:". Otherwise, if both are "" -// the Slack API will unset the custom status/emoji. If statusExpiration is set to 0 -// the status will not expire. +// SetUserCustomStatus will set a custom status and emoji for the currently authenticated user. +// For more information see the SetUserCustomStatusContext documentation. func (api *Client) SetUserCustomStatus(statusText, statusEmoji string, statusExpiration int64) error { return api.SetUserCustomStatusContextWithUser(context.Background(), "", statusText, statusEmoji, statusExpiration) } -// SetUserCustomStatusContext will set a custom status and emoji for the currently authenticated user with a custom context -// -// For more information see SetUserCustomStatus +// SetUserCustomStatusContext will set a custom status and emoji for the currently authenticated user with a custom context. +// For more information see the SetUserCustomStatusContextWithUser documentation. func (api *Client) SetUserCustomStatusContext(ctx context.Context, statusText, statusEmoji string, statusExpiration int64) error { return api.SetUserCustomStatusContextWithUser(ctx, "", statusText, statusEmoji, statusExpiration) } // SetUserCustomStatusWithUser will set a custom status and emoji for the provided user. -// -// For more information see SetUserCustomStatus +// For more information see the SetUserCustomStatusContextWithUser documentation. func (api *Client) SetUserCustomStatusWithUser(user, statusText, statusEmoji string, statusExpiration int64) error { return api.SetUserCustomStatusContextWithUser(context.Background(), user, statusText, statusEmoji, statusExpiration) } -// SetUserCustomStatusContextWithUser will set a custom status and emoji for the provided user with a custom context +// SetUserCustomStatusContextWithUser will set a custom status and emoji for the currently authenticated user. +// If statusEmoji is "" and statusText is not, the Slack API will automatically set it to ":speech_balloon:". +// Otherwise, if both are "" the Slack API will unset the custom status/emoji. If statusExpiration is set to 0 +// the status will not expire. // -// For more information see SetUserCustomStatus +// Slack API docs: https://api.slack.com/methods/users.profile.set func (api *Client) SetUserCustomStatusContextWithUser(ctx context.Context, user, statusText, statusEmoji string, statusExpiration int64) error { // XXX(theckman): this anonymous struct is for making requests to the Slack // API for setting and unsetting a User's Custom Status/Emoji. To change @@ -705,6 +723,7 @@ type GetUserProfileParameters struct { } // GetUserProfile retrieves a user's profile information. +// For more information see the GetUserProfileContext documentation. func (api *Client) GetUserProfile(params *GetUserProfileParameters) (*UserProfile, error) { return api.GetUserProfileContext(context.Background(), params) } @@ -715,6 +734,7 @@ type getUserProfileResponse struct { } // GetUserProfileContext retrieves a user's profile information with a context. +// Slack API docs: https://api.slack.com/methods/users.profile.get func (api *Client) GetUserProfileContext(ctx context.Context, params *GetUserProfileParameters) (*UserProfile, error) { values := url.Values{"token": {api.token}} diff --git a/backend/vendor/github.com/slack-go/slack/views.go b/backend/vendor/github.com/slack-go/slack/views.go index e6a96178..0822d2cb 100644 --- a/backend/vendor/github.com/slack-go/slack/views.go +++ b/backend/vendor/github.com/slack-go/slack/views.go @@ -155,6 +155,7 @@ type ViewResponse struct { } // OpenView opens a view for a user. +// For more information see the OpenViewContext documentation. func (api *Client) OpenView(triggerID string, view ModalViewRequest) (*ViewResponse, error) { return api.OpenViewContext(context.Background(), triggerID, view) } @@ -177,6 +178,7 @@ func ValidateUniqueBlockID(view ModalViewRequest) bool { } // OpenViewContext opens a view for a user with a custom context. +// Slack API docs: https://api.slack.com/methods/views.open func (api *Client) OpenViewContext( ctx context.Context, triggerID string, @@ -208,11 +210,13 @@ func (api *Client) OpenViewContext( } // PublishView publishes a static view for a user. +// For more information see the PublishViewContext documentation. func (api *Client) PublishView(userID string, view HomeTabViewRequest, hash string) (*ViewResponse, error) { return api.PublishViewContext(context.Background(), userID, view, hash) } // PublishViewContext publishes a static view for a user with a custom context. +// Slack API docs: https://api.slack.com/methods/views.publish func (api *Client) PublishViewContext( ctx context.Context, userID string, @@ -241,11 +245,13 @@ func (api *Client) PublishViewContext( } // PushView pushes a view onto the stack of a root view. +// For more information see the PushViewContext documentation. func (api *Client) PushView(triggerID string, view ModalViewRequest) (*ViewResponse, error) { return api.PushViewContext(context.Background(), triggerID, view) } -// PublishViewContext pushes a view onto the stack of a root view with a custom context. +// PushViewContext pushes a view onto the stack of a root view with a custom context. +// Slack API docs: https://api.slack.com/methods/views.push func (api *Client) PushViewContext( ctx context.Context, triggerID string, @@ -272,11 +278,13 @@ func (api *Client) PushViewContext( } // UpdateView updates an existing view. +// For more information see the UpdateViewContext documentation. func (api *Client) UpdateView(view ModalViewRequest, externalID, hash, viewID string) (*ViewResponse, error) { return api.UpdateViewContext(context.Background(), view, externalID, hash, viewID) } // UpdateViewContext updates an existing view with a custom context. +// Slack API docs: https://api.slack.com/methods/views.update func (api *Client) UpdateViewContext( ctx context.Context, view ModalViewRequest, diff --git a/backend/vendor/github.com/slack-go/slack/webhooks.go b/backend/vendor/github.com/slack-go/slack/webhooks.go index e3233536..5a854f38 100644 --- a/backend/vendor/github.com/slack-go/slack/webhooks.go +++ b/backend/vendor/github.com/slack-go/slack/webhooks.go @@ -6,7 +6,6 @@ import ( "encoding/json" "fmt" "io" - "io/ioutil" "net/http" ) @@ -24,6 +23,8 @@ type WebhookMessage struct { ReplaceOriginal bool `json:"replace_original"` DeleteOriginal bool `json:"delete_original"` ReplyBroadcast bool `json:"reply_broadcast,omitempty"` + UnfurlLinks bool `json:"unfurl_links,omitempty"` + UnfurlMedia bool `json:"unfurl_media,omitempty"` } func PostWebhook(url string, msg *WebhookMessage) error { @@ -55,7 +56,7 @@ func PostWebhookCustomHTTPContext(ctx context.Context, url string, httpClient *h return fmt.Errorf("failed to post webhook: %w", err) } defer func() { - io.Copy(ioutil.Discard, resp.Body) + io.Copy(io.Discard, resp.Body) resp.Body.Close() }() diff --git a/backend/vendor/github.com/slack-go/slack/workflow_step.go b/backend/vendor/github.com/slack-go/slack/workflow_step.go index bcc892c5..747a5dc0 100644 --- a/backend/vendor/github.com/slack-go/slack/workflow_step.go +++ b/backend/vendor/github.com/slack-go/slack/workflow_step.go @@ -44,12 +44,15 @@ func NewConfigurationModalRequest(blocks Blocks, privateMetaData string, externa } } +// SaveWorkflowStepConfiguration opens a configuration modal for a workflow step. +// For more information see the SaveWorkflowStepConfigurationContext documentation. func (api *Client) SaveWorkflowStepConfiguration(workflowStepEditID string, inputs *WorkflowStepInputs, outputs *[]WorkflowStepOutput) error { return api.SaveWorkflowStepConfigurationContext(context.Background(), workflowStepEditID, inputs, outputs) } +// SaveWorkflowStepConfigurationContext saves the configuration of a workflow step with a custom context. +// Slack API docs: https://api.slack.com/methods/workflows.updateStep func (api *Client) SaveWorkflowStepConfigurationContext(ctx context.Context, workflowStepEditID string, inputs *WorkflowStepInputs, outputs *[]WorkflowStepOutput) error { - // More information: https://api.slack.com/methods/workflows.updateStep wscr := WorkflowStepCompleteResponse{ WorkflowStepEditID: workflowStepEditID, Inputs: inputs, diff --git a/backend/vendor/go.etcd.io/bbolt/.go-version b/backend/vendor/go.etcd.io/bbolt/.go-version index f124bfa1..013173af 100644 --- a/backend/vendor/go.etcd.io/bbolt/.go-version +++ b/backend/vendor/go.etcd.io/bbolt/.go-version @@ -1 +1 @@ -1.21.9 +1.22.6 diff --git a/backend/vendor/go.etcd.io/bbolt/Makefile b/backend/vendor/go.etcd.io/bbolt/Makefile index 18154c63..21407797 100644 --- a/backend/vendor/go.etcd.io/bbolt/Makefile +++ b/backend/vendor/go.etcd.io/bbolt/Makefile @@ -41,6 +41,15 @@ coverage: TEST_FREELIST_TYPE=array go test -v -timeout 30m \ -coverprofile cover-freelist-array.out -covermode atomic +BOLT_CMD=bbolt + +build: + go build -o bin/${BOLT_CMD} ./cmd/${BOLT_CMD} + +.PHONY: clean +clean: # Clean binaries + rm -f ./bin/${BOLT_CMD} + .PHONY: gofail-enable gofail-enable: install-gofail gofail enable . @@ -61,3 +70,7 @@ test-failpoint: @echo "[failpoint] array freelist test" TEST_FREELIST_TYPE=array go test -v ${TESTFLAGS} -timeout 30m ./tests/failpoint +.PHONY: test-robustness # Running robustness tests requires root permission +test-robustness: + go test -v ${TESTFLAGS} ./tests/dmflakey -test.root + go test -v ${TESTFLAGS} ./tests/robustness -test.root diff --git a/backend/vendor/go.etcd.io/bbolt/db.go b/backend/vendor/go.etcd.io/bbolt/db.go index 4175bdf3..822798e4 100644 --- a/backend/vendor/go.etcd.io/bbolt/db.go +++ b/backend/vendor/go.etcd.io/bbolt/db.go @@ -524,7 +524,7 @@ func (db *DB) munmap() error { // gofail: var unmapError string // return errors.New(unmapError) if err := munmap(db); err != nil { - return fmt.Errorf("unmap error: " + err.Error()) + return fmt.Errorf("unmap error: %v", err.Error()) } return nil @@ -571,7 +571,7 @@ func (db *DB) munlock(fileSize int) error { // gofail: var munlockError string // return errors.New(munlockError) if err := munlock(db, fileSize); err != nil { - return fmt.Errorf("munlock error: " + err.Error()) + return fmt.Errorf("munlock error: %v", err.Error()) } return nil } @@ -580,7 +580,7 @@ func (db *DB) mlock(fileSize int) error { // gofail: var mlockError string // return errors.New(mlockError) if err := mlock(db, fileSize); err != nil { - return fmt.Errorf("mlock error: " + err.Error()) + return fmt.Errorf("mlock error: %v", err.Error()) } return nil } @@ -1159,6 +1159,8 @@ func (db *DB) grow(sz int) error { // https://github.com/boltdb/bolt/issues/284 if !db.NoGrowSync && !db.readOnly { if runtime.GOOS != "windows" { + // gofail: var resizeFileError string + // return errors.New(resizeFileError) if err := db.file.Truncate(int64(sz)); err != nil { return fmt.Errorf("file resize error: %s", err) } diff --git a/backend/vendor/go.etcd.io/bbolt/freelist.go b/backend/vendor/go.etcd.io/bbolt/freelist.go index 61d43f81..dffc7bc7 100644 --- a/backend/vendor/go.etcd.io/bbolt/freelist.go +++ b/backend/vendor/go.etcd.io/bbolt/freelist.go @@ -252,6 +252,14 @@ func (f *freelist) rollback(txid txid) { } // Remove pages from pending list and mark as free if allocated by txid. delete(f.pending, txid) + + // Remove pgids which are allocated by this txid + for pgid, tid := range f.allocs { + if tid == txid { + delete(f.allocs, pgid) + } + } + f.mergeSpans(m) } diff --git a/backend/vendor/go.etcd.io/bbolt/tx.go b/backend/vendor/go.etcd.io/bbolt/tx.go index 2fac8c0a..766395de 100644 --- a/backend/vendor/go.etcd.io/bbolt/tx.go +++ b/backend/vendor/go.etcd.io/bbolt/tx.go @@ -1,6 +1,7 @@ package bbolt import ( + "errors" "fmt" "io" "os" @@ -185,6 +186,10 @@ func (tx *Tx) Commit() error { // If the high water mark has moved up then attempt to grow the database. if tx.meta.pgid > opgid { + _ = errors.New("") + // gofail: var lackOfDiskSpace string + // tx.rollback() + // return errors.New(lackOfDiskSpace) if err := tx.db.grow(int(tx.meta.pgid+1) * tx.db.pageSize); err != nil { tx.rollback() return err @@ -470,6 +475,7 @@ func (tx *Tx) write() error { // Ignore file sync if flag is set on DB. if !tx.db.NoSync || IgnoreNoSync { + // gofail: var beforeSyncDataPages struct{} if err := fdatasync(tx.db); err != nil { return err } @@ -507,6 +513,7 @@ func (tx *Tx) writeMeta() error { return err } if !tx.db.NoSync || IgnoreNoSync { + // gofail: var beforeSyncMetaPage struct{} if err := fdatasync(tx.db); err != nil { return err } diff --git a/backend/vendor/golang.org/x/crypto/LICENSE b/backend/vendor/golang.org/x/crypto/LICENSE index 6a66aea5..2a7cf70d 100644 --- a/backend/vendor/golang.org/x/crypto/LICENSE +++ b/backend/vendor/golang.org/x/crypto/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2009 The Go Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -10,7 +10,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. diff --git a/backend/vendor/golang.org/x/image/LICENSE b/backend/vendor/golang.org/x/image/LICENSE index 6a66aea5..2a7cf70d 100644 --- a/backend/vendor/golang.org/x/image/LICENSE +++ b/backend/vendor/golang.org/x/image/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2009 The Go Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -10,7 +10,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. diff --git a/backend/vendor/golang.org/x/image/draw/impl.go b/backend/vendor/golang.org/x/image/draw/impl.go index 94ee8265..fcd19943 100644 --- a/backend/vendor/golang.org/x/image/draw/impl.go +++ b/backend/vendor/golang.org/x/image/draw/impl.go @@ -778,8 +778,8 @@ func (nnInterpolator) transform_RGBA_Gray_Src(dst *image.RGBA, dr, adr image.Rec d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -800,8 +800,8 @@ func (nnInterpolator) transform_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image.R d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -825,8 +825,8 @@ func (nnInterpolator) transform_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -849,8 +849,8 @@ func (nnInterpolator) transform_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -874,8 +874,8 @@ func (nnInterpolator) transform_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Rec d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -898,8 +898,8 @@ func (nnInterpolator) transform_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr image d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -942,8 +942,8 @@ func (nnInterpolator) transform_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr image d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -986,8 +986,8 @@ func (nnInterpolator) transform_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr image d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1030,8 +1030,8 @@ func (nnInterpolator) transform_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr image d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1074,8 +1074,8 @@ func (nnInterpolator) transform_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr i d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1095,8 +1095,8 @@ func (nnInterpolator) transform_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr im d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1115,8 +1115,8 @@ func (nnInterpolator) transform_RGBA_Image_Over(dst *image.RGBA, dr, adr image.R d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1136,8 +1136,8 @@ func (nnInterpolator) transform_RGBA_Image_Src(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1159,8 +1159,8 @@ func (nnInterpolator) transform_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, dr dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1199,8 +1199,8 @@ func (nnInterpolator) transform_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr, dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1241,8 +1241,8 @@ func (nnInterpolator) transform_Image_Image_Over(dst Image, dr, adr image.Rectan dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1281,8 +1281,8 @@ func (nnInterpolator) transform_Image_Image_Src(dst Image, dr, adr image.Rectang dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -1559,7 +1559,7 @@ func (ablInterpolator) scale_RGBA_Gray_Src(dst *image.RGBA, dr, adr image.Rectan swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -1577,7 +1577,7 @@ func (ablInterpolator) scale_RGBA_Gray_Src(dst *image.RGBA, dr, adr image.Rectan d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -1596,15 +1596,15 @@ func (ablInterpolator) scale_RGBA_Gray_Src(dst *image.RGBA, dr, adr image.Rectan s10i := (sr.Min.Y+int(sy0)-src.Rect.Min.Y)*src.Stride + (sr.Min.X + int(sx1) - src.Rect.Min.X) s10ru := uint32(src.Pix[s10i]) * 0x101 s10r := float64(s10ru) - s10r = xFrac1*s00r + xFrac0*s10r + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.Stride + (sr.Min.X + int(sx0) - src.Rect.Min.X) s01ru := uint32(src.Pix[s01i]) * 0x101 s01r := float64(s01ru) s11i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.Stride + (sr.Min.X + int(sx1) - src.Rect.Min.X) s11ru := uint32(src.Pix[s11i]) * 0x101 s11r := float64(s11ru) - s11r = xFrac1*s01r + xFrac0*s11r - s11r = yFrac1*s10r + yFrac0*s11r + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) pr := uint32(s11r) out := uint8(pr >> 8) dst.Pix[d+0] = out @@ -1623,7 +1623,7 @@ func (ablInterpolator) scale_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image.Rect swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -1641,7 +1641,7 @@ func (ablInterpolator) scale_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image.Rect d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -1672,10 +1672,10 @@ func (ablInterpolator) scale_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image.Rect s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.Stride + (sr.Min.X+int(sx0)-src.Rect.Min.X)*4 s01au := uint32(src.Pix[s01i+3]) * 0x101 s01ru := uint32(src.Pix[s01i+0]) * s01au / 0xff @@ -1694,14 +1694,14 @@ func (ablInterpolator) scale_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image.Rect s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -1723,7 +1723,7 @@ func (ablInterpolator) scale_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.Recta swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -1741,7 +1741,7 @@ func (ablInterpolator) scale_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.Recta d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -1772,10 +1772,10 @@ func (ablInterpolator) scale_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.Recta s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.Stride + (sr.Min.X+int(sx0)-src.Rect.Min.X)*4 s01au := uint32(src.Pix[s01i+3]) * 0x101 s01ru := uint32(src.Pix[s01i+0]) * s01au / 0xff @@ -1794,14 +1794,14 @@ func (ablInterpolator) scale_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.Recta s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -1822,7 +1822,7 @@ func (ablInterpolator) scale_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.Recta swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -1840,7 +1840,7 @@ func (ablInterpolator) scale_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.Recta d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -1871,10 +1871,10 @@ func (ablInterpolator) scale_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.Recta s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.Stride + (sr.Min.X+int(sx0)-src.Rect.Min.X)*4 s01ru := uint32(src.Pix[s01i+0]) * 0x101 s01gu := uint32(src.Pix[s01i+1]) * 0x101 @@ -1893,14 +1893,14 @@ func (ablInterpolator) scale_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.Recta s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -1922,7 +1922,7 @@ func (ablInterpolator) scale_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Rectan swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -1940,7 +1940,7 @@ func (ablInterpolator) scale_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Rectan d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -1971,10 +1971,10 @@ func (ablInterpolator) scale_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Rectan s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.Stride + (sr.Min.X+int(sx0)-src.Rect.Min.X)*4 s01ru := uint32(src.Pix[s01i+0]) * 0x101 s01gu := uint32(src.Pix[s01i+1]) * 0x101 @@ -1993,14 +1993,14 @@ func (ablInterpolator) scale_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Rectan s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -2021,7 +2021,7 @@ func (ablInterpolator) scale_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr image.Re swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -2039,7 +2039,7 @@ func (ablInterpolator) scale_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -2110,9 +2110,9 @@ func (ablInterpolator) scale_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr image.Re s10r := float64(s10ru) s10g := float64(s10gu) s10b := float64(s10bu) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.YStride + (sr.Min.X + int(sx0) - src.Rect.Min.X) s01j := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.CStride + (sr.Min.X + int(sx0) - src.Rect.Min.X) @@ -2171,12 +2171,12 @@ func (ablInterpolator) scale_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr image.Re s11r := float64(s11ru) s11g := float64(s11gu) s11b := float64(s11bu) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -2196,7 +2196,7 @@ func (ablInterpolator) scale_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr image.Re swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -2214,7 +2214,7 @@ func (ablInterpolator) scale_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -2285,9 +2285,9 @@ func (ablInterpolator) scale_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr image.Re s10r := float64(s10ru) s10g := float64(s10gu) s10b := float64(s10bu) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.YStride + (sr.Min.X + int(sx0) - src.Rect.Min.X) s01j := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.CStride + ((sr.Min.X+int(sx0))/2 - src.Rect.Min.X/2) @@ -2346,12 +2346,12 @@ func (ablInterpolator) scale_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr image.Re s11r := float64(s11ru) s11g := float64(s11gu) s11b := float64(s11bu) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -2371,7 +2371,7 @@ func (ablInterpolator) scale_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr image.Re swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -2389,7 +2389,7 @@ func (ablInterpolator) scale_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -2460,9 +2460,9 @@ func (ablInterpolator) scale_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr image.Re s10r := float64(s10ru) s10g := float64(s10gu) s10b := float64(s10bu) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.YStride + (sr.Min.X + int(sx0) - src.Rect.Min.X) s01j := ((sr.Min.Y+int(sy1))/2-src.Rect.Min.Y/2)*src.CStride + ((sr.Min.X+int(sx0))/2 - src.Rect.Min.X/2) @@ -2521,12 +2521,12 @@ func (ablInterpolator) scale_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr image.Re s11r := float64(s11ru) s11g := float64(s11gu) s11b := float64(s11bu) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -2546,7 +2546,7 @@ func (ablInterpolator) scale_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr image.Re swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -2564,7 +2564,7 @@ func (ablInterpolator) scale_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -2635,9 +2635,9 @@ func (ablInterpolator) scale_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr image.Re s10r := float64(s10ru) s10g := float64(s10gu) s10b := float64(s10bu) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) s01i := (sr.Min.Y+int(sy1)-src.Rect.Min.Y)*src.YStride + (sr.Min.X + int(sx0) - src.Rect.Min.X) s01j := ((sr.Min.Y+int(sy1))/2-src.Rect.Min.Y/2)*src.CStride + (sr.Min.X + int(sx0) - src.Rect.Min.X) @@ -2696,12 +2696,12 @@ func (ablInterpolator) scale_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr image.Re s11r := float64(s11ru) s11g := float64(s11gu) s11b := float64(s11bu) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -2721,7 +2721,7 @@ func (ablInterpolator) scale_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr imag swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -2739,7 +2739,7 @@ func (ablInterpolator) scale_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr imag d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -2762,10 +2762,10 @@ func (ablInterpolator) scale_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr imag s10g := float64(s10u.G) s10b := float64(s10u.B) s10a := float64(s10u.A) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01u := src.RGBA64At(sr.Min.X+int(sx0), sr.Min.Y+int(sy1)) s01r := float64(s01u.R) s01g := float64(s01u.G) @@ -2776,14 +2776,14 @@ func (ablInterpolator) scale_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr imag s11g := float64(s11u.G) s11b := float64(s11u.B) s11a := float64(s11u.A) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) p := color.RGBA64{uint16(s11r), uint16(s11g), uint16(s11b), uint16(s11a)} pa1 := (0xffff - uint32(p.A)) * 0x101 dst.Pix[d+0] = uint8((uint32(dst.Pix[d+0])*pa1/0xffff + uint32(p.R)) >> 8) @@ -2802,7 +2802,7 @@ func (ablInterpolator) scale_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr image swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -2820,7 +2820,7 @@ func (ablInterpolator) scale_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr image d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -2843,10 +2843,10 @@ func (ablInterpolator) scale_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr image s10g := float64(s10u.G) s10b := float64(s10u.B) s10a := float64(s10u.A) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01u := src.RGBA64At(sr.Min.X+int(sx0), sr.Min.Y+int(sy1)) s01r := float64(s01u.R) s01g := float64(s01u.G) @@ -2857,14 +2857,14 @@ func (ablInterpolator) scale_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr image s11g := float64(s11u.G) s11b := float64(s11u.B) s11a := float64(s11u.A) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) p := color.RGBA64{uint16(s11r), uint16(s11g), uint16(s11b), uint16(s11a)} dst.Pix[d+0] = uint8(p.R >> 8) dst.Pix[d+1] = uint8(p.G >> 8) @@ -2882,7 +2882,7 @@ func (ablInterpolator) scale_RGBA_Image_Over(dst *image.RGBA, dr, adr image.Rect swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -2900,7 +2900,7 @@ func (ablInterpolator) scale_RGBA_Image_Over(dst *image.RGBA, dr, adr image.Rect d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -2923,10 +2923,10 @@ func (ablInterpolator) scale_RGBA_Image_Over(dst *image.RGBA, dr, adr image.Rect s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01ru, s01gu, s01bu, s01au := src.At(sr.Min.X+int(sx0), sr.Min.Y+int(sy1)).RGBA() s01r := float64(s01ru) s01g := float64(s01gu) @@ -2937,14 +2937,14 @@ func (ablInterpolator) scale_RGBA_Image_Over(dst *image.RGBA, dr, adr image.Rect s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -2966,7 +2966,7 @@ func (ablInterpolator) scale_RGBA_Image_Src(dst *image.RGBA, dr, adr image.Recta swMinus1, shMinus1 := sw-1, sh-1 for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -2984,7 +2984,7 @@ func (ablInterpolator) scale_RGBA_Image_Src(dst *image.RGBA, dr, adr image.Recta d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -3007,10 +3007,10 @@ func (ablInterpolator) scale_RGBA_Image_Src(dst *image.RGBA, dr, adr image.Recta s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01ru, s01gu, s01bu, s01au := src.At(sr.Min.X+int(sx0), sr.Min.Y+int(sy1)).RGBA() s01r := float64(s01ru) s01g := float64(s01gu) @@ -3021,14 +3021,14 @@ func (ablInterpolator) scale_RGBA_Image_Src(dst *image.RGBA, dr, adr image.Recta s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -3052,7 +3052,7 @@ func (ablInterpolator) scale_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, dr, a dstColorRGBA64 := color.RGBA64{} for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -3069,7 +3069,7 @@ func (ablInterpolator) scale_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, dr, a } for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -3106,10 +3106,10 @@ func (ablInterpolator) scale_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, dr, a s10g := float64(s10u.G) s10b := float64(s10u.B) s10a := float64(s10u.A) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01u := src.RGBA64At(sr.Min.X+int(sx0), sr.Min.Y+int(sy1)) if srcMask != nil { _, _, _, ma := srcMask.At(smp.X+sr.Min.X+int(sx0), smp.Y+sr.Min.Y+int(sy1)).RGBA() @@ -3134,14 +3134,14 @@ func (ablInterpolator) scale_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, dr, a s11g := float64(s11u.G) s11b := float64(s11u.B) s11a := float64(s11u.A) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) p := color.RGBA64{uint16(s11r), uint16(s11g), uint16(s11b), uint16(s11a)} q := dst.RGBA64At(dr.Min.X+int(dx), dr.Min.Y+int(dy)) if dstMask != nil { @@ -3172,7 +3172,7 @@ func (ablInterpolator) scale_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr, ad dstColorRGBA64 := color.RGBA64{} for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -3189,7 +3189,7 @@ func (ablInterpolator) scale_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr, ad } for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -3226,10 +3226,10 @@ func (ablInterpolator) scale_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr, ad s10g := float64(s10u.G) s10b := float64(s10u.B) s10a := float64(s10u.A) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01u := src.RGBA64At(sr.Min.X+int(sx0), sr.Min.Y+int(sy1)) if srcMask != nil { _, _, _, ma := srcMask.At(smp.X+sr.Min.X+int(sx0), smp.Y+sr.Min.Y+int(sy1)).RGBA() @@ -3254,14 +3254,14 @@ func (ablInterpolator) scale_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr, ad s11g := float64(s11u.G) s11b := float64(s11u.B) s11a := float64(s11u.A) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) p := color.RGBA64{uint16(s11r), uint16(s11g), uint16(s11b), uint16(s11a)} if dstMask != nil { q := dst.RGBA64At(dr.Min.X+int(dx), dr.Min.Y+int(dy)) @@ -3295,7 +3295,7 @@ func (ablInterpolator) scale_Image_Image_Over(dst Image, dr, adr image.Rectangle dstColor := color.Color(dstColorRGBA64) for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -3312,7 +3312,7 @@ func (ablInterpolator) scale_Image_Image_Over(dst Image, dr, adr image.Rectangle } for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -3349,10 +3349,10 @@ func (ablInterpolator) scale_Image_Image_Over(dst Image, dr, adr image.Rectangle s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01ru, s01gu, s01bu, s01au := src.At(sr.Min.X+int(sx0), sr.Min.Y+int(sy1)).RGBA() if srcMask != nil { _, _, _, ma := srcMask.At(smp.X+sr.Min.X+int(sx0), smp.Y+sr.Min.Y+int(sy1)).RGBA() @@ -3377,14 +3377,14 @@ func (ablInterpolator) scale_Image_Image_Over(dst Image, dr, adr image.Rectangle s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -3419,7 +3419,7 @@ func (ablInterpolator) scale_Image_Image_Src(dst Image, dr, adr image.Rectangle, dstColor := color.Color(dstColorRGBA64) for dy := int32(adr.Min.Y); dy < int32(adr.Max.Y); dy++ { - sy := (float64(dy)+0.5)*yscale - 0.5 + sy := float64((float64(dy)+0.5)*yscale) - 0.5 // If sy < 0, we will clamp sy0 to 0 anyway, so it doesn't matter if // we say int32(sy) instead of int32(math.Floor(sy)). Similarly for // sx, below. @@ -3436,7 +3436,7 @@ func (ablInterpolator) scale_Image_Image_Src(dst Image, dr, adr image.Rectangle, } for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { - sx := (float64(dx)+0.5)*xscale - 0.5 + sx := float64((float64(dx)+0.5)*xscale) - 0.5 sx0 := int32(sx) xFrac0 := sx - float64(sx0) xFrac1 := 1 - xFrac0 @@ -3473,10 +3473,10 @@ func (ablInterpolator) scale_Image_Image_Src(dst Image, dr, adr image.Rectangle, s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01ru, s01gu, s01bu, s01au := src.At(sr.Min.X+int(sx0), sr.Min.Y+int(sy1)).RGBA() if srcMask != nil { _, _, _, ma := srcMask.At(smp.X+sr.Min.X+int(sx0), smp.Y+sr.Min.Y+int(sy1)).RGBA() @@ -3501,14 +3501,14 @@ func (ablInterpolator) scale_Image_Image_Src(dst Image, dr, adr image.Rectangle, s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -3543,8 +3543,8 @@ func (ablInterpolator) transform_RGBA_Gray_Src(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -3583,15 +3583,15 @@ func (ablInterpolator) transform_RGBA_Gray_Src(dst *image.RGBA, dr, adr image.Re s10i := (sy0-src.Rect.Min.Y)*src.Stride + (sx1 - src.Rect.Min.X) s10ru := uint32(src.Pix[s10i]) * 0x101 s10r := float64(s10ru) - s10r = xFrac1*s00r + xFrac0*s10r + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) s01i := (sy1-src.Rect.Min.Y)*src.Stride + (sx0 - src.Rect.Min.X) s01ru := uint32(src.Pix[s01i]) * 0x101 s01r := float64(s01ru) s11i := (sy1-src.Rect.Min.Y)*src.Stride + (sx1 - src.Rect.Min.X) s11ru := uint32(src.Pix[s11i]) * 0x101 s11r := float64(s11ru) - s11r = xFrac1*s01r + xFrac0*s11r - s11r = yFrac1*s10r + yFrac0*s11r + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) pr := uint32(s11r) out := uint8(pr >> 8) dst.Pix[d+0] = out @@ -3608,8 +3608,8 @@ func (ablInterpolator) transform_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image. d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -3660,10 +3660,10 @@ func (ablInterpolator) transform_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image. s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01i := (sy1-src.Rect.Min.Y)*src.Stride + (sx0-src.Rect.Min.X)*4 s01au := uint32(src.Pix[s01i+3]) * 0x101 s01ru := uint32(src.Pix[s01i+0]) * s01au / 0xff @@ -3682,14 +3682,14 @@ func (ablInterpolator) transform_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image. s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -3709,8 +3709,8 @@ func (ablInterpolator) transform_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.R d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -3761,10 +3761,10 @@ func (ablInterpolator) transform_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.R s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01i := (sy1-src.Rect.Min.Y)*src.Stride + (sx0-src.Rect.Min.X)*4 s01au := uint32(src.Pix[s01i+3]) * 0x101 s01ru := uint32(src.Pix[s01i+0]) * s01au / 0xff @@ -3783,14 +3783,14 @@ func (ablInterpolator) transform_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.R s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -3809,8 +3809,8 @@ func (ablInterpolator) transform_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.R d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -3861,10 +3861,10 @@ func (ablInterpolator) transform_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.R s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01i := (sy1-src.Rect.Min.Y)*src.Stride + (sx0-src.Rect.Min.X)*4 s01ru := uint32(src.Pix[s01i+0]) * 0x101 s01gu := uint32(src.Pix[s01i+1]) * 0x101 @@ -3883,14 +3883,14 @@ func (ablInterpolator) transform_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.R s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -3910,8 +3910,8 @@ func (ablInterpolator) transform_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Re d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -3962,10 +3962,10 @@ func (ablInterpolator) transform_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Re s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01i := (sy1-src.Rect.Min.Y)*src.Stride + (sx0-src.Rect.Min.X)*4 s01ru := uint32(src.Pix[s01i+0]) * 0x101 s01gu := uint32(src.Pix[s01i+1]) * 0x101 @@ -3984,14 +3984,14 @@ func (ablInterpolator) transform_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Re s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -4010,8 +4010,8 @@ func (ablInterpolator) transform_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr imag d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -4102,9 +4102,9 @@ func (ablInterpolator) transform_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr imag s10r := float64(s10ru) s10g := float64(s10gu) s10b := float64(s10bu) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) s01i := (sy1-src.Rect.Min.Y)*src.YStride + (sx0 - src.Rect.Min.X) s01j := (sy1-src.Rect.Min.Y)*src.CStride + (sx0 - src.Rect.Min.X) @@ -4163,12 +4163,12 @@ func (ablInterpolator) transform_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr imag s11r := float64(s11ru) s11g := float64(s11gu) s11b := float64(s11bu) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -4186,8 +4186,8 @@ func (ablInterpolator) transform_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr imag d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -4278,9 +4278,9 @@ func (ablInterpolator) transform_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr imag s10r := float64(s10ru) s10g := float64(s10gu) s10b := float64(s10bu) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) s01i := (sy1-src.Rect.Min.Y)*src.YStride + (sx0 - src.Rect.Min.X) s01j := (sy1-src.Rect.Min.Y)*src.CStride + ((sx0)/2 - src.Rect.Min.X/2) @@ -4339,12 +4339,12 @@ func (ablInterpolator) transform_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr imag s11r := float64(s11ru) s11g := float64(s11gu) s11b := float64(s11bu) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -4362,8 +4362,8 @@ func (ablInterpolator) transform_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr imag d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -4454,9 +4454,9 @@ func (ablInterpolator) transform_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr imag s10r := float64(s10ru) s10g := float64(s10gu) s10b := float64(s10bu) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) s01i := (sy1-src.Rect.Min.Y)*src.YStride + (sx0 - src.Rect.Min.X) s01j := ((sy1)/2-src.Rect.Min.Y/2)*src.CStride + ((sx0)/2 - src.Rect.Min.X/2) @@ -4515,12 +4515,12 @@ func (ablInterpolator) transform_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr imag s11r := float64(s11ru) s11g := float64(s11gu) s11b := float64(s11bu) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -4538,8 +4538,8 @@ func (ablInterpolator) transform_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr imag d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -4630,9 +4630,9 @@ func (ablInterpolator) transform_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr imag s10r := float64(s10ru) s10g := float64(s10gu) s10b := float64(s10bu) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) s01i := (sy1-src.Rect.Min.Y)*src.YStride + (sx0 - src.Rect.Min.X) s01j := ((sy1)/2-src.Rect.Min.Y/2)*src.CStride + (sx0 - src.Rect.Min.X) @@ -4691,12 +4691,12 @@ func (ablInterpolator) transform_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr imag s11r := float64(s11ru) s11g := float64(s11gu) s11b := float64(s11bu) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -4714,8 +4714,8 @@ func (ablInterpolator) transform_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -4758,10 +4758,10 @@ func (ablInterpolator) transform_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr s10g := float64(s10u.G) s10b := float64(s10u.B) s10a := float64(s10u.A) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01u := src.RGBA64At(sx0, sy1) s01r := float64(s01u.R) s01g := float64(s01u.G) @@ -4772,14 +4772,14 @@ func (ablInterpolator) transform_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr s11g := float64(s11u.G) s11b := float64(s11u.B) s11a := float64(s11u.A) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) p := color.RGBA64{uint16(s11r), uint16(s11g), uint16(s11b), uint16(s11a)} pa1 := (0xffff - uint32(p.A)) * 0x101 dst.Pix[d+0] = uint8((uint32(dst.Pix[d+0])*pa1/0xffff + uint32(p.R)) >> 8) @@ -4796,8 +4796,8 @@ func (ablInterpolator) transform_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr i d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -4840,10 +4840,10 @@ func (ablInterpolator) transform_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr i s10g := float64(s10u.G) s10b := float64(s10u.B) s10a := float64(s10u.A) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01u := src.RGBA64At(sx0, sy1) s01r := float64(s01u.R) s01g := float64(s01u.G) @@ -4854,14 +4854,14 @@ func (ablInterpolator) transform_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr i s11g := float64(s11u.G) s11b := float64(s11u.B) s11a := float64(s11u.A) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) p := color.RGBA64{uint16(s11r), uint16(s11g), uint16(s11b), uint16(s11a)} dst.Pix[d+0] = uint8(p.R >> 8) dst.Pix[d+1] = uint8(p.G >> 8) @@ -4877,8 +4877,8 @@ func (ablInterpolator) transform_RGBA_Image_Over(dst *image.RGBA, dr, adr image. d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -4921,10 +4921,10 @@ func (ablInterpolator) transform_RGBA_Image_Over(dst *image.RGBA, dr, adr image. s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01ru, s01gu, s01bu, s01au := src.At(sx0, sy1).RGBA() s01r := float64(s01ru) s01g := float64(s01gu) @@ -4935,14 +4935,14 @@ func (ablInterpolator) transform_RGBA_Image_Over(dst *image.RGBA, dr, adr image. s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -4962,8 +4962,8 @@ func (ablInterpolator) transform_RGBA_Image_Src(dst *image.RGBA, dr, adr image.R d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -5006,10 +5006,10 @@ func (ablInterpolator) transform_RGBA_Image_Src(dst *image.RGBA, dr, adr image.R s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01ru, s01gu, s01bu, s01au := src.At(sx0, sy1).RGBA() s01r := float64(s01ru) s01g := float64(s01gu) @@ -5020,14 +5020,14 @@ func (ablInterpolator) transform_RGBA_Image_Src(dst *image.RGBA, dr, adr image.R s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -5049,8 +5049,8 @@ func (ablInterpolator) transform_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, d dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -5107,10 +5107,10 @@ func (ablInterpolator) transform_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, d s10g := float64(s10u.G) s10b := float64(s10u.B) s10a := float64(s10u.A) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01u := src.RGBA64At(sx0, sy1) if srcMask != nil { _, _, _, ma := srcMask.At(smp.X+sx0, smp.Y+sy1).RGBA() @@ -5135,14 +5135,14 @@ func (ablInterpolator) transform_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, d s11g := float64(s11u.G) s11b := float64(s11u.B) s11a := float64(s11u.A) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) p := color.RGBA64{uint16(s11r), uint16(s11g), uint16(s11b), uint16(s11a)} q := dst.RGBA64At(dr.Min.X+int(dx), dr.Min.Y+int(dy)) if dstMask != nil { @@ -5171,8 +5171,8 @@ func (ablInterpolator) transform_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -5229,10 +5229,10 @@ func (ablInterpolator) transform_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr s10g := float64(s10u.G) s10b := float64(s10u.B) s10a := float64(s10u.A) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01u := src.RGBA64At(sx0, sy1) if srcMask != nil { _, _, _, ma := srcMask.At(smp.X+sx0, smp.Y+sy1).RGBA() @@ -5257,14 +5257,14 @@ func (ablInterpolator) transform_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr s11g := float64(s11u.G) s11b := float64(s11u.B) s11a := float64(s11u.A) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) p := color.RGBA64{uint16(s11r), uint16(s11g), uint16(s11b), uint16(s11a)} if dstMask != nil { q := dst.RGBA64At(dr.Min.X+int(dx), dr.Min.Y+int(dy)) @@ -5295,8 +5295,8 @@ func (ablInterpolator) transform_Image_Image_Over(dst Image, dr, adr image.Recta dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -5353,10 +5353,10 @@ func (ablInterpolator) transform_Image_Image_Over(dst Image, dr, adr image.Recta s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01ru, s01gu, s01bu, s01au := src.At(sx0, sy1).RGBA() if srcMask != nil { _, _, _, ma := srcMask.At(smp.X+sx0, smp.Y+sy1).RGBA() @@ -5381,14 +5381,14 @@ func (ablInterpolator) transform_Image_Image_Over(dst Image, dr, adr image.Recta s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -5420,8 +5420,8 @@ func (ablInterpolator) transform_Image_Image_Src(dst Image, dr, adr image.Rectan dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -5478,10 +5478,10 @@ func (ablInterpolator) transform_Image_Image_Src(dst Image, dr, adr image.Rectan s10g := float64(s10gu) s10b := float64(s10bu) s10a := float64(s10au) - s10r = xFrac1*s00r + xFrac0*s10r - s10g = xFrac1*s00g + xFrac0*s10g - s10b = xFrac1*s00b + xFrac0*s10b - s10a = xFrac1*s00a + xFrac0*s10a + s10r = float64(xFrac1*s00r) + float64(xFrac0*s10r) + s10g = float64(xFrac1*s00g) + float64(xFrac0*s10g) + s10b = float64(xFrac1*s00b) + float64(xFrac0*s10b) + s10a = float64(xFrac1*s00a) + float64(xFrac0*s10a) s01ru, s01gu, s01bu, s01au := src.At(sx0, sy1).RGBA() if srcMask != nil { _, _, _, ma := srcMask.At(smp.X+sx0, smp.Y+sy1).RGBA() @@ -5506,14 +5506,14 @@ func (ablInterpolator) transform_Image_Image_Src(dst Image, dr, adr image.Rectan s11g := float64(s11gu) s11b := float64(s11bu) s11a := float64(s11au) - s11r = xFrac1*s01r + xFrac0*s11r - s11g = xFrac1*s01g + xFrac0*s11g - s11b = xFrac1*s01b + xFrac0*s11b - s11a = xFrac1*s01a + xFrac0*s11a - s11r = yFrac1*s10r + yFrac0*s11r - s11g = yFrac1*s10g + yFrac0*s11g - s11b = yFrac1*s10b + yFrac0*s11b - s11a = yFrac1*s10a + yFrac0*s11a + s11r = float64(xFrac1*s01r) + float64(xFrac0*s11r) + s11g = float64(xFrac1*s01g) + float64(xFrac0*s11g) + s11b = float64(xFrac1*s01b) + float64(xFrac0*s11b) + s11a = float64(xFrac1*s01a) + float64(xFrac0*s11a) + s11r = float64(yFrac1*s10r) + float64(yFrac0*s11r) + s11g = float64(yFrac1*s10g) + float64(yFrac0*s11g) + s11b = float64(yFrac1*s10b) + float64(yFrac0*s11b) + s11a = float64(yFrac1*s10a) + float64(yFrac0*s11a) pr := uint32(s11r) pg := uint32(s11g) pb := uint32(s11b) @@ -5783,7 +5783,7 @@ func (z *kernelScaler) scaleX_Gray(tmp [][4]float64, src *image.Gray, sr image.R for _, c := range z.horizontal.contribs[s.i:s.j] { pi := (sr.Min.Y+int(y)-src.Rect.Min.Y)*src.Stride + (sr.Min.X + int(c.coord) - src.Rect.Min.X) pru := uint32(src.Pix[pi]) * 0x101 - pr += float64(pru) * c.weight + pr += float64(float64(pru) * c.weight) } pr *= s.invTotalWeightFFFF tmp[t] = [4]float64{ @@ -5808,10 +5808,10 @@ func (z *kernelScaler) scaleX_NRGBA(tmp [][4]float64, src *image.NRGBA, sr image pru := uint32(src.Pix[pi+0]) * pau / 0xff pgu := uint32(src.Pix[pi+1]) * pau / 0xff pbu := uint32(src.Pix[pi+2]) * pau / 0xff - pr += float64(pru) * c.weight - pg += float64(pgu) * c.weight - pb += float64(pbu) * c.weight - pa += float64(pau) * c.weight + pr += float64(float64(pru) * c.weight) + pg += float64(float64(pgu) * c.weight) + pb += float64(float64(pbu) * c.weight) + pa += float64(float64(pau) * c.weight) } tmp[t] = [4]float64{ pr * s.invTotalWeightFFFF, @@ -5835,10 +5835,10 @@ func (z *kernelScaler) scaleX_RGBA(tmp [][4]float64, src *image.RGBA, sr image.R pgu := uint32(src.Pix[pi+1]) * 0x101 pbu := uint32(src.Pix[pi+2]) * 0x101 pau := uint32(src.Pix[pi+3]) * 0x101 - pr += float64(pru) * c.weight - pg += float64(pgu) * c.weight - pb += float64(pbu) * c.weight - pa += float64(pau) * c.weight + pr += float64(float64(pru) * c.weight) + pg += float64(float64(pgu) * c.weight) + pb += float64(float64(pbu) * c.weight) + pa += float64(float64(pau) * c.weight) } tmp[t] = [4]float64{ pr * s.invTotalWeightFFFF, @@ -5883,9 +5883,9 @@ func (z *kernelScaler) scaleX_YCbCr444(tmp [][4]float64, src *image.YCbCr, sr im pbu = 0xffff } - pr += float64(pru) * c.weight - pg += float64(pgu) * c.weight - pb += float64(pbu) * c.weight + pr += float64(float64(pru) * c.weight) + pg += float64(float64(pgu) * c.weight) + pb += float64(float64(pbu) * c.weight) } tmp[t] = [4]float64{ pr * s.invTotalWeightFFFF, @@ -5930,9 +5930,9 @@ func (z *kernelScaler) scaleX_YCbCr422(tmp [][4]float64, src *image.YCbCr, sr im pbu = 0xffff } - pr += float64(pru) * c.weight - pg += float64(pgu) * c.weight - pb += float64(pbu) * c.weight + pr += float64(float64(pru) * c.weight) + pg += float64(float64(pgu) * c.weight) + pb += float64(float64(pbu) * c.weight) } tmp[t] = [4]float64{ pr * s.invTotalWeightFFFF, @@ -5977,9 +5977,9 @@ func (z *kernelScaler) scaleX_YCbCr420(tmp [][4]float64, src *image.YCbCr, sr im pbu = 0xffff } - pr += float64(pru) * c.weight - pg += float64(pgu) * c.weight - pb += float64(pbu) * c.weight + pr += float64(float64(pru) * c.weight) + pg += float64(float64(pgu) * c.weight) + pb += float64(float64(pbu) * c.weight) } tmp[t] = [4]float64{ pr * s.invTotalWeightFFFF, @@ -6024,9 +6024,9 @@ func (z *kernelScaler) scaleX_YCbCr440(tmp [][4]float64, src *image.YCbCr, sr im pbu = 0xffff } - pr += float64(pru) * c.weight - pg += float64(pgu) * c.weight - pb += float64(pbu) * c.weight + pr += float64(float64(pru) * c.weight) + pg += float64(float64(pgu) * c.weight) + pb += float64(float64(pbu) * c.weight) } tmp[t] = [4]float64{ pr * s.invTotalWeightFFFF, @@ -6054,10 +6054,10 @@ func (z *kernelScaler) scaleX_RGBA64Image(tmp [][4]float64, src image.RGBA64Imag pu.B = uint16(uint32(pu.B) * ma / 0xffff) pu.A = uint16(uint32(pu.A) * ma / 0xffff) } - pr += float64(pu.R) * c.weight - pg += float64(pu.G) * c.weight - pb += float64(pu.B) * c.weight - pa += float64(pu.A) * c.weight + pr += float64(float64(pu.R) * c.weight) + pg += float64(float64(pu.G) * c.weight) + pb += float64(float64(pu.B) * c.weight) + pa += float64(float64(pu.A) * c.weight) } tmp[t] = [4]float64{ pr * s.invTotalWeightFFFF, @@ -6085,10 +6085,10 @@ func (z *kernelScaler) scaleX_Image(tmp [][4]float64, src image.Image, sr image. pbu = pbu * ma / 0xffff pau = pau * ma / 0xffff } - pr += float64(pru) * c.weight - pg += float64(pgu) * c.weight - pb += float64(pbu) * c.weight - pa += float64(pau) * c.weight + pr += float64(float64(pru) * c.weight) + pg += float64(float64(pgu) * c.weight) + pb += float64(float64(pbu) * c.weight) + pa += float64(float64(pau) * c.weight) } tmp[t] = [4]float64{ pr * s.invTotalWeightFFFF, @@ -6108,10 +6108,10 @@ func (z *kernelScaler) scaleY_RGBA_Over(dst *image.RGBA, dr, adr image.Rectangle var pr, pg, pb, pa float64 for _, c := range z.vertical.contribs[s.i:s.j] { p := &tmp[c.coord*z.dw+dx] - pr += p[0] * c.weight - pg += p[1] * c.weight - pb += p[2] * c.weight - pa += p[3] * c.weight + pr += float64(p[0] * c.weight) + pg += float64(p[1] * c.weight) + pb += float64(p[2] * c.weight) + pa += float64(p[3] * c.weight) } if pr > pa { @@ -6145,10 +6145,10 @@ func (z *kernelScaler) scaleY_RGBA_Src(dst *image.RGBA, dr, adr image.Rectangle, var pr, pg, pb, pa float64 for _, c := range z.vertical.contribs[s.i:s.j] { p := &tmp[c.coord*z.dw+dx] - pr += p[0] * c.weight - pg += p[1] * c.weight - pb += p[2] * c.weight - pa += p[3] * c.weight + pr += float64(p[0] * c.weight) + pg += float64(p[1] * c.weight) + pb += float64(p[2] * c.weight) + pa += float64(p[3] * c.weight) } if pr > pa { @@ -6179,10 +6179,10 @@ func (z *kernelScaler) scaleY_RGBA64Image_Over(dst RGBA64Image, dr, adr image.Re var pr, pg, pb, pa float64 for _, c := range z.vertical.contribs[s.i:s.j] { p := &tmp[c.coord*z.dw+dx] - pr += p[0] * c.weight - pg += p[1] * c.weight - pb += p[2] * c.weight - pa += p[3] * c.weight + pr += float64(p[0] * c.weight) + pg += float64(p[1] * c.weight) + pb += float64(p[2] * c.weight) + pa += float64(p[3] * c.weight) } if pr > pa { @@ -6226,10 +6226,10 @@ func (z *kernelScaler) scaleY_RGBA64Image_Src(dst RGBA64Image, dr, adr image.Rec var pr, pg, pb, pa float64 for _, c := range z.vertical.contribs[s.i:s.j] { p := &tmp[c.coord*z.dw+dx] - pr += p[0] * c.weight - pg += p[1] * c.weight - pb += p[2] * c.weight - pa += p[3] * c.weight + pr += float64(p[0] * c.weight) + pg += float64(p[1] * c.weight) + pb += float64(p[2] * c.weight) + pa += float64(p[3] * c.weight) } if pr > pa { @@ -6275,10 +6275,10 @@ func (z *kernelScaler) scaleY_Image_Over(dst Image, dr, adr image.Rectangle, tmp var pr, pg, pb, pa float64 for _, c := range z.vertical.contribs[s.i:s.j] { p := &tmp[c.coord*z.dw+dx] - pr += p[0] * c.weight - pg += p[1] * c.weight - pb += p[2] * c.weight - pa += p[3] * c.weight + pr += float64(p[0] * c.weight) + pg += float64(p[1] * c.weight) + pb += float64(p[2] * c.weight) + pa += float64(p[3] * c.weight) } if pr > pa { @@ -6322,10 +6322,10 @@ func (z *kernelScaler) scaleY_Image_Src(dst Image, dr, adr image.Rectangle, tmp var pr, pg, pb, pa float64 for _, c := range z.vertical.contribs[s.i:s.j] { p := &tmp[c.coord*z.dw+dx] - pr += p[0] * c.weight - pg += p[1] * c.weight - pb += p[2] * c.weight - pa += p[3] * c.weight + pr += float64(p[0] * c.weight) + pg += float64(p[1] * c.weight) + pb += float64(p[2] * c.weight) + pa += float64(p[3] * c.weight) } if pr > pa { @@ -6384,8 +6384,8 @@ func (q *Kernel) transform_RGBA_Gray_Src(dst *image.RGBA, dr, adr image.Rectangl d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -6447,7 +6447,7 @@ func (q *Kernel) transform_RGBA_Gray_Src(dst *image.RGBA, dr, adr image.Rectangl if w := xWeights[kx-ix] * yWeight; w != 0 { pi := (ky-src.Rect.Min.Y)*src.Stride + (kx - src.Rect.Min.X) pru := uint32(src.Pix[pi]) * 0x101 - pr += float64(pru) * w + pr += float64(float64(pru) * w) } } } @@ -6483,8 +6483,8 @@ func (q *Kernel) transform_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image.Rectan d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -6549,10 +6549,10 @@ func (q *Kernel) transform_RGBA_NRGBA_Over(dst *image.RGBA, dr, adr image.Rectan pru := uint32(src.Pix[pi+0]) * pau / 0xff pgu := uint32(src.Pix[pi+1]) * pau / 0xff pbu := uint32(src.Pix[pi+2]) * pau / 0xff - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w - pa += float64(pau) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) + pa += float64(float64(pau) * w) } } } @@ -6603,8 +6603,8 @@ func (q *Kernel) transform_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.Rectang d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -6669,10 +6669,10 @@ func (q *Kernel) transform_RGBA_NRGBA_Src(dst *image.RGBA, dr, adr image.Rectang pru := uint32(src.Pix[pi+0]) * pau / 0xff pgu := uint32(src.Pix[pi+1]) * pau / 0xff pbu := uint32(src.Pix[pi+2]) * pau / 0xff - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w - pa += float64(pau) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) + pa += float64(float64(pau) * w) } } } @@ -6718,8 +6718,8 @@ func (q *Kernel) transform_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.Rectang d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -6784,10 +6784,10 @@ func (q *Kernel) transform_RGBA_RGBA_Over(dst *image.RGBA, dr, adr image.Rectang pgu := uint32(src.Pix[pi+1]) * 0x101 pbu := uint32(src.Pix[pi+2]) * 0x101 pau := uint32(src.Pix[pi+3]) * 0x101 - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w - pa += float64(pau) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) + pa += float64(float64(pau) * w) } } } @@ -6838,8 +6838,8 @@ func (q *Kernel) transform_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Rectangl d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -6904,10 +6904,10 @@ func (q *Kernel) transform_RGBA_RGBA_Src(dst *image.RGBA, dr, adr image.Rectangl pgu := uint32(src.Pix[pi+1]) * 0x101 pbu := uint32(src.Pix[pi+2]) * 0x101 pau := uint32(src.Pix[pi+3]) * 0x101 - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w - pa += float64(pau) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) + pa += float64(float64(pau) * w) } } } @@ -6953,8 +6953,8 @@ func (q *Kernel) transform_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr image.Rect d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7040,9 +7040,9 @@ func (q *Kernel) transform_RGBA_YCbCr444_Src(dst *image.RGBA, dr, adr image.Rect pbu = 0xffff } - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) } } } @@ -7077,8 +7077,8 @@ func (q *Kernel) transform_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr image.Rect d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7164,9 +7164,9 @@ func (q *Kernel) transform_RGBA_YCbCr422_Src(dst *image.RGBA, dr, adr image.Rect pbu = 0xffff } - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) } } } @@ -7201,8 +7201,8 @@ func (q *Kernel) transform_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr image.Rect d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7288,9 +7288,9 @@ func (q *Kernel) transform_RGBA_YCbCr420_Src(dst *image.RGBA, dr, adr image.Rect pbu = 0xffff } - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) } } } @@ -7325,8 +7325,8 @@ func (q *Kernel) transform_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr image.Rect d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7412,9 +7412,9 @@ func (q *Kernel) transform_RGBA_YCbCr440_Src(dst *image.RGBA, dr, adr image.Rect pbu = 0xffff } - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) } } } @@ -7449,8 +7449,8 @@ func (q *Kernel) transform_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr image. d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7511,10 +7511,10 @@ func (q *Kernel) transform_RGBA_RGBA64Image_Over(dst *image.RGBA, dr, adr image. for kx := ix; kx < jx; kx++ { if w := xWeights[kx-ix] * yWeight; w != 0 { pu := src.RGBA64At(kx, ky) - pr += float64(pu.R) * w - pg += float64(pu.G) * w - pb += float64(pu.B) * w - pa += float64(pu.A) * w + pr += float64(float64(pu.R) * w) + pg += float64(float64(pu.G) * w) + pb += float64(float64(pu.B) * w) + pa += float64(float64(pu.A) * w) } } } @@ -7565,8 +7565,8 @@ func (q *Kernel) transform_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr image.R d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7627,10 +7627,10 @@ func (q *Kernel) transform_RGBA_RGBA64Image_Src(dst *image.RGBA, dr, adr image.R for kx := ix; kx < jx; kx++ { if w := xWeights[kx-ix] * yWeight; w != 0 { pu := src.RGBA64At(kx, ky) - pr += float64(pu.R) * w - pg += float64(pu.G) * w - pb += float64(pu.B) * w - pa += float64(pu.A) * w + pr += float64(float64(pu.R) * w) + pg += float64(float64(pu.G) * w) + pb += float64(float64(pu.B) * w) + pa += float64(float64(pu.A) * w) } } } @@ -7676,8 +7676,8 @@ func (q *Kernel) transform_RGBA_Image_Over(dst *image.RGBA, dr, adr image.Rectan d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7738,10 +7738,10 @@ func (q *Kernel) transform_RGBA_Image_Over(dst *image.RGBA, dr, adr image.Rectan for kx := ix; kx < jx; kx++ { if w := xWeights[kx-ix] * yWeight; w != 0 { pru, pgu, pbu, pau := src.At(kx, ky).RGBA() - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w - pa += float64(pau) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) + pa += float64(float64(pau) * w) } } } @@ -7792,8 +7792,8 @@ func (q *Kernel) transform_RGBA_Image_Src(dst *image.RGBA, dr, adr image.Rectang d := (dr.Min.Y+int(dy)-dst.Rect.Min.Y)*dst.Stride + (dr.Min.X+adr.Min.X-dst.Rect.Min.X)*4 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7854,10 +7854,10 @@ func (q *Kernel) transform_RGBA_Image_Src(dst *image.RGBA, dr, adr image.Rectang for kx := ix; kx < jx; kx++ { if w := xWeights[kx-ix] * yWeight; w != 0 { pru, pgu, pbu, pau := src.At(kx, ky).RGBA() - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w - pa += float64(pau) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) + pa += float64(float64(pau) * w) } } } @@ -7906,8 +7906,8 @@ func (q *Kernel) transform_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, dr, adr dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -7975,10 +7975,10 @@ func (q *Kernel) transform_RGBA64Image_RGBA64Image_Over(dst RGBA64Image, dr, adr pu.B = uint16(uint32(pu.B) * ma / 0xffff) pu.A = uint16(uint32(pu.A) * ma / 0xffff) } - pr += float64(pu.R) * w - pg += float64(pu.G) * w - pb += float64(pu.B) * w - pa += float64(pu.A) * w + pr += float64(float64(pu.R) * w) + pg += float64(float64(pu.G) * w) + pb += float64(float64(pu.B) * w) + pa += float64(float64(pu.A) * w) } } } @@ -8041,8 +8041,8 @@ func (q *Kernel) transform_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr, adr dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -8110,10 +8110,10 @@ func (q *Kernel) transform_RGBA64Image_RGBA64Image_Src(dst RGBA64Image, dr, adr pu.B = uint16(uint32(pu.B) * ma / 0xffff) pu.A = uint16(uint32(pu.A) * ma / 0xffff) } - pr += float64(pu.R) * w - pg += float64(pu.G) * w - pb += float64(pu.B) * w - pa += float64(pu.A) * w + pr += float64(float64(pu.R) * w) + pg += float64(float64(pu.G) * w) + pb += float64(float64(pu.B) * w) + pa += float64(float64(pu.A) * w) } } } @@ -8178,8 +8178,8 @@ func (q *Kernel) transform_Image_Image_Over(dst Image, dr, adr image.Rectangle, dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -8247,10 +8247,10 @@ func (q *Kernel) transform_Image_Image_Over(dst Image, dr, adr image.Rectangle, pbu = pbu * ma / 0xffff pau = pau * ma / 0xffff } - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w - pa += float64(pau) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) + pa += float64(float64(pau) * w) } } } @@ -8313,8 +8313,8 @@ func (q *Kernel) transform_Image_Image_Src(dst Image, dr, adr image.Rectangle, d dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx := d2s[0]*dxf + d2s[1]*dyf + d2s[2] - sy := d2s[3]*dxf + d2s[4]*dyf + d2s[5] + sx := float64(d2s[0]*dxf) + float64(d2s[1]*dyf) + d2s[2] + sy := float64(d2s[3]*dxf) + float64(d2s[4]*dyf) + d2s[5] if !(image.Point{int(sx) + bias.X, int(sy) + bias.Y}).In(sr) { continue } @@ -8382,10 +8382,10 @@ func (q *Kernel) transform_Image_Image_Src(dst Image, dr, adr image.Rectangle, d pbu = pbu * ma / 0xffff pau = pau * ma / 0xffff } - pr += float64(pru) * w - pg += float64(pgu) * w - pb += float64(pbu) * w - pa += float64(pau) * w + pr += float64(float64(pru) * w) + pg += float64(float64(pgu) * w) + pb += float64(float64(pbu) * w) + pa += float64(float64(pau) * w) } } } diff --git a/backend/vendor/golang.org/x/image/draw/scale.go b/backend/vendor/golang.org/x/image/draw/scale.go index ba1bdf3c..aef200b2 100644 --- a/backend/vendor/golang.org/x/image/draw/scale.go +++ b/backend/vendor/golang.org/x/image/draw/scale.go @@ -182,9 +182,9 @@ var ( // Computer Graphics", Computer Graphics, Vol. 22, No. 4, pp. 221-228. CatmullRom = &Kernel{2, func(t float64) float64 { if t < 1 { - return (1.5*t-2.5)*t*t + 1 + return float64((float64(1.5*t)-2.5)*t*t) + 1 } - return ((-0.5*t+2.5)*t-4)*t + 2 + return float64((float64(float64(float64(-0.5*t)+2.5)*t)-4)*t) + 2 }} // TODO: a Kaiser-Bessel kernel? @@ -247,7 +247,7 @@ func newDistrib(q *Kernel, dw, sw int32) distrib { // source column or row. n, sources := int32(0), make([]source, dw) for x := range sources { - center := (float64(x)+0.5)*scale - 0.5 + center := float64((float64(x)+0.5)*scale) - 0.5 i := int32(math.Floor(center - halfWidth)) if i < 0 { i = 0 @@ -302,7 +302,7 @@ func abs(f float64) float64 { // ftou converts the range [0.0, 1.0] to [0, 0xffff]. func ftou(f float64) uint16 { - i := int32(0xffff*f + 0.5) + i := int32(float64(0xffff*f) + 0.5) if i > 0xffff { return 0xffff } @@ -332,12 +332,12 @@ func fffftou(f float64) uint16 { func invert(m *f64.Aff3) f64.Aff3 { m00 := +m[3*1+1] m01 := -m[3*0+1] - m02 := +m[3*1+2]*m[3*0+1] - m[3*1+1]*m[3*0+2] + m02 := +float64(m[3*1+2]*m[3*0+1]) - float64(m[3*1+1]*m[3*0+2]) m10 := -m[3*1+0] m11 := +m[3*0+0] - m12 := +m[3*1+0]*m[3*0+2] - m[3*1+2]*m[3*0+0] + m12 := +float64(m[3*1+0]*m[3*0+2]) - float64(m[3*1+2]*m[3*0+0]) - det := m00*m11 - m10*m01 + det := float64(m00*m11) - float64(m10*m01) return f64.Aff3{ m00 / det, @@ -351,12 +351,12 @@ func invert(m *f64.Aff3) f64.Aff3 { func matMul(p, q *f64.Aff3) f64.Aff3 { return f64.Aff3{ - p[3*0+0]*q[3*0+0] + p[3*0+1]*q[3*1+0], - p[3*0+0]*q[3*0+1] + p[3*0+1]*q[3*1+1], - p[3*0+0]*q[3*0+2] + p[3*0+1]*q[3*1+2] + p[3*0+2], - p[3*1+0]*q[3*0+0] + p[3*1+1]*q[3*1+0], - p[3*1+0]*q[3*0+1] + p[3*1+1]*q[3*1+1], - p[3*1+0]*q[3*0+2] + p[3*1+1]*q[3*1+2] + p[3*1+2], + float64(p[3*0+0]*q[3*0+0]) + float64(p[3*0+1]*q[3*1+0]), + float64(p[3*0+0]*q[3*0+1]) + float64(p[3*0+1]*q[3*1+1]), + float64(p[3*0+0]*q[3*0+2]) + float64(p[3*0+1]*q[3*1+2]) + p[3*0+2], + float64(p[3*1+0]*q[3*0+0]) + float64(p[3*1+1]*q[3*1+0]), + float64(p[3*1+0]*q[3*0+1]) + float64(p[3*1+1]*q[3*1+1]), + float64(p[3*1+0]*q[3*0+2]) + float64(p[3*1+1]*q[3*1+2]) + p[3*1+2], } } @@ -371,8 +371,8 @@ func transformRect(s2d *f64.Aff3, sr *image.Rectangle) (dr image.Rectangle) { for i, p := range ps { sxf := float64(p.X) syf := float64(p.Y) - dx := int(math.Floor(s2d[0]*sxf + s2d[1]*syf + s2d[2])) - dy := int(math.Floor(s2d[3]*sxf + s2d[4]*syf + s2d[5])) + dx := int(math.Floor(float64(s2d[0]*sxf) + float64(s2d[1]*syf) + s2d[2])) + dy := int(math.Floor(float64(s2d[3]*sxf) + float64(s2d[4]*syf) + s2d[5])) // The +1 adjustments below are because an image.Rectangle is inclusive // on the low end but exclusive on the high end. @@ -428,8 +428,8 @@ func transform_Uniform(dst Image, dr, adr image.Rectangle, d2s *f64.Aff3, src *i d := dst.PixOffset(dr.Min.X+adr.Min.X, dr.Min.Y+int(dy)) for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -450,8 +450,8 @@ func transform_Uniform(dst Image, dr, adr image.Rectangle, d2s *f64.Aff3, src *i dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -479,8 +479,8 @@ func transform_Uniform(dst Image, dr, adr image.Rectangle, d2s *f64.Aff3, src *i d := dst.PixOffset(dr.Min.X+adr.Min.X, dr.Min.Y+int(dy)) for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx, d = dx+1, d+4 { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } @@ -505,8 +505,8 @@ func transform_Uniform(dst Image, dr, adr image.Rectangle, d2s *f64.Aff3, src *i dyf := float64(dr.Min.Y+int(dy)) + 0.5 for dx := int32(adr.Min.X); dx < int32(adr.Max.X); dx++ { dxf := float64(dr.Min.X+int(dx)) + 0.5 - sx0 := int(d2s[0]*dxf+d2s[1]*dyf+d2s[2]) + bias.X - sy0 := int(d2s[3]*dxf+d2s[4]*dyf+d2s[5]) + bias.Y + sx0 := int(float64(d2s[0]*dxf)+float64(d2s[1]*dyf)+d2s[2]) + bias.X + sy0 := int(float64(d2s[3]*dxf)+float64(d2s[4]*dyf)+d2s[5]) + bias.Y if !(image.Point{sx0, sy0}).In(sr) { continue } diff --git a/backend/vendor/golang.org/x/net/LICENSE b/backend/vendor/golang.org/x/net/LICENSE index 6a66aea5..2a7cf70d 100644 --- a/backend/vendor/golang.org/x/net/LICENSE +++ b/backend/vendor/golang.org/x/net/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2009 The Go Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -10,7 +10,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. diff --git a/backend/vendor/golang.org/x/sync/LICENSE b/backend/vendor/golang.org/x/sync/LICENSE index 6a66aea5..2a7cf70d 100644 --- a/backend/vendor/golang.org/x/sync/LICENSE +++ b/backend/vendor/golang.org/x/sync/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2009 The Go Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -10,7 +10,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. diff --git a/backend/vendor/golang.org/x/sys/LICENSE b/backend/vendor/golang.org/x/sys/LICENSE index 6a66aea5..2a7cf70d 100644 --- a/backend/vendor/golang.org/x/sys/LICENSE +++ b/backend/vendor/golang.org/x/sys/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2009 The Go Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -10,7 +10,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. diff --git a/backend/vendor/golang.org/x/sys/unix/mkerrors.sh b/backend/vendor/golang.org/x/sys/unix/mkerrors.sh index 4ed2e488..e14b766a 100644 --- a/backend/vendor/golang.org/x/sys/unix/mkerrors.sh +++ b/backend/vendor/golang.org/x/sys/unix/mkerrors.sh @@ -58,6 +58,7 @@ includes_Darwin=' #define _DARWIN_USE_64_BIT_INODE #define __APPLE_USE_RFC_3542 #include +#include #include #include #include @@ -551,6 +552,7 @@ ccflags="$@" $2 !~ /^RTC_VL_(ACCURACY|BACKUP|DATA)/ && $2 ~ /^(NETLINK|NLM|NLMSG|NLA|IFA|IFAN|RT|RTC|RTCF|RTN|RTPROT|RTNH|ARPHRD|ETH_P|NETNSA)_/ || $2 ~ /^SOCK_|SK_DIAG_|SKNLGRP_$/ || + $2 ~ /^(CONNECT|SAE)_/ || $2 ~ /^FIORDCHK$/ || $2 ~ /^SIOC/ || $2 ~ /^TIOC/ || diff --git a/backend/vendor/golang.org/x/sys/unix/syscall_darwin.go b/backend/vendor/golang.org/x/sys/unix/syscall_darwin.go index 4cc7b005..099867de 100644 --- a/backend/vendor/golang.org/x/sys/unix/syscall_darwin.go +++ b/backend/vendor/golang.org/x/sys/unix/syscall_darwin.go @@ -402,6 +402,18 @@ func IoctlSetIfreqMTU(fd int, ifreq *IfreqMTU) error { return ioctlPtr(fd, SIOCSIFMTU, unsafe.Pointer(ifreq)) } +//sys renamexNp(from string, to string, flag uint32) (err error) + +func RenamexNp(from string, to string, flag uint32) (err error) { + return renamexNp(from, to, flag) +} + +//sys renameatxNp(fromfd int, from string, tofd int, to string, flag uint32) (err error) + +func RenameatxNp(fromfd int, from string, tofd int, to string, flag uint32) (err error) { + return renameatxNp(fromfd, from, tofd, to, flag) +} + //sys sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) = SYS_SYSCTL func Uname(uname *Utsname) error { @@ -554,6 +566,43 @@ func PthreadFchdir(fd int) (err error) { return pthread_fchdir_np(fd) } +// Connectx calls connectx(2) to initiate a connection on a socket. +// +// srcIf, srcAddr, and dstAddr are filled into a [SaEndpoints] struct and passed as the endpoints argument. +// +// - srcIf is the optional source interface index. 0 means unspecified. +// - srcAddr is the optional source address. nil means unspecified. +// - dstAddr is the destination address. +// +// On success, Connectx returns the number of bytes enqueued for transmission. +func Connectx(fd int, srcIf uint32, srcAddr, dstAddr Sockaddr, associd SaeAssocID, flags uint32, iov []Iovec, connid *SaeConnID) (n uintptr, err error) { + endpoints := SaEndpoints{ + Srcif: srcIf, + } + + if srcAddr != nil { + addrp, addrlen, err := srcAddr.sockaddr() + if err != nil { + return 0, err + } + endpoints.Srcaddr = (*RawSockaddr)(addrp) + endpoints.Srcaddrlen = uint32(addrlen) + } + + if dstAddr != nil { + addrp, addrlen, err := dstAddr.sockaddr() + if err != nil { + return 0, err + } + endpoints.Dstaddr = (*RawSockaddr)(addrp) + endpoints.Dstaddrlen = uint32(addrlen) + } + + err = connectx(fd, &endpoints, associd, flags, iov, &n, connid) + return +} + +//sys connectx(fd int, endpoints *SaEndpoints, associd SaeAssocID, flags uint32, iov []Iovec, n *uintptr, connid *SaeConnID) (err error) //sys sendfile(infd int, outfd int, offset int64, len *int64, hdtr unsafe.Pointer, flags int) (err error) //sys shmat(id int, addr uintptr, flag int) (ret uintptr, err error) diff --git a/backend/vendor/golang.org/x/sys/unix/syscall_hurd.go b/backend/vendor/golang.org/x/sys/unix/syscall_hurd.go index ba46651f..a6a2d2fc 100644 --- a/backend/vendor/golang.org/x/sys/unix/syscall_hurd.go +++ b/backend/vendor/golang.org/x/sys/unix/syscall_hurd.go @@ -11,6 +11,7 @@ package unix int ioctl(int, unsigned long int, uintptr_t); */ import "C" +import "unsafe" func ioctl(fd int, req uint, arg uintptr) (err error) { r0, er := C.ioctl(C.int(fd), C.ulong(req), C.uintptr_t(arg)) diff --git a/backend/vendor/golang.org/x/sys/unix/syscall_linux.go b/backend/vendor/golang.org/x/sys/unix/syscall_linux.go index 5682e262..3f1d3d4c 100644 --- a/backend/vendor/golang.org/x/sys/unix/syscall_linux.go +++ b/backend/vendor/golang.org/x/sys/unix/syscall_linux.go @@ -2592,3 +2592,4 @@ func SchedGetAttr(pid int, flags uint) (*SchedAttr, error) { } //sys Cachestat(fd uint, crange *CachestatRange, cstat *Cachestat_t, flags uint) (err error) +//sys Mseal(b []byte, flags uint) (err error) diff --git a/backend/vendor/golang.org/x/sys/unix/syscall_openbsd.go b/backend/vendor/golang.org/x/sys/unix/syscall_openbsd.go index b25343c7..b86ded54 100644 --- a/backend/vendor/golang.org/x/sys/unix/syscall_openbsd.go +++ b/backend/vendor/golang.org/x/sys/unix/syscall_openbsd.go @@ -293,6 +293,7 @@ func Uname(uname *Utsname) error { //sys Mkfifoat(dirfd int, path string, mode uint32) (err error) //sys Mknod(path string, mode uint32, dev int) (err error) //sys Mknodat(dirfd int, path string, mode uint32, dev int) (err error) +//sys Mount(fsType string, dir string, flags int, data unsafe.Pointer) (err error) //sys Nanosleep(time *Timespec, leftover *Timespec) (err error) //sys Open(path string, mode int, perm uint32) (fd int, err error) //sys Openat(dirfd int, path string, mode int, perm uint32) (fd int, err error) diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_darwin_amd64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_darwin_amd64.go index e40fa852..d73c4652 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_darwin_amd64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_darwin_amd64.go @@ -237,6 +237,9 @@ const ( CLOCK_UPTIME_RAW_APPROX = 0x9 CLONE_NOFOLLOW = 0x1 CLONE_NOOWNERCOPY = 0x2 + CONNECT_DATA_AUTHENTICATED = 0x4 + CONNECT_DATA_IDEMPOTENT = 0x2 + CONNECT_RESUME_ON_READ_WRITE = 0x1 CR0 = 0x0 CR1 = 0x1000 CR2 = 0x2000 @@ -1169,6 +1172,11 @@ const ( PT_WRITE_D = 0x5 PT_WRITE_I = 0x4 PT_WRITE_U = 0x6 + RENAME_EXCL = 0x4 + RENAME_NOFOLLOW_ANY = 0x10 + RENAME_RESERVED1 = 0x8 + RENAME_SECLUDE = 0x1 + RENAME_SWAP = 0x2 RLIMIT_AS = 0x5 RLIMIT_CORE = 0x4 RLIMIT_CPU = 0x0 @@ -1260,6 +1268,10 @@ const ( RTV_SSTHRESH = 0x20 RUSAGE_CHILDREN = -0x1 RUSAGE_SELF = 0x0 + SAE_ASSOCID_ALL = 0xffffffff + SAE_ASSOCID_ANY = 0x0 + SAE_CONNID_ALL = 0xffffffff + SAE_CONNID_ANY = 0x0 SCM_CREDS = 0x3 SCM_RIGHTS = 0x1 SCM_TIMESTAMP = 0x2 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_darwin_arm64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_darwin_arm64.go index bb02aa6c..4a55a400 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_darwin_arm64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_darwin_arm64.go @@ -237,6 +237,9 @@ const ( CLOCK_UPTIME_RAW_APPROX = 0x9 CLONE_NOFOLLOW = 0x1 CLONE_NOOWNERCOPY = 0x2 + CONNECT_DATA_AUTHENTICATED = 0x4 + CONNECT_DATA_IDEMPOTENT = 0x2 + CONNECT_RESUME_ON_READ_WRITE = 0x1 CR0 = 0x0 CR1 = 0x1000 CR2 = 0x2000 @@ -1169,6 +1172,11 @@ const ( PT_WRITE_D = 0x5 PT_WRITE_I = 0x4 PT_WRITE_U = 0x6 + RENAME_EXCL = 0x4 + RENAME_NOFOLLOW_ANY = 0x10 + RENAME_RESERVED1 = 0x8 + RENAME_SECLUDE = 0x1 + RENAME_SWAP = 0x2 RLIMIT_AS = 0x5 RLIMIT_CORE = 0x4 RLIMIT_CPU = 0x0 @@ -1260,6 +1268,10 @@ const ( RTV_SSTHRESH = 0x20 RUSAGE_CHILDREN = -0x1 RUSAGE_SELF = 0x0 + SAE_ASSOCID_ALL = 0xffffffff + SAE_ASSOCID_ANY = 0x0 + SAE_CONNID_ALL = 0xffffffff + SAE_CONNID_ANY = 0x0 SCM_CREDS = 0x3 SCM_RIGHTS = 0x1 SCM_TIMESTAMP = 0x2 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux.go index 877a62b4..01a70b24 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux.go @@ -457,6 +457,7 @@ const ( B600 = 0x8 B75 = 0x2 B9600 = 0xd + BCACHEFS_SUPER_MAGIC = 0xca451a4e BDEVFS_MAGIC = 0x62646576 BINDERFS_SUPER_MAGIC = 0x6c6f6f70 BINFMTFS_MAGIC = 0x42494e4d @@ -928,6 +929,7 @@ const ( EPOLL_CTL_ADD = 0x1 EPOLL_CTL_DEL = 0x2 EPOLL_CTL_MOD = 0x3 + EPOLL_IOC_TYPE = 0x8a EROFS_SUPER_MAGIC_V1 = 0xe0f5e1e2 ESP_V4_FLOW = 0xa ESP_V6_FLOW = 0xc @@ -941,9 +943,6 @@ const ( ETHTOOL_FEC_OFF = 0x4 ETHTOOL_FEC_RS = 0x8 ETHTOOL_FLAG_ALL = 0x7 - ETHTOOL_FLAG_COMPACT_BITSETS = 0x1 - ETHTOOL_FLAG_OMIT_REPLY = 0x2 - ETHTOOL_FLAG_STATS = 0x4 ETHTOOL_FLASHDEV = 0x33 ETHTOOL_FLASH_MAX_FILENAME = 0x80 ETHTOOL_FWVERS_LEN = 0x20 @@ -1705,6 +1704,7 @@ const ( KEXEC_ARCH_S390 = 0x160000 KEXEC_ARCH_SH = 0x2a0000 KEXEC_ARCH_X86_64 = 0x3e0000 + KEXEC_CRASH_HOTPLUG_SUPPORT = 0x8 KEXEC_FILE_DEBUG = 0x8 KEXEC_FILE_NO_INITRAMFS = 0x4 KEXEC_FILE_ON_CRASH = 0x2 @@ -1780,6 +1780,7 @@ const ( KEY_SPEC_USER_KEYRING = -0x4 KEY_SPEC_USER_SESSION_KEYRING = -0x5 LANDLOCK_ACCESS_FS_EXECUTE = 0x1 + LANDLOCK_ACCESS_FS_IOCTL_DEV = 0x8000 LANDLOCK_ACCESS_FS_MAKE_BLOCK = 0x800 LANDLOCK_ACCESS_FS_MAKE_CHAR = 0x40 LANDLOCK_ACCESS_FS_MAKE_DIR = 0x80 @@ -1861,6 +1862,19 @@ const ( MAP_FILE = 0x0 MAP_FIXED = 0x10 MAP_FIXED_NOREPLACE = 0x100000 + MAP_HUGE_16GB = 0x88000000 + MAP_HUGE_16KB = 0x38000000 + MAP_HUGE_16MB = 0x60000000 + MAP_HUGE_1GB = 0x78000000 + MAP_HUGE_1MB = 0x50000000 + MAP_HUGE_256MB = 0x70000000 + MAP_HUGE_2GB = 0x7c000000 + MAP_HUGE_2MB = 0x54000000 + MAP_HUGE_32MB = 0x64000000 + MAP_HUGE_512KB = 0x4c000000 + MAP_HUGE_512MB = 0x74000000 + MAP_HUGE_64KB = 0x40000000 + MAP_HUGE_8MB = 0x5c000000 MAP_HUGE_MASK = 0x3f MAP_HUGE_SHIFT = 0x1a MAP_PRIVATE = 0x2 @@ -2498,6 +2512,23 @@ const ( PR_PAC_GET_ENABLED_KEYS = 0x3d PR_PAC_RESET_KEYS = 0x36 PR_PAC_SET_ENABLED_KEYS = 0x3c + PR_PPC_DEXCR_CTRL_CLEAR = 0x4 + PR_PPC_DEXCR_CTRL_CLEAR_ONEXEC = 0x10 + PR_PPC_DEXCR_CTRL_EDITABLE = 0x1 + PR_PPC_DEXCR_CTRL_MASK = 0x1f + PR_PPC_DEXCR_CTRL_SET = 0x2 + PR_PPC_DEXCR_CTRL_SET_ONEXEC = 0x8 + PR_PPC_DEXCR_IBRTPD = 0x1 + PR_PPC_DEXCR_NPHIE = 0x3 + PR_PPC_DEXCR_SBHE = 0x0 + PR_PPC_DEXCR_SRAPD = 0x2 + PR_PPC_GET_DEXCR = 0x48 + PR_PPC_SET_DEXCR = 0x49 + PR_RISCV_CTX_SW_FENCEI_OFF = 0x1 + PR_RISCV_CTX_SW_FENCEI_ON = 0x0 + PR_RISCV_SCOPE_PER_PROCESS = 0x0 + PR_RISCV_SCOPE_PER_THREAD = 0x1 + PR_RISCV_SET_ICACHE_FLUSH_CTX = 0x47 PR_RISCV_V_GET_CONTROL = 0x46 PR_RISCV_V_SET_CONTROL = 0x45 PR_RISCV_V_VSTATE_CTRL_CUR_MASK = 0x3 @@ -3192,6 +3223,7 @@ const ( STATX_MTIME = 0x40 STATX_NLINK = 0x4 STATX_SIZE = 0x200 + STATX_SUBVOL = 0x8000 STATX_TYPE = 0x1 STATX_UID = 0x8 STATX__RESERVED = 0x80000000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_386.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_386.go index e4bc0bd5..684a5168 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_386.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_386.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x80088a02 + EPIOCSPARAMS = 0x40088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go index 689317af..61d74b59 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_amd64.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x80088a02 + EPIOCSPARAMS = 0x40088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go index 5cca668a..a28c9e3e 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_arm.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x80088a02 + EPIOCSPARAMS = 0x40088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go index 14270508..ab5d1fe8 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_arm64.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x80088a02 + EPIOCSPARAMS = 0x40088a01 EPOLL_CLOEXEC = 0x80000 ESR_MAGIC = 0x45535201 EXTPROC = 0x10000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_loong64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_loong64.go index 28e39afd..c523090e 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_loong64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_loong64.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x80088a02 + EPIOCSPARAMS = 0x40088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go index cd66e92c..01e6ea78 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x80 + EPIOCGPARAMS = 0x40088a02 + EPIOCSPARAMS = 0x80088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go index c1595eba..7aa610b1 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips64.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x80 + EPIOCGPARAMS = 0x40088a02 + EPIOCSPARAMS = 0x80088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go index ee9456b0..92af771b 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mips64le.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x80 + EPIOCGPARAMS = 0x40088a02 + EPIOCSPARAMS = 0x80088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go index 8cfca81e..b27ef5e6 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_mipsle.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x80 + EPIOCGPARAMS = 0x40088a02 + EPIOCSPARAMS = 0x80088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc.go index 60b0deb3..237a2cef 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x20 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x40088a02 + EPIOCSPARAMS = 0x80088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000000 FF1 = 0x4000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go index f90aa728..4a5c555a 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x20 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x40088a02 + EPIOCSPARAMS = 0x80088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000000 FF1 = 0x4000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go index ba9e0150..a02fb49a 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_ppc64le.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x20 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x40088a02 + EPIOCSPARAMS = 0x80088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000000 FF1 = 0x4000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go index 07cdfd6e..e26a7c61 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_riscv64.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x80088a02 + EPIOCSPARAMS = 0x40088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go index 2f1dd214..c48f7c21 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_s390x.go @@ -78,6 +78,8 @@ const ( ECHOPRT = 0x400 EFD_CLOEXEC = 0x80000 EFD_NONBLOCK = 0x800 + EPIOCGPARAMS = 0x80088a02 + EPIOCSPARAMS = 0x40088a01 EPOLL_CLOEXEC = 0x80000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go index f40519d9..ad4b9aac 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_linux_sparc64.go @@ -82,6 +82,8 @@ const ( EFD_CLOEXEC = 0x400000 EFD_NONBLOCK = 0x4000 EMT_TAGOVF = 0x1 + EPIOCGPARAMS = 0x40088a02 + EPIOCSPARAMS = 0x80088a01 EPOLL_CLOEXEC = 0x400000 EXTPROC = 0x10000 FF1 = 0x8000 diff --git a/backend/vendor/golang.org/x/sys/unix/zerrors_zos_s390x.go b/backend/vendor/golang.org/x/sys/unix/zerrors_zos_s390x.go index da08b2ab..1ec2b140 100644 --- a/backend/vendor/golang.org/x/sys/unix/zerrors_zos_s390x.go +++ b/backend/vendor/golang.org/x/sys/unix/zerrors_zos_s390x.go @@ -581,6 +581,8 @@ const ( AT_EMPTY_PATH = 0x1000 AT_REMOVEDIR = 0x200 RENAME_NOREPLACE = 1 << 0 + ST_RDONLY = 1 + ST_NOSUID = 2 ) const ( diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go index 07642c30..24b346e1 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go @@ -740,6 +740,54 @@ func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) { // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func renamexNp(from string, to string, flag uint32) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(from) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(to) + if err != nil { + return + } + _, _, e1 := syscall_syscall(libc_renamex_np_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flag)) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_renamex_np_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_renamex_np renamex_np "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func renameatxNp(fromfd int, from string, tofd int, to string, flag uint32) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(from) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(to) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_renameatx_np_trampoline_addr, uintptr(fromfd), uintptr(unsafe.Pointer(_p0)), uintptr(tofd), uintptr(unsafe.Pointer(_p1)), uintptr(flag), 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_renameatx_np_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_renameatx_np renameatx_np "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) { var _p0 unsafe.Pointer if len(mib) > 0 { @@ -793,6 +841,26 @@ var libc_pthread_fchdir_np_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func connectx(fd int, endpoints *SaEndpoints, associd SaeAssocID, flags uint32, iov []Iovec, n *uintptr, connid *SaeConnID) (err error) { + var _p0 unsafe.Pointer + if len(iov) > 0 { + _p0 = unsafe.Pointer(&iov[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + _, _, e1 := syscall_syscall9(libc_connectx_trampoline_addr, uintptr(fd), uintptr(unsafe.Pointer(endpoints)), uintptr(associd), uintptr(flags), uintptr(_p0), uintptr(len(iov)), uintptr(unsafe.Pointer(n)), uintptr(unsafe.Pointer(connid)), 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_connectx_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_connectx connectx "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func sendfile(infd int, outfd int, offset int64, len *int64, hdtr unsafe.Pointer, flags int) (err error) { _, _, e1 := syscall_syscall6(libc_sendfile_trampoline_addr, uintptr(infd), uintptr(outfd), uintptr(offset), uintptr(unsafe.Pointer(len)), uintptr(hdtr), uintptr(flags)) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s index 923e08cb..ebd21310 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s @@ -223,6 +223,16 @@ TEXT libc_ioctl_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_ioctl_trampoline_addr(SB), RODATA, $8 DATA ·libc_ioctl_trampoline_addr(SB)/8, $libc_ioctl_trampoline<>(SB) +TEXT libc_renamex_np_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_renamex_np(SB) +GLOBL ·libc_renamex_np_trampoline_addr(SB), RODATA, $8 +DATA ·libc_renamex_np_trampoline_addr(SB)/8, $libc_renamex_np_trampoline<>(SB) + +TEXT libc_renameatx_np_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_renameatx_np(SB) +GLOBL ·libc_renameatx_np_trampoline_addr(SB), RODATA, $8 +DATA ·libc_renameatx_np_trampoline_addr(SB)/8, $libc_renameatx_np_trampoline<>(SB) + TEXT libc_sysctl_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_sysctl(SB) GLOBL ·libc_sysctl_trampoline_addr(SB), RODATA, $8 @@ -238,6 +248,11 @@ TEXT libc_pthread_fchdir_np_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_pthread_fchdir_np_trampoline_addr(SB), RODATA, $8 DATA ·libc_pthread_fchdir_np_trampoline_addr(SB)/8, $libc_pthread_fchdir_np_trampoline<>(SB) +TEXT libc_connectx_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_connectx(SB) +GLOBL ·libc_connectx_trampoline_addr(SB), RODATA, $8 +DATA ·libc_connectx_trampoline_addr(SB)/8, $libc_connectx_trampoline<>(SB) + TEXT libc_sendfile_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_sendfile(SB) GLOBL ·libc_sendfile_trampoline_addr(SB), RODATA, $8 diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go index 7d73dda6..824b9c2d 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go @@ -740,6 +740,54 @@ func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) { // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func renamexNp(from string, to string, flag uint32) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(from) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(to) + if err != nil { + return + } + _, _, e1 := syscall_syscall(libc_renamex_np_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flag)) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_renamex_np_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_renamex_np renamex_np "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func renameatxNp(fromfd int, from string, tofd int, to string, flag uint32) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(from) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(to) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_renameatx_np_trampoline_addr, uintptr(fromfd), uintptr(unsafe.Pointer(_p0)), uintptr(tofd), uintptr(unsafe.Pointer(_p1)), uintptr(flag), 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_renameatx_np_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_renameatx_np renameatx_np "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error) { var _p0 unsafe.Pointer if len(mib) > 0 { @@ -793,6 +841,26 @@ var libc_pthread_fchdir_np_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func connectx(fd int, endpoints *SaEndpoints, associd SaeAssocID, flags uint32, iov []Iovec, n *uintptr, connid *SaeConnID) (err error) { + var _p0 unsafe.Pointer + if len(iov) > 0 { + _p0 = unsafe.Pointer(&iov[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + _, _, e1 := syscall_syscall9(libc_connectx_trampoline_addr, uintptr(fd), uintptr(unsafe.Pointer(endpoints)), uintptr(associd), uintptr(flags), uintptr(_p0), uintptr(len(iov)), uintptr(unsafe.Pointer(n)), uintptr(unsafe.Pointer(connid)), 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_connectx_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_connectx connectx "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func sendfile(infd int, outfd int, offset int64, len *int64, hdtr unsafe.Pointer, flags int) (err error) { _, _, e1 := syscall_syscall6(libc_sendfile_trampoline_addr, uintptr(infd), uintptr(outfd), uintptr(offset), uintptr(unsafe.Pointer(len)), uintptr(hdtr), uintptr(flags)) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s index 05770011..4f178a22 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s @@ -223,6 +223,16 @@ TEXT libc_ioctl_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_ioctl_trampoline_addr(SB), RODATA, $8 DATA ·libc_ioctl_trampoline_addr(SB)/8, $libc_ioctl_trampoline<>(SB) +TEXT libc_renamex_np_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_renamex_np(SB) +GLOBL ·libc_renamex_np_trampoline_addr(SB), RODATA, $8 +DATA ·libc_renamex_np_trampoline_addr(SB)/8, $libc_renamex_np_trampoline<>(SB) + +TEXT libc_renameatx_np_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_renameatx_np(SB) +GLOBL ·libc_renameatx_np_trampoline_addr(SB), RODATA, $8 +DATA ·libc_renameatx_np_trampoline_addr(SB)/8, $libc_renameatx_np_trampoline<>(SB) + TEXT libc_sysctl_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_sysctl(SB) GLOBL ·libc_sysctl_trampoline_addr(SB), RODATA, $8 @@ -238,6 +248,11 @@ TEXT libc_pthread_fchdir_np_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_pthread_fchdir_np_trampoline_addr(SB), RODATA, $8 DATA ·libc_pthread_fchdir_np_trampoline_addr(SB)/8, $libc_pthread_fchdir_np_trampoline<>(SB) +TEXT libc_connectx_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_connectx(SB) +GLOBL ·libc_connectx_trampoline_addr(SB), RODATA, $8 +DATA ·libc_connectx_trampoline_addr(SB)/8, $libc_connectx_trampoline<>(SB) + TEXT libc_sendfile_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_sendfile(SB) GLOBL ·libc_sendfile_trampoline_addr(SB), RODATA, $8 diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_linux.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_linux.go index 87d8612a..1bc1a5ad 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_linux.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_linux.go @@ -2229,3 +2229,19 @@ func Cachestat(fd uint, crange *CachestatRange, cstat *Cachestat_t, flags uint) } return } + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func Mseal(b []byte, flags uint) (err error) { + var _p0 unsafe.Pointer + if len(b) > 0 { + _p0 = unsafe.Pointer(&b[0]) + } else { + _p0 = unsafe.Pointer(&_zero) + } + _, _, e1 := Syscall(SYS_MSEAL, uintptr(_p0), uintptr(len(b)), uintptr(flags)) + if e1 != 0 { + err = errnoErr(e1) + } + return +} diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.go index 9dc42410..1851df14 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.go @@ -1493,6 +1493,30 @@ var libc_mknodat_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func Mount(fsType string, dir string, flags int, data unsafe.Pointer) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(fsType) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(dir) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_mount_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flags), uintptr(data), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_mount_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_mount mount "libc.so" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Nanosleep(time *Timespec, leftover *Timespec) (err error) { _, _, e1 := syscall_syscall(libc_nanosleep_trampoline_addr, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.s index 41b56173..0b43c693 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_386.s @@ -463,6 +463,11 @@ TEXT libc_mknodat_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_mknodat_trampoline_addr(SB), RODATA, $4 DATA ·libc_mknodat_trampoline_addr(SB)/4, $libc_mknodat_trampoline<>(SB) +TEXT libc_mount_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_mount(SB) +GLOBL ·libc_mount_trampoline_addr(SB), RODATA, $4 +DATA ·libc_mount_trampoline_addr(SB)/4, $libc_mount_trampoline<>(SB) + TEXT libc_nanosleep_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_nanosleep(SB) GLOBL ·libc_nanosleep_trampoline_addr(SB), RODATA, $4 diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.go index 0d3a0751..e1ec0dbe 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.go @@ -1493,6 +1493,30 @@ var libc_mknodat_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func Mount(fsType string, dir string, flags int, data unsafe.Pointer) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(fsType) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(dir) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_mount_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flags), uintptr(data), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_mount_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_mount mount "libc.so" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Nanosleep(time *Timespec, leftover *Timespec) (err error) { _, _, e1 := syscall_syscall(libc_nanosleep_trampoline_addr, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.s index 4019a656..880c6d6e 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_amd64.s @@ -463,6 +463,11 @@ TEXT libc_mknodat_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_mknodat_trampoline_addr(SB), RODATA, $8 DATA ·libc_mknodat_trampoline_addr(SB)/8, $libc_mknodat_trampoline<>(SB) +TEXT libc_mount_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_mount(SB) +GLOBL ·libc_mount_trampoline_addr(SB), RODATA, $8 +DATA ·libc_mount_trampoline_addr(SB)/8, $libc_mount_trampoline<>(SB) + TEXT libc_nanosleep_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_nanosleep(SB) GLOBL ·libc_nanosleep_trampoline_addr(SB), RODATA, $8 diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.go index c39f7776..7c8452a6 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.go @@ -1493,6 +1493,30 @@ var libc_mknodat_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func Mount(fsType string, dir string, flags int, data unsafe.Pointer) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(fsType) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(dir) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_mount_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flags), uintptr(data), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_mount_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_mount mount "libc.so" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Nanosleep(time *Timespec, leftover *Timespec) (err error) { _, _, e1 := syscall_syscall(libc_nanosleep_trampoline_addr, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.s index ac4af24f..b8ef95b0 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm.s @@ -463,6 +463,11 @@ TEXT libc_mknodat_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_mknodat_trampoline_addr(SB), RODATA, $4 DATA ·libc_mknodat_trampoline_addr(SB)/4, $libc_mknodat_trampoline<>(SB) +TEXT libc_mount_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_mount(SB) +GLOBL ·libc_mount_trampoline_addr(SB), RODATA, $4 +DATA ·libc_mount_trampoline_addr(SB)/4, $libc_mount_trampoline<>(SB) + TEXT libc_nanosleep_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_nanosleep(SB) GLOBL ·libc_nanosleep_trampoline_addr(SB), RODATA, $4 diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.go index 57571d07..2ffdf861 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.go @@ -1493,6 +1493,30 @@ var libc_mknodat_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func Mount(fsType string, dir string, flags int, data unsafe.Pointer) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(fsType) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(dir) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_mount_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flags), uintptr(data), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_mount_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_mount mount "libc.so" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Nanosleep(time *Timespec, leftover *Timespec) (err error) { _, _, e1 := syscall_syscall(libc_nanosleep_trampoline_addr, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.s index f77d5321..2af3b5c7 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_arm64.s @@ -463,6 +463,11 @@ TEXT libc_mknodat_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_mknodat_trampoline_addr(SB), RODATA, $8 DATA ·libc_mknodat_trampoline_addr(SB)/8, $libc_mknodat_trampoline<>(SB) +TEXT libc_mount_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_mount(SB) +GLOBL ·libc_mount_trampoline_addr(SB), RODATA, $8 +DATA ·libc_mount_trampoline_addr(SB)/8, $libc_mount_trampoline<>(SB) + TEXT libc_nanosleep_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_nanosleep(SB) GLOBL ·libc_nanosleep_trampoline_addr(SB), RODATA, $8 diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.go index e62963e6..1da08d52 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.go @@ -1493,6 +1493,30 @@ var libc_mknodat_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func Mount(fsType string, dir string, flags int, data unsafe.Pointer) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(fsType) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(dir) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_mount_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flags), uintptr(data), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_mount_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_mount mount "libc.so" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Nanosleep(time *Timespec, leftover *Timespec) (err error) { _, _, e1 := syscall_syscall(libc_nanosleep_trampoline_addr, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.s index fae140b6..b7a25135 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_mips64.s @@ -463,6 +463,11 @@ TEXT libc_mknodat_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_mknodat_trampoline_addr(SB), RODATA, $8 DATA ·libc_mknodat_trampoline_addr(SB)/8, $libc_mknodat_trampoline<>(SB) +TEXT libc_mount_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_mount(SB) +GLOBL ·libc_mount_trampoline_addr(SB), RODATA, $8 +DATA ·libc_mount_trampoline_addr(SB)/8, $libc_mount_trampoline<>(SB) + TEXT libc_nanosleep_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_nanosleep(SB) GLOBL ·libc_nanosleep_trampoline_addr(SB), RODATA, $8 diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.go index 00831354..6e85b0aa 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.go @@ -1493,6 +1493,30 @@ var libc_mknodat_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func Mount(fsType string, dir string, flags int, data unsafe.Pointer) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(fsType) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(dir) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_mount_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flags), uintptr(data), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_mount_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_mount mount "libc.so" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Nanosleep(time *Timespec, leftover *Timespec) (err error) { _, _, e1 := syscall_syscall(libc_nanosleep_trampoline_addr, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.s index 9d1e0ff0..f15dadf0 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_ppc64.s @@ -555,6 +555,12 @@ TEXT libc_mknodat_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_mknodat_trampoline_addr(SB), RODATA, $8 DATA ·libc_mknodat_trampoline_addr(SB)/8, $libc_mknodat_trampoline<>(SB) +TEXT libc_mount_trampoline<>(SB),NOSPLIT,$0-0 + CALL libc_mount(SB) + RET +GLOBL ·libc_mount_trampoline_addr(SB), RODATA, $8 +DATA ·libc_mount_trampoline_addr(SB)/8, $libc_mount_trampoline<>(SB) + TEXT libc_nanosleep_trampoline<>(SB),NOSPLIT,$0-0 CALL libc_nanosleep(SB) RET diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.go b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.go index 79029ed5..28b487df 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.go @@ -1493,6 +1493,30 @@ var libc_mknodat_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func Mount(fsType string, dir string, flags int, data unsafe.Pointer) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(fsType) + if err != nil { + return + } + var _p1 *byte + _p1, err = BytePtrFromString(dir) + if err != nil { + return + } + _, _, e1 := syscall_syscall6(libc_mount_trampoline_addr, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(_p1)), uintptr(flags), uintptr(data), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_mount_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_mount mount "libc.so" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func Nanosleep(time *Timespec, leftover *Timespec) (err error) { _, _, e1 := syscall_syscall(libc_nanosleep_trampoline_addr, uintptr(unsafe.Pointer(time)), uintptr(unsafe.Pointer(leftover)), 0) if e1 != 0 { diff --git a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.s b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.s index da115f9a..1e7f321e 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.s +++ b/backend/vendor/golang.org/x/sys/unix/zsyscall_openbsd_riscv64.s @@ -463,6 +463,11 @@ TEXT libc_mknodat_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_mknodat_trampoline_addr(SB), RODATA, $8 DATA ·libc_mknodat_trampoline_addr(SB)/8, $libc_mknodat_trampoline<>(SB) +TEXT libc_mount_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_mount(SB) +GLOBL ·libc_mount_trampoline_addr(SB), RODATA, $8 +DATA ·libc_mount_trampoline_addr(SB)/8, $libc_mount_trampoline<>(SB) + TEXT libc_nanosleep_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_nanosleep(SB) GLOBL ·libc_nanosleep_trampoline_addr(SB), RODATA, $8 diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_386.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_386.go index 53aef5dc..524b0820 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_386.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_386.go @@ -457,4 +457,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_amd64.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_amd64.go index 71d52476..d3e38f68 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_amd64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_amd64.go @@ -379,4 +379,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_arm.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_arm.go index c7477061..70b35bf3 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_arm.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_arm.go @@ -421,4 +421,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go index f96e214f..6c778c23 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_arm64.go @@ -324,4 +324,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_loong64.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_loong64.go index 28425346..37281cf5 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_loong64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_loong64.go @@ -318,4 +318,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips.go index d0953018..7e567f1e 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips.go @@ -441,4 +441,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 4459 SYS_LSM_SET_SELF_ATTR = 4460 SYS_LSM_LIST_MODULES = 4461 + SYS_MSEAL = 4462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64.go index 295c7f4b..38ae55e5 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64.go @@ -371,4 +371,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 5459 SYS_LSM_SET_SELF_ATTR = 5460 SYS_LSM_LIST_MODULES = 5461 + SYS_MSEAL = 5462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64le.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64le.go index d1a9eaca..55e92e60 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64le.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mips64le.go @@ -371,4 +371,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 5459 SYS_LSM_SET_SELF_ATTR = 5460 SYS_LSM_LIST_MODULES = 5461 + SYS_MSEAL = 5462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mipsle.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mipsle.go index bec157c3..60658d6a 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mipsle.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_mipsle.go @@ -441,4 +441,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 4459 SYS_LSM_SET_SELF_ATTR = 4460 SYS_LSM_LIST_MODULES = 4461 + SYS_MSEAL = 4462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc.go index 7ee7bdc4..e203e8a7 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc.go @@ -448,4 +448,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64.go index fad1f25b..5944b97d 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64.go @@ -420,4 +420,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64le.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64le.go index 7d3e1635..c66d416d 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64le.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_ppc64le.go @@ -420,4 +420,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go index 0ed53ad9..9889f6a5 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_riscv64.go @@ -325,4 +325,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_s390x.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_s390x.go index 2fba04ad..01d86825 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_s390x.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_s390x.go @@ -386,4 +386,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go index 621d00d7..7b703e77 100644 --- a/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go +++ b/backend/vendor/golang.org/x/sys/unix/zsysnum_linux_sparc64.go @@ -399,4 +399,5 @@ const ( SYS_LSM_GET_SELF_ATTR = 459 SYS_LSM_SET_SELF_ATTR = 460 SYS_LSM_LIST_MODULES = 461 + SYS_MSEAL = 462 ) diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_darwin_amd64.go b/backend/vendor/golang.org/x/sys/unix/ztypes_darwin_amd64.go index 091d107f..d003c3d4 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_darwin_amd64.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_darwin_amd64.go @@ -306,6 +306,19 @@ type XVSockPgen struct { type _Socklen uint32 +type SaeAssocID uint32 + +type SaeConnID uint32 + +type SaEndpoints struct { + Srcif uint32 + Srcaddr *RawSockaddr + Srcaddrlen uint32 + Dstaddr *RawSockaddr + Dstaddrlen uint32 + _ [4]byte +} + type Xucred struct { Version uint32 Uid uint32 diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_darwin_arm64.go b/backend/vendor/golang.org/x/sys/unix/ztypes_darwin_arm64.go index 28ff4ef7..0d45a941 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_darwin_arm64.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_darwin_arm64.go @@ -306,6 +306,19 @@ type XVSockPgen struct { type _Socklen uint32 +type SaeAssocID uint32 + +type SaeConnID uint32 + +type SaEndpoints struct { + Srcif uint32 + Srcaddr *RawSockaddr + Srcaddrlen uint32 + Dstaddr *RawSockaddr + Dstaddrlen uint32 + _ [4]byte +} + type Xucred struct { Version uint32 Uid uint32 diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_386.go b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_386.go index 6cbd094a..51e13eb0 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_386.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_386.go @@ -625,6 +625,7 @@ const ( POLLRDNORM = 0x40 POLLWRBAND = 0x100 POLLWRNORM = 0x4 + POLLRDHUP = 0x4000 ) type CapRights struct { diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_amd64.go b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_amd64.go index 7c03b6ee..d002d8ef 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_amd64.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_amd64.go @@ -630,6 +630,7 @@ const ( POLLRDNORM = 0x40 POLLWRBAND = 0x100 POLLWRNORM = 0x4 + POLLRDHUP = 0x4000 ) type CapRights struct { diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_arm.go b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_arm.go index 422107ee..3f863d89 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_arm.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_arm.go @@ -616,6 +616,7 @@ const ( POLLRDNORM = 0x40 POLLWRBAND = 0x100 POLLWRNORM = 0x4 + POLLRDHUP = 0x4000 ) type CapRights struct { diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_arm64.go b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_arm64.go index 505a12ac..61c72931 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_arm64.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_arm64.go @@ -610,6 +610,7 @@ const ( POLLRDNORM = 0x40 POLLWRBAND = 0x100 POLLWRNORM = 0x4 + POLLRDHUP = 0x4000 ) type CapRights struct { diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_riscv64.go b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_riscv64.go index cc986c79..b5d17414 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_riscv64.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_freebsd_riscv64.go @@ -612,6 +612,7 @@ const ( POLLRDNORM = 0x40 POLLWRBAND = 0x100 POLLWRNORM = 0x4 + POLLRDHUP = 0x4000 ) type CapRights struct { diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_linux.go b/backend/vendor/golang.org/x/sys/unix/ztypes_linux.go index 4740b834..9f2550dc 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_linux.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_linux.go @@ -110,7 +110,8 @@ type Statx_t struct { Mnt_id uint64 Dio_mem_align uint32 Dio_offset_align uint32 - _ [12]uint64 + Subvol uint64 + _ [11]uint64 } type Fsid struct { @@ -2485,7 +2486,7 @@ type XDPMmapOffsets struct { type XDPUmemReg struct { Addr uint64 Len uint64 - Chunk_size uint32 + Size uint32 Headroom uint32 Flags uint32 Tx_metadata_len uint32 @@ -3473,7 +3474,7 @@ const ( DEVLINK_PORT_FN_ATTR_STATE = 0x2 DEVLINK_PORT_FN_ATTR_OPSTATE = 0x3 DEVLINK_PORT_FN_ATTR_CAPS = 0x4 - DEVLINK_PORT_FUNCTION_ATTR_MAX = 0x5 + DEVLINK_PORT_FUNCTION_ATTR_MAX = 0x6 ) type FsverityDigest struct { @@ -3806,6 +3807,9 @@ const ( ETHTOOL_MSG_PSE_GET_REPLY = 0x25 ETHTOOL_MSG_RSS_GET_REPLY = 0x26 ETHTOOL_MSG_KERNEL_MAX = 0x2b + ETHTOOL_FLAG_COMPACT_BITSETS = 0x1 + ETHTOOL_FLAG_OMIT_REPLY = 0x2 + ETHTOOL_FLAG_STATS = 0x4 ETHTOOL_A_HEADER_UNSPEC = 0x0 ETHTOOL_A_HEADER_DEV_INDEX = 0x1 ETHTOOL_A_HEADER_DEV_NAME = 0x2 @@ -3975,7 +3979,7 @@ const ( ETHTOOL_A_TSINFO_TX_TYPES = 0x3 ETHTOOL_A_TSINFO_RX_FILTERS = 0x4 ETHTOOL_A_TSINFO_PHC_INDEX = 0x5 - ETHTOOL_A_TSINFO_MAX = 0x5 + ETHTOOL_A_TSINFO_MAX = 0x6 ETHTOOL_A_CABLE_TEST_UNSPEC = 0x0 ETHTOOL_A_CABLE_TEST_HEADER = 0x1 ETHTOOL_A_CABLE_TEST_MAX = 0x1 diff --git a/backend/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go b/backend/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go index 15adc041..ad05b51a 100644 --- a/backend/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go +++ b/backend/vendor/golang.org/x/sys/unix/ztypes_linux_riscv64.go @@ -727,6 +727,37 @@ const ( RISCV_HWPROBE_EXT_ZBA = 0x8 RISCV_HWPROBE_EXT_ZBB = 0x10 RISCV_HWPROBE_EXT_ZBS = 0x20 + RISCV_HWPROBE_EXT_ZICBOZ = 0x40 + RISCV_HWPROBE_EXT_ZBC = 0x80 + RISCV_HWPROBE_EXT_ZBKB = 0x100 + RISCV_HWPROBE_EXT_ZBKC = 0x200 + RISCV_HWPROBE_EXT_ZBKX = 0x400 + RISCV_HWPROBE_EXT_ZKND = 0x800 + RISCV_HWPROBE_EXT_ZKNE = 0x1000 + RISCV_HWPROBE_EXT_ZKNH = 0x2000 + RISCV_HWPROBE_EXT_ZKSED = 0x4000 + RISCV_HWPROBE_EXT_ZKSH = 0x8000 + RISCV_HWPROBE_EXT_ZKT = 0x10000 + RISCV_HWPROBE_EXT_ZVBB = 0x20000 + RISCV_HWPROBE_EXT_ZVBC = 0x40000 + RISCV_HWPROBE_EXT_ZVKB = 0x80000 + RISCV_HWPROBE_EXT_ZVKG = 0x100000 + RISCV_HWPROBE_EXT_ZVKNED = 0x200000 + RISCV_HWPROBE_EXT_ZVKNHA = 0x400000 + RISCV_HWPROBE_EXT_ZVKNHB = 0x800000 + RISCV_HWPROBE_EXT_ZVKSED = 0x1000000 + RISCV_HWPROBE_EXT_ZVKSH = 0x2000000 + RISCV_HWPROBE_EXT_ZVKT = 0x4000000 + RISCV_HWPROBE_EXT_ZFH = 0x8000000 + RISCV_HWPROBE_EXT_ZFHMIN = 0x10000000 + RISCV_HWPROBE_EXT_ZIHINTNTL = 0x20000000 + RISCV_HWPROBE_EXT_ZVFH = 0x40000000 + RISCV_HWPROBE_EXT_ZVFHMIN = 0x80000000 + RISCV_HWPROBE_EXT_ZFA = 0x100000000 + RISCV_HWPROBE_EXT_ZTSO = 0x200000000 + RISCV_HWPROBE_EXT_ZACAS = 0x400000000 + RISCV_HWPROBE_EXT_ZICOND = 0x800000000 + RISCV_HWPROBE_EXT_ZIHINTPAUSE = 0x1000000000 RISCV_HWPROBE_KEY_CPUPERF_0 = 0x5 RISCV_HWPROBE_MISALIGNED_UNKNOWN = 0x0 RISCV_HWPROBE_MISALIGNED_EMULATED = 0x1 @@ -734,4 +765,6 @@ const ( RISCV_HWPROBE_MISALIGNED_FAST = 0x3 RISCV_HWPROBE_MISALIGNED_UNSUPPORTED = 0x4 RISCV_HWPROBE_MISALIGNED_MASK = 0x7 + RISCV_HWPROBE_KEY_ZICBOZ_BLOCK_SIZE = 0x6 + RISCV_HWPROBE_WHICH_CPUS = 0x1 ) diff --git a/backend/vendor/golang.org/x/sys/windows/security_windows.go b/backend/vendor/golang.org/x/sys/windows/security_windows.go index 97651b5b..b6e1ab76 100644 --- a/backend/vendor/golang.org/x/sys/windows/security_windows.go +++ b/backend/vendor/golang.org/x/sys/windows/security_windows.go @@ -1179,7 +1179,7 @@ type OBJECTS_AND_NAME struct { //sys makeSelfRelativeSD(absoluteSD *SECURITY_DESCRIPTOR, selfRelativeSD *SECURITY_DESCRIPTOR, selfRelativeSDSize *uint32) (err error) = advapi32.MakeSelfRelativeSD //sys setEntriesInAcl(countExplicitEntries uint32, explicitEntries *EXPLICIT_ACCESS, oldACL *ACL, newACL **ACL) (ret error) = advapi32.SetEntriesInAclW -//sys GetAce(acl *ACL, aceIndex uint32, pAce **ACCESS_ALLOWED_ACE) (ret error) = advapi32.GetAce +//sys GetAce(acl *ACL, aceIndex uint32, pAce **ACCESS_ALLOWED_ACE) (err error) = advapi32.GetAce // Control returns the security descriptor control bits. func (sd *SECURITY_DESCRIPTOR) Control() (control SECURITY_DESCRIPTOR_CONTROL, revision uint32, err error) { diff --git a/backend/vendor/golang.org/x/sys/windows/syscall_windows.go b/backend/vendor/golang.org/x/sys/windows/syscall_windows.go index 6525c62f..5cee9a31 100644 --- a/backend/vendor/golang.org/x/sys/windows/syscall_windows.go +++ b/backend/vendor/golang.org/x/sys/windows/syscall_windows.go @@ -17,8 +17,10 @@ import ( "unsafe" ) -type Handle uintptr -type HWND uintptr +type ( + Handle uintptr + HWND uintptr +) const ( InvalidHandle = ^Handle(0) @@ -211,6 +213,10 @@ func NewCallbackCDecl(fn interface{}) uintptr { //sys OpenProcess(desiredAccess uint32, inheritHandle bool, processId uint32) (handle Handle, err error) //sys ShellExecute(hwnd Handle, verb *uint16, file *uint16, args *uint16, cwd *uint16, showCmd int32) (err error) [failretval<=32] = shell32.ShellExecuteW //sys GetWindowThreadProcessId(hwnd HWND, pid *uint32) (tid uint32, err error) = user32.GetWindowThreadProcessId +//sys LoadKeyboardLayout(name *uint16, flags uint32) (hkl Handle, err error) [failretval==0] = user32.LoadKeyboardLayoutW +//sys UnloadKeyboardLayout(hkl Handle) (err error) = user32.UnloadKeyboardLayout +//sys GetKeyboardLayout(tid uint32) (hkl Handle) = user32.GetKeyboardLayout +//sys ToUnicodeEx(vkey uint32, scancode uint32, keystate *byte, pwszBuff *uint16, cchBuff int32, flags uint32, hkl Handle) (ret int32) = user32.ToUnicodeEx //sys GetShellWindow() (shellWindow HWND) = user32.GetShellWindow //sys MessageBox(hwnd HWND, text *uint16, caption *uint16, boxtype uint32) (ret int32, err error) [failretval==0] = user32.MessageBoxW //sys ExitWindowsEx(flags uint32, reason uint32) (err error) = user32.ExitWindowsEx @@ -307,6 +313,10 @@ func NewCallbackCDecl(fn interface{}) uintptr { //sys SetConsoleMode(console Handle, mode uint32) (err error) = kernel32.SetConsoleMode //sys GetConsoleScreenBufferInfo(console Handle, info *ConsoleScreenBufferInfo) (err error) = kernel32.GetConsoleScreenBufferInfo //sys setConsoleCursorPosition(console Handle, position uint32) (err error) = kernel32.SetConsoleCursorPosition +//sys GetConsoleCP() (cp uint32, err error) = kernel32.GetConsoleCP +//sys GetConsoleOutputCP() (cp uint32, err error) = kernel32.GetConsoleOutputCP +//sys SetConsoleCP(cp uint32) (err error) = kernel32.SetConsoleCP +//sys SetConsoleOutputCP(cp uint32) (err error) = kernel32.SetConsoleOutputCP //sys WriteConsole(console Handle, buf *uint16, towrite uint32, written *uint32, reserved *byte) (err error) = kernel32.WriteConsoleW //sys ReadConsole(console Handle, buf *uint16, toread uint32, read *uint32, inputControl *byte) (err error) = kernel32.ReadConsoleW //sys resizePseudoConsole(pconsole Handle, size uint32) (hr error) = kernel32.ResizePseudoConsole @@ -1368,9 +1378,11 @@ func SetsockoptLinger(fd Handle, level, opt int, l *Linger) (err error) { func SetsockoptInet4Addr(fd Handle, level, opt int, value [4]byte) (err error) { return Setsockopt(fd, int32(level), int32(opt), (*byte)(unsafe.Pointer(&value[0])), 4) } + func SetsockoptIPMreq(fd Handle, level, opt int, mreq *IPMreq) (err error) { return Setsockopt(fd, int32(level), int32(opt), (*byte)(unsafe.Pointer(mreq)), int32(unsafe.Sizeof(*mreq))) } + func SetsockoptIPv6Mreq(fd Handle, level, opt int, mreq *IPv6Mreq) (err error) { return syscall.EWINDOWS } diff --git a/backend/vendor/golang.org/x/sys/windows/types_windows.go b/backend/vendor/golang.org/x/sys/windows/types_windows.go index d8cb71db..7b97a154 100644 --- a/backend/vendor/golang.org/x/sys/windows/types_windows.go +++ b/backend/vendor/golang.org/x/sys/windows/types_windows.go @@ -1060,6 +1060,7 @@ const ( SIO_GET_EXTENSION_FUNCTION_POINTER = IOC_INOUT | IOC_WS2 | 6 SIO_KEEPALIVE_VALS = IOC_IN | IOC_VENDOR | 4 SIO_UDP_CONNRESET = IOC_IN | IOC_VENDOR | 12 + SIO_UDP_NETRESET = IOC_IN | IOC_VENDOR | 15 // cf. http://support.microsoft.com/default.aspx?scid=kb;en-us;257460 @@ -2003,7 +2004,21 @@ const ( MOVEFILE_FAIL_IF_NOT_TRACKABLE = 0x20 ) -const GAA_FLAG_INCLUDE_PREFIX = 0x00000010 +// Flags for GetAdaptersAddresses, see +// https://learn.microsoft.com/en-us/windows/win32/api/iphlpapi/nf-iphlpapi-getadaptersaddresses. +const ( + GAA_FLAG_SKIP_UNICAST = 0x1 + GAA_FLAG_SKIP_ANYCAST = 0x2 + GAA_FLAG_SKIP_MULTICAST = 0x4 + GAA_FLAG_SKIP_DNS_SERVER = 0x8 + GAA_FLAG_INCLUDE_PREFIX = 0x10 + GAA_FLAG_SKIP_FRIENDLY_NAME = 0x20 + GAA_FLAG_INCLUDE_WINS_INFO = 0x40 + GAA_FLAG_INCLUDE_GATEWAYS = 0x80 + GAA_FLAG_INCLUDE_ALL_INTERFACES = 0x100 + GAA_FLAG_INCLUDE_ALL_COMPARTMENTS = 0x200 + GAA_FLAG_INCLUDE_TUNNEL_BINDINGORDER = 0x400 +) const ( IF_TYPE_OTHER = 1 @@ -2017,6 +2032,50 @@ const ( IF_TYPE_IEEE1394 = 144 ) +// Enum NL_PREFIX_ORIGIN for [IpAdapterUnicastAddress], see +// https://learn.microsoft.com/en-us/windows/win32/api/nldef/ne-nldef-nl_prefix_origin +const ( + IpPrefixOriginOther = 0 + IpPrefixOriginManual = 1 + IpPrefixOriginWellKnown = 2 + IpPrefixOriginDhcp = 3 + IpPrefixOriginRouterAdvertisement = 4 + IpPrefixOriginUnchanged = 1 << 4 +) + +// Enum NL_SUFFIX_ORIGIN for [IpAdapterUnicastAddress], see +// https://learn.microsoft.com/en-us/windows/win32/api/nldef/ne-nldef-nl_suffix_origin +const ( + NlsoOther = 0 + NlsoManual = 1 + NlsoWellKnown = 2 + NlsoDhcp = 3 + NlsoLinkLayerAddress = 4 + NlsoRandom = 5 + IpSuffixOriginOther = 0 + IpSuffixOriginManual = 1 + IpSuffixOriginWellKnown = 2 + IpSuffixOriginDhcp = 3 + IpSuffixOriginLinkLayerAddress = 4 + IpSuffixOriginRandom = 5 + IpSuffixOriginUnchanged = 1 << 4 +) + +// Enum NL_DAD_STATE for [IpAdapterUnicastAddress], see +// https://learn.microsoft.com/en-us/windows/win32/api/nldef/ne-nldef-nl_dad_state +const ( + NldsInvalid = 0 + NldsTentative = 1 + NldsDuplicate = 2 + NldsDeprecated = 3 + NldsPreferred = 4 + IpDadStateInvalid = 0 + IpDadStateTentative = 1 + IpDadStateDuplicate = 2 + IpDadStateDeprecated = 3 + IpDadStatePreferred = 4 +) + type SocketAddress struct { Sockaddr *syscall.RawSockaddrAny SockaddrLength int32 @@ -3404,3 +3463,14 @@ type DCB struct { EvtChar byte wReserved1 uint16 } + +// Keyboard Layout Flags. +// See https://learn.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-loadkeyboardlayoutw +const ( + KLF_ACTIVATE = 0x00000001 + KLF_SUBSTITUTE_OK = 0x00000002 + KLF_REORDER = 0x00000008 + KLF_REPLACELANG = 0x00000010 + KLF_NOTELLSHELL = 0x00000080 + KLF_SETFORPROCESS = 0x00000100 +) diff --git a/backend/vendor/golang.org/x/sys/windows/zsyscall_windows.go b/backend/vendor/golang.org/x/sys/windows/zsyscall_windows.go index eba76101..4c2e1bdc 100644 --- a/backend/vendor/golang.org/x/sys/windows/zsyscall_windows.go +++ b/backend/vendor/golang.org/x/sys/windows/zsyscall_windows.go @@ -247,7 +247,9 @@ var ( procGetCommandLineW = modkernel32.NewProc("GetCommandLineW") procGetComputerNameExW = modkernel32.NewProc("GetComputerNameExW") procGetComputerNameW = modkernel32.NewProc("GetComputerNameW") + procGetConsoleCP = modkernel32.NewProc("GetConsoleCP") procGetConsoleMode = modkernel32.NewProc("GetConsoleMode") + procGetConsoleOutputCP = modkernel32.NewProc("GetConsoleOutputCP") procGetConsoleScreenBufferInfo = modkernel32.NewProc("GetConsoleScreenBufferInfo") procGetCurrentDirectoryW = modkernel32.NewProc("GetCurrentDirectoryW") procGetCurrentProcessId = modkernel32.NewProc("GetCurrentProcessId") @@ -347,8 +349,10 @@ var ( procSetCommMask = modkernel32.NewProc("SetCommMask") procSetCommState = modkernel32.NewProc("SetCommState") procSetCommTimeouts = modkernel32.NewProc("SetCommTimeouts") + procSetConsoleCP = modkernel32.NewProc("SetConsoleCP") procSetConsoleCursorPosition = modkernel32.NewProc("SetConsoleCursorPosition") procSetConsoleMode = modkernel32.NewProc("SetConsoleMode") + procSetConsoleOutputCP = modkernel32.NewProc("SetConsoleOutputCP") procSetCurrentDirectoryW = modkernel32.NewProc("SetCurrentDirectoryW") procSetDefaultDllDirectories = modkernel32.NewProc("SetDefaultDllDirectories") procSetDllDirectoryW = modkernel32.NewProc("SetDllDirectoryW") @@ -478,12 +482,16 @@ var ( procGetDesktopWindow = moduser32.NewProc("GetDesktopWindow") procGetForegroundWindow = moduser32.NewProc("GetForegroundWindow") procGetGUIThreadInfo = moduser32.NewProc("GetGUIThreadInfo") + procGetKeyboardLayout = moduser32.NewProc("GetKeyboardLayout") procGetShellWindow = moduser32.NewProc("GetShellWindow") procGetWindowThreadProcessId = moduser32.NewProc("GetWindowThreadProcessId") procIsWindow = moduser32.NewProc("IsWindow") procIsWindowUnicode = moduser32.NewProc("IsWindowUnicode") procIsWindowVisible = moduser32.NewProc("IsWindowVisible") + procLoadKeyboardLayoutW = moduser32.NewProc("LoadKeyboardLayoutW") procMessageBoxW = moduser32.NewProc("MessageBoxW") + procToUnicodeEx = moduser32.NewProc("ToUnicodeEx") + procUnloadKeyboardLayout = moduser32.NewProc("UnloadKeyboardLayout") procCreateEnvironmentBlock = moduserenv.NewProc("CreateEnvironmentBlock") procDestroyEnvironmentBlock = moduserenv.NewProc("DestroyEnvironmentBlock") procGetUserProfileDirectoryW = moduserenv.NewProc("GetUserProfileDirectoryW") @@ -789,6 +797,14 @@ func FreeSid(sid *SID) (err error) { return } +func GetAce(acl *ACL, aceIndex uint32, pAce **ACCESS_ALLOWED_ACE) (err error) { + r1, _, e1 := syscall.Syscall(procGetAce.Addr(), 3, uintptr(unsafe.Pointer(acl)), uintptr(aceIndex), uintptr(unsafe.Pointer(pAce))) + if r1 == 0 { + err = errnoErr(e1) + } + return +} + func GetLengthSid(sid *SID) (len uint32) { r0, _, _ := syscall.Syscall(procGetLengthSid.Addr(), 1, uintptr(unsafe.Pointer(sid)), 0, 0) len = uint32(r0) @@ -1225,14 +1241,6 @@ func setEntriesInAcl(countExplicitEntries uint32, explicitEntries *EXPLICIT_ACCE return } -func GetAce(acl *ACL, aceIndex uint32, pAce **ACCESS_ALLOWED_ACE) (ret error) { - r0, _, _ := syscall.Syscall(procGetAce.Addr(), 3, uintptr(unsafe.Pointer(acl)), uintptr(aceIndex), uintptr(unsafe.Pointer(pAce))) - if r0 == 0 { - ret = GetLastError() - } - return -} - func SetKernelObjectSecurity(handle Handle, securityInformation SECURITY_INFORMATION, securityDescriptor *SECURITY_DESCRIPTOR) (err error) { r1, _, e1 := syscall.Syscall(procSetKernelObjectSecurity.Addr(), 3, uintptr(handle), uintptr(securityInformation), uintptr(unsafe.Pointer(securityDescriptor))) if r1 == 0 { @@ -2158,6 +2166,15 @@ func GetComputerName(buf *uint16, n *uint32) (err error) { return } +func GetConsoleCP() (cp uint32, err error) { + r0, _, e1 := syscall.Syscall(procGetConsoleCP.Addr(), 0, 0, 0, 0) + cp = uint32(r0) + if cp == 0 { + err = errnoErr(e1) + } + return +} + func GetConsoleMode(console Handle, mode *uint32) (err error) { r1, _, e1 := syscall.Syscall(procGetConsoleMode.Addr(), 2, uintptr(console), uintptr(unsafe.Pointer(mode)), 0) if r1 == 0 { @@ -2166,6 +2183,15 @@ func GetConsoleMode(console Handle, mode *uint32) (err error) { return } +func GetConsoleOutputCP() (cp uint32, err error) { + r0, _, e1 := syscall.Syscall(procGetConsoleOutputCP.Addr(), 0, 0, 0, 0) + cp = uint32(r0) + if cp == 0 { + err = errnoErr(e1) + } + return +} + func GetConsoleScreenBufferInfo(console Handle, info *ConsoleScreenBufferInfo) (err error) { r1, _, e1 := syscall.Syscall(procGetConsoleScreenBufferInfo.Addr(), 2, uintptr(console), uintptr(unsafe.Pointer(info)), 0) if r1 == 0 { @@ -3034,6 +3060,14 @@ func SetCommTimeouts(handle Handle, timeouts *CommTimeouts) (err error) { return } +func SetConsoleCP(cp uint32) (err error) { + r1, _, e1 := syscall.Syscall(procSetConsoleCP.Addr(), 1, uintptr(cp), 0, 0) + if r1 == 0 { + err = errnoErr(e1) + } + return +} + func setConsoleCursorPosition(console Handle, position uint32) (err error) { r1, _, e1 := syscall.Syscall(procSetConsoleCursorPosition.Addr(), 2, uintptr(console), uintptr(position), 0) if r1 == 0 { @@ -3050,6 +3084,14 @@ func SetConsoleMode(console Handle, mode uint32) (err error) { return } +func SetConsoleOutputCP(cp uint32) (err error) { + r1, _, e1 := syscall.Syscall(procSetConsoleOutputCP.Addr(), 1, uintptr(cp), 0, 0) + if r1 == 0 { + err = errnoErr(e1) + } + return +} + func SetCurrentDirectory(path *uint16) (err error) { r1, _, e1 := syscall.Syscall(procSetCurrentDirectoryW.Addr(), 1, uintptr(unsafe.Pointer(path)), 0, 0) if r1 == 0 { @@ -4082,6 +4124,12 @@ func GetGUIThreadInfo(thread uint32, info *GUIThreadInfo) (err error) { return } +func GetKeyboardLayout(tid uint32) (hkl Handle) { + r0, _, _ := syscall.Syscall(procGetKeyboardLayout.Addr(), 1, uintptr(tid), 0, 0) + hkl = Handle(r0) + return +} + func GetShellWindow() (shellWindow HWND) { r0, _, _ := syscall.Syscall(procGetShellWindow.Addr(), 0, 0, 0, 0) shellWindow = HWND(r0) @@ -4115,6 +4163,15 @@ func IsWindowVisible(hwnd HWND) (isVisible bool) { return } +func LoadKeyboardLayout(name *uint16, flags uint32) (hkl Handle, err error) { + r0, _, e1 := syscall.Syscall(procLoadKeyboardLayoutW.Addr(), 2, uintptr(unsafe.Pointer(name)), uintptr(flags), 0) + hkl = Handle(r0) + if hkl == 0 { + err = errnoErr(e1) + } + return +} + func MessageBox(hwnd HWND, text *uint16, caption *uint16, boxtype uint32) (ret int32, err error) { r0, _, e1 := syscall.Syscall6(procMessageBoxW.Addr(), 4, uintptr(hwnd), uintptr(unsafe.Pointer(text)), uintptr(unsafe.Pointer(caption)), uintptr(boxtype), 0, 0) ret = int32(r0) @@ -4124,6 +4181,20 @@ func MessageBox(hwnd HWND, text *uint16, caption *uint16, boxtype uint32) (ret i return } +func ToUnicodeEx(vkey uint32, scancode uint32, keystate *byte, pwszBuff *uint16, cchBuff int32, flags uint32, hkl Handle) (ret int32) { + r0, _, _ := syscall.Syscall9(procToUnicodeEx.Addr(), 7, uintptr(vkey), uintptr(scancode), uintptr(unsafe.Pointer(keystate)), uintptr(unsafe.Pointer(pwszBuff)), uintptr(cchBuff), uintptr(flags), uintptr(hkl), 0, 0) + ret = int32(r0) + return +} + +func UnloadKeyboardLayout(hkl Handle) (err error) { + r1, _, e1 := syscall.Syscall(procUnloadKeyboardLayout.Addr(), 1, uintptr(hkl), 0, 0) + if r1 == 0 { + err = errnoErr(e1) + } + return +} + func CreateEnvironmentBlock(block **uint16, token Token, inheritExisting bool) (err error) { var _p0 uint32 if inheritExisting { diff --git a/backend/vendor/golang.org/x/text/LICENSE b/backend/vendor/golang.org/x/text/LICENSE index 6a66aea5..2a7cf70d 100644 --- a/backend/vendor/golang.org/x/text/LICENSE +++ b/backend/vendor/golang.org/x/text/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2009 The Go Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -10,7 +10,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. diff --git a/backend/vendor/modules.txt b/backend/vendor/modules.txt index a04068ec..37bea280 100644 --- a/backend/vendor/modules.txt +++ b/backend/vendor/modules.txt @@ -4,13 +4,13 @@ cloud.google.com/go/compute/metadata # github.com/Depado/bfchroma/v2 v2.0.0 ## explicit; go 1.18 github.com/Depado/bfchroma/v2 -# github.com/PuerkitoBio/goquery v1.9.2 -## explicit; go 1.18 +# github.com/PuerkitoBio/goquery v1.10.0 +## explicit; go 1.23 github.com/PuerkitoBio/goquery # github.com/ajg/form v1.5.1 ## explicit github.com/ajg/form -# github.com/alecthomas/chroma/v2 v2.13.0 +# github.com/alecthomas/chroma/v2 v2.14.0 ## explicit; go 1.19 github.com/alecthomas/chroma/v2 github.com/alecthomas/chroma/v2/formatters/html @@ -90,11 +90,11 @@ github.com/go-pkgz/lcw/v2/eventbus # github.com/go-pkgz/lgr v0.11.1 ## explicit; go 1.20 github.com/go-pkgz/lgr -# github.com/go-pkgz/notify v1.1.1 +# github.com/go-pkgz/notify v1.2.0 ## explicit; go 1.21 github.com/go-pkgz/notify -# github.com/go-pkgz/repeater v1.1.3 -## explicit; go 1.12 +# github.com/go-pkgz/repeater v1.2.0 +## explicit; go 1.20 github.com/go-pkgz/repeater github.com/go-pkgz/repeater/strategy # github.com/go-pkgz/rest v1.19.0 @@ -173,8 +173,8 @@ github.com/redis/go-redis/v9/internal/util # github.com/rrivera/identicon v0.0.0-20240116195454-d5ba35832c0d ## explicit; go 1.21 github.com/rrivera/identicon -# github.com/rs/xid v1.5.0 -## explicit; go 1.12 +# github.com/rs/xid v1.6.0 +## explicit; go 1.16 github.com/rs/xid # github.com/russross/blackfriday/v2 v2.1.0 ## explicit @@ -184,7 +184,7 @@ github.com/russross/blackfriday/v2 github.com/skip2/go-qrcode github.com/skip2/go-qrcode/bitset github.com/skip2/go-qrcode/reedsolomon -# github.com/slack-go/slack v0.12.5 +# github.com/slack-go/slack v0.14.0 ## explicit; go 1.16 github.com/slack-go/slack github.com/slack-go/slack/internal/backoff @@ -207,8 +207,8 @@ github.com/xdg-go/stringprep # github.com/youmark/pkcs8 v0.0.0-20240726163527-a2c0da244d78 ## explicit; go 1.17 github.com/youmark/pkcs8 -# go.etcd.io/bbolt v1.3.10 -## explicit; go 1.21 +# go.etcd.io/bbolt v1.3.11 +## explicit; go 1.22 go.etcd.io/bbolt # go.mongodb.org/mongo-driver v1.16.0 ## explicit; go 1.18 @@ -264,18 +264,18 @@ go.mongodb.org/mongo-driver/x/mongo/driver/wiremessage ## explicit; go 1.20 go.uber.org/goleak go.uber.org/goleak/internal/stack -# golang.org/x/crypto v0.25.0 +# golang.org/x/crypto v0.27.0 ## explicit; go 1.20 golang.org/x/crypto/acme golang.org/x/crypto/acme/autocert golang.org/x/crypto/ocsp golang.org/x/crypto/pbkdf2 golang.org/x/crypto/scrypt -# golang.org/x/image v0.18.0 +# golang.org/x/image v0.22.0 ## explicit; go 1.18 golang.org/x/image/draw golang.org/x/image/math/f64 -# golang.org/x/net v0.27.0 +# golang.org/x/net v0.29.0 ## explicit; go 1.18 golang.org/x/net/html golang.org/x/net/html/atom @@ -297,16 +297,16 @@ golang.org/x/oauth2/jws golang.org/x/oauth2/jwt golang.org/x/oauth2/microsoft golang.org/x/oauth2/yandex -# golang.org/x/sync v0.7.0 +# golang.org/x/sync v0.9.0 ## explicit; go 1.18 golang.org/x/sync/errgroup golang.org/x/sync/singleflight -# golang.org/x/sys v0.22.0 +# golang.org/x/sys v0.25.0 ## explicit; go 1.18 golang.org/x/sys/unix golang.org/x/sys/windows golang.org/x/sys/windows/registry -# golang.org/x/text v0.16.0 +# golang.org/x/text v0.20.0 ## explicit; go 1.18 golang.org/x/text/secure/bidirule golang.org/x/text/transform diff --git a/compose-dev-backend.yml b/compose-dev-backend.yml index 055cce01..eaa2a1cc 100644 --- a/compose-dev-backend.yml +++ b/compose-dev-backend.yml @@ -2,8 +2,8 @@ # starts backend on 8080 with basic auth "dev:password" and Dev oauth2 provider on port 8084 # UI on http://127.0.0.1:8080/web # -# build remark42 docker image - docker-compose -f compose-dev-backend.yml build -# start remark42 service - docker-compose -f compose-dev-backend.yml up +# build remark42 docker image - docker compose -f compose-dev-backend.yml build +# start remark42 service - docker compose -f compose-dev-backend.yml up version: "2" services: @@ -66,8 +66,6 @@ services: - AUTH_GITHUB_CSEC=1111 - AUTH_FACEBOOK_CID=1111 - AUTH_FACEBOOK_CSEC=1111 - - AUTH_TWITTER_CID=1111 - - AUTH_TWITTER_CSEC=1111 - AUTH_PATREON_CID=1111 - AUTH_PATREON_CSEC=1111 - AUTH_DISCORD_CID=1111 diff --git a/compose-dev-frontend.yml b/compose-dev-frontend.yml index 1908d695..e6e420b3 100644 --- a/compose-dev-frontend.yml +++ b/compose-dev-frontend.yml @@ -2,8 +2,8 @@ # starts backend on 8080 with basic auth "dev:password" and Dev oauth2 provider on port 8084 # UI on http://127.0.0.1:8080/web # -# build remark42 docker image - docker-compose -f compose-dev-frontend.yml build -# start remark42 service - docker-compose -f compose-dev-frontend.yml up +# build remark42 docker image - docker compose -f compose-dev-frontend.yml build +# start remark42 service - docker compose -f compose-dev-frontend.yml up version: "2" services: diff --git a/docker-compose.yml b/docker-compose.yml index df615681..9ec5af5f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -2,7 +2,7 @@ version: "2" services: remark: - # remove the next line in case you want to use this docker-compose separately + # remove the next line in case you want to use this Docker Compose file separately # as otherwise it would complain for absence of Dockerfile build: . image: umputun/remark42:latest diff --git a/frontend/.nvmrc b/frontend/.nvmrc index cb406c60..b6a7d89c 100644 --- a/frontend/.nvmrc +++ b/frontend/.nvmrc @@ -1 +1 @@ -16.20.2 +16 diff --git a/frontend/apps/remark42/app/locales/fa.json b/frontend/apps/remark42/app/locales/fa.json new file mode 100644 index 00000000..24f8b29e --- /dev/null +++ b/frontend/apps/remark42/app/locales/fa.json @@ -0,0 +1,182 @@ +{ + "auth.back": "بازگشت", + "auth.email-address": "آدرس ایمیل", + "auth.loading": "در حال بارگذاری...", + "auth.oauth-button": "ورود با {provider}", + "auth.oauth-source": "استفاده از شبکه اجتماعی", + "auth.open-profile": "نمایش پروفایل من", + "auth.or": "یا", + "auth.signin": "ورود", + "auth.signout": "خروج", + "auth.submit": "ارسال", + "auth.symbols-restriction": "نام کاربری باید فقط شامل حروف، اعداد، زیرخط یا فضا باشد", + "auth.telegram-check": "بررسی", + "auth.telegram-link": "از طریق لینک", + "auth.telegram-message-1": "تلگرام را باز کنید", + "auth.telegram-message-2": "و در آنجا روی “شروع” کلیک کنید.", + "auth.telegram-message-3": "سپس، روی “بررسی” زیر کلیک کنید.", + "auth.telegram-optional-qr": "یا با اسکن کد QR", + "auth.telegram-qr": "کد QR تلگرام", + "auth.user-not-found": "هیچ کاربری پیدا نشد", + "auth.username": "نام کاربری", + "authPanel.disable-comments": "غیرفعال کردن نظرات", + "authPanel.disabled-cookies": "غیرفعال کردن مسدودسازی کوکی‌های شخص ثالث برای ورود یا باز کردن نظرات", + "authPanel.enable-comments": "فعال کردن نظرات", + "authPanel.enable-cookies": "اجازه دادن به کوکی‌ها برای ورود و نظر دادن", + "authPanel.hide-settings": "پنهان کردن تنظیمات", + "authPanel.new-page": "صفحه جدید", + "authPanel.read-only": "فقط خواندنی", + "authPanel.show-settings": "نمایش تنظیمات", + "blockingDuration.day": "برای یک روز", + "blockingDuration.month": "برای یک ماه", + "blockingDuration.permanently": "به طور دائمی", + "blockingDuration.week": "برای یک هفته", + "comment.block": "مسدود کردن", + "comment.block-user": "آیا می‌خواهید {userName} را {duration} مسدود کنید؟", + "comment.blocked-user": "مسدود شده", + "comment.blocking-period": "دوره مسدودسازی", + "comment.cancel": "لغو", + "comment.copied": "کپی شد!", + "comment.copy": "کپی", + "comment.delete": "حذف", + "comment.delete-message": "آیا می‌خواهید این نظر را حذف کنید؟", + "comment.deleted-comment": "این نظر حذف شد", + "comment.deleted-user": "حذف شده", + "comment.edit": "ویرایش", + "comment.edit-countdown": "ویرایش غیرفعال خواهد شد", + "comment.expired-time": "زمان ویرایش منقضی شده است.", + "comment.go-to-parent": "رفتن به نظر والد", + "comment.hide": "پنهان کردن", + "comment.hide-user-comment": "آیا می‌خواهید نظرات {userName} را پنهان کنید؟", + "comment.paid-patreon": "مشترک پرداختی پاترئون", + "comment.pin": "سنجاق کردن", + "comment.pin-comment": "آیا می‌خواهید این نظر را سنجاق کنید؟", + "comment.reply": "پاسخ", + "comment.time": "{day} در {time}", + "comment.toggle-verification": "تغییر وضعیت تأیید", + "comment.unblock": "رفع مسدودیت", + "comment.unblock-user": "آیا می‌خواهید این کاربر را رفع مسدود کنید؟", + "comment.unpin": "برداشتن سنجاق", + "comment.unpin-comment": "آیا می‌خواهید این نظر را از سنجاق بردارید؟", + "comment.unverified-user": "کاربر تأیید نشده", + "comment.unverify-user": "آیا می‌خواهید {userName} را تأیید نکنید؟", + "comment.verified-user": "کاربر تأیید شده", + "comment.verify-user": "آیا می‌خواهید {userName} را تأیید کنید؟", + "commentForm.anonymous-uploading-disabled": "بارگذاری تصویر برای کاربران ناشناس غیرفعال است. لطفاً به عنوان کاربر ناشناس وارد نشوید تا بتوانید تصاویر را پیوست کنید.", + "commentForm.exceeded-size": "{fileName} از حد مجاز اندازه {maxImageSize} فراتر رفته است", + "commentForm.input-placeholder": "نظر خود را وارد نمایید", + "commentForm.new-comment": "نظر جدید", + "commentForm.notice-about-styling": "استفاده از Markdown پشتیبانی می‌شود", + "commentForm.preview": "پیش‌نمایش", + "commentForm.reply": "پاسخ", + "commentForm.save": "ذخیره", + "commentForm.send": "ارسال", + "commentForm.subscribe-by": "مشترک شدن توسط", + "commentForm.subscribe-or": "یا", + "commentForm.unauthorized-uploading-disabled": "بارگذاری تصویر برای کاربران غیرمجاز غیرفعال است. شما باید قبل از بارگذاری وارد شوید.", + "commentForm.unexpected-error": "مشکلی پیش آمده است. لطفاً کمی بعد دوباره تلاش کنید.", + "commentForm.upload-file-fail": "{fileName} بارگذاری با خطای \"{errorMessage}\" ناموفق بود", + "commentForm.uploading": "در حال بارگذاری...", + "commentForm.uploading-file": "در حال بارگذاری {fileName}...", + "commentsSort.best": "بهترین", + "commentsSort.least-controversial": "کمترین جنجالی", + "commentsSort.least-recently-updated": "کمترین به‌روز شده", + "commentsSort.most-controversial": "بیشترین جنجالی", + "commentsSort.newest": "جدیدترین", + "commentsSort.oldest": "قدیمی‌ترین", + "commentsSort.recently-updated": "به تازگی به‌روز شده", + "commentsSort.worst": "بدترین", + "empty-state": "هنوز نظری وجود ندارد", + "errors.0": "مشکلی پیش آمده است. لطفاً کمی بعد دوباره تلاش کنید.", + "errors.1": "نظر پیدا نشد. لطفاً صفحه را تازه‌سازی کنید و دوباره تلاش کنید.", + "errors.10": "برای ویرایش نظر خیلی دیر شده است.", + "errors.11": "نظر قبلاً پاسخی دارد، ویرایش ممکن نیست.", + "errors.12": "نتیجه رأی‌گیری را نمی‌توان ذخیره کرد. لطفاً کمی بعد دوباره تلاش کنید.", + "errors.13": "شما نمی‌توانید برای نظر خود رأی دهید.", + "errors.14": "شما قبلاً برای این نظر رأی داده‌اید.", + "errors.15": "رأی‌های زیادی برای این نظر وجود دارد.", + "errors.16": "حداقل امتیاز برای نظر رسیده است.", + "errors.17": "عملیات رد شد. لطفاً کمی بعد دوباره تلاش کنید.", + "errors.18": "فایل درخواستی پیدا نشد.", + "errors.19": "نظر شامل کلمات ممنوعه است.", + "errors.2": "عدم موفقیت در تجزیه درخواست ورودی.", + "errors.20": "تصویر ارسال شده پیدا نشد. لطفاً دوباره آن را بارگذاری کنید.", + "errors.3": "شما اجازه انجام این عملیات را ندارید.", + "errors.4": "داده‌های نظر نامعتبر است.", + "errors.5": "نظر پیدا نشد. لطفاً صفحه را تازه‌سازی کنید و دوباره تلاش کنید.", + "errors.6": "سایت پیدا نشد. لطفاً صفحه را تازه‌سازی کنید و دوباره تلاش کنید.", + "errors.7": "کاربر مسدود شده است.", + "errors.8": "نمی‌توان نظرات را در این صفحه ارسال کرد. نظرات فقط خواندنی هستند.", + "errors.9": "تغییر نظر ناموفق بود. لطفاً کمی بعد دوباره تلاش کنید.", + "errors.conflict": "تعارض.", + "errors.failed-fetch": "عدم موفقیت در دریافت. لطفاً اتصال اینترنت خود را بررسی کنید یا کمی بعد دوباره تلاش کنید.", + "errors.forbidden": "ممنوع.", + "errors.not-authorized": "مجوز ندارید.", + "errors.to-many-request": "شما به حداکثر حد درخواست رسیده‌اید.", + "errors.unexpected-error": "مشکلی پیش آمده است.", + "profile.close": "بستن پروفایل", + "profile.request-to-delete-data": "درخواست حذف داده‌های من", + "retry": "دوباره تلاش کنید", + "root.pinned-comments": "نظرات سنجاق شده", + "root.powered-by": "توسعه داده شده توسط Remark42", + "root.show-more": "نمایش بیشتر", + "settings.block": "مسدود کردن", + "settings.block-time": "تا {day} در {time}", + "settings.block-user": "آیا می‌خواهید {userName} را مسدود کنید؟", + "settings.blocked-users-header": "کاربران مسدود شده:", + "settings.blocked-users-title": "کاربران مسدود شده", + "settings.hidden-user-header": "کاربران پنهان شده:", + "settings.hidden-users-title": "کاربران پنهان شده", + "settings.hide": "پنهان کردن", + "settings.no-blocked-users": "هیچ کاربر مسدود شده‌ای وجود ندارد.", + "settings.no-hidden-users": "هیچ کاربر پنهان شده‌ای وجود ندارد.", + "settings.permanently": "به طور دائمی", + "settings.show": "نمایش", + "settings.unblock": "رفع مسدودیت", + "settings.unblock-user": "آیا می‌خواهید {userName} را رفع مسدود کنید؟", + "settings.unknown": "ناشناس", + "sort-by": "مرتب‌سازی بر اساس", + "subscribeByEmail.back": "بازگشت", + "subscribeByEmail.close": "بستن", + "subscribeByEmail.email": "ایمیل", + "subscribeByEmail.have-been-subscribed": "شما به‌روزرسانی‌ها را از طریق ایمیل دریافت کرده‌اید", + "subscribeByEmail.have-been-unsubscribed": "شما از به‌روزرسانی‌های ایمیل حذف شده‌اید", + "subscribeByEmail.only-registered-users": "فقط برای کاربران ثبت‌نام شده در دسترس است", + "subscribeByEmail.submit": "ارسال", + "subscribeByEmail.subscribe": "مشترک شدن", + "subscribeByEmail.subscribe-by-email": "مشترک شدن از طریق ایمیل", + "subscribeByEmail.subscribe-to-replies": "مشترک شدن به پاسخ‌ها", + "subscribeByEmail.subscribed": "شما به‌روزرسانی‌ها را از طریق ایمیل دریافت کرده‌اید", + "subscribeByEmail.unsubscribe": "حذف اشتراک", + "subscribeByRSS.button-title": "مشترک شدن از طریق RSS", + "subscribeByRSS.replies": "پاسخ‌ها", + "subscribeByRSS.site": "سایت", + "subscribeByRSS.thread": "موضوع", + "subscribeByRSS.title": "RSS", + "subscribeByTelegram.have-been-subscribed": "شما به‌روزرسانی‌ها را از طریق تلگرام دریافت کرده‌اید", + "subscribeByTelegram.have-been-unsubscribed": "شما از به‌روزرسانی‌های تلگرام حذف شده‌اید", + "subscribeByTelegram.only-registered-users": "فقط برای کاربران ثبت‌نام شده در دسترس است", + "subscribeByTelegram.resubscribe": "دوباره مشترک شوید", + "subscribeByTelegram.subscribe-by-telegram": "مشترک شدن از طریق تلگرام", + "subscribeByTelegram.telegram": "تلگرام", + "subscribeByTelegram.unsubscribe": "حذف اشتراک", + "token": "توکن را از ایمیل کپی و پیست کنید", + "token.expired": "توکن منقضی شده است", + "token.invalid": "توکن نامعتبر است", + "toolbar.attach-image": "تصویر را پیوست کنید، بکشید و رها کنید یا از کلیپ بورد پیست کنید", + "toolbar.bold": "متن پررنگ را اضافه کنید {shortcut}", + "toolbar.code": "کد را وارد کنید", + "toolbar.header": "متن عنوان را اضافه کنید", + "toolbar.italic": "متن کج را اضافه کنید {shortcut}", + "toolbar.link": "لینک را اضافه کنید {shortcut}", + "toolbar.ordered-list": "لیست شماره‌دار را اضافه کنید", + "toolbar.quote": "نقل قول را وارد کنید", + "toolbar.unordered-list": "لیست گلوله‌دار را اضافه کنید", + "user.comments": "نظرات", + "user.load-more": "بیشتر بارگذاری کنید", + "user.my-comments": "نظرات من", + "vote.controversy": "جنجال: {value}", + "vote.downvote": "رأی منفی", + "vote.score": "امتیاز رأی‌ها", + "vote.upvote": "رأی مثبت" +} diff --git a/frontend/apps/remark42/app/utils/loadLocale.ts b/frontend/apps/remark42/app/utils/loadLocale.ts index 404b63a0..585c41b0 100644 --- a/frontend/apps/remark42/app/utils/loadLocale.ts +++ b/frontend/apps/remark42/app/utils/loadLocale.ts @@ -55,9 +55,7 @@ export async function loadLocale(locale: string): Promise return import(/* webpackChunkName: "ar" */ '../locales/ar.json').then((res) => res.default).catch(() => enMessages); } if (locale === 'zh-tw') { - return import(/* webpackChunkName: "zh-tw" */ '../locales/zh-tw.json') - .then((res) => res.default) - .catch(() => enMessages); + return import(/* webpackChunkName: "zh-tw" */ '../locales/zh-tw.json').then((res) => res.default).catch(() => enMessages); } if (locale === 'th') { return import(/* webpackChunkName: "th" */ '../locales/th.json').then((res) => res.default).catch(() => enMessages); @@ -65,6 +63,9 @@ export async function loadLocale(locale: string): Promise if (locale === 'cs') { return import(/* webpackChunkName: "cs" */ '../locales/cs.json').then((res) => res.default).catch(() => enMessages); } + if (locale === 'fa') { + return import(/* webpackChunkName: "fa" */ '../locales/fa.json').then((res) => res.default).catch(() => enMessages); + } return enMessages; } diff --git a/frontend/apps/remark42/codecov.yml b/frontend/apps/remark42/codecov.yml index 86b27115..d8ec974d 100644 --- a/frontend/apps/remark42/codecov.yml +++ b/frontend/apps/remark42/codecov.yml @@ -1,6 +1,5 @@ codecov: - notify: - require_ci_to_pass: false + require_ci_to_pass: false ignore: - .editorconfig diff --git a/frontend/apps/remark42/package.json b/frontend/apps/remark42/package.json index 461079a5..a8558da7 100644 --- a/frontend/apps/remark42/package.json +++ b/frontend/apps/remark42/package.json @@ -75,7 +75,6 @@ "babel-loader": "^8.2.5", "babel-plugin-jsx-remove-data-test-id": "^3.0.0", "clean-webpack-plugin": "^4.0.0", - "codecov": "^3.8.3", "copy-webpack-plugin": "^12.0.2", "cross-env": "^7.0.3", "css-loader": "^6.7.1", diff --git a/frontend/apps/remark42/tasks/supportedLocales.json b/frontend/apps/remark42/tasks/supportedLocales.json index c57b8278..cd8284d2 100644 --- a/frontend/apps/remark42/tasks/supportedLocales.json +++ b/frontend/apps/remark42/tasks/supportedLocales.json @@ -1 +1 @@ -["en", "ru", "de", "fi", "es", "zh", "tr", "bg", "ua", "pl", "vi", "be", "fr", "ja", "ko", "bp", "it", "ar", "zh-tw", "th", "cs"] +["en", "ru", "de", "fi", "es", "zh", "tr", "bg", "ua", "pl", "vi", "be", "fr", "ja", "ko", "bp", "it", "ar", "zh-tw", "th", "cs", "fa"] diff --git a/frontend/pnpm-lock.yaml b/frontend/pnpm-lock.yaml index da903995..41c203e9 100644 --- a/frontend/pnpm-lock.yaml +++ b/frontend/pnpm-lock.yaml @@ -50,7 +50,6 @@ importers: bem-react-helper: ^1.2.2 clean-webpack-plugin: ^4.0.0 clsx: ^1.1.1 - codecov: ^3.8.3 copy-webpack-plugin: ^12.0.2 core-js: ^3.23.3 cross-env: ^7.0.3 @@ -163,7 +162,6 @@ importers: babel-loader: 8.2.5_fswvdo7jykdwhfxrdcvghfn6pa babel-plugin-jsx-remove-data-test-id: 3.0.0_@babel+core@7.18.6 clean-webpack-plugin: 4.0.0_webpack@5.73.0 - codecov: 3.8.3 copy-webpack-plugin: 12.0.2_webpack@5.73.0 cross-env: 7.0.3 css-loader: 6.7.1_webpack@5.73.0 @@ -2652,11 +2650,6 @@ packages: preact: 10.6.2 dev: true - /@tootallnate/once/1.1.2: - resolution: {integrity: sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==} - engines: {node: '>= 6'} - dev: true - /@tootallnate/once/2.0.0: resolution: {integrity: sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A==} engines: {node: '>= 10'} @@ -3694,11 +3687,6 @@ packages: resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==} dev: true - /argv/0.0.2: - resolution: {integrity: sha512-dEamhpPEwRUBpLNHeuCm/v+g0anFByHahxodVO/BbAarHVBBg2MccCwf9K+o1Pof+2btdnkJelYVUWjW/VrATw==} - engines: {node: '>=0.6.10'} - dev: true - /aria-query/4.2.2: resolution: {integrity: sha512-o/HelwhuKpTj/frsOsbNLNgnNGVIFsVP/SW2BSF14gVl7kAfMOJ6/8wUAUvG1R1NHKrfG+2sHZTu0yauT1qBrA==} engines: {node: '>=6.0'} @@ -4427,22 +4415,6 @@ packages: engines: {iojs: '>= 1.0.0', node: '>= 0.12.0'} dev: true - /codecov/3.8.3: - resolution: {integrity: sha512-Y8Hw+V3HgR7V71xWH2vQ9lyS358CbGCldWlJFR0JirqoGtOoas3R3/OclRTvgUYFK29mmJICDPauVKmpqbwhOA==} - engines: {node: '>=4.0'} - deprecated: https://about.codecov.io/blog/codecov-uploader-deprecation-plan/ - hasBin: true - dependencies: - argv: 0.0.2 - ignore-walk: 3.0.4 - js-yaml: 3.14.1 - teeny-request: 7.1.1 - urlgrey: 1.0.0 - transitivePeerDependencies: - - encoding - - supports-color - dev: true - /collect-v8-coverage/1.0.1: resolution: {integrity: sha512-iBPtljfCNcTKNAto0KEtDfZ3qzjJvqE3aTGZsbhjSBlorqpXJlaWWtPO35D+ZImoC3KWejX64o+yPGxhWSTzfg==} dev: true @@ -6143,12 +6115,6 @@ packages: resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} dev: true - /fast-url-parser/1.1.3: - resolution: {integrity: sha512-5jOCVXADYNuRkKFzNJ0dCCewsZiYo0dz8QNYljkOpFC6r2U4OBmKtvm/Tsuh4w1YYdDqDb31a8TVhBJ2OJKdqQ==} - dependencies: - punycode: 1.4.1 - dev: true - /fastest-levenshtein/1.0.12: resolution: {integrity: sha512-On2N+BpYJ15xIC974QNVuYGMOlEVt4s0EOI3wwMqOmK1fdDY+FN/zltPV8vosq4ad4c/gJ1KHScUn/6AWIgiow==} dev: true @@ -6728,17 +6694,6 @@ packages: resolution: {integrity: sha512-SGeBX54F94Wgu5RH3X5jsDtf4eHyRogWX1XGT3b4HuW3tQPM4AaBzoUji/4AAJNXCEOWZ5O0DgZmJw1947gD5Q==} dev: true - /http-proxy-agent/4.0.1: - resolution: {integrity: sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==} - engines: {node: '>= 6'} - dependencies: - '@tootallnate/once': 1.1.2 - agent-base: 6.0.2 - debug: 4.3.4 - transitivePeerDependencies: - - supports-color - dev: true - /http-proxy-agent/5.0.0: resolution: {integrity: sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==} engines: {node: '>= 6'} @@ -6840,12 +6795,6 @@ packages: resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} dev: true - /ignore-walk/3.0.4: - resolution: {integrity: sha512-PY6Ii8o1jMRA1z4F2hRkH/xN59ox43DavKvD3oDpfurRlOJyAHpifIwpbdv1n4jt4ov0jSpw3kQ4GhJnpBL6WQ==} - dependencies: - minimatch: 3.1.2 - dev: true - /ignore/5.2.0: resolution: {integrity: sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ==} engines: {node: '>= 4'} @@ -9912,10 +9861,6 @@ packages: resolution: {integrity: sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==} dev: true - /punycode/1.4.1: - resolution: {integrity: sha512-jmYNElW7yvO7TV33CjSmvSiE2yco3bV2czu/OzDKdMNVZQWfxCblURLhf+47syQRBntjfLdd/H0egrzIG+oaFQ==} - dev: true - /punycode/2.1.1: resolution: {integrity: sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==} engines: {node: '>=6'} @@ -10739,12 +10684,6 @@ packages: engines: {node: '>= 0.8'} dev: true - /stream-events/1.0.5: - resolution: {integrity: sha512-E1GUzBSgvct8Jsb3v2X15pjzN1tYebtbLaMg+eBOUOAxgbLoSbT2NS91ckc5lJD1KfLjId+jXJRgo0qnV5Nerg==} - dependencies: - stubs: 3.0.0 - dev: true - /strict-event-emitter/0.2.4: resolution: {integrity: sha512-xIqTLS5azUH1djSUsLH9DbP6UnM/nI18vu8d43JigCQEoVsnY+mrlE+qv6kYqs6/1OkMnMIiL6ffedQSZStuoQ==} dependencies: @@ -10891,10 +10830,6 @@ packages: engines: {node: '>=8'} dev: true - /stubs/3.0.0: - resolution: {integrity: sha512-PdHt7hHUJKxvTCgbKX9C1V/ftOcjJQgz8BZwNfV5c4B6dcGqlpelTbJ999jBGZ2jYiPAwcX5dP6oBwVlBlUbxw==} - dev: true - /style-loader/3.3.1_webpack@5.73.0: resolution: {integrity: sha512-GPcQ+LDJbrcxHORTRes6Jy2sfvK2kS6hpSfI/fXhPt+spVzxF6LJ1dHLN9zIGmVaaP044YKaIatFaufENRiDoQ==} engines: {node: '>= 12.13.0'} @@ -11078,20 +11013,6 @@ packages: engines: {node: '>=6'} dev: true - /teeny-request/7.1.1: - resolution: {integrity: sha512-iwY6rkW5DDGq8hE2YgNQlKbptYpY5Nn2xecjQiNjOXWbKzPGUfmeUBCSQbbr306d7Z7U2N0TPl+/SwYRfua1Dg==} - engines: {node: '>=10'} - dependencies: - http-proxy-agent: 4.0.1 - https-proxy-agent: 5.0.1 - node-fetch: 2.6.7 - stream-events: 1.0.5 - uuid: 8.3.2 - transitivePeerDependencies: - - encoding - - supports-color - dev: true - /terminal-link/2.1.1: resolution: {integrity: sha512-un0FmiRUQNr5PJqy9kP7c40F5BOfpGlYTrxonDChEZB7pzZxRNp/bt+ymiy9/npwXya9KH99nJ/GXFIiUkYGFQ==} engines: {node: '>=8'} @@ -11653,12 +11574,6 @@ packages: webpack: 5.73.0_323cogk7mrkhphrh6zdbuggp4a dev: true - /urlgrey/1.0.0: - resolution: {integrity: sha512-hJfIzMPJmI9IlLkby8QrsCykQ+SXDeO2W5Q9QTW3QpqZVTx4a/K7p8/5q+/isD8vsbVaFgql/gvAoQCRQ2Cb5w==} - dependencies: - fast-url-parser: 1.1.3 - dev: true - /use-sync-external-store/1.2.0_@preact+compat@17.1.1: resolution: {integrity: sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==} peerDependencies: diff --git a/site/Dockerfile b/site/Dockerfile index 9dd161ea..ed71aad3 100644 --- a/site/Dockerfile +++ b/site/Dockerfile @@ -1,4 +1,4 @@ -FROM node:20-alpine as build +FROM node:20-alpine AS build WORKDIR /site COPY ./ /site diff --git a/site/Dockerfile.dev b/site/Dockerfile.dev index 80e3db41..92174656 100644 --- a/site/Dockerfile.dev +++ b/site/Dockerfile.dev @@ -1,4 +1,4 @@ -FROM node:20-alpine as build +FROM node:20-alpine AS build WORKDIR /site COPY ./ /site diff --git a/site/README.md b/site/README.md index 289c1414..813b2558 100644 --- a/site/README.md +++ b/site/README.md @@ -29,8 +29,8 @@ yarn build Install dependencies and run development server inside Docker: ```shell -docker-compose build -docker-compose up server +docker compose build +docker compose up server ``` Then serve files from `./build` with your favorite server @@ -38,7 +38,7 @@ Then serve files from `./build` with your favorite server ### Development ```shell -docker-compose up --build server +docker compose up --build server ``` Then head to http://localhost:8080 diff --git a/site/package.json b/site/package.json index 0894cb99..e23a5327 100644 --- a/site/package.json +++ b/site/package.json @@ -21,18 +21,18 @@ "clean": "rm -rf .tmp/* build/*" }, "devDependencies": { - "@11ty/eleventy": "^2.0.1", + "@11ty/eleventy": "^3.0.0", "@11ty/eleventy-plugin-syntaxhighlight": "^5.0.0", - "@tailwindcss/typography": "^0.5.10", + "@tailwindcss/typography": "^0.5.15", "cross-env": "^7.0.3", - "date-fns": "^3.3.1", + "date-fns": "^4.1.0", "html-minifier": "^4.0.0", "markdown-it": "^14.0.0", - "markdown-it-anchor": "^8.4.1", + "markdown-it-anchor": "^9.2.0", "markdown-it-container": "^4.0.0", "node-fetch": "^3.3.2", "npm-run-all": "^4.1.5", - "prettier": "^2.8.8", - "tailwindcss": "^3.4.1" + "prettier": "^3.3.3", + "tailwindcss": "^3.4.14" } } diff --git a/site/src/docs/configuration/authorization/index.md b/site/src/docs/configuration/authorization/index.md index c148ab31..244019b6 100644 --- a/site/src/docs/configuration/authorization/index.md +++ b/site/src/docs/configuration/authorization/index.md @@ -83,15 +83,6 @@ _instructions for Google OAuth2 setup borrowed from [oauth2_proxy](https://githu 4. Choose the new project from the top right project dropdown (only if another project is selected) 5. Select **"Certificates & secrets"** and click on **"+ New Client Secret"** (`AUTH_MICROSOFT_CSEC`) -### Twitter - -> **Important**: Twitter developer accounts created after _November 15th 2021_ need "Elevated access" to use the Standard v1.1 API routes required to work properly. Apply for this access from within the Twitter developer portal. - -1. Create a new Twitter application https://developer.twitter.com/en/apps -2. Fill **App name**, **Description** and **URL** of your site -3. In the field **Callback URLs** enter the correct URL of your callback handler, e.g. domain + `/auth/twitter/callback` -4. Under **Key and tokens** take note of the **Consumer API Key** and **Consumer API Secret key**. Those will be used as `AUTH_TWITTER_CID` and `AUTH_TWITTER_CSEC` - ### Yandex 1. Create a new **"OAuth App"**: https://oauth.yandex.com/client/new diff --git a/site/src/docs/configuration/email/index.md b/site/src/docs/configuration/email/index.md index 94c50135..471c9083 100644 --- a/site/src/docs/configuration/email/index.md +++ b/site/src/docs/configuration/email/index.md @@ -14,7 +14,7 @@ This documentation describes how to enable the email-related capabilities of Rem - email notifications for any users except anonymous: - GitHub or Google or Twitter or any other kind of user gets the ability to get email notifications about new replies to their comments (and any of the responses down the tree): + GitHub or Google or any other kind of user gets the ability to get email notifications about new replies to their comments (and any of the responses down the tree): ![Email notifications subscription](images/email_notifications.png) @@ -201,7 +201,7 @@ Now we have the following templates: - `email_unsubscribe.html.tmpl` – used for notification about successful unsubscribing from replies - `error_response.html.tmpl` – used for HTML errors -To replace any template, add the file with the same name to the directory with the remark42 executable file. In case you run Remark42 inside docker-compose, you can put customised templates into a directory like `customised_templates` and then mount it like that: +To replace any template, add the file with the same name to the directory with the remark42 executable file. In case you run Remark42 inside Docker Compose, you can put customised templates into a directory like `customised_templates` and then mount it like that: ```yaml volumes: diff --git a/site/src/docs/configuration/frontend/index.md b/site/src/docs/configuration/frontend/index.md index 2887d083..7720ee37 100644 --- a/site/src/docs/configuration/frontend/index.md +++ b/site/src/docs/configuration/frontend/index.md @@ -30,7 +30,7 @@ Example with all of the params: var remark_config = { host: 'https://remark42.example.com', site_id: 'my_site', - components: ['embed', 'last-comments'] + components: ['embed', 'last-comments'], max_shown_comments: 100, theme: 'dark', page_title: 'My custom title for a page', diff --git a/site/src/docs/configuration/parameters/index.md b/site/src/docs/configuration/parameters/index.md index d95d055b..af4e34a3 100644 --- a/site/src/docs/configuration/parameters/index.md +++ b/site/src/docs/configuration/parameters/index.md @@ -93,8 +93,6 @@ services: | auth.microsoft.csec | AUTH_MICROSOFT_CSEC | | Microsoft OAuth client secret | | auth.github.cid | AUTH_GITHUB_CID | | GitHub OAuth client ID | | auth.github.csec | AUTH_GITHUB_CSEC | | GitHub OAuth client secret | -| auth.twitter.cid | AUTH_TWITTER_CID | | Twitter Consumer API Key | -| auth.twitter.csec | AUTH_TWITTER_CSEC | | Twitter Consumer API Secret key | | auth.patreon.cid | AUTH_PATREON_CID | | Patreon OAuth Client ID | | auth.patreon.csec | AUTH_PATREON_CSEC | | Patreon OAuth Client Secret | | auth.discord.cid | AUTH_DISCORD_CID | | Discord OAuth Client ID | @@ -156,7 +154,7 @@ services: | emoji | EMOJI | `false` | enable emoji support | | simple-view | SIMPLE_VIEW | `false` | minimized UI with basic info only | | proxy-cors | PROXY_CORS | `false` | disable internal CORS and delegate it to proxy | -| allowed-hosts | ALLOWED_HOSTS | enable all | limit hosts/sources allowed to embed comments | +| allowed-hosts | ALLOWED_HOSTS | enable all | limit hosts/sources allowed to embed comments via CSP 'frame-ancestors' | | address | REMARK_ADDRESS | all interfaces | web server listening address | | port | REMARK_PORT | `8080` | web server port | | web-root | REMARK_WEB_ROOT | `./web` | web server root directory | @@ -192,6 +190,8 @@ The following list of command-line options is deprecated and might be removed in | notify.email.notify_admin | notify.admins=email | NOTIFY_EMAIL_ADMIN | NOTIFY_ADMINS=email | | | 1.9.0 | | notify.telegram.token | telegram.token | NOTIFY_TELEGRAM_TOKEN | TELEGRAM_TOKEN | | Telegram token | 1.9.0 | | notify.telegram.timeout | telegram.timeout | NOTIFY_TELEGRAM_TIMEOUT | TELEGRAM_TIMEOUT | | Telegram timeout | 1.9.0 | +| auth.twitter.cid | none | AUTH_TWITTER_CID | none | | Twitter Consumer API Key | 1.14.0 | | +| auth.twitter.csec | none | AUTH_TWITTER_CSEC | none | | Twitter Consumer API Secret key | 1.14.0 | | diff --git a/site/src/docs/contributing/backend/index.md b/site/src/docs/contributing/backend/index.md index 00f7eee4..694e8b9a 100644 --- a/site/src/docs/contributing/backend/index.md +++ b/site/src/docs/contributing/backend/index.md @@ -11,7 +11,7 @@ cp compose-dev-backend.yml compose-private.yml # now, edit / debug `compose-private.yml` to your heart's content # build and run -docker-compose -f compose-private.yml up --build +docker compose -f compose-private.yml up --build ``` It starts Remark42 on `127.0.0.1:8080` and adds local OAuth2 provider "Dev". To access the UI demo page go to . By default, you would be logged in as `dev_user`, defined as admin. You can tweak any of the [supported parameters](https://remark42.com/docs/configuration/parameters/) in corresponded yml file. diff --git a/site/src/docs/contributing/frontend/index.md b/site/src/docs/contributing/frontend/index.md index 323b78d8..ae9e35eb 100644 --- a/site/src/docs/contributing/frontend/index.md +++ b/site/src/docs/contributing/frontend/index.md @@ -59,7 +59,7 @@ cp compose-dev-frontend.yml compose-private.yml # now, edit / debug `compose-private.yml` to your heart's content # build and run -docker-compose -f compose-private.yml up --build +docker compose -f compose-private.yml up --build ``` Then in the new terminal tab or window, run the following to start the frontend with Hot Reloading: @@ -78,7 +78,7 @@ It starts Remark42 backend on `127.0.0.1:8080` and adds local OAuth2 provider "D Frontend Docker Compose config (`compose-dev-frontend.yml`) by default skips running backend related tests. ::: note 🚨 -Before submitting your changes as a Pull Request, run the backend using the `docker-compose -f compose-dev-frontend.yml build --build-arg SKIP_FRONTEND_BUILD=""; docker-compose -f compose-private.yml up` command and test your changes against , frontend, built statically (unlike frontend on port 9000, which runs dynamically). That is how Remark42 authors will test your changes once you submit them. +Before submitting your changes as a Pull Request, run the backend using the `docker compose -f compose-dev-frontend.yml build --build-arg SKIP_FRONTEND_BUILD=""; docker compose -f compose-private.yml up` command and test your changes against , frontend, built statically (unlike frontend on port 9000, which runs dynamically). That is how Remark42 authors will test your changes once you submit them. ::: ## Static build diff --git a/site/src/docs/contributing/translations/index.md b/site/src/docs/contributing/translations/index.md index 9827e26a..08966dfe 100644 --- a/site/src/docs/contributing/translations/index.md +++ b/site/src/docs/contributing/translations/index.md @@ -41,7 +41,7 @@ below to have your translation available to all remark42 users and included in t 1. Uncomment `locale: "ru"` line in [frontend/apps/remark42/templates/demo.ejs](https://github.com/umputun/remark42/blob/master/frontend/apps/remark42/templates/demo.ejs) and replace `ru` with your translation language code 2. [Run remark42 in Docker](https://github.com/umputun/remark42#development) by issuing the following commands from the root directory of your remark42 fork: - `shell docker-compose -f compose-dev-frontend.yml build docker-compose -f compose-dev-frontend.yml up ` + `shell docker compose -f compose-dev-frontend.yml build docker compose -f compose-dev-frontend.yml up ` 3. open , log in, make a comment, make a reply to a comment, and make sure your translation looks as you expect it to look 4. make a screenshot from with your translation in place diff --git a/site/src/docs/getting-started/installation/index.md b/site/src/docs/getting-started/installation/index.md index 63f385fc..cac1f149 100644 --- a/site/src/docs/getting-started/installation/index.md +++ b/site/src/docs/getting-started/installation/index.md @@ -10,8 +10,8 @@ _This is the recommended way to run Remark42_ - copy provided [`docker-compose.yml`](https://github.com/umputun/remark42/blob/master/docker-compose.yml) and customize for your needs - make sure you **don't keep** `ADMIN_PASSWD=something...` for any non-development deployments -- pull prepared images from the Docker Hub and start - `docker-compose pull && docker-compose up -d` -- alternatively, compile from the sources - `docker-compose build && docker-compose up -d` +- pull prepared images from the Docker Hub and start - `docker compose pull && docker compose up -d` +- alternatively, compile from the sources - `docker compose build && docker compose up -d` ### Installation with Binary diff --git a/site/src/docs/manuals/reproxy/index.md b/site/src/docs/manuals/reproxy/index.md index 3e9f71fb..64086d0d 100644 --- a/site/src/docs/manuals/reproxy/index.md +++ b/site/src/docs/manuals/reproxy/index.md @@ -4,7 +4,7 @@ title: Configure with Reproxy ## How to configure remark42 with [Reproxy](https://reproxy.io) -Example of Reproxy configuration (reverse proxy) running remark42 service on remark42.example.com with docker compose. Reproxy handles SSL termination with LE and gzip all the responses. +Example of Reproxy configuration (reverse proxy) running remark42 service on remark42.example.com with Docker Compose. Reproxy handles SSL termination with LE and gzip all the responses. ```yaml version: "3.4" diff --git a/site/src/docs/manuals/separate-domain/index.md b/site/src/docs/manuals/separate-domain/index.md index 83815f90..28cee01b 100644 --- a/site/src/docs/manuals/separate-domain/index.md +++ b/site/src/docs/manuals/separate-domain/index.md @@ -10,17 +10,19 @@ Unless discussion [#1139](https://github.com/umputun/remark42/discussions/1139) ### Setup -Set `ALLOWED_HOSTS='self',example1.org,example2.org` with your domain names and `AUTH_SAME_SITE=none`. The `'self'` value means "domain which Remark42 is installed on" so you don't need to write it twice. +Set `ALLOWED_HOSTS="'self',example1.org,example2.org"` with your domain names and `AUTH_SAME_SITE=none`. + +The `'self'` in `ALLOWED_HOSTS` value means "domain where Remark42 is installed on" and needed if you want `remark42.example.com/web/` to work in case you want to test something with it. ### Technical details -`ALLOWED_HOSTS` sets CSP [frame-ancestors](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/frame-ancestors), which, once enabled, limits the domains where Remark42 would work. The default value is not set so that it would work on any domain. +`ALLOWED_HOSTS` sets CSP [frame-ancestors](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/frame-ancestors), which, once enabled, limits the domains where Remark42 would work. The default value is `*` so that it would work on any domain`. -`AUTH_SAME_SITE` sets the [SAME_SITE](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie/SameSite) attribute for authorisation cookies, allowing Remark42 either on the original domain and subdomains there (default value, not set which equals to `Lax`) or allows setting authorisation cookies on any domain where remark42 is shown (`None` setting). +`AUTH_SAME_SITE` sets the [SAME_SITE](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie/SameSite) attribute for authorisation cookies, allowing Remark42 either on the original domain and subdomains there (default value, which equals to `Lax`) or allows setting authorisation cookies on any domain where remark42 is shown (`None` setting). Here are all possible combinations of these two: -- Default setup with unaltered variables: comments are shown on any domain, but the authorisation wouldn't work anywhere, but on the same domain Remark42 is installed on and subdomains of it. -- `ALLOWED_HOSTS` set to a set of domains: comments are shown only on listed domains, authorisation wouldn't work anywhere, but on the same domain Remark42 is installed on and subdomains of it. +- Default setup with unaltered variables: comments are shown on any domain, but the authorisation wouldn't work anywhere, except on the same domain Remark42 is installed on and subdomains of it. +- `ALLOWED_HOSTS` set to a set of domains: comments are shown only on listed domains, and authorisation wouldn't work anywhere, expect on the same domain Remark42 is installed on and subdomains of it. - `AUTH_SAME_SITE` set to `None`: comments are shown on any domain. The authorisation would work anywhere. - `ALLOWED_HOSTS` set to a set of domains and `AUTH_SAME_SITE` set to `None`: comments are shown on listed domains. The authorisation would work on all of them. diff --git a/site/src/docs/manuals/subdomain/index.md b/site/src/docs/manuals/subdomain/index.md index 7c4e9917..91010770 100644 --- a/site/src/docs/manuals/subdomain/index.md +++ b/site/src/docs/manuals/subdomain/index.md @@ -8,16 +8,16 @@ All documentation examples show configurations with remark42 on its own subdomai - The frontend URL looks like this: `s.src = 'https://example.com/remark42/web/embed.js;` -- The backend `REMARK_URL` parameter will be `https://example.com/remark42` +- The backend `REMARK_URL` parameter will be `https://example.com/remark42`. `ALLOWED_HOSTS="'self'"` and `AUTH_SAME_SITE=strict` to make comments work only from the same domain. -- And you also need to slightly modify the callback URL for the social media login API's: +- And you also need to slightly modify the callback URL for the social media login APIs: - Facebook Valid OAuth Redirect URIs: `https://example.com/remark42/auth/facebook/callback` - Google Authorized redirect URIs: `https://example.com/remark42/auth/google/callback` - GitHub Authorised callback URL: `https://example.com/remark42/auth/github/callback` -### docker-compose configuration +### Docker Compose configuration -Both Nginx and Caddy configuration below rely on remark42 available on hostname `remark42`, which is achieved by having `container_name: remark42` in docker-compose. +Both Nginx and Caddy configuration below rely on remark42 available on hostname `remark42`, which is achieved by having `container_name: remark42` in Docker Compose configuration file. Example `docker-compose.yml`: diff --git a/site/src/pages/index.md b/site/src/pages/index.md index 698fe050..1a7af722 100644 --- a/site/src/pages/index.md +++ b/site/src/pages/index.md @@ -8,7 +8,7 @@ title: Remark42 – Privacy-focused lightweight commenting engine Remark42 allows you to have a self-hosted, lightweight, and simple (yet functional) comment engine, which doesn't spy on users. It can be embedded into blogs, articles or any other place where readers add comments. -- Social login via Google, Twitter, Facebook, Microsoft, GitHub, Apple, Yandex, Patreon and Telegram +- Social login via Google, Facebook, Microsoft, GitHub, Apple, Yandex, Patreon and Telegram - Login via email - Optional anonymous access - Multi-level nested comments with both tree and plain presentations diff --git a/site/yarn.lock b/site/yarn.lock index 43fdf46f..b08d577a 100644 --- a/site/yarn.lock +++ b/site/yarn.lock @@ -2,27 +2,49 @@ # yarn lockfile v1 -"@11ty/dependency-tree@^2.0.1": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@11ty/dependency-tree/-/dependency-tree-2.0.1.tgz#b3c8fa6c91c4a29257e70dd19d26cca75cde89d2" - integrity sha512-5R+DsT9LJ9tXiSQ4y+KLFppCkQyXhzAm1AIuBWE/sbU0hSXY5pkhoqQYEcPJQFg/nglL+wD55iv2j+7O96UAvg== - -"@11ty/eleventy-dev-server@^1.0.4": - version "1.0.4" - resolved "https://registry.yarnpkg.com/@11ty/eleventy-dev-server/-/eleventy-dev-server-1.0.4.tgz#87c2cf182ed22f90ac2793e1e1337a0d9e32b318" - integrity sha512-qVBmV2G1KF/0o5B/3fITlrrDHy4bONUI2YuN3/WJ3BNw4NU1d/we8XhKrlgq13nNvHoBx5czYp3LZt8qRG53Fg== +"@11ty/dependency-tree-esm@^1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@11ty/dependency-tree-esm/-/dependency-tree-esm-1.0.0.tgz#de6e0a94b8f26f6126925eacd88f993fc406935d" + integrity sha512-Z3KN1Fkv50UM/ZzTR3VBbyOY52HnmhIVCsAV1hn2UzFsGAjyF1Cw8uohhVtheDOSuBR7ZSeo1unwkz1HxFlUtQ== dependencies: - "@11ty/eleventy-utils" "^1.0.1" - chokidar "^3.5.3" - debug "^4.3.4" + "@11ty/eleventy-utils" "^1.0.2" + acorn "^8.10.0" + dependency-graph "^0.11.0" + normalize-path "^3.0.0" + +"@11ty/dependency-tree@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@11ty/dependency-tree/-/dependency-tree-3.0.1.tgz#e165fbf0cc62a21fbfccff293b3b467d2464d964" + integrity sha512-aZizxcL4Z/clm3KPRx8i9ohW9R2gLssXfUSy7qQmQRXb4CUOyvmqk2gKeJqRmXIfMi2bB9w03SgtN5v1YwqpiA== + dependencies: + "@11ty/eleventy-utils" "^1.0.2" + +"@11ty/eleventy-dev-server@^2.0.4": + version "2.0.4" + resolved "https://registry.yarnpkg.com/@11ty/eleventy-dev-server/-/eleventy-dev-server-2.0.4.tgz#acd48f4007d0e2103098de77ed5c4710e1d7cc08" + integrity sha512-d0CuufX6yPtVz+RW0oJZg1pVoxo1jOrPmpXYacoiKLJm0MMC9MkPQOCXlimguHVaceHejFo5+aZB9/aGB2RR0A== + dependencies: + "@11ty/eleventy-utils" "^1.0.3" + chokidar "^3.6.0" + debug "^4.3.7" dev-ip "^1.0.1" - finalhandler "^1.2.0" + finalhandler "^1.3.0" mime "^3.0.0" minimist "^1.2.8" - morphdom "^2.7.0" + morphdom "^2.7.4" please-upgrade-node "^3.2.0" - ssri "^8.0.1" - ws "^8.13.0" + send "^0.19.0" + ssri "^11.0.0" + urlpattern-polyfill "^10.0.0" + ws "^8.18.0" + +"@11ty/eleventy-plugin-bundle@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@11ty/eleventy-plugin-bundle/-/eleventy-plugin-bundle-3.0.0.tgz#e2c5930a1f73d53fdab6f200c8d91651d12d3e48" + integrity sha512-JSnqehT+sWSPi6e44jTXUW+KiV9284YF9fzPQvfGB4cXlk/m/SJk17CavHCleIvKXDN+jrUw9TZkwAwr85ONWQ== + dependencies: + debug "^4.3.4" + posthtml-match-helper "^2.0.2" "@11ty/eleventy-plugin-syntaxhighlight@^5.0.0": version "5.0.0" @@ -31,55 +53,55 @@ dependencies: prismjs "^1.29.0" -"@11ty/eleventy-utils@^1.0.1": - version "1.0.2" - resolved "https://registry.yarnpkg.com/@11ty/eleventy-utils/-/eleventy-utils-1.0.2.tgz#a936338385c83e7ce61438d08c85830db8c5c648" - integrity sha512-Zy2leMK1DQR6Q6ZPSagv7QpJaAz9uVbb+RmVetYFp3foMeQtOSZx7w2u5daRFmP+PeNq9vO9H4xtBToYFWZwHA== +"@11ty/eleventy-utils@^1.0.2", "@11ty/eleventy-utils@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@11ty/eleventy-utils/-/eleventy-utils-1.0.3.tgz#fb70305aed2499eba93b7d1d31de045efe3997fa" + integrity sha512-nULO91om7vQw4Y/UBjM8i7nJ1xl+/nyK4rImZ41lFxiY2d+XUz7ChAj1CDYFjrLZeu0utAYJTZ45LlcHTkUG4g== dependencies: normalize-path "^3.0.0" -"@11ty/eleventy@^2.0.1": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@11ty/eleventy/-/eleventy-2.0.1.tgz#d96104c401a83b59f69a207c96aa53ad42131b15" - integrity sha512-t8XVUbCJByhVEa1RzO0zS2QzbL3wPY8ot1yUw9noqiSHxJWUwv6jiwm1/MZDPTYtkZH2ZHvdQIRQ5/SjG9XmLw== +"@11ty/eleventy@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@11ty/eleventy/-/eleventy-3.0.0.tgz#a2eabcb0b55f3987d7687f4446e7294e6195476e" + integrity sha512-0P0ZsJXVW2QiNdhd7z+GYy6n+ivh0enx1DRdua5ta6NlzY2AhbkeWBY6U+FKA8lPS3H4+XsTpfLLfIScpPZLaQ== dependencies: - "@11ty/dependency-tree" "^2.0.1" - "@11ty/eleventy-dev-server" "^1.0.4" - "@11ty/eleventy-utils" "^1.0.1" + "@11ty/dependency-tree" "^3.0.1" + "@11ty/dependency-tree-esm" "^1.0.0" + "@11ty/eleventy-dev-server" "^2.0.4" + "@11ty/eleventy-plugin-bundle" "^3.0.0" + "@11ty/eleventy-utils" "^1.0.3" "@11ty/lodash-custom" "^4.17.21" - "@iarna/toml" "^2.2.5" - "@sindresorhus/slugify" "^1.1.2" - bcp-47-normalize "^1.1.1" - chokidar "^3.5.3" + "@11ty/posthtml-urls" "^1.0.0" + "@11ty/recursive-copy" "^3.0.0" + "@sindresorhus/slugify" "^2.2.1" + bcp-47-normalize "^2.3.0" + chardet "^2.0.0" + chokidar "^3.6.0" cross-spawn "^7.0.3" - debug "^4.3.4" - dependency-graph "^0.11.0" - ejs "^3.1.9" - fast-glob "^3.2.12" + debug "^4.3.7" + dependency-graph "^1.0.0" + entities "^5.0.0" + fast-glob "^3.3.2" + filesize "^10.1.6" graceful-fs "^4.2.11" gray-matter "^4.0.3" - hamljs "^0.6.2" - handlebars "^4.7.7" is-glob "^4.0.3" - iso-639-1 "^2.1.15" + iso-639-1 "^3.1.3" + js-yaml "^4.1.0" kleur "^4.1.5" - liquidjs "^10.7.0" - luxon "^3.3.0" - markdown-it "^13.0.1" - micromatch "^4.0.5" + liquidjs "^10.17.0" + luxon "^3.5.0" + markdown-it "^14.1.0" + micromatch "^4.0.8" minimist "^1.2.8" moo "^0.5.2" - multimatch "^5.0.0" - mustache "^4.2.0" + node-retrieve-globals "^6.0.0" normalize-path "^3.0.0" - nunjucks "^3.2.3" - path-to-regexp "^6.2.1" + nunjucks "^3.2.4" please-upgrade-node "^3.2.0" posthtml "^0.16.6" - posthtml-urls "^1.0.0" - pug "^3.0.2" - recursive-copy "^2.0.14" - semver "^7.3.8" + posthtml-match-helper "^2.0.2" + semver "^7.6.3" slugify "^1.6.6" "@11ty/lodash-custom@^4.17.21": @@ -87,40 +109,37 @@ resolved "https://registry.yarnpkg.com/@11ty/lodash-custom/-/lodash-custom-4.17.21.tgz#a8d2e25a47ee3bb58b71cde4edc2ae8dd3d1b269" integrity sha512-Mqt6im1xpb1Ykn3nbcCovWXK3ggywRJa+IXIdoz4wIIK+cvozADH63lexcuPpGS/gJ6/m2JxyyXDyupkMr5DHw== +"@11ty/posthtml-urls@^1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@11ty/posthtml-urls/-/posthtml-urls-1.0.0.tgz#7848ac581d88aab1f841ba86a71d3058c32c3e19" + integrity sha512-CcsRdI933x613u7CjM+QGs7iD/m8SaDup3Apohg1+7dybigrEUHc2jGS3mcMgQKvF2+IphqmepD/FrKLlPkPEg== + dependencies: + evaluate-value "^2.0.0" + http-equiv-refresh "^2.0.1" + list-to-array "^1.1.0" + object.entries "^1.1.7" + parse-srcset "^1.0.2" + +"@11ty/recursive-copy@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@11ty/recursive-copy/-/recursive-copy-3.0.0.tgz#3dc6e3fac20d8f1d37b48c4757ae94e7311e662c" + integrity sha512-v1Mr7dWx5nk69/HRRtDHUYDV9N8+cE12IGiKSFOwML7HjOzUXwTP88e3cGuhqoVstkBil1ZEIaOB0KPP1zwqXA== + dependencies: + errno "^0.1.2" + graceful-fs "^4.2.11" + junk "^1.0.1" + maximatch "^0.1.0" + mkdirp "^3.0.1" + pify "^2.3.0" + promise "^7.0.1" + rimraf "^5.0.7" + slash "^1.0.0" + "@alloc/quick-lru@^5.2.0": version "5.2.0" resolved "https://registry.yarnpkg.com/@alloc/quick-lru/-/quick-lru-5.2.0.tgz#7bf68b20c0a350f936915fcae06f58e32007ce30" integrity sha512-UrcABB+4bUrFABwbluTIBErXwvbsU/V7TZWfmbgJfbkwiBuziS9gxdODUyuiecfdGQ85jglMW6juS3+z5TsKLw== -"@babel/helper-string-parser@^7.23.4": - version "7.23.4" - resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.23.4.tgz#9478c707febcbbe1ddb38a3d91a2e054ae622d83" - integrity sha512-803gmbQdqwdf4olxrX4AJyFBV/RTr3rSmOj0rKwesmzlfhYNDEs+/iOcznzpNWlJlIlTJC2QfPFcHB6DlzdVLQ== - -"@babel/helper-validator-identifier@^7.22.20": - version "7.22.20" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz#c4ae002c61d2879e724581d96665583dbc1dc0e0" - integrity sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A== - -"@babel/parser@^7.6.0", "@babel/parser@^7.9.6": - version "7.23.9" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.23.9.tgz#7b903b6149b0f8fa7ad564af646c4c38a77fc44b" - integrity sha512-9tcKgqKbs3xGJ+NtKF2ndOBBLVwPjl1SHxPQkd36r3Dlirw3xWUeGaTbqr7uGZcTaxkVNwc+03SVP7aCdWrTlA== - -"@babel/types@^7.6.1", "@babel/types@^7.9.6": - version "7.23.9" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.23.9.tgz#1dd7b59a9a2b5c87f8b41e52770b5ecbf492e002" - integrity sha512-dQjSq/7HaSjRM43FFGnv5keM2HsxpmyV1PfaSVm0nzzjwwTmjOe6J4bC8e3+pTEIgHaHj+1ZlLThRJ2auc/w1Q== - dependencies: - "@babel/helper-string-parser" "^7.23.4" - "@babel/helper-validator-identifier" "^7.22.20" - to-fast-properties "^2.0.0" - -"@iarna/toml@^2.2.5": - version "2.2.5" - resolved "https://registry.yarnpkg.com/@iarna/toml/-/toml-2.2.5.tgz#b32366c89b43c6f8cefbdefac778b9c828e3ba8c" - integrity sha512-trnsAYxU3xnS1gPHPyU961coFyLkh4gAD/0zQ5mymY4yOZ+CYvsPqUbOFSw0aDM4y0tV7tiFxL/1XfXPNC6IPg== - "@isaacs/cliui@^8.0.2": version "8.0.2" resolved "https://registry.yarnpkg.com/@isaacs/cliui/-/cliui-8.0.2.tgz#b37667b7bc181c168782259bab42474fbf52b550" @@ -191,46 +210,47 @@ resolved "https://registry.yarnpkg.com/@pkgjs/parseargs/-/parseargs-0.11.0.tgz#a77ea742fab25775145434eb1d2328cf5013ac33" integrity sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg== -"@sindresorhus/slugify@^1.1.2": - version "1.1.2" - resolved "https://registry.yarnpkg.com/@sindresorhus/slugify/-/slugify-1.1.2.tgz#c2c0129298b8caace2d9156176fe244d0e83156c" - integrity sha512-V9nR/W0Xd9TSGXpZ4iFUcFGhuOJtZX82Fzxj1YISlbSgKvIiNa7eLEZrT0vAraPOt++KHauIVNYgGRgjc13dXA== +"@sindresorhus/slugify@^2.2.1": + version "2.2.1" + resolved "https://registry.yarnpkg.com/@sindresorhus/slugify/-/slugify-2.2.1.tgz#fa2e2e25d6e1e74a2eeb5e2c37f5ccc516ed2c4b" + integrity sha512-MkngSCRZ8JdSOCHRaYd+D01XhvU3Hjy6MGl06zhOk614hp9EOAp5gIkBeQg7wtmxpitU6eAL4kdiRMcJa2dlrw== dependencies: - "@sindresorhus/transliterate" "^0.1.1" - escape-string-regexp "^4.0.0" + "@sindresorhus/transliterate" "^1.0.0" + escape-string-regexp "^5.0.0" -"@sindresorhus/transliterate@^0.1.1": - version "0.1.2" - resolved "https://registry.yarnpkg.com/@sindresorhus/transliterate/-/transliterate-0.1.2.tgz#ffce368271d153550e87de81486004f2637425af" - integrity sha512-5/kmIOY9FF32nicXH+5yLNTX4NJ4atl7jRgqAJuIn/iyDFXBktOKDxCvyGE/EzmF4ngSUvjXxQUQlQiZ5lfw+w== +"@sindresorhus/transliterate@^1.0.0": + version "1.6.0" + resolved "https://registry.yarnpkg.com/@sindresorhus/transliterate/-/transliterate-1.6.0.tgz#2309fff65a868047e6d2dd70dec747c5b36a8327" + integrity sha512-doH1gimEu3A46VX6aVxpHTeHrytJAG6HgdxntYnCFiIFHEM/ZGpG8KiZGBChchjQmG0XFIBL552kBTjVcMZXwQ== dependencies: - escape-string-regexp "^2.0.0" - lodash.deburr "^4.1.0" + escape-string-regexp "^5.0.0" -"@tailwindcss/typography@^0.5.10": - version "0.5.10" - resolved "https://registry.yarnpkg.com/@tailwindcss/typography/-/typography-0.5.10.tgz#2abde4c6d5c797ab49cf47610830a301de4c1e0a" - integrity sha512-Pe8BuPJQJd3FfRnm6H0ulKIGoMEQS+Vq01R6M5aCrFB/ccR/shT+0kXLjouGC1gFLm9hopTFN+DMP0pfwRWzPw== +"@tailwindcss/typography@^0.5.15": + version "0.5.15" + resolved "https://registry.yarnpkg.com/@tailwindcss/typography/-/typography-0.5.15.tgz#007ab9870c86082a1c76e5b3feda9392c7c8d648" + integrity sha512-AqhlCXl+8grUz8uqExv5OTtgpjuVIwFTSXTrh8y9/pw6q2ek7fJ+Y8ZEVw7EB2DCcuCOtEjf9w3+J3rzts01uA== dependencies: lodash.castarray "^4.4.0" lodash.isplainobject "^4.0.6" lodash.merge "^4.6.2" postcss-selector-parser "6.0.10" -"@types/minimatch@^3.0.3": - version "3.0.5" - resolved "https://registry.yarnpkg.com/@types/minimatch/-/minimatch-3.0.5.tgz#1001cc5e6a3704b83c236027e77f2f58ea010f40" - integrity sha512-Klz949h02Gz2uZCMGwDUSDS1YBlTdDDgbWHi+81l29tQALUtvz4rAYi5uoVhE5Lagoq6DeqAUlbrHvW/mXDgdQ== - a-sync-waterfall@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/a-sync-waterfall/-/a-sync-waterfall-1.0.1.tgz#75b6b6aa72598b497a125e7a2770f14f4c8a1fa7" integrity sha512-RYTOHHdWipFUliRFMCS4X2Yn2X8M87V/OpSqWzKKOGhzqyUxzyVmhHDH9sAvG+ZuQf/TAOFsLCpMw09I1ufUnA== -acorn@^7.1.1: - version "7.4.1" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.4.1.tgz#feaed255973d2e77555b83dbc08851a6c63520fa" - integrity sha512-nQyp0o1/mNdbTO1PO6kHkwSrmgZ0MT/jCCpNiwbUjGoRN4dlBhqJtoQuCnEOKzgTVwg0ZWiCoQy6SxMebQVh8A== +acorn-walk@^8.3.2: + version "8.3.4" + resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-8.3.4.tgz#794dd169c3977edf4ba4ea47583587c5866236b7" + integrity sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g== + dependencies: + acorn "^8.11.0" + +acorn@^8.1.3, acorn@^8.10.0, acorn@^8.11.0, acorn@^8.11.2: + version "8.14.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.14.0.tgz#063e2c70cac5fb4f6467f0b11152e04c682795b0" + integrity sha512-cl669nCJTZBsL97OF4kUQm5g5hC2uihk0NxY3WENAC0TYdILVkAyHymAntgxGkl7K+t0cXIrH5siy5S4XkFycA== ansi-regex@^5.0.1: version "5.0.1" @@ -249,7 +269,7 @@ ansi-styles@^3.2.1: dependencies: color-convert "^1.9.0" -ansi-styles@^4.0.0, ansi-styles@^4.1.0: +ansi-styles@^4.0.0: version "4.3.0" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== @@ -261,11 +281,6 @@ ansi-styles@^6.1.0: resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-6.2.1.tgz#0e62320cf99c21afff3b3012192546aacbfb05c5" integrity sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug== -any-promise@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/any-promise/-/any-promise-0.1.0.tgz#830b680aa7e56f33451d4b049f3bd8044498ee27" - integrity sha512-lqzY9o+BbeGHRCOyxQkt/Tgvz0IZhTmQiA+LxQW8wSNpcTbj8K+0cZiSEvbpNZZP9/11Gy7dnLO3GNWUXO4d1g== - any-promise@^1.0.0: version "1.3.0" resolved "https://registry.yarnpkg.com/any-promise/-/any-promise-1.3.0.tgz#abc6afeedcea52e809cdc0376aed3ce39635d17f" @@ -309,11 +324,6 @@ array-differ@^1.0.0: resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-1.0.0.tgz#eff52e3758249d33be402b8bb8e564bb2b5d4031" integrity sha512-LeZY+DZDRnvP7eMuQ6LHfCzUGxAAIViUBliK24P3hWXL6y4SortgR6Nim6xrkfSLlmH0+k+9NYNwVC2s53ZrYQ== -array-differ@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/array-differ/-/array-differ-3.0.0.tgz#3cbb3d0f316810eafcc47624734237d6aee4ae6b" - integrity sha512-THtfYS6KtME/yIAhKjZ2ul7XI96lQGHRputJQHO80LAWQnuGP4iCIN8vdMRboGbIEYBwU33q8Tch1os2+X0kMg== - array-union@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/array-union/-/array-union-1.0.2.tgz#9a34410e4f4e3da23dea375be5be70f24778ec39" @@ -321,11 +331,6 @@ array-union@^1.0.1: dependencies: array-uniq "^1.0.1" -array-union@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/array-union/-/array-union-2.1.0.tgz#b798420adbeb1de828d84acd8a2e23d3efe85e8d" - integrity sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw== - array-uniq@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" @@ -350,26 +355,11 @@ arrify@^1.0.0: resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" integrity sha512-3CYzex9M9FGQjCGMGyi6/31c8GJbgb0qGyrx5HWxPd0aCwh4cB2YjMb2Xf9UuoogrMrlO9cTqnB5rI5GHZTcUA== -arrify@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/arrify/-/arrify-2.0.1.tgz#c9655e9331e0abcd588d2a7cad7e9956f66701fa" - integrity sha512-3duEwti880xqi4eAMN8AyR4a0ByT90zoYdLlevfrvU43vb0YZwZVfxOgxWrLXXXpyugL0hNZc9G6BiB5B3nUug== - asap@^2.0.3, asap@~2.0.3: version "2.0.6" resolved "https://registry.yarnpkg.com/asap/-/asap-2.0.6.tgz#e50347611d7e690943208bbdafebcbc2fb866d46" integrity sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA== -assert-never@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/assert-never/-/assert-never-1.2.1.tgz#11f0e363bf146205fb08193b5c7b90f4d1cf44fe" - integrity sha512-TaTivMB6pYI1kXwrFlEhLeGfOqoDNdTxjCdwRfFFkEA30Eu+k48W34nlok2EYWJfFFzqaEmichdNM7th6M5HNw== - -async@^3.2.3: - version "3.2.5" - resolved "https://registry.yarnpkg.com/async/-/async-3.2.5.tgz#ebd52a8fdaf7a2289a24df399f8d8485c8a46b66" - integrity sha512-baNZyqaaLhyLVKm/DlvdW051MSgO6b8eVfIezl9E5PqWxFgzLm/wQntEW4zOytVburDEr0JlALEpdOFwvErLsg== - available-typed-arrays@^1.0.6, available-typed-arrays@^1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz#a5cc375d6a03c2efc87a553f3e0b1522def14846" @@ -377,39 +367,32 @@ available-typed-arrays@^1.0.6, available-typed-arrays@^1.0.7: dependencies: possible-typed-array-names "^1.0.0" -babel-walk@3.0.0-canary-5: - version "3.0.0-canary-5" - resolved "https://registry.yarnpkg.com/babel-walk/-/babel-walk-3.0.0-canary-5.tgz#f66ecd7298357aee44955f235a6ef54219104b11" - integrity sha512-GAwkz0AihzY5bkwIY5QDR+LvsRQgB/B+1foMPvi0FZPMl5fjD7ICiznUiBdLYMH1QYe6vqu4gWYytZOccLouFw== - dependencies: - "@babel/types" "^7.9.6" - balanced-match@^1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== -bcp-47-match@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/bcp-47-match/-/bcp-47-match-1.0.3.tgz#cb8d03071389a10aff2062b862d6575ffd7cd7ef" - integrity sha512-LggQ4YTdjWQSKELZF5JwchnBa1u0pIQSZf5lSdOHEdbVP55h0qICA/FUp3+W99q0xqxYa1ZQizTUH87gecII5w== +bcp-47-match@^2.0.0: + version "2.0.3" + resolved "https://registry.yarnpkg.com/bcp-47-match/-/bcp-47-match-2.0.3.tgz#603226f6e5d3914a581408be33b28a53144b09d0" + integrity sha512-JtTezzbAibu8G0R9op9zb3vcWZd9JF6M0xOYGPn0fNCd7wOpRB1mU2mH9T8gaBGbAAyIIVgB2G7xG0GP98zMAQ== -bcp-47-normalize@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/bcp-47-normalize/-/bcp-47-normalize-1.1.1.tgz#d2c76218d132f223c44e4a06a7224be3030f8ec3" - integrity sha512-jWZ1Jdu3cs0EZdfCkS0UE9Gg01PtxnChjEBySeB+Zo6nkqtFfnvtoQQgP1qU1Oo4qgJgxhTI6Sf9y/pZIhPs0A== +bcp-47-normalize@^2.3.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/bcp-47-normalize/-/bcp-47-normalize-2.3.0.tgz#00f7de9dfdd0f6901c048083be5ac60903bf4f7a" + integrity sha512-8I/wfzqQvttUFz7HVJgIZ7+dj3vUaIyIxYXaTRP1YWoSDfzt6TUmxaKZeuXR62qBmYr+nvuWINFRl6pZ5DlN4Q== dependencies: - bcp-47 "^1.0.0" - bcp-47-match "^1.0.0" + bcp-47 "^2.0.0" + bcp-47-match "^2.0.0" -bcp-47@^1.0.0: - version "1.0.8" - resolved "https://registry.yarnpkg.com/bcp-47/-/bcp-47-1.0.8.tgz#bf63ae4269faabe7c100deac0811121a48b6a561" - integrity sha512-Y9y1QNBBtYtv7hcmoX0tR+tUNSFZGZ6OL6vKPObq8BbOhkCoyayF6ogfLTgAli/KuAEbsYHYUNq2AQuY6IuLag== +bcp-47@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/bcp-47/-/bcp-47-2.1.0.tgz#7e80734c3338fe8320894981dccf4968c3092df6" + integrity sha512-9IIS3UPrvIa1Ej+lVDdDwO7zLehjqsaByECw0bu2RRGP73jALm6FYbzI5gWbgHLvNdkvfXB5YrSbocZdOS0c0w== dependencies: - is-alphabetical "^1.0.0" - is-alphanumerical "^1.0.0" - is-decimal "^1.0.0" + is-alphabetical "^2.0.0" + is-alphanumerical "^2.0.0" + is-decimal "^2.0.0" binary-extensions@^2.0.0: version "2.2.0" @@ -471,22 +454,12 @@ chalk@^2.4.1: escape-string-regexp "^1.0.5" supports-color "^5.3.0" -chalk@^4.0.2: - version "4.1.2" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" - integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== - dependencies: - ansi-styles "^4.1.0" - supports-color "^7.1.0" +chardet@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/chardet/-/chardet-2.0.0.tgz#24a74bd3954965ba2d30f490a915fc3cf053051f" + integrity sha512-xVgPpulCooDjY6zH4m9YW3jbkaBe3FKIAvF5sj5t7aBNsVl2ljIE+xwJ4iNgiDZHFQvNIpjdKdVOQvvk5ZfxbQ== -character-parser@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/character-parser/-/character-parser-2.2.0.tgz#c7ce28f36d4bcd9744e5ffc2c5fcde1c73261fc0" - integrity sha512-+UqJQjFEFaTAs3bNsF2j2kEN1baG/zghZbdqoYEDxGZtJo9LBzl1A+m0D4n3qKx8N2FNv8/Xp6yV9mQmBuptaw== - dependencies: - is-regex "^1.0.3" - -chokidar@^3.5.3: +chokidar@^3.5.3, chokidar@^3.6.0: version "3.6.0" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.6.0.tgz#197c6cc669ef2a8dc5e7b4d97ee4e092c3eb0d5b" integrity sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw== @@ -557,14 +530,6 @@ concat-map@0.0.1: resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== -constantinople@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/constantinople/-/constantinople-4.0.1.tgz#0def113fa0e4dc8de83331a5cf79c8b325213151" - integrity sha512-vCrqcSIq4//Gx74TXXCGnHpulY1dskqLTFGDmhrGxzeXL8lF8kvXv6mpNWlJj1uD4DW23D4ljAqbY4RRaaUZIw== - dependencies: - "@babel/parser" "^7.6.0" - "@babel/types" "^7.6.1" - cross-env@^7.0.3: version "7.0.3" resolved "https://registry.yarnpkg.com/cross-env/-/cross-env-7.0.3.tgz#865264b29677dc015ba8418918965dd232fc54cf" @@ -602,10 +567,10 @@ data-uri-to-buffer@^4.0.0: resolved "https://registry.yarnpkg.com/data-uri-to-buffer/-/data-uri-to-buffer-4.0.1.tgz#d8feb2b2881e6a4f58c2e08acfd0e2834e26222e" integrity sha512-0R9ikRb668HB7QDxT1vkpuUBtqc53YyAwMwGeUFKRojY/NWKvdZ+9UYtRfGmhqNbRkTSVpMbmyhXipFFv2cb/A== -date-fns@^3.3.1: - version "3.3.1" - resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-3.3.1.tgz#7581daca0892d139736697717a168afbb908cfed" - integrity sha512-y8e109LYGgoQDveiEBD3DYXKba1jWf5BA8YU1FL5Tvm0BTdEfy54WLCwnuYWZNnzzvALy/QQ4Hov+Q9RVRv+Zw== +date-fns@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-4.1.0.tgz#64b3d83fff5aa80438f5b1a633c2e83b8a1c2d14" + integrity sha512-Ukq0owbQXxa/U3EGtsdVBkR1w7KOQ5gIBqdH2hkvknzZPYvBxb/aa6E8L7tmjFtkwZBu3UXBbjIgPo/Ez4xaNg== debug@2.6.9: version "2.6.9" @@ -614,12 +579,12 @@ debug@2.6.9: dependencies: ms "2.0.0" -debug@^4.3.4: - version "4.3.4" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" - integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== +debug@^4.3.4, debug@^4.3.7: + version "4.3.7" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.7.tgz#87945b4151a011d76d95a198d7111c865c360a52" + integrity sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ== dependencies: - ms "2.1.2" + ms "^2.1.3" define-data-property@^1.0.1, define-data-property@^1.1.2, define-data-property@^1.1.4: version "1.1.4" @@ -639,11 +604,26 @@ define-properties@^1.1.3, define-properties@^1.2.0, define-properties@^1.2.1: has-property-descriptors "^1.0.0" object-keys "^1.1.1" +depd@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df" + integrity sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw== + dependency-graph@^0.11.0: version "0.11.0" resolved "https://registry.yarnpkg.com/dependency-graph/-/dependency-graph-0.11.0.tgz#ac0ce7ed68a54da22165a85e97a01d53f5eb2e27" integrity sha512-JeMq7fEshyepOWDfcfHK06N3MhyPhz++vtqWhMT5O9A3K42rdsEDpfdVqjaqaAhsw6a+ZqeDvQVtD0hFHQWrzg== +dependency-graph@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/dependency-graph/-/dependency-graph-1.0.0.tgz#bb5e85aec1310bc13b22dbd76e3196c4ee4c10d2" + integrity sha512-cW3gggJ28HZ/LExwxP2B++aiKxhJXMSIt9K48FOXQkm+vuG5gyatXnLsONRJdzO/7VfjDIiaOOa/bs4l464Lwg== + +destroy@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.2.0.tgz#4803735509ad8be552934c67df614f94e66fa015" + integrity sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg== + dev-ip@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/dev-ip/-/dev-ip-1.0.1.tgz#a76a3ed1855be7a012bb8ac16cb80f3c00dc28f0" @@ -659,11 +639,6 @@ dlv@^1.1.3: resolved "https://registry.yarnpkg.com/dlv/-/dlv-1.1.3.tgz#5c198a8a11453596e751494d49874bc7732f2e79" integrity sha512-+HlytyjlPKnIG8XuRG8WvmBP8xs8P71y+SKKS6ZXWoEgLuePxtDoUEiH7WkdePWrQ5JBpE6aoVqfZfJUQkjXwA== -doctypes@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/doctypes/-/doctypes-1.1.0.tgz#ea80b106a87538774e8a3a4a5afe293de489e0a9" - integrity sha512-LLBi6pEqS6Do3EKQ3J0NqHWV5hhb78Pi8vvESYwyOy2c31ZEZVdtitdzsQsKb7878PEERhzUk0ftqGhG6Mz+pQ== - dom-serializer@^1.0.1: version "1.4.1" resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-1.4.1.tgz#de5d41b1aea290215dc45a6dae8adcf1d32e2d30" @@ -704,13 +679,6 @@ ee-first@1.1.1: resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d" integrity sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow== -ejs@^3.1.9: - version "3.1.10" - resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.10.tgz#69ab8358b14e896f80cc39e62087b88500c3ac3b" - integrity sha512-UeJmFfOrAQS8OJWPZ4qtgHyWExa088/MtK5UEyoJGFH67cDEXkZSviOiKRCZ4Xij0zxI3JECgYs3oKx+AizQBA== - dependencies: - jake "^10.8.5" - emoji-regex@^8.0.0: version "8.0.0" resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" @@ -721,17 +689,17 @@ emoji-regex@^9.2.2: resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-9.2.2.tgz#840c8803b0d8047f4ff0cf963176b32d4ef3ed72" integrity sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg== -encodeurl@~1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-1.0.2.tgz#ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59" - integrity sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w== +encodeurl@~2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/encodeurl/-/encodeurl-2.0.0.tgz#7b8ea898077d7e409d3ac45474ea38eaf0857a58" + integrity sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg== entities@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/entities/-/entities-2.2.0.tgz#098dc90ebb83d8dffa089d55256b351d34c4da55" integrity sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A== -entities@^3.0.1, entities@~3.0.1: +entities@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/entities/-/entities-3.0.1.tgz#2b887ca62585e96db3903482d336c1006c3001d4" integrity sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q== @@ -741,6 +709,11 @@ entities@^4.4.0: resolved "https://registry.yarnpkg.com/entities/-/entities-4.5.0.tgz#5d268ea5e7113ec74c4d033b79ea5a35a488fb48" integrity sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw== +entities@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/entities/-/entities-5.0.0.tgz#b2ab51fe40d995817979ec79dd621154c3c0f62b" + integrity sha512-BeJFvFRJddxobhvEdm5GqHzRV/X+ACeuw0/BuuxsCh1EUZcAIz8+kYmBp/LrQuloy6K1f3a0M7+IhmZ7QnkISA== + errno@^0.1.2: version "0.1.8" resolved "https://registry.yarnpkg.com/errno/-/errno-0.1.8.tgz#8bb3e9c7d463be4976ff888f76b4809ebc2e811f" @@ -814,6 +787,13 @@ es-errors@^1.2.1, es-errors@^1.3.0: resolved "https://registry.yarnpkg.com/es-errors/-/es-errors-1.3.0.tgz#05f75a25dab98e4fb1dcd5e1472c0546d5057c8f" integrity sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw== +es-object-atoms@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/es-object-atoms/-/es-object-atoms-1.0.0.tgz#ddb55cd47ac2e240701260bc2a8e31ecb643d941" + integrity sha512-MZ4iQ6JwHOBQjahnjwaC1ZtIBH+2ohjamzAO3oaHcXYup7qxjF2fixyH+Q71voWHeOkI2q/TnJao/KfXYIZWbw== + dependencies: + es-errors "^1.3.0" + es-set-tostringtag@^2.0.2: version "2.0.3" resolved "https://registry.yarnpkg.com/es-set-tostringtag/-/es-set-tostringtag-2.0.3.tgz#8bb60f0a440c2e4281962428438d58545af39777" @@ -842,21 +822,33 @@ escape-string-regexp@^1.0.5: resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== -escape-string-regexp@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz#a30304e99daa32e23b2fd20f51babd07cffca344" - integrity sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w== +escape-string-regexp@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-5.0.0.tgz#4683126b500b61762f2dbebace1806e8be31b1c8" + integrity sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw== -escape-string-regexp@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" - integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== +esm-import-transformer@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/esm-import-transformer/-/esm-import-transformer-3.0.2.tgz#0ccc2a9cb0e793e4b148ecb4064e2d52bb15580b" + integrity sha512-PgvO0wro44lTDM9pYeeOIfpS0lGF80jA+rjT7sBd3b07rxv1AxeNMEI5kSCqRKke2W6SPEz17W3kHOLjaiD7Cw== + dependencies: + acorn "^8.11.2" esprima@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== +etag@~1.8.1: + version "1.8.1" + resolved "https://registry.yarnpkg.com/etag/-/etag-1.8.1.tgz#41ae2eeb65efa62268aebfea83ac7d79299b0887" + integrity sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg== + +evaluate-value@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/evaluate-value/-/evaluate-value-2.0.0.tgz#bb7169ab4a49fb76b7ab5631c7d327797fd8e65f" + integrity sha512-VonfiuDJc0z4sOO7W0Pd130VLsXN6vmBWZlrog1mCb/o7o/Nl5Lr25+Kj/nkCCAhG+zqeeGjxhkK9oHpkgTHhQ== + extend-shallow@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" @@ -864,7 +856,7 @@ extend-shallow@^2.0.1: dependencies: is-extendable "^0.1.0" -fast-glob@^3.2.12, fast-glob@^3.3.0: +fast-glob@^3.3.0, fast-glob@^3.3.2: version "3.3.2" resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-3.3.2.tgz#a904501e57cfdd2ffcded45e99a54fef55e46129" integrity sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow== @@ -890,12 +882,10 @@ fetch-blob@^3.1.2, fetch-blob@^3.1.4: node-domexception "^1.0.0" web-streams-polyfill "^3.0.3" -filelist@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/filelist/-/filelist-1.0.4.tgz#f78978a1e944775ff9e62e744424f215e58352b5" - integrity sha512-w1cEuf3S+DrLCQL7ET6kz+gmlJdbq9J7yXCSjK/OZCPA+qEN1WyF4ZAf0YYJa4/shHJra2t/d/r8SV4Ji+x+8Q== - dependencies: - minimatch "^5.0.1" +filesize@^10.1.6: + version "10.1.6" + resolved "https://registry.yarnpkg.com/filesize/-/filesize-10.1.6.tgz#31194da825ac58689c0bce3948f33ce83aabd361" + integrity sha512-sJslQKU2uM33qH5nqewAwVB2QgR6w1aMNsYUp3aN5rMRyXEwJGmZvaWzeJFNTOXWlHQyBFCWrdj3fV/fsTOX8w== fill-range@^7.1.1: version "7.1.1" @@ -904,13 +894,13 @@ fill-range@^7.1.1: dependencies: to-regex-range "^5.0.1" -finalhandler@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.2.0.tgz#7d23fe5731b207b4640e4fcd00aec1f9207a7b32" - integrity sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg== +finalhandler@^1.3.0: + version "1.3.1" + resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.3.1.tgz#0c575f1d1d324ddd1da35ad7ece3df7d19088019" + integrity sha512-6BN9trH7bp3qvnrRyzsBz+g3lZxTNZTbVO2EV1CS0WIcDbawYVdYvGflME/9QP0h0pYlCDBCTjYa9nZzMDpyxQ== dependencies: debug "2.6.9" - encodeurl "~1.0.2" + encodeurl "~2.0.0" escape-html "~1.0.3" on-finished "2.4.1" parseurl "~1.3.3" @@ -939,10 +929,10 @@ formdata-polyfill@^4.0.10: dependencies: fetch-blob "^3.1.2" -fs.realpath@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" - integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== +fresh@0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/fresh/-/fresh-0.5.2.tgz#3d8cadd90d976569fa835ab1f8e4b23a105605a7" + integrity sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q== fsevents@~2.3.2: version "2.3.3" @@ -1014,17 +1004,17 @@ glob@^10.3.10: minipass "^5.0.0 || ^6.0.2 || ^7.0.0" path-scurry "^1.10.1" -glob@^7.1.3: - version "7.2.3" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" - integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== +glob@^10.3.7: + version "10.4.5" + resolved "https://registry.yarnpkg.com/glob/-/glob-10.4.5.tgz#f4d9f0b90ffdbab09c9d77f5f29b4262517b0956" + integrity sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg== dependencies: - fs.realpath "^1.0.0" - inflight "^1.0.4" - inherits "2" - minimatch "^3.1.1" - once "^1.3.0" - path-is-absolute "^1.0.0" + foreground-child "^3.1.0" + jackspeak "^3.1.2" + minimatch "^9.0.4" + minipass "^7.1.2" + package-json-from-dist "^1.0.0" + path-scurry "^1.11.1" globalthis@^1.0.3: version "1.0.3" @@ -1040,7 +1030,7 @@ gopd@^1.0.1: dependencies: get-intrinsic "^1.1.3" -graceful-fs@^4.1.2, graceful-fs@^4.1.4, graceful-fs@^4.2.11: +graceful-fs@^4.1.2, graceful-fs@^4.2.11: version "4.2.11" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== @@ -1055,23 +1045,6 @@ gray-matter@^4.0.3: section-matter "^1.0.0" strip-bom-string "^1.0.0" -hamljs@^0.6.2: - version "0.6.2" - resolved "https://registry.yarnpkg.com/hamljs/-/hamljs-0.6.2.tgz#7b7116cf6dbe7278e42b3f6ef8725a33e177c8e3" - integrity sha512-/chXRp4WpL47I+HX1vCCdSbEXAljEG2FBMmgO7Am0bYsqgnEjreeWzUdX1onXqwZtcfgxbCg5WtEYYvuZ5muBg== - -handlebars@^4.7.7: - version "4.7.8" - resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.7.8.tgz#41c42c18b1be2365439188c77c6afae71c0cd9e9" - integrity sha512-vafaFqs8MZkRrSX7sFVUdo3ap/eNiLnb4IakshzvP56X5Nr1iGKAIqdX6tMlm6HcNRIkr6AxO5jFEoJzzpT8aQ== - dependencies: - minimist "^1.2.5" - neo-async "^2.6.2" - source-map "^0.6.1" - wordwrap "^1.0.0" - optionalDependencies: - uglify-js "^3.1.4" - has-bigints@^1.0.1, has-bigints@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/has-bigints/-/has-bigints-1.0.2.tgz#0871bd3e3d51626f6ca0966668ba35d5602d6eaa" @@ -1082,11 +1055,6 @@ has-flag@^3.0.0: resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" integrity sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw== -has-flag@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" - integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== - has-property-descriptors@^1.0.0, has-property-descriptors@^1.0.1, has-property-descriptors@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz#963ed7d071dc7bf5f084c5bfbe0d1b6222586854" @@ -1151,20 +1119,23 @@ htmlparser2@^7.1.1: domutils "^2.8.0" entities "^3.0.1" -http-equiv-refresh@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/http-equiv-refresh/-/http-equiv-refresh-1.0.0.tgz#8ec538866042be5f3f7afa737d198d94beb1b07b" - integrity sha512-TScO04soylRN9i/QdOdgZyhydXg9z6XdaGzEyOgDKycePeDeTT4KvigjBcI+tgfTlieLWauGORMq5F1eIDa+1w== +http-equiv-refresh@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/http-equiv-refresh/-/http-equiv-refresh-2.0.1.tgz#2816aee5ccce42734a13ecfe79dacc0db29c39b1" + integrity sha512-XJpDL/MLkV3dKwLzHwr2dY05dYNfBNlyPu4STQ8WvKCFdc6vC5tPXuq28of663+gHVg03C+16pHHs/+FmmDjcw== -inflight@^1.0.4: - version "1.0.6" - resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" - integrity sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA== +http-errors@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-2.0.0.tgz#b7774a1486ef73cf7667ac9ae0858c012c57b9d3" + integrity sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ== dependencies: - once "^1.3.0" - wrappy "1" + depd "2.0.0" + inherits "2.0.4" + setprototypeof "1.2.0" + statuses "2.0.1" + toidentifier "1.0.1" -inherits@2: +inherits@2.0.4: version "2.0.4" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== @@ -1178,18 +1149,18 @@ internal-slot@^1.0.7: hasown "^2.0.0" side-channel "^1.0.4" -is-alphabetical@^1.0.0: - version "1.0.4" - resolved "https://registry.yarnpkg.com/is-alphabetical/-/is-alphabetical-1.0.4.tgz#9e7d6b94916be22153745d184c298cbf986a686d" - integrity sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg== +is-alphabetical@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-alphabetical/-/is-alphabetical-2.0.1.tgz#01072053ea7c1036df3c7d19a6daaec7f19e789b" + integrity sha512-FWyyY60MeTNyeSRpkM2Iry0G9hpr7/9kD40mD/cGQEuilcZYS4okz8SN2Q6rLCJ8gbCt6fN+rC+6tMGS99LaxQ== -is-alphanumerical@^1.0.0: - version "1.0.4" - resolved "https://registry.yarnpkg.com/is-alphanumerical/-/is-alphanumerical-1.0.4.tgz#7eb9a2431f855f6b1ef1a78e326df515696c4dbf" - integrity sha512-UzoZUr+XfVz3t3v4KyGEniVL9BDRoQtY7tOyrRybkVNjDFWyo1yhXNGrrBTQxp3ib9BLAWs7k2YKBQsFRkZG9A== +is-alphanumerical@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-alphanumerical/-/is-alphanumerical-2.0.1.tgz#7c03fbe96e3e931113e57f964b0a368cc2dfd875" + integrity sha512-hmbYhX/9MUMF5uh7tOXyK/n0ZvWpad5caBA17GsC6vyuCqaWliRG5K1qS9inmUhEMaOBIW7/whAnSwveW/LtZw== dependencies: - is-alphabetical "^1.0.0" - is-decimal "^1.0.0" + is-alphabetical "^2.0.0" + is-decimal "^2.0.0" is-array-buffer@^3.0.4: version "3.0.4" @@ -1245,18 +1216,10 @@ is-date-object@^1.0.1: dependencies: has-tostringtag "^1.0.0" -is-decimal@^1.0.0: - version "1.0.4" - resolved "https://registry.yarnpkg.com/is-decimal/-/is-decimal-1.0.4.tgz#65a3a5958a1c5b63a706e1b333d7cd9f630d3fa5" - integrity sha512-RGdriMmQQvZ2aqaQq3awNA6dCGtKpiDFcOzrTWrDAT2MiWrKQVPmxLGHl7Y2nNu6led0kEyoX0enY0qXYsv9zw== - -is-expression@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/is-expression/-/is-expression-4.0.0.tgz#c33155962abf21d0afd2552514d67d2ec16fd2ab" - integrity sha512-zMIXX63sxzG3XrkHkrAPvm/OVZVSCPNkwMHU8oTX7/U3AL78I0QXCEICXUM13BIa8TYGZ68PiTKfQz3yaTNr4A== - dependencies: - acorn "^7.1.1" - object-assign "^4.1.1" +is-decimal@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-decimal/-/is-decimal-2.0.1.tgz#9469d2dc190d0214fd87d78b78caecc0cc14eef7" + integrity sha512-AAB9hiomQs5DXWcRB1rqsxGUstbRroFOPPVAomNk/3XHR5JyEZChOyTWe2oayKnsSsr/kcGqF+z6yuH6HHpN0A== is-extendable@^0.1.0: version "0.1.1" @@ -1302,12 +1265,7 @@ is-number@^7.0.0: resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== -is-promise@^2.0.0: - version "2.2.2" - resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1" - integrity sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ== - -is-regex@^1.0.3, is-regex@^1.1.4: +is-regex@^1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.4.tgz#eef5663cd59fa4c0ae339505323df6854bb15958" integrity sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg== @@ -1360,10 +1318,10 @@ isexe@^2.0.0: resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== -iso-639-1@^2.1.15: - version "2.1.15" - resolved "https://registry.yarnpkg.com/iso-639-1/-/iso-639-1-2.1.15.tgz#20cf78a4f691aeb802c16f17a6bad7d99271e85d" - integrity sha512-7c7mBznZu2ktfvyT582E2msM+Udc1EjOyhVRE/0ZsjD9LBtWSm23h3PtiRh2a35XoUsTQQjJXaJzuLjXsOdFDg== +iso-639-1@^3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/iso-639-1/-/iso-639-1-3.1.3.tgz#73c0a8d19988837e1cf5c2fa397a67f72cd34aee" + integrity sha512-1jz0Wh9hyLMRwqEPchb/KZCiTqfFWtc9R3nm7GHPygBAKS8wdKJ3FH4lvLsri6UtAE5Kz5SnowtXZa//6bqMyw== jackspeak@^2.3.5: version "2.3.6" @@ -1374,25 +1332,19 @@ jackspeak@^2.3.5: optionalDependencies: "@pkgjs/parseargs" "^0.11.0" -jake@^10.8.5: - version "10.8.7" - resolved "https://registry.yarnpkg.com/jake/-/jake-10.8.7.tgz#63a32821177940c33f356e0ba44ff9d34e1c7d8f" - integrity sha512-ZDi3aP+fG/LchyBzUM804VjddnwfSfsdeYkwt8NcbKRvo4rFkjhs456iLFn3k2ZUWvNe4i48WACDbza8fhq2+w== +jackspeak@^3.1.2: + version "3.4.3" + resolved "https://registry.yarnpkg.com/jackspeak/-/jackspeak-3.4.3.tgz#8833a9d89ab4acde6188942bd1c53b6390ed5a8a" + integrity sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw== dependencies: - async "^3.2.3" - chalk "^4.0.2" - filelist "^1.0.4" - minimatch "^3.1.2" + "@isaacs/cliui" "^8.0.2" + optionalDependencies: + "@pkgjs/parseargs" "^0.11.0" -jiti@^1.19.1: - version "1.21.0" - resolved "https://registry.yarnpkg.com/jiti/-/jiti-1.21.0.tgz#7c97f8fe045724e136a397f7340475244156105d" - integrity sha512-gFqAIbuKyyso/3G2qhiO2OM6shY6EPP/R0+mkDbyspxKazh8BXDC5FiFsUjlczgdNz/vfra0da2y+aHrusLG/Q== - -js-stringify@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/js-stringify/-/js-stringify-1.0.2.tgz#1736fddfd9724f28a3682adc6230ae7e4e9679db" - integrity sha512-rtS5ATOo2Q5k1G+DADISilDA6lv79zIiwFd6CcjuIxGKLFm5C+RLImRscVap9k55i+MOZwgliw+NejvkLuGD5g== +jiti@^1.21.0: + version "1.21.6" + resolved "https://registry.yarnpkg.com/jiti/-/jiti-1.21.6.tgz#6c7f7398dd4b3142767f9a168af2f317a428d268" + integrity sha512-2yTgeWTWzMWkHu6Jp9NKgePDaYHbntiwvYuuJLbbN9vl7DC9DvXKOB2BC3ZZ92D3cvV/aflH0osDfwpHepQ53w== js-yaml@^3.13.1: version "3.14.1" @@ -1402,19 +1354,18 @@ js-yaml@^3.13.1: argparse "^1.0.7" esprima "^4.0.0" +js-yaml@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-4.1.0.tgz#c1fb65f8f5017901cdd2c951864ba18458a10602" + integrity sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA== + dependencies: + argparse "^2.0.1" + json-parse-better-errors@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== -jstransformer@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/jstransformer/-/jstransformer-1.0.0.tgz#ed8bf0921e2f3f1ed4d5c1a44f68709ed24722c3" - integrity sha512-C9YK3Rf8q6VAPDCCU9fnqo3mAfOH6vUGnMcP4AQAYIEpWtfGLpwOTmZ+igtdK5y+VvI2n3CyYSzy4Qh34eq24A== - dependencies: - is-promise "^2.0.0" - promise "^7.0.1" - junk@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/junk/-/junk-1.0.3.tgz#87be63488649cbdca6f53ab39bec9ccd2347f592" @@ -1445,13 +1396,6 @@ lines-and-columns@^1.1.6: resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== -linkify-it@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/linkify-it/-/linkify-it-4.0.1.tgz#01f1d5e508190d06669982ba31a7d9f56a5751ec" - integrity sha512-C7bfi1UZmoj8+PQx22XyeXCuBlokoyWQL5pWSP+EI6nzRylyThouddufc2c1NDIcP9k5agmN9fLpA7VNJfIiqw== - dependencies: - uc.micro "^1.0.1" - linkify-it@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/linkify-it/-/linkify-it-5.0.0.tgz#9ef238bfa6dc70bd8e7f9572b52d369af569b421" @@ -1459,10 +1403,10 @@ linkify-it@^5.0.0: dependencies: uc.micro "^2.0.0" -liquidjs@^10.7.0: - version "10.10.1" - resolved "https://registry.yarnpkg.com/liquidjs/-/liquidjs-10.10.1.tgz#1432ae7cc18641bd21e51aba551f8af963c0ad4d" - integrity sha512-h699VW79OLoshCTjFF02tmRCrd8t/E49LSIsjLwlg4k0TbMVjxsCRXVUEsURXbfKl3HUln2cShlDQCrSNm2YaA== +liquidjs@^10.17.0: + version "10.18.0" + resolved "https://registry.yarnpkg.com/liquidjs/-/liquidjs-10.18.0.tgz#9b9b7df1d068f416f4656af94b11eeb138602296" + integrity sha512-gCJPmpmZ3oi2rMMHo/c+bW1LaRF+ZAKYTWQmKXPp0uK9EkWMFRmgbk3+Io4LSJGAOnpCZSgHJbNzcygx3kfAAQ== dependencies: commander "^10.0.0" @@ -1486,11 +1430,6 @@ lodash.castarray@^4.4.0: resolved "https://registry.yarnpkg.com/lodash.castarray/-/lodash.castarray-4.4.0.tgz#c02513515e309daddd4c24c60cfddcf5976d9115" integrity sha512-aVx8ztPv7/2ULbArGJ2Y42bG1mEQ5mGjpdvrbJcJFU3TbYybe+QlLS4pst9zV52ymy2in1KpFPiZnAOATxD4+Q== -lodash.deburr@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/lodash.deburr/-/lodash.deburr-4.1.0.tgz#ddb1bbb3ef07458c0177ba07de14422cb033ff9b" - integrity sha512-m/M1U1f3ddMCs6Hq2tAsYThTBDaAKFDX3dwDo97GEYzamXi9SqUpjWi/Rrj/gf3X2n8ktwgZrlP1z6E3v/IExQ== - lodash.isplainobject@^4.0.6: version "4.0.6" resolved "https://registry.yarnpkg.com/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz#7c526a52d89b45c45cc690b88163be0497f550cb" @@ -1506,55 +1445,42 @@ lower-case@^1.1.1: resolved "https://registry.yarnpkg.com/lower-case/-/lower-case-1.1.4.tgz#9a2cabd1b9e8e0ae993a4bf7d5875c39c42e8eac" integrity sha512-2Fgx1Ycm599x+WGpIYwJOvsjmXFzTSc34IwDWALRA/8AopUKAVPwfJ+h5+f85BCp0PWmmJcWzEpxOpoXycMpdA== -lru-cache@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" - integrity sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA== - dependencies: - yallist "^4.0.0" +lru-cache@^10.2.0: + version "10.4.3" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.4.3.tgz#410fc8a17b70e598013df257c2446b7f3383f119" + integrity sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ== "lru-cache@^9.1.1 || ^10.0.0": version "10.2.0" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-10.2.0.tgz#0bd445ca57363465900f4d1f9bd8db343a4d95c3" integrity sha512-2bIM8x+VAf6JT4bKAljS1qUWgMsqZRPGJS6FSahIMPVvctcNhyVp7AJu7quxOW9jwkryBReKZY5tY5JYv2n/7Q== -luxon@^3.3.0: - version "3.4.4" - resolved "https://registry.yarnpkg.com/luxon/-/luxon-3.4.4.tgz#cf20dc27dc532ba41a169c43fdcc0063601577af" - integrity sha512-zobTr7akeGHnv7eBOXcRgMeCP6+uyYsczwmeRCauvpvaAltgNyTbLH/+VaEAPUeWBT+1GuNmz4wC/6jtQzbbVA== +luxon@^3.5.0: + version "3.5.0" + resolved "https://registry.yarnpkg.com/luxon/-/luxon-3.5.0.tgz#6b6f65c5cd1d61d1fd19dbf07ee87a50bf4b8e20" + integrity sha512-rh+Zjr6DNfUYR3bPwJEnuwDdqMbxZW7LOQfUN4B54+Cl+0o5zaU9RJ6bcidfDtC1cWCZXQ+nvX8bf6bAji37QQ== -markdown-it-anchor@^8.4.1: - version "8.6.7" - resolved "https://registry.yarnpkg.com/markdown-it-anchor/-/markdown-it-anchor-8.6.7.tgz#ee6926daf3ad1ed5e4e3968b1740eef1c6399634" - integrity sha512-FlCHFwNnutLgVTflOYHPW2pPcl2AACqVzExlkGQNsi4CJgqOHN7YTgDd4LuhgN1BFO3TS0vLAruV1Td6dwWPJA== +markdown-it-anchor@^9.2.0: + version "9.2.0" + resolved "https://registry.yarnpkg.com/markdown-it-anchor/-/markdown-it-anchor-9.2.0.tgz#89375d9a2a79336403ab7c4fd36b1965cc45e5c8" + integrity sha512-sa2ErMQ6kKOA4l31gLGYliFQrMKkqSO0ZJgGhDHKijPf0pNFM9vghjAh3gn26pS4JDRs7Iwa9S36gxm3vgZTzg== markdown-it-container@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/markdown-it-container/-/markdown-it-container-4.0.0.tgz#3912394f7da6e8ef3b43a0f58b1d0ded851f2a38" integrity sha512-HaNccxUH0l7BNGYbFbjmGpf5aLHAMTinqRZQAEQbMr2cdD3z91Q6kIo1oUn1CQndkT03jat6ckrdRYuwwqLlQw== -markdown-it@^13.0.1: - version "13.0.2" - resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-13.0.2.tgz#1bc22e23379a6952e5d56217fbed881e0c94d536" - integrity sha512-FtwnEuuK+2yVU7goGn/MJ0WBZMM9ZPgU9spqlFs7/A/pDIUNSOQZhUgOqYCficIuR2QaFnrt8LHqBWsbTAoI5w== - dependencies: - argparse "^2.0.1" - entities "~3.0.1" - linkify-it "^4.0.1" - mdurl "^1.0.1" - uc.micro "^1.0.5" - -markdown-it@^14.0.0: - version "14.0.0" - resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-14.0.0.tgz#b4b2ddeb0f925e88d981f84c183b59bac9e3741b" - integrity sha512-seFjF0FIcPt4P9U39Bq1JYblX0KZCjDLFFQPHpL5AzHpqPEKtosxmdq/LTVZnjfH7tjt9BxStm+wXcDBNuYmzw== +markdown-it@^14.0.0, markdown-it@^14.1.0: + version "14.1.0" + resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-14.1.0.tgz#3c3c5992883c633db4714ccb4d7b5935d98b7d45" + integrity sha512-a54IwgWPaeBCAAsv13YgmALOF1elABB08FxO9i+r4VFk5Vl4pKokRPeX8u5TCgSsPi6ec1otfLjdOpVcgbpshg== dependencies: argparse "^2.0.1" entities "^4.4.0" linkify-it "^5.0.0" mdurl "^2.0.0" punycode.js "^2.3.1" - uc.micro "^2.0.0" + uc.micro "^2.1.0" maximatch@^0.1.0: version "0.1.0" @@ -1566,11 +1492,6 @@ maximatch@^0.1.0: arrify "^1.0.0" minimatch "^3.0.0" -mdurl@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/mdurl/-/mdurl-1.0.1.tgz#fe85b2ec75a59037f2adfec100fd6c601761152e" - integrity sha512-/sKlQJCBYVY9Ers9hqzKou4H6V5UWc/M59TH2dvkt+84itfnq7uFOMLpOiOS4ujvHP4etln18fmIxA5R5fll0g== - mdurl@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/mdurl/-/mdurl-2.0.0.tgz#80676ec0433025dd3e17ee983d0fe8de5a2237e0" @@ -1586,7 +1507,7 @@ merge2@^1.3.0: resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg== -micromatch@^4.0.4, micromatch@^4.0.5: +micromatch@^4.0.4, micromatch@^4.0.5, micromatch@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.8.tgz#d66fa18f3a47076789320b9b1af32bd86d9fa202" integrity sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA== @@ -1594,25 +1515,23 @@ micromatch@^4.0.4, micromatch@^4.0.5: braces "^3.0.3" picomatch "^2.3.1" +mime@1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" + integrity sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg== + mime@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/mime/-/mime-3.0.0.tgz#b374550dca3a0c18443b0c950a6a58f1931cf7a7" integrity sha512-jSCU7/VB1loIWBZe14aEYHU/+1UMEHoaO7qxCOVJOw9GgH72VAWppxNcjU+x9a2k3GSIBXNKxXQFqRvvZ7vr3A== -minimatch@^3.0.0, minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2: +minimatch@^3.0.0, minimatch@^3.0.4: version "3.1.2" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== dependencies: brace-expansion "^1.1.7" -minimatch@^5.0.1: - version "5.1.6" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.6.tgz#1cfcb8cf5522ea69952cd2af95ae09477f122a96" - integrity sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g== - dependencies: - brace-expansion "^2.0.1" - minimatch@^9.0.1: version "9.0.3" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" @@ -1620,65 +1539,52 @@ minimatch@^9.0.1: dependencies: brace-expansion "^2.0.1" -minimist@^1.2.5, minimist@^1.2.6, minimist@^1.2.8: +minimatch@^9.0.4: + version "9.0.5" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.5.tgz#d74f9dd6b57d83d8e98cfb82133b03978bc929e5" + integrity sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow== + dependencies: + brace-expansion "^2.0.1" + +minimist@^1.2.8: version "1.2.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.8.tgz#c1a464e7693302e082a075cee0c057741ac4772c" integrity sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA== -minipass@^3.1.1: - version "3.3.6" - resolved "https://registry.yarnpkg.com/minipass/-/minipass-3.3.6.tgz#7bba384db3a1520d18c9c0e5251c3444e95dd94a" - integrity sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw== - dependencies: - yallist "^4.0.0" - "minipass@^5.0.0 || ^6.0.2 || ^7.0.0": version "7.0.4" resolved "https://registry.yarnpkg.com/minipass/-/minipass-7.0.4.tgz#dbce03740f50a4786ba994c1fb908844d27b038c" integrity sha512-jYofLM5Dam9279rdkWzqHozUo4ybjdZmCsDHePy5V/PbBcVMiSZR97gmAy45aqi8CK1lG2ECd356FU86avfwUQ== -mkdirp@^0.5.1: - version "0.5.6" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.6.tgz#7def03d2432dcae4ba1d611445c48396062255f6" - integrity sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw== - dependencies: - minimist "^1.2.6" +minipass@^7.0.3, minipass@^7.1.2: + version "7.1.2" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-7.1.2.tgz#93a9626ce5e5e66bd4db86849e7515e92340a707" + integrity sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw== + +mkdirp@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-3.0.1.tgz#e44e4c5607fb279c168241713cc6e0fea9adcb50" + integrity sha512-+NsyUUAZDmo6YVHzL/stxSu3t9YS1iljliy3BSDrXJ/dkn1KYdmtZODGGjLcc9XLgVVpH4KshHB8XmZgMhaBXg== moo@^0.5.2: version "0.5.2" resolved "https://registry.yarnpkg.com/moo/-/moo-0.5.2.tgz#f9fe82473bc7c184b0d32e2215d3f6e67278733c" integrity sha512-iSAJLHYKnX41mKcJKjqvnAN9sf0LMDTXDEvFv+ffuRR9a1MIuXLjMNL6EsnDHSkKLTWNqQQ5uo61P4EbU4NU+Q== -morphdom@^2.7.0: - version "2.7.2" - resolved "https://registry.yarnpkg.com/morphdom/-/morphdom-2.7.2.tgz#d48a87254f9b3031c0e1ec367736721fbaf22167" - integrity sha512-Dqb/lHFyTi7SZpY0a5R4I/0Edo+iPMbaUexsHHsLAByyixCDiLHPHyVoKVmrpL0THcT7V9Cgev9y21TQYq6wQg== +morphdom@^2.7.4: + version "2.7.4" + resolved "https://registry.yarnpkg.com/morphdom/-/morphdom-2.7.4.tgz#c61d511e935cc25ca588dfaa752461f27865865e" + integrity sha512-ATTbWMgGa+FaMU3FhnFYB6WgulCqwf6opOll4CBzmVDTLvPMmUPrEv8CudmLPK0MESa64+6B89fWOxP3+YIlxQ== ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" integrity sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A== -ms@2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" - integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== - -multimatch@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/multimatch/-/multimatch-5.0.0.tgz#932b800963cea7a31a033328fa1e0c3a1874dbe6" - integrity sha512-ypMKuglUrZUD99Tk2bUQ+xNQj43lPEfAeX2o9cTteAmShXy2VHDJpuwu1o0xqoKCt9jLVAvwyFKdLTPXKAfJyA== - dependencies: - "@types/minimatch" "^3.0.3" - array-differ "^3.0.0" - array-union "^2.1.0" - arrify "^2.0.1" - minimatch "^3.0.4" - -mustache@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/mustache/-/mustache-4.2.0.tgz#e5892324d60a12ec9c2a73359edca52972bf6f64" - integrity sha512-71ippSywq5Yb7/tVYyGbkBggbU8H3u5Rz56fH60jGFgr8uHwxs+aSKeqmluIVzM0m0kB7xQjKS6qPfd0b2ZoqQ== +ms@2.1.3, ms@^2.1.3: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== mz@^2.7.0: version "2.7.0" @@ -1694,11 +1600,6 @@ nanoid@^3.3.7: resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.7.tgz#d0c301a691bc8d54efa0a2226ccf3fe2fd656bd8" integrity sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g== -neo-async@^2.6.2: - version "2.6.2" - resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" - integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== - nice-try@^1.0.4: version "1.0.5" resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" @@ -1725,6 +1626,15 @@ node-fetch@^3.3.2: fetch-blob "^3.1.4" formdata-polyfill "^4.0.10" +node-retrieve-globals@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/node-retrieve-globals/-/node-retrieve-globals-6.0.0.tgz#682889351b83fb7b6c48d0e09b16a0487ff3ee1f" + integrity sha512-VoEp6WMN/JcbBrJr6LnFE11kdzpKiBKNPFrHCEK2GgFWtiYpeL85WgcZpZFFnWxAU0O65+b+ipQAy4Oxy/+Pdg== + dependencies: + acorn "^8.1.3" + acorn-walk "^8.3.2" + esm-import-transformer "^3.0.2" + normalize-package-data@^2.3.2: version "2.5.0" resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" @@ -1755,7 +1665,7 @@ npm-run-all@^4.1.5: shell-quote "^1.6.1" string.prototype.padend "^3.0.0" -nunjucks@^3.2.3: +nunjucks@^3.2.4: version "3.2.4" resolved "https://registry.yarnpkg.com/nunjucks/-/nunjucks-3.2.4.tgz#f0878eef528ce7b0aa35d67cc6898635fd74649e" integrity sha512-26XRV6BhkgK0VOxfbU5cQI+ICFUtMLixv1noZn1tGU38kQH5A5nmmbk/O45xdyBhD1esk47nKrY0mvQpZIhRjQ== @@ -1764,7 +1674,7 @@ nunjucks@^3.2.3: asap "^2.0.3" commander "^5.1.0" -object-assign@^4.0.1, object-assign@^4.1.1: +object-assign@^4.0.1: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" integrity sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg== @@ -1794,6 +1704,15 @@ object.assign@^4.1.5: has-symbols "^1.0.3" object-keys "^1.1.1" +object.entries@^1.1.7: + version "1.1.8" + resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.1.8.tgz#bffe6f282e01f4d17807204a24f8edd823599c41" + integrity sha512-cmopxi8VwRIAw/fkijJohSfpef5PdN0pMQJN6VC/ZKvn0LIknWD8KtgY6KlQdEc4tIjcQ3HxSMmnvtzIscdaYQ== + dependencies: + call-bind "^1.0.7" + define-properties "^1.2.1" + es-object-atoms "^1.0.0" + on-finished@2.4.1: version "2.4.1" resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.4.1.tgz#58c8c44116e54845ad57f14ab10b03533184ac3f" @@ -1801,12 +1720,10 @@ on-finished@2.4.1: dependencies: ee-first "1.1.1" -once@^1.3.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" - integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== - dependencies: - wrappy "1" +package-json-from-dist@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/package-json-from-dist/-/package-json-from-dist-1.0.1.tgz#4f1471a010827a86f94cfd9b0727e36d267de505" + integrity sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw== param-case@^2.1.1: version "2.1.1" @@ -1833,11 +1750,6 @@ parseurl@~1.3.3: resolved "https://registry.yarnpkg.com/parseurl/-/parseurl-1.3.3.tgz#9da19e7bee8d12dff0513ed5b76957793bc2e8d4" integrity sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ== -path-is-absolute@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" - integrity sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg== - path-key@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" @@ -1861,10 +1773,13 @@ path-scurry@^1.10.1: lru-cache "^9.1.1 || ^10.0.0" minipass "^5.0.0 || ^6.0.2 || ^7.0.0" -path-to-regexp@^6.2.1: - version "6.3.0" - resolved "https://registry.yarnpkg.com/path-to-regexp/-/path-to-regexp-6.3.0.tgz#2b6a26a337737a8e1416f9272ed0766b1c0389f4" - integrity sha512-Yhpw4T9C6hPpgPeA28us07OJeqZ5EzQTkbfwuhsUg0c237RomFoETJgmp2sa3F/41gfLE6G5cqcYwznmeEeOlQ== +path-scurry@^1.11.1: + version "1.11.1" + resolved "https://registry.yarnpkg.com/path-scurry/-/path-scurry-1.11.1.tgz#7960a668888594a0720b12a911d1a742ab9f11d2" + integrity sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA== + dependencies: + lru-cache "^10.2.0" + minipass "^5.0.0 || ^6.0.2 || ^7.0.0" path-type@^3.0.0: version "3.0.0" @@ -1976,6 +1891,11 @@ postcss@^8.4.23: picocolors "^1.0.0" source-map-js "^1.0.2" +posthtml-match-helper@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/posthtml-match-helper/-/posthtml-match-helper-2.0.2.tgz#fb0043fbd85a053da215a08e66264bbc9c80fde1" + integrity sha512-ehnazjlSwcGa3P2LlFYmTmcnaembTSt9dLWIRRDVHDPidf6InWAr9leKeeLvUXgnU32g6BrFS64Je+c2Ld+l9g== + posthtml-parser@^0.11.0: version "0.11.0" resolved "https://registry.yarnpkg.com/posthtml-parser/-/posthtml-parser-0.11.0.tgz#25d1c7bf811ea83559bc4c21c189a29747a24b7a" @@ -1990,16 +1910,6 @@ posthtml-render@^3.0.0: dependencies: is-json "^2.0.1" -posthtml-urls@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/posthtml-urls/-/posthtml-urls-1.0.0.tgz#3102d7b9e5c2fbdf19c8ec7ca825600dad3b9164" - integrity sha512-CMJ0L009sGQVUuYM/g6WJdscsq6ooAwhUuF6CDlYPMLxKp2rmCYVebEU+wZGxnQstGJhZPMvXsRhtqekILd5/w== - dependencies: - http-equiv-refresh "^1.0.0" - list-to-array "^1.1.0" - parse-srcset "^1.0.2" - promise-each "^2.2.0" - posthtml@^0.16.6: version "0.16.6" resolved "https://registry.yarnpkg.com/posthtml/-/posthtml-0.16.6.tgz#e2fc407f67a64d2fa3567afe770409ffdadafe59" @@ -2008,23 +1918,16 @@ posthtml@^0.16.6: posthtml-parser "^0.11.0" posthtml-render "^3.0.0" -prettier@^2.8.8: - version "2.8.8" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.8.tgz#e8c5d7e98a4305ffe3de2e1fc4aca1a71c28b1da" - integrity sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q== +prettier@^3.3.3: + version "3.3.3" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.3.3.tgz#30c54fe0be0d8d12e6ae61dbb10109ea00d53105" + integrity sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew== prismjs@^1.29.0: version "1.29.0" resolved "https://registry.yarnpkg.com/prismjs/-/prismjs-1.29.0.tgz#f113555a8fa9b57c35e637bba27509dcf802dd12" integrity sha512-Kx/1w86q/epKcmte75LNrEoT+lX8pBpavuAbvJWRXar7Hz8jrtF+e3vY751p0R8H9HdArwaCTNDDzHg/ScJK1Q== -promise-each@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/promise-each/-/promise-each-2.2.0.tgz#3353174eff2694481037e04e01f77aa0fb6d1b60" - integrity sha512-67roqt1k3QDA41DZ8xi0V+rF3GoaMiX7QilbXu0vXimut+9RcKBNZ/t60xCRgcsihmNUsEjh48xLfNqOrKblUg== - dependencies: - any-promise "^0.1.0" - promise@^7.0.1: version "7.3.1" resolved "https://registry.yarnpkg.com/promise/-/promise-7.3.1.tgz#064b72602b18f90f29192b8b1bc418ffd1ebd3bf" @@ -2037,114 +1940,6 @@ prr@~1.0.1: resolved "https://registry.yarnpkg.com/prr/-/prr-1.0.1.tgz#d3fc114ba06995a45ec6893f484ceb1d78f5f476" integrity sha512-yPw4Sng1gWghHQWj0B3ZggWUm4qVbPwPFcRG8KyxiU7J2OHFSoEHKS+EZ3fv5l1t9CyCiop6l/ZYeWbrgoQejw== -pug-attrs@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/pug-attrs/-/pug-attrs-3.0.0.tgz#b10451e0348165e31fad1cc23ebddd9dc7347c41" - integrity sha512-azINV9dUtzPMFQktvTXciNAfAuVh/L/JCl0vtPCwvOA21uZrC08K/UnmrL+SXGEVc1FwzjW62+xw5S/uaLj6cA== - dependencies: - constantinople "^4.0.1" - js-stringify "^1.0.2" - pug-runtime "^3.0.0" - -pug-code-gen@^3.0.3: - version "3.0.3" - resolved "https://registry.yarnpkg.com/pug-code-gen/-/pug-code-gen-3.0.3.tgz#58133178cb423fe1716aece1c1da392a75251520" - integrity sha512-cYQg0JW0w32Ux+XTeZnBEeuWrAY7/HNE6TWnhiHGnnRYlCgyAUPoyh9KzCMa9WhcJlJ1AtQqpEYHc+vbCzA+Aw== - dependencies: - constantinople "^4.0.1" - doctypes "^1.1.0" - js-stringify "^1.0.2" - pug-attrs "^3.0.0" - pug-error "^2.1.0" - pug-runtime "^3.0.1" - void-elements "^3.1.0" - with "^7.0.0" - -pug-error@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/pug-error/-/pug-error-2.0.0.tgz#5c62173cb09c34de2a2ce04f17b8adfec74d8ca5" - integrity sha512-sjiUsi9M4RAGHktC1drQfCr5C5eriu24Lfbt4s+7SykztEOwVZtbFk1RRq0tzLxcMxMYTBR+zMQaG07J/btayQ== - -pug-error@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/pug-error/-/pug-error-2.1.0.tgz#17ea37b587b6443d4b8f148374ec27b54b406e55" - integrity sha512-lv7sU9e5Jk8IeUheHata6/UThZ7RK2jnaaNztxfPYUY+VxZyk/ePVaNZ/vwmH8WqGvDz3LrNYt/+gA55NDg6Pg== - -pug-filters@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/pug-filters/-/pug-filters-4.0.0.tgz#d3e49af5ba8472e9b7a66d980e707ce9d2cc9b5e" - integrity sha512-yeNFtq5Yxmfz0f9z2rMXGw/8/4i1cCFecw/Q7+D0V2DdtII5UvqE12VaZ2AY7ri6o5RNXiweGH79OCq+2RQU4A== - dependencies: - constantinople "^4.0.1" - jstransformer "1.0.0" - pug-error "^2.0.0" - pug-walk "^2.0.0" - resolve "^1.15.1" - -pug-lexer@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/pug-lexer/-/pug-lexer-5.0.1.tgz#ae44628c5bef9b190b665683b288ca9024b8b0d5" - integrity sha512-0I6C62+keXlZPZkOJeVam9aBLVP2EnbeDw3An+k0/QlqdwH6rv8284nko14Na7c0TtqtogfWXcRoFE4O4Ff20w== - dependencies: - character-parser "^2.2.0" - is-expression "^4.0.0" - pug-error "^2.0.0" - -pug-linker@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/pug-linker/-/pug-linker-4.0.0.tgz#12cbc0594fc5a3e06b9fc59e6f93c146962a7708" - integrity sha512-gjD1yzp0yxbQqnzBAdlhbgoJL5qIFJw78juN1NpTLt/mfPJ5VgC4BvkoD3G23qKzJtIIXBbcCt6FioLSFLOHdw== - dependencies: - pug-error "^2.0.0" - pug-walk "^2.0.0" - -pug-load@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/pug-load/-/pug-load-3.0.0.tgz#9fd9cda52202b08adb11d25681fb9f34bd41b662" - integrity sha512-OCjTEnhLWZBvS4zni/WUMjH2YSUosnsmjGBB1An7CsKQarYSWQ0GCVyd4eQPMFJqZ8w9xgs01QdiZXKVjk92EQ== - dependencies: - object-assign "^4.1.1" - pug-walk "^2.0.0" - -pug-parser@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/pug-parser/-/pug-parser-6.0.0.tgz#a8fdc035863a95b2c1dc5ebf4ecf80b4e76a1260" - integrity sha512-ukiYM/9cH6Cml+AOl5kETtM9NR3WulyVP2y4HOU45DyMim1IeP/OOiyEWRr6qk5I5klpsBnbuHpwKmTx6WURnw== - dependencies: - pug-error "^2.0.0" - token-stream "1.0.0" - -pug-runtime@^3.0.0, pug-runtime@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/pug-runtime/-/pug-runtime-3.0.1.tgz#f636976204723f35a8c5f6fad6acda2a191b83d7" - integrity sha512-L50zbvrQ35TkpHwv0G6aLSuueDRwc/97XdY8kL3tOT0FmhgG7UypU3VztfV/LATAvmUfYi4wNxSajhSAeNN+Kg== - -pug-strip-comments@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/pug-strip-comments/-/pug-strip-comments-2.0.0.tgz#f94b07fd6b495523330f490a7f554b4ff876303e" - integrity sha512-zo8DsDpH7eTkPHCXFeAk1xZXJbyoTfdPlNR0bK7rpOMuhBYb0f5qUVCO1xlsitYd3w5FQTK7zpNVKb3rZoUrrQ== - dependencies: - pug-error "^2.0.0" - -pug-walk@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/pug-walk/-/pug-walk-2.0.0.tgz#417aabc29232bb4499b5b5069a2b2d2a24d5f5fe" - integrity sha512-yYELe9Q5q9IQhuvqsZNwA5hfPkMJ8u92bQLIMcsMxf/VADjNtEYptU+inlufAFYcWdHlwNfZOEnOOQrZrcyJCQ== - -pug@^3.0.2: - version "3.0.3" - resolved "https://registry.yarnpkg.com/pug/-/pug-3.0.3.tgz#e18324a314cd022883b1e0372b8af3a1a99f7597" - integrity sha512-uBi6kmc9f3SZ3PXxqcHiUZLmIXgfgWooKWXcwSGwQd2Zi5Rb0bT14+8CJjJgI8AB+nndLaNgHGrcc6bPIB665g== - dependencies: - pug-code-gen "^3.0.3" - pug-filters "^4.0.0" - pug-lexer "^5.0.1" - pug-linker "^4.0.0" - pug-load "^3.0.0" - pug-parser "^6.0.0" - pug-runtime "^3.0.1" - pug-strip-comments "^2.0.0" - punycode.js@^2.3.1: version "2.3.1" resolved "https://registry.yarnpkg.com/punycode.js/-/punycode.js-2.3.1.tgz#6b53e56ad75588234e79f4affa90972c7dd8cdb7" @@ -2155,6 +1950,11 @@ queue-microtask@^1.2.2: resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== +range-parser@~1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.1.tgz#3cf37023d199e1c24d1a55b84800c2f3e6468031" + integrity sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg== + read-cache@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/read-cache/-/read-cache-1.0.0.tgz#e664ef31161166c9751cdbe8dbcf86b5fb58f774" @@ -2178,21 +1978,6 @@ readdirp@~3.6.0: dependencies: picomatch "^2.2.1" -recursive-copy@^2.0.14: - version "2.0.14" - resolved "https://registry.yarnpkg.com/recursive-copy/-/recursive-copy-2.0.14.tgz#6358af3b5f8da89562f000db44720c4daa94b6d7" - integrity sha512-K8WNY8f8naTpfbA+RaXmkaQuD1IeW9EgNEfyGxSqqTQukpVtoOKros9jUqbpEsSw59YOmpd8nCBgtqJZy5nvog== - dependencies: - errno "^0.1.2" - graceful-fs "^4.1.4" - junk "^1.0.1" - maximatch "^0.1.0" - mkdirp "^0.5.1" - pify "^2.3.0" - promise "^7.0.1" - rimraf "^2.7.1" - slash "^1.0.0" - regexp.prototype.flags@^1.5.2: version "1.5.2" resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.5.2.tgz#138f644a3350f981a858c44f6bb1a61ff59be334" @@ -2208,7 +1993,7 @@ relateurl@^0.2.7: resolved "https://registry.yarnpkg.com/relateurl/-/relateurl-0.2.7.tgz#54dbf377e51440aca90a4cd274600d3ff2d888a9" integrity sha512-G08Dxvm4iDN3MLM0EsP62EDV9IuhXPR6blNz6Utcp7zyV3tr4HVNINt6MpaRWbxoOHT3Q7YN2P+jaHX8vUbgog== -resolve@^1.1.7, resolve@^1.10.0, resolve@^1.15.1, resolve@^1.22.2: +resolve@^1.1.7, resolve@^1.10.0, resolve@^1.22.2: version "1.22.8" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.8.tgz#b6c87a9f2aa06dfab52e3d70ac8cde321fa5a48d" integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== @@ -2222,12 +2007,12 @@ reusify@^1.0.4: resolved "https://registry.yarnpkg.com/reusify/-/reusify-1.0.4.tgz#90da382b1e126efc02146e90845a88db12925d76" integrity sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw== -rimraf@^2.7.1: - version "2.7.1" - resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.7.1.tgz#35797f13a7fdadc566142c29d4f07ccad483e3ec" - integrity sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w== +rimraf@^5.0.7: + version "5.0.10" + resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-5.0.10.tgz#23b9843d3dc92db71f96e1a2ce92e39fd2a8221c" + integrity sha512-l0OE8wL34P4nJH/H2ffoaniAokM2qSmrtXHmlpvYr5AVVX8msAyW0l8NVJFDxlSK4u3Uh/f41cQheDVdnYijwQ== dependencies: - glob "^7.1.3" + glob "^10.3.7" run-parallel@^1.1.9: version "1.2.0" @@ -2273,12 +2058,29 @@ semver-compare@^1.0.0: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== -semver@^7.3.8: - version "7.6.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.0.tgz#1a46a4db4bffcccd97b743b5005c8325f23d4e2d" - integrity sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg== +semver@^7.6.3: + version "7.6.3" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.3.tgz#980f7b5550bc175fb4dc09403085627f9eb33143" + integrity sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A== + +send@^0.19.0: + version "0.19.1" + resolved "https://registry.yarnpkg.com/send/-/send-0.19.1.tgz#1c2563b2ee4fe510b806b21ec46f355005a369f9" + integrity sha512-p4rRk4f23ynFEfcD9LA0xRYngj+IyGiEYyqqOak8kaN0TvNmuxC2dcVeBn62GpCeR2CpWqyHCNScTP91QbAVFg== dependencies: - lru-cache "^6.0.0" + debug "2.6.9" + depd "2.0.0" + destroy "1.2.0" + encodeurl "~2.0.0" + escape-html "~1.0.3" + etag "~1.8.1" + fresh "0.5.2" + http-errors "2.0.0" + mime "1.6.0" + ms "2.1.3" + on-finished "2.4.1" + range-parser "~1.2.1" + statuses "2.0.1" set-function-length@^1.2.1: version "1.2.1" @@ -2302,6 +2104,11 @@ set-function-name@^2.0.1: functions-have-names "^1.2.3" has-property-descriptors "^1.0.2" +setprototypeof@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/setprototypeof/-/setprototypeof-1.2.0.tgz#66c9a24a73f9fc28cbe66b09fed3d33dcaf1b424" + integrity sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw== + shebang-command@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" @@ -2361,7 +2168,7 @@ source-map-js@^1.0.2: resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw== -source-map@^0.6.1, source-map@~0.6.0: +source-map@~0.6.0: version "0.6.1" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== @@ -2397,12 +2204,12 @@ sprintf-js@~1.0.2: resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" integrity sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g== -ssri@^8.0.1: - version "8.0.1" - resolved "https://registry.yarnpkg.com/ssri/-/ssri-8.0.1.tgz#638e4e439e2ffbd2cd289776d5ca457c4f51a2af" - integrity sha512-97qShzy1AiyxvPNIkLWoGua7xoQzzPjQ0HAH4B0rWKo7SZ6USuPcrUiAFrws0UH8RrbWmgq3LMTObhPIHbbBeQ== +ssri@^11.0.0: + version "11.0.0" + resolved "https://registry.yarnpkg.com/ssri/-/ssri-11.0.0.tgz#ab39fc4382264839d1803ee7c53d00e5fa467739" + integrity sha512-aZpUoMN/Jj2MqA4vMCeiKGnc/8SuSyHbGSBdgFbZxP8OJGF/lFkIuElzPxsN0q8TQQ+prw3P4EDfB3TBHHgfXw== dependencies: - minipass "^3.1.1" + minipass "^7.0.3" statuses@2.0.1: version "2.0.1" @@ -2523,22 +2330,15 @@ supports-color@^5.3.0: dependencies: has-flag "^3.0.0" -supports-color@^7.1.0: - version "7.2.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" - integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== - dependencies: - has-flag "^4.0.0" - supports-preserve-symlinks-flag@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== -tailwindcss@^3.4.1: - version "3.4.1" - resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.4.1.tgz#f512ca5d1dd4c9503c7d3d28a968f1ad8f5c839d" - integrity sha512-qAYmXRfk3ENzuPBakNK0SRrUDipP8NQnEY6772uDhflcQz5EhRdD7JNZxyrFHVQNCwULPBn6FNPp9brpO7ctcA== +tailwindcss@^3.4.14: + version "3.4.14" + resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.4.14.tgz#6dd23a7f54ec197b19159e91e3bb1e55e7aa73ac" + integrity sha512-IcSvOcTRcUtQQ7ILQL5quRDg7Xs93PdJEk1ZLbhhvJc7uj/OAhYOnruEiwnGgBvUtaUAJ8/mhSw1o8L2jCiENA== dependencies: "@alloc/quick-lru" "^5.2.0" arg "^5.0.2" @@ -2548,7 +2348,7 @@ tailwindcss@^3.4.1: fast-glob "^3.3.0" glob-parent "^6.0.2" is-glob "^4.0.3" - jiti "^1.19.1" + jiti "^1.21.0" lilconfig "^2.1.0" micromatch "^4.0.5" normalize-path "^3.0.0" @@ -2577,11 +2377,6 @@ thenify-all@^1.0.0: dependencies: any-promise "^1.0.0" -to-fast-properties@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" - integrity sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog== - to-regex-range@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" @@ -2589,10 +2384,10 @@ to-regex-range@^5.0.1: dependencies: is-number "^7.0.0" -token-stream@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/token-stream/-/token-stream-1.0.0.tgz#cc200eab2613f4166d27ff9afc7ca56d49df6eb4" - integrity sha512-VSsyNPPW74RpHwR8Fc21uubwHY7wMDeJLys2IX5zJNih+OnAnaifKHo+1LHT7DAdloQ7apeaaWg8l7qnf/TnEg== +toidentifier@1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.1.tgz#3be34321a88a820ed1bd80dfaa33e479fbb8dd35" + integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== ts-interface-checker@^0.1.9: version "0.1.13" @@ -2643,17 +2438,17 @@ typed-array-length@^1.0.4: is-typed-array "^1.1.13" possible-typed-array-names "^1.0.0" -uc.micro@^1.0.1, uc.micro@^1.0.5: - version "1.0.6" - resolved "https://registry.yarnpkg.com/uc.micro/-/uc.micro-1.0.6.tgz#9c411a802a409a91fc6cf74081baba34b24499ac" - integrity sha512-8Y75pvTYkLJW2hWQHXxoqRgV7qb9B+9vFEtidML+7koHUFapnVJAZ6cKs+Qjz5Aw3aZWHMC6u0wJE3At+nSGwA== - uc.micro@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/uc.micro/-/uc.micro-2.0.0.tgz#84b3c335c12b1497fd9e80fcd3bfa7634c363ff1" integrity sha512-DffL94LsNOccVn4hyfRe5rdKa273swqeA5DJpMOeFmEn1wCDc7nAbbB0gXlgBCL7TNzeTv6G7XVWzan7iJtfig== -uglify-js@^3.1.4, uglify-js@^3.5.1: +uc.micro@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/uc.micro/-/uc.micro-2.1.0.tgz#f8d3f7d0ec4c3dea35a7e3c8efa4cb8b45c9e7ee" + integrity sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A== + +uglify-js@^3.5.1: version "3.17.4" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.17.4.tgz#61678cf5fa3f5b7eb789bb345df29afb8257c22c" integrity sha512-T9q82TJI9e/C1TAxYvfb16xO120tMVFZrGA3f9/P4424DNu6ypK103y0GPFVa17yotwSyZW5iYXgjYHkGrJW/g== @@ -2678,6 +2473,11 @@ upper-case@^1.1.1: resolved "https://registry.yarnpkg.com/upper-case/-/upper-case-1.1.3.tgz#f6b4501c2ec4cdd26ba78be7222961de77621598" integrity sha512-WRbjgmYzgXkCV7zNVpy5YgrHgbBv126rMALQQMrmzOVC4GM2waQ9x7xtm8VU+1yF2kWyPzI9zbZ48n4vSxwfSA== +urlpattern-polyfill@^10.0.0: + version "10.0.0" + resolved "https://registry.yarnpkg.com/urlpattern-polyfill/-/urlpattern-polyfill-10.0.0.tgz#f0a03a97bfb03cdf33553e5e79a2aadd22cac8ec" + integrity sha512-H/A06tKD7sS1O1X2SshBVeA5FLycRpjqiBeqGKmBwBDBy28EnRjORxTNe269KSSr5un5qyWi1iL61wLxpd+ZOg== + util-deprecate@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" @@ -2691,11 +2491,6 @@ validate-npm-package-license@^3.0.1: spdx-correct "^3.0.0" spdx-expression-parse "^3.0.0" -void-elements@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/void-elements/-/void-elements-3.1.0.tgz#614f7fbf8d801f0bb5f0661f5b2f5785750e4f09" - integrity sha512-Dhxzh5HZuiHQhbvTW9AMetFfBHDMYpo23Uo9btPXgdYP+3T5S+p+jgNy7spra+veYhBP2dCSgxR/i2Y02h5/6w== - web-streams-polyfill@^3.0.3: version "3.3.3" resolved "https://registry.yarnpkg.com/web-streams-polyfill/-/web-streams-polyfill-3.3.3.tgz#2073b91a2fdb1fbfbd401e7de0ac9f8214cecb4b" @@ -2737,21 +2532,6 @@ which@^2.0.1: dependencies: isexe "^2.0.0" -with@^7.0.0: - version "7.0.2" - resolved "https://registry.yarnpkg.com/with/-/with-7.0.2.tgz#ccee3ad542d25538a7a7a80aad212b9828495bac" - integrity sha512-RNGKj82nUPg3g5ygxkQl0R937xLyho1J24ItRCBTr/m1YnZkzJy1hUiHUJrc/VlsDQzsCnInEGSg3bci0Lmd4w== - dependencies: - "@babel/parser" "^7.9.6" - "@babel/types" "^7.9.6" - assert-never "^1.2.1" - babel-walk "3.0.0-canary-5" - -wordwrap@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" - integrity sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q== - "wrap-ansi-cjs@npm:wrap-ansi@^7.0.0": version "7.0.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" @@ -2770,20 +2550,10 @@ wrap-ansi@^8.1.0: string-width "^5.0.1" strip-ansi "^7.0.1" -wrappy@1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" - integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== - -ws@^8.13.0: - version "8.17.1" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.17.1.tgz#9293da530bb548febc95371d90f9c878727d919b" - integrity sha512-6XQFvXTkbfUOZOKKILFG1PDK2NDQs4azKQl26T0YS5CxqWLgXajbPZ+h4gZekJyRqFU8pvnbAbbs/3TgRPy+GQ== - -yallist@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" - integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== +ws@^8.18.0: + version "8.18.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.18.0.tgz#0d7505a6eafe2b0e712d232b42279f53bc289bbc" + integrity sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw== yaml@^2.3.4: version "2.3.4"