Sync from SUSE:SLFO:Main rubygem-js-routes revision 73171796b0368aa6ed8349971fb58333

This commit is contained in:
2025-02-06 18:26:36 +01:00
commit cec0bf7b19
5 changed files with 628 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

70
gem2rpm.yml Normal file
View File

@@ -0,0 +1,70 @@
# ---
# ## used by gem2rpm
# :summary: this is a custom summary
# ## used by gem2rpm
# :description: |-
# this is a custom description
#
# it can be multiline
# ## used by gem2rpm
# :license: MIT or Ruby
# ## used by gem2rpm and gem_packages
# :version_suffix: -x_y
# ## used by gem2rpm and gem_packages
# :disable_docs: true
# ## used by gem2rpm
# :disable_automatic_rdoc_dep: true
# ## used by gem2rpm
# :preamble: |-
# BuildRequires: foobar
# Requires: foobar
# ## used by gem2rpm
# :patches:
# foo.patch: -p1
# bar.patch:
# ## used by gem2rpm
:sources:
# - foo.desktop
# - bar.desktop
# :gem_install_args: '....'
# ## used by gem2rpm
# :pre_install: |-
# %if 0%{?use_system_libev}
# export USE_VENDORED_LIBEV="no"
# %endif
# ## used by gem2rpm
# :post_install: |-
# # delete custom files here or do other fancy stuff
# install -D -m 0644 %{S:1} %{buildroot}%{_bindir}/gem2rpm-opensuse
# ## used by gem2rpm
# :testsuite_command: |-
# (pushd %{buildroot}%{gem_base}/gems/%{mod_full_name} && rake test)
# ## used by gem2rpm
# :filelist: |-
# /usr/bin/gem2rpm-opensuse
# ## used by gem2rpm
# :scripts:
# :post: |-
# /bin/echo foo
# ## used by gem_packages
# :main:
# :preamble: |-
# Requires: util-linux
# Recommends: pwgen
# :filelist: |-
# /usr/bin/gem2rpm-opensuse
# ## used by gem_packages
# :custom:
# apache:
# :preamble: |-
# Requires: .....
# :filelist: |-
# /etc/apache2/conf.d/passenger.conf
# :summary: Custom summary is optional
# :description: |-
# Custom description is optional
#
# bar
# :post: |-
# /bin/echo foo
#

BIN
js-routes-2.2.10.gem (Stored with Git LFS) Normal file

Binary file not shown.

478
rubygem-js-routes.changes Normal file
View File

@@ -0,0 +1,478 @@
-------------------------------------------------------------------
Mon Nov 4 16:57:24 UTC 2024 - Dan Čermák <dan.cermak@posteo.net>
- New upstream release 2.2.10, see bundled CHANGELOG.md
-------------------------------------------------------------------
Tue Nov 28 08:11:50 UTC 2023 - Dan Čermák <dan.cermak@posteo.net>
- ## v2.2.8
* Leave emoji symbols intact when encoding URI fragment [#312](https://github.com/railsware/js-routes/issues/312)
* Use webpacker config variable instead of hardcode [#309](https://github.com/railsware/js-routes/issues/309)
* Use `File.exist?` to be compatible with all versions of ruby [#310](https://github.com/railsware/js-routes/issues/310)
-------------------------------------------------------------------
Fri Nov 3 07:40:25 UTC 2023 - Dan Čermák <dan.cermak@posteo.net>
- ## v2.2.7
* Fix ESM Tree Shaking [#306](https://github.com/railsware/js-routes/issues/306)
## v2.2.6
* Prefer to extend `javascript:build` instead of `assets:precompile`. [#305](https://github.com/railsware/js-routes/issues/305)
* Add stimulus framework application.js location to generators
-------------------------------------------------------------------
Fri Apr 28 08:25:09 UTC 2023 - Marcus Rueckert <mrueckert@suse.de>
- updated to version 2.2.5
* Upgraded eslint and prettier versions [#304](https://github.com/railsware/js-routes/issues/304)
* Fix middleware generator [#300](https://github.com/railsware/js-routes/issues/300)
* Support `params` special parameter
-------------------------------------------------------------------
Thu Aug 4 13:16:15 UTC 2022 - Stephan Kulow <coolo@suse.com>
- updated to version 2.2.4
* Fix rails engine loading if sprockets is not in Gemfile. Fixes [#294](https://github.com/railsware/js-routes/issues/294)
-------------------------------------------------------------------
Thu Apr 28 05:34:07 UTC 2022 - Stephan Kulow <coolo@suse.com>
- updated to version 2.2.3
* Fixed NIL module type namespace defintion [#297](https://github.com/railsware/js-routes/issues/297).
* The patch may cause a problem with nested `namespace` option
* Ex. Value like `MyProject.Routes` requires to define `window.MyProject` before importing the routes file
-------------------------------------------------------------------
Tue Feb 15 07:31:20 UTC 2022 - Stephan Kulow <coolo@suse.com>
- updated to version 2.2.2
see installed CHANGELOG.md
## v2.2.2.
* Fix custom file path [#295](https://github.com/railsware/js-routes/issues/295)
-------------------------------------------------------------------
Tue Jan 25 07:07:17 UTC 2022 - Stephan Kulow <coolo@suse.com>
updated to version 2.2.1
see installed CHANGELOG.md
## v2.2.1
* Improve generator to update route files on `assets:precompile` and add them to `.gitignore by default` [#288](https://github.com/railsware/js-routes/issues/288#issuecomment-1012182815)
## v2.2.0
* Use Rack Middleware to automatically update routes file in development [#288](https://github.com/railsware/js-routes/issues/288)
* This setup is now a default recommended due to lack of any downside comparing to [ERB Loader](./Readme.md#webpacker) and [Manual Setup](./Readme.md#advanced-setup)
## v2.1.3
* Fix `default_url_options` bug. [#290](https://github.com/railsware/js-routes/issues/290)
## v2.1.2
* Improve browser window object detection. [#287](https://github.com/railsware/js-routes/issues/287)
## v2.1.1
* Added webpacker generator `./bin/rails generate js_routes:webpacker`
* Reorganized Readme to describe different setups with their pros and cons more clearly
## v2.1.0
* Support typescript defintions file aka `routes.d.ts`. See [Readme.md](./Readme.md#definitions) for more information.
-------------------------------------------------------------------
Mon Jul 26 05:59:53 UTC 2021 - Stephan Kulow <coolo@suse.com>
updated to version 2.0.8
see installed CHANGELOG.md
## v2.0.8
* Forbid usage of `namespace` option if `module_type` is not `nil`. [#281](https://github.com/railsware/js-routes/issues/281).
-------------------------------------------------------------------
Thu Jun 24 17:33:10 UTC 2021 - Stephan Kulow <coolo@suse.com>
updated to version 2.0.7
see installed CHANGELOG.md
## v2.0.7
* Remove source map annotation from JS file. Fixes [#277](https://github.com/railsware/js-routes/issues/277)
* Generated file is not minified, so it is better to use app side bundler/compressor for source maps
## v2.0.6
* Disable `namespace` option default for all envs [#278](https://github.com/railsware/js-routes/issues/278)
## v2.0.5
* Fixed backward compatibility issue [#276](https://github.com/railsware/js-routes/issues/276)
## v2.0.4
* Fixed backward compatibility issue [#275](https://github.com/railsware/js-routes/issues/275)
## v2.0.3
* Fixed backward compatibility issue [#275](https://github.com/railsware/js-routes/issues/275)
## v2.0.2
* Fixed backward compatibility issue [#274](https://github.com/railsware/js-routes/issues/274)
## v2.0.1
* Fixed backward compatibility issue [#272](https://github.com/railsware/js-routes/issues/272)
## v2.0.0
Version 2.0 has some breaking changes.
See [UPGRADE TO 2.0](./VERSION_2_UPGRADE.md) for guidance.
* `module_type` option support
* `documentation` option spport
* Migrated implementation to typescript
* ESM tree shaking support
* Support camel case `toParam` version of `to_param` property
-------------------------------------------------------------------
Wed Jan 20 12:51:18 UTC 2021 - Stephan Kulow <coolo@suse.com>
updated to version 1.4.14
see installed CHANGELOG.md
## v1.4.14
* Fix compatibility with UMD modules #237 [Comment](https://github.com/railsware/js-routes/issues/237#issuecomment-752754679)
## v1.4.13
* Improve compatibility with node environment #269.
* Change default file location configuration to Webpacker if both Webpacker and Sprockets are loaded
## v1.4.11
* Use app/javascript/routes.js as a default file location if app/javascript directory exists
* Add `default` export for better experience when used as es6 module
## v1.4.10
* Require engine only when sprockets is loaded #257.
-------------------------------------------------------------------
Mon Feb 10 15:00:51 UTC 2020 - Stephan Kulow <coolo@suse.com>
- updated to version 1.4.9
see installed CHANGELOG.md
## v1.4.9
* Allow to specify null namespace and receive routes as an object without assigning it anywhere #247
-------------------------------------------------------------------
Fri Jul 19 09:20:12 UTC 2019 - Stephan Kulow <coolo@suse.com>
- updated to version 1.4.7
see installed CHANGELOG.md
## v1.4.7
* Fix a LocalJumpError on secondary initialization of the app #248
-------------------------------------------------------------------
Sun May 5 09:32:27 UTC 2019 - Stephan Kulow <coolo@suse.com>
- updated to version 1.4.6
see installed CHANGELOG.md
## v1.4.6
* Fix regression of #244 in #243
## v1.4.5
* Fix escaping inside route parameters and globbing #244
## v1.4.4
-------------------------------------------------------------------
Mon May 7 12:04:09 UTC 2018 - factory-auto@kulow.org
- updated to version 1.4.4
see installed CHANGELOG.md
* More informative stack trace for ParameterMissing error #235
## v1.4.3
* Proper implementation of the :subdomain option in routes generation
-------------------------------------------------------------------
Tue Jan 9 07:33:54 UTC 2018 - coolo@suse.com
- updated to version 1.4.3
see installed CHANGELOG.md
-------------------------------------------------------------------
Sun Dec 3 19:23:22 UTC 2017 - coolo@suse.com
- updated to version 1.4.2
see installed CHANGELOG.md
## v1.4.2
* Added JsRoutes namespace to Engine #230
-------------------------------------------------------------------
Mon Sep 11 12:42:03 UTC 2017 - coolo@suse.com
- updated to version 1.4.1
see installed CHANGELOG.md
## v1.4.1
* Fixed bug when js-routes is used in envs without window.location #224
## v1.4.0
* __breaking change!__ Implemented Routes.config() and Routes.configure instead of Routes.defaults
New methods support 4 options at the moment:
``` js
Routes.configuration(); // =>
/*
{
prefix: "",
default_url_options: {},
special_options_key: '_options',
serializer: function(...) { ... }
}
*/
Routes.configure({
prefix: '/app',
default_url_options: {format: 'json'},
special_options_key: '_my_options_key',
serializer: function(...) { ... }
});
```
## v1.3.3
* Improved optional parameters support #216
## v1.3.2
* Added `application` option #214
## v1.3.1
* Raise error object with id null passed as route paramter #209
* Sprockets bugfixes #212
-------------------------------------------------------------------
Wed Mar 1 05:40:51 UTC 2017 - coolo@suse.com
- updated to version 1.3.3
see installed CHANGELOG.md
-------------------------------------------------------------------
Fri Dec 9 05:35:41 UTC 2016 - coolo@suse.com
- updated to version 1.3.2
see installed CHANGELOG.md
-------------------------------------------------------------------
Tue Nov 29 05:36:01 UTC 2016 - coolo@suse.com
- updated to version 1.3.1
see installed CHANGELOG.md
## v1.3.0
* Introduce the special _options key. Fixes #86
-------------------------------------------------------------------
Thu Aug 18 04:31:27 UTC 2016 - coolo@suse.com
- updated to version 1.3.0
see installed CHANGELOG.md
-------------------------------------------------------------------
Thu Aug 11 04:36:53 UTC 2016 - coolo@suse.com
- updated to version 1.2.9
see installed CHANGELOG.md
## v1.2.9
* Fixed deprecation varning on Sprockets 3.7
-------------------------------------------------------------------
Sat Aug 6 04:37:31 UTC 2016 - coolo@suse.com
- updated to version 1.2.8
see installed CHANGELOG.md
## v1.2.8
* Bugfix warning on Sprockets 4.0 #202
-------------------------------------------------------------------
Fri Jul 15 04:34:16 UTC 2016 - coolo@suse.com
- updated to version 1.2.7
see installed CHANGELOG.md
## v1.2.7
* Drop support 1.9.3
* Add helper for indexOf, if no native implementation in JS engine
* Add sprockets3 compatibility
* Bugfix domain defaults to path #197
-------------------------------------------------------------------
Fri Jun 3 04:29:19 UTC 2016 - coolo@suse.com
- updated to version 1.2.6
see installed CHANGELOG.md
## v1.2.6
* Use default prefix from `Rails.application.config.relative_url_root` #186
* Bugfix route globbing with optional fragments bug #191
-------------------------------------------------------------------
Wed Apr 6 06:23:51 UTC 2016 - coolo@suse.com
- updated to version 1.2.5
see installed CHANGELOG.md
## v1.2.5
* Bugfix subdomain default parameter in routes #184
* Bugfix infinite recursion in some specific route sets #183
## v1.2.4
* Additional bugfixes to support all versions of Sprockets: 2.x and 3.x
-------------------------------------------------------------------
Sun Feb 14 05:31:32 UTC 2016 - coolo@suse.com
- updated to version 1.2.4
see installed CHANGELOG.md
-------------------------------------------------------------------
Thu Jan 28 05:30:45 UTC 2016 - coolo@suse.com
- updated to version 1.2.3
see installed CHANGELOG.md
## v1.2.3
* Sprockets ~= 3.0 support
## v1.2.2
* Sprockets ~= 3.0 support
* Support default parameters specified in route.rb file
-------------------------------------------------------------------
Thu Jan 21 05:38:29 UTC 2016 - coolo@suse.com
- updated to version 1.2.2
see installed CHANGELOG.md
## v1.2.1
* Fixes for Rails 5
## v1.2.0
* Support host, port and protocol inline parameters
* Support host, port and protocol parameters given to a route explicitly
* Remove all incompatibilities between actiondispatch and js-routes in handling route URLs
## v1.1.2
* Bugfix support nested object null parameters #164
* Bugfix support for nested optional parameters #162 #163
-------------------------------------------------------------------
Tue Sep 15 04:30:38 UTC 2015 - coolo@suse.com
- updated to version 1.1.2
see installed CHANGELOG.md
## v1.1.1
* Bugfix regression in serialisation on blank strings caused by [#155](https://github.com/railsware/js-routes/pull/155/files)
-------------------------------------------------------------------
Fri Sep 11 04:29:02 UTC 2015 - coolo@suse.com
- updated to version 1.1.1
see installed CHANGELOG.md
-------------------------------------------------------------------
Thu Aug 6 04:30:03 UTC 2015 - coolo@suse.com
- updated to version 1.1.0
see installed CHANGELOG.md
## v1.1.0
* Ensure routes are loaded, prior to generating them [#148](https://github.com/railsware/js-routes/pull/148)
* Use `flat_map` rather than `map{...}.flatten` [#149](https://github.com/railsware/js-routes/pull/149)
* URL escape routes.rb url to fix bad URI(is not URI?) error [#150](https://github.com/railsware/js-routes/pull/150)
* Fix for rails 5 - test rails-edge on travis allowing failure [#151](https://github.com/railsware/js-routes/pull/151)
* Adds `serializer` option [#155](https://github.com/railsware/js-routes/pull/155/files)
## v1.0.1
* Support sprockets-3
* Performance optimization of include/exclude options
-------------------------------------------------------------------
Thu Apr 23 08:08:11 UTC 2015 - coolo@suse.com
- updated to version 1.0.1
see installed CHANGELOG.md
## v1.0.0
-------------------------------------------------------------------
Tue Feb 10 17:58:15 UTC 2015 - coolo@suse.com
- updated to version 1.0.0
-------------------------------------------------------------------
Mon Oct 13 14:18:35 UTC 2014 - coolo@suse.com
- adapt to new rubygem packaging
-------------------------------------------------------------------
Wed Apr 23 09:42:34 UTC 2014 - tboerger@suse.com
- Initial packaging of 0.9.7

54
rubygem-js-routes.spec Normal file
View File

@@ -0,0 +1,54 @@
#
# spec file for package rubygem-js-routes
#
# Copyright (c) 2024 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
#
# This file was generated with a gem2rpm.yml and not just plain gem2rpm.
# All sections marked as MANUAL, license headers, summaries and descriptions
# can be maintained in that file. Please consult this file before editing any
# of those fields
#
Name: rubygem-js-routes
Version: 2.2.10
Release: 0
%define mod_name js-routes
%define mod_full_name %{mod_name}-%{version}
BuildRequires: %{ruby >= 2.4.0}
BuildRequires: %{rubygem gem2rpm}
BuildRequires: ruby-macros >= 5
URL: http://github.com/railsware/js-routes
Source: https://rubygems.org/gems/%{mod_full_name}.gem
Source1: gem2rpm.yml
Summary: Brings Rails named routes to javascript
License: MIT
%description
Exposes all Rails Routes URL helpers as javascript module.
%prep
%build
%install
%gem_install \
--doc-files="CHANGELOG.md LICENSE.txt Readme.md" \
-f
%gem_packages
%changelog