Skip to content

Commit

Permalink
chore(vite): Migrate from webpack to vite
Browse files Browse the repository at this point in the history
Signed-off-by: Raimund Schlüßler <[email protected]>
  • Loading branch information
raimund-schluessler committed Dec 10, 2023
1 parent c2d6f98 commit 8429627
Show file tree
Hide file tree
Showing 20 changed files with 3,388 additions and 4,767 deletions.
File renamed without changes.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -253,3 +253,6 @@ coverage
.phpunit.result.cache

.php_cs.cache

css/*
!css/tasks-icon.css
17 changes: 5 additions & 12 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -88,15 +88,8 @@ update-composer: composer.phar
# Removes the build directory and the compiled files
.PHONY: clean
clean:
rm -f ./js/tasks-main.js
rm -f ./js/tasks-main.js.map
rm -f ./js/tasks-main.js.LICENSE.txt
rm -f ./js/tasks-dashboard.js
rm -f ./js/tasks-dashboard.js.map
rm -f ./js/tasks-dashboard.js.LICENSE.txt
rm -f ./js/tasks-talk.js
rm -f ./js/tasks-talk.js.map
rm -f ./js/tasks-talk.js.LICENSE.txt
rm -rf ./js/*
ls -d ./css/* | grep -P '^((?!tasks-icon.css).)*$$' | xargs -r -d'\n' rm
rm -rf $(build_directory)

# Same as clean but also removes dependencies installed by npm
Expand All @@ -115,7 +108,7 @@ appstore: clean build-js-production
--exclude=/.babelrc.js \
--exclude=/.codecov.yml \
--exclude=/.editorconfig \
--exclude=/.eslintrc.js \
--exclude=/.eslintrc.cjs \
--exclude=/.gitattributes \
--exclude=/.gitignore \
--exclude=/.phpunit.result.cache \
Expand All @@ -129,7 +122,7 @@ appstore: clean build-js-production
--exclude=/.travis.yml \
--exclude=/.tx \
--exclude=/.v8flags*.json \
--exclude=/babel.config.js \
--exclude=/babel.config.cjs \
--exclude=/build.xml \
--exclude=/clover.integration.xml \
--exclude=/clover.unit.xml \
Expand All @@ -146,7 +139,7 @@ appstore: clean build-js-production
--exclude=/phpunit.integration.xml \
--exclude=/README.md \
--exclude=/stylelint.config.js \
--exclude=/webpack.config.js \
--exclude=/vite.config.mjs \
--exclude=/build \
--exclude=/coverage \
--exclude=/img/src \
Expand Down
File renamed without changes.
File renamed without changes.
3 changes: 0 additions & 3 deletions img/color_picker.svg

This file was deleted.

4 changes: 3 additions & 1 deletion lib/Dashboard/TasksWidget.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public function getOrder(): int {
* @inheritDoc
*/
public function getIconClass(): string {
return 'app-icon-tasks';
return 'icon-tasks';
}

/**
Expand All @@ -83,5 +83,7 @@ public function getUrl(): ?string {
*/
public function load(): void {
\OCP\Util::addScript('tasks', 'tasks-dashboard');
\OCP\Util::addStyle('tasks', 'tasks-dashboard');
\OCP\Util::addStyle('tasks', 'tasks-icon');
}
}
3 changes: 2 additions & 1 deletion lib/Listeners/BeforeTemplateRenderedListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ public function handle(Event $event): void {
$pathInfo = $this->request->getPathInfo();
if (strpos($pathInfo, '/call/') === 0 || strpos($pathInfo, '/apps/spreed') === 0) {
Util::addScript('tasks', 'tasks-talk');
Util::addStyle('tasks', 'tasks-talk');
Util::addStyle('tasks', 'tasks-icon');
Util::addStyle('tasks', 'tasks-TaskCreateDialog');
}
}
}
Loading

0 comments on commit 8429627

Please sign in to comment.