承接 web-vision/deepl-base 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

web-vision/deepl-base

Composer 安装命令:

composer require web-vision/deepl-base

包简介

DeepL Base - Provides shared things across deepl related extensions, for example a shared point when overriding same TYPO3 backend fluid files are required and similar.

README 文档

README

URL
Repository: https://github.com/web-vision/deepl-base
Read online: https://docs.typo3.org/p/web-vision/deepl-base/main/en-us/
TER: https://extensions.typo3.org/extension/deepl_base/

Description

This package is a TYPO Extension providing some shared things required by multiple deepl translate or write related extensions, which should work together but must work independent of each other, requiring this shared base extension as common ground.

Note

This extension does not provide anything useful as direct usage, and makes no sense to install it standalone. Should only be a dependency for other extensions.

Compatibility

Branch Version TYPO3 PHP
main 2.0.x-dev v13 8.2, 8.3, 8.4, 8.5 (depending on TYPO3)
1 ^1, 1.0.x-dev v12 + v13 8.1, 8.2, 8.3, 8.4 (depending on TYPO3)

Installation

Install with your flavour:

  • TER
  • Extension Manager
  • composer

We prefer composer installation:

composer require 'web-vision/deepl-base':'2.*.*@dev'

Note

Until first release you may need to ensure allowing dev versions but preferring stable releases which requires:

composer config minimum-stability "dev" \
&& composer config "prefer-stable" true \
&& composer require 'web-vision/deepl-base':'2.*.*@dev'

Documentation

Note

For the start, the documentation for developers and integrators is contained here in the README.md file and will be converted into rendered documentation at a later point.

PageLayout module localization model - Translation Modes

ViewHelper

InjectVariablesViewHelper

InjectVariablesViewHelper can be placed in fluid templates and requires to define a speaking identifier used to dispatch the PSR-14 ModifyInjectVariablesViewHelperEvent event, which can be used to set or modify variables either in the global current template scope or for children rendering scope.

Example usage in fluid template
<html
    data-namespace-typo3-fluid="true"
    xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
    xmlns:deeplbase="http://typo3.org/ns/WebVision/Deepl/Base/ViewHelpers"
>
<deeplbase:injectVariables identifier="custom-template-variable-inject">
    Render {globalOrLocalVariableProviderVariable} only available in children
    context.
</deeplbase:injectVariables>
Render {globalOnlyVariableProviderVariable} only ignoring local variable provider
changes.
</html>
Explicit usage from this extension
<html
    data-namespace-typo3-fluid="true"
    xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
    xmlns:deeplbase="http://typo3.org/ns/WebVision/Deepl/Base/ViewHelpers"
>
<deeplbase:injectVariables identifier="languageTranslationDropdown">
    <f:for each="{translationPartials}" as="translationPartial">
        <f:render partial="{translationPartial}" arguments="{_all}"/>
    </f:for>
</deeplbase:injectVariables>
</html>
What does it do?

This part renders partials registered by an EventListener. With this identifier an extension could provide its own translation dropdown for the Backend PageView. The extension must be self-aware registering a partial, which is callable by Fluid.

A working example is provided at Classes/EventListener/DefaultTranslationDropdownEventListener.php and Resources/Private/Backend/Partials/Translation/DefaultTranslationDropdown.html.

ModifyInjectVariablesViewHelperEvent
  • getIdentifier(): string: identifier used within the fluid template and should
  • getGlobalVariableProvider(): VariableProviderInterface: provides the fluid variable container of the current context. Modification will be available after the ViewHelper and within the children context unless overridden within the getLocalVariableProvider.
  • getLocalVariableProvider(): VariableProviderInterface: provides the fluid variable container with children context only variables, overriding global variables. Local variable does not change the variables in the template after the ViewHelper call.

Modified Backend Templates

Note

Modifed backend templates are listed here describing the modification, for example, if one or more InjectVariableViewhelper has been placed along with the identifier and use-case.

Create a release (maintainers only)

Prerequisites:

  • git binary
  • ssh key allowed to push new branches to the repository
  • GitHub command line tool gh installed and configured with user having permission to create pull requests.

Prepare release locally

Set RELEASE_BRANCH to branch release should happen, for example: 'main'. Set RELEASE_VERSION to release version working on, for example: '1.0.0'.

echo '>> Create release based on configuration' ; \
  RELEASE_BRANCH='main' ; \
  RELEASE_VERSION="2.0.4" ; \
  DEV_VERSION="2.0.5" ; \
  echo ">> Checkout branches" && \
  git checkout main && \
  git fetch --all && \
  git pull --rebase && \
  git checkout ${RELEASE_BRANCH} && \
  git pull --rebase && \
  echo ">> Create release ${RELEASE_VERSION}" && \
  git checkout -b release-${RELEASE_VERSION} && \
  sed -i "s/^COMPOSER_ROOT_VERSION.*/COMPOSER_ROOT_VERSION=\"${RELEASE_VERSION}\"/" Build/Scripts/runTests.sh && \
  sed -i "s/^  RELEASE_VERSION.*/  RELEASE_VERSION=\"${RELEASE_VERSION}\" ; \\\\/" README.md && \
  sed -i "s/^  DEV_VERSION.*/  DEV_VERSION=\"${DEV_VERSION}\" ; \\\\/" README.md && \
  tailor set-version ${RELEASE_VERSION} && \
  composer config "extra"."typo3/cms"."version" "${RELEASE_VERSION}" && \
  echo "${RELEASE_VERSION}" > VERSION && \
  git add . && \
  git commit -m "[RELEASE] ${RELEASE_VERSION}" && \
  git push --set-upstream origin release-${RELEASE_VERSION} && \
  gh pr create --fill --base ${RELEASE_BRANCH} --title "[RELEASE] ${RELEASE_VERSION}" && \
  sleep 10 && \
  gh pr checks --watch --interval 2 && \
  sleep 10 && \
  gh pr merge -rd --admin && \
  git remote prune origin && \
  git tag ${RELEASE_VERSION} && \
  git push origin ${RELEASE_VERSION} && \
  echo ">> Post-release - set dev version: ${DEV_VERSION}-dev" && \
  git checkout -b set-version-${DEV_VERSION} && \
  sed -i "s/^COMPOSER_ROOT_VERSION.*/COMPOSER_ROOT_VERSION=\"${DEV_VERSION}-dev\"/" Build/Scripts/runTests.sh && \
  tailor set-version ${DEV_VERSION} && \
  composer config "extra"."typo3/cms"."version" "${DEV_VERSION}-dev" && \
  echo "${DEV_VERSION}-dev" > VERSION && \
  git add . && \
  git commit -m "[TASK] Set dev version ${DEV_VERSION}" && \
  git push --set-upstream origin set-version-${DEV_VERSION} && \
  gh pr create --fill --base ${RELEASE_BRANCH} --title "[TASK] Set dev version \"${DEV_VERSION}-dev\"" && \
  sleep 10 && \
  gh pr checks --watch --interval 2 && \
  sleep 10 && \
  gh pr merge -rd --admin && \
  git remote prune origin

web-vision/deepl-base 适用场景与选型建议

web-vision/deepl-base 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 132.23k 次下载、GitHub Stars 达 0, 最近一次更新时间为 2025 年 05 月 16 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「extension」 「translate」 「TYPO3 CMS」 「deepl」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 web-vision/deepl-base 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 web-vision/deepl-base 我们能提供哪些服务?
定制开发 / 二次开发

基于 web-vision/deepl-base 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 132.23k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 35
  • 依赖项目数: 4
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 5
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2025-05-16