@scrabble-solver/scrabble-solver 2.11.4 → 2.11.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.next/BUILD_ID +1 -1
- package/.next/build-manifest.json +7 -7
- package/.next/cache/.tsbuildinfo +1 -1
- package/.next/cache/eslint/.cache_8dgz12 +1 -1
- package/.next/cache/next-server.js.nft.json +1 -1
- package/.next/cache/webpack/client-production/0.pack +0 -0
- package/.next/cache/webpack/client-production/index.pack +0 -0
- package/.next/cache/webpack/edge-server-production/0.pack +0 -0
- package/.next/cache/webpack/edge-server-production/index.pack +0 -0
- package/.next/cache/webpack/server-production/0.pack +0 -0
- package/.next/cache/webpack/server-production/index.pack +0 -0
- package/.next/export-marker.json +1 -1
- package/.next/next-server.js.nft.json +1 -1
- package/.next/prerender-manifest.json +1 -1
- package/.next/routes-manifest.json +1 -1
- package/.next/server/chunks/131.js +1 -1
- package/.next/server/chunks/277.js +851 -1179
- package/.next/server/chunks/636.js +286 -0
- package/.next/server/chunks/675.js +550 -0
- package/.next/server/middleware-build-manifest.js +1 -1
- package/.next/server/pages/404.html +1 -5
- package/.next/server/pages/404.js.nft.json +1 -1
- package/.next/server/pages/500.html +1 -1
- package/.next/server/pages/_app.js +73 -9
- package/.next/server/pages/_app.js.nft.json +1 -1
- package/.next/server/pages/_document.js.nft.json +1 -1
- package/.next/server/pages/_error.js +1 -280
- package/.next/server/pages/_error.js.nft.json +1 -1
- package/.next/server/pages/api/solve.js +22 -2
- package/.next/server/pages/index.html +1 -1
- package/.next/server/pages/index.js +381 -314
- package/.next/server/pages/index.js.nft.json +1 -1
- package/.next/server/pages/index.json +1 -1
- package/.next/server/pages-manifest.json +1 -1
- package/.next/static/Jmk00rVXCbdjFgP77tKXQ/_buildManifest.js +1 -0
- package/.next/static/chunks/pages/{404-448ba28510855455.js → 404-8176f4acd0cfeb42.js} +1 -1
- package/.next/static/chunks/pages/_app-b4fa92112b8f0385.js +28 -0
- package/.next/static/chunks/pages/index-ccd762f8f5028729.js +1 -0
- package/.next/static/css/1cd302e7648d209c.css +2 -0
- package/.next/static/css/34adfcf12a7d9bb6.css +1 -0
- package/.next/trace +50 -53
- package/next.config.js +1 -0
- package/package.json +12 -13
- package/src/@types/svg.d.ts +1 -1
- package/src/components/Board/Board.tsx +48 -44
- package/src/components/Board/components/Actions/Actions.tsx +4 -2
- package/src/components/Board/components/Cell/Cell.module.scss +59 -5
- package/src/components/Board/hooks/useGrid.ts +5 -3
- package/src/components/Button/Button.module.scss +1 -1
- package/src/components/Dictionary/Dictionary.module.scss +0 -1
- package/src/components/EmptyState/EmptyState.module.scss +0 -1
- package/src/components/Key/Key.module.scss +1 -1
- package/src/components/Loading/Loading.module.scss +1 -1
- package/src/components/Loading/Loading.tsx +1 -1
- package/src/components/Logo/Logo.tsx +10 -12
- package/src/components/Logo/LogoBlueprint.tsx +21 -0
- package/src/components/Logo/index.ts +1 -1
- package/src/components/Modal/Modal.module.scss +1 -6
- package/src/components/Modal/Modal.tsx +15 -8
- package/src/components/NavButtons/NavButtons.tsx +2 -2
- package/src/components/PlainTiles/PlainTiles.tsx +0 -10
- package/src/components/PlainTiles/Tile.tsx +1 -4
- package/src/components/Rack/Rack.module.scss +59 -0
- package/src/components/Results/HeaderButton.tsx +6 -6
- package/src/components/Results/Results.module.scss +3 -1
- package/src/components/Results/Results.tsx +7 -7
- package/src/components/Results/useColumns.ts +2 -5
- package/src/components/Solver/Solver.tsx +6 -23
- package/src/components/Tile/Tile.module.scss +2 -1
- package/src/components/Tile/Tile.tsx +8 -4
- package/src/components/index.ts +0 -5
- package/src/hooks/index.ts +6 -0
- package/src/hooks/useAppLayout.ts +62 -12
- package/src/hooks/useDirection.ts +2 -2
- package/src/hooks/useEffectOnce.ts +5 -0
- package/src/hooks/useIsTouchDevice.ts +1 -1
- package/src/hooks/useLanguage.ts +2 -2
- package/src/hooks/useLatest.ts +13 -0
- package/src/hooks/useLocalStorage.ts +51 -0
- package/src/hooks/useMedia.ts +36 -0
- package/src/hooks/useMediaQueries.ts +13 -0
- package/src/hooks/useMediaQuery.ts +2 -1
- package/src/hooks/useOnWindowResize.ts +13 -0
- package/src/hooks/useViewportSize.ts +19 -0
- package/src/i18n/constants.ts +14 -22
- package/src/lib/arrayEquals.ts +5 -0
- package/src/lib/index.ts +1 -0
- package/src/lib/zipCharactersAndTiles.ts +3 -1
- package/src/modals/DictionaryModal/DictionaryModal.tsx +2 -2
- package/src/modals/KeyMapModal/KeyMapModal.tsx +2 -2
- package/src/modals/KeyMapModal/components/Mapping/Mapping.module.scss +0 -1
- package/src/modals/KeyMapModal/keys.tsx +0 -2
- package/src/modals/MenuModal/MenuModal.module.scss +28 -4
- package/src/modals/MenuModal/MenuModal.tsx +4 -4
- package/src/modals/RemainingTilesModal/RemainingTilesModal.tsx +2 -2
- package/src/modals/ResultsModal/ResultsModal.module.scss +1 -5
- package/src/modals/ResultsModal/ResultsModal.tsx +10 -2
- package/src/modals/SettingsModal/SettingsModal.tsx +2 -2
- package/src/modals/SettingsModal/components/AutoGroupTilesSetting/lib.ts +3 -1
- package/src/modals/SettingsModal/components/ConfigSetting/ConfigSetting.module.scss +0 -1
- package/src/modals/SettingsModal/components/LocaleSetting/LocaleSetting.module.scss +1 -6
- package/src/modals/WordsModal/WordsModal.tsx +2 -2
- package/src/pages/index.module.scss +3 -21
- package/src/pages/index.tsx +51 -69
- package/src/parameters/index.ts +29 -2
- package/src/state/localStorage.ts +13 -2
- package/src/state/sagas.ts +16 -8
- package/src/state/slices/boardInitialState.ts +5 -1
- package/src/state/slices/boardSlice.ts +2 -2
- package/src/state/slices/rackInitialState.ts +8 -2
- package/src/state/slices/rackSlice.ts +16 -13
- package/src/state/slices/settingsInitialState.ts +9 -4
- package/src/state/slices/settingsSlice.ts +3 -1
- package/src/styles/animations.scss +0 -20
- package/src/styles/global.scss +4 -15
- package/src/styles/mixins.scss +0 -60
- package/src/styles/variables.scss +14 -5
- package/src/types/index.ts +4 -0
- package/.next/static/MvHZRF4XuJ7g8LLLRkf8U/_buildManifest.js +0 -1
- package/.next/static/chunks/pages/_app-66d80a5594aab8dc.js +0 -28
- package/.next/static/chunks/pages/index-0858deea02b2a417.js +0 -1
- package/.next/static/css/885da289cec275b3.css +0 -1
- package/.next/static/css/ea1c8134fe9a143e.css +0 -2
- package/src/components/LogoSplashScreen/LogoSplashScreen.module.scss +0 -65
- package/src/components/LogoSplashScreen/LogoSplashScreen.tsx +0 -31
- package/src/components/LogoSplashScreen/index.ts +0 -1
- package/src/components/Sizer/Sizer.module.scss +0 -10
- package/src/components/Sizer/Sizer.tsx +0 -10
- package/src/components/Sizer/index.ts +0 -1
- package/src/components/SplashScreen/SplashScreen.module.scss +0 -14
- package/src/components/SplashScreen/SplashScreen.tsx +0 -19
- package/src/components/SplashScreen/index.ts +0 -1
- package/src/components/SvgFontCss/SvgFontCss.tsx +0 -14
- package/src/components/SvgFontCss/createCss.ts +0 -11
- package/src/components/SvgFontCss/createStyle.ts +0 -9
- package/src/components/SvgFontCss/createSvg.ts +0 -10
- package/src/components/SvgFontCss/index.ts +0 -1
- package/src/components/SvgFontFix/SvgFontFix.module.scss +0 -5
- package/src/components/SvgFontFix/SvgFontFix.tsx +0 -21
- package/src/components/SvgFontFix/index.ts +0 -1
- package/src/hooks/useLocalStorage/index.ts +0 -1
- package/src/hooks/useLocalStorage/useLocalStorage.ts +0 -13
- package/src/hooks/useLocalStorage/useLocalStorageBoard.ts +0 -29
- package/src/hooks/useLocalStorage/useLocalStorageConfigId.ts +0 -29
- package/src/hooks/useLocalStorage/useLocalStorageLocale.ts +0 -32
- package/src/hooks/useLocalStorage/useLocalStorageRack.ts +0 -29
- /package/.next/static/{MvHZRF4XuJ7g8LLLRkf8U → Jmk00rVXCbdjFgP77tKXQ}/_ssgManifest.js +0 -0
- /package/{src/components/Logo/Logo.svg → public/logo.svg} +0 -0
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
exports.id = 636;
|
|
3
|
+
exports.ids = [636];
|
|
4
|
+
exports.modules = {
|
|
5
|
+
|
|
6
|
+
/***/ 6495:
|
|
7
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
8
|
+
|
|
9
|
+
var __webpack_unused_export__;
|
|
10
|
+
|
|
11
|
+
__webpack_unused_export__ = ({
|
|
12
|
+
value: true
|
|
13
|
+
});
|
|
14
|
+
Object.defineProperty(exports, "Z", ({
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: function() {
|
|
17
|
+
return _extends;
|
|
18
|
+
}
|
|
19
|
+
}));
|
|
20
|
+
function extends_() {
|
|
21
|
+
extends_ = Object.assign || function(target) {
|
|
22
|
+
for(var i = 1; i < arguments.length; i++){
|
|
23
|
+
var source = arguments[i];
|
|
24
|
+
for(var key in source){
|
|
25
|
+
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
26
|
+
target[key] = source[key];
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
return target;
|
|
31
|
+
};
|
|
32
|
+
return extends_.apply(this, arguments);
|
|
33
|
+
}
|
|
34
|
+
function _extends() {
|
|
35
|
+
return extends_.apply(this, arguments);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
/***/ }),
|
|
40
|
+
|
|
41
|
+
/***/ 92648:
|
|
42
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
43
|
+
|
|
44
|
+
var __webpack_unused_export__;
|
|
45
|
+
|
|
46
|
+
__webpack_unused_export__ = ({
|
|
47
|
+
value: true
|
|
48
|
+
});
|
|
49
|
+
Object.defineProperty(exports, "Z", ({
|
|
50
|
+
enumerable: true,
|
|
51
|
+
get: function() {
|
|
52
|
+
return _interopRequireDefault;
|
|
53
|
+
}
|
|
54
|
+
}));
|
|
55
|
+
function _interopRequireDefault(obj) {
|
|
56
|
+
return obj && obj.__esModule ? obj : {
|
|
57
|
+
default: obj
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
/***/ }),
|
|
63
|
+
|
|
64
|
+
/***/ 91598:
|
|
65
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
66
|
+
|
|
67
|
+
var __webpack_unused_export__;
|
|
68
|
+
|
|
69
|
+
__webpack_unused_export__ = ({
|
|
70
|
+
value: true
|
|
71
|
+
});
|
|
72
|
+
Object.defineProperty(exports, "Z", ({
|
|
73
|
+
enumerable: true,
|
|
74
|
+
get: function() {
|
|
75
|
+
return _interopRequireWildcard;
|
|
76
|
+
}
|
|
77
|
+
}));
|
|
78
|
+
function _getRequireWildcardCache(nodeInterop) {
|
|
79
|
+
if (typeof WeakMap !== "function") return null;
|
|
80
|
+
var cacheBabelInterop = new WeakMap();
|
|
81
|
+
var cacheNodeInterop = new WeakMap();
|
|
82
|
+
return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) {
|
|
83
|
+
return nodeInterop ? cacheNodeInterop : cacheBabelInterop;
|
|
84
|
+
})(nodeInterop);
|
|
85
|
+
}
|
|
86
|
+
function _interopRequireWildcard(obj, nodeInterop) {
|
|
87
|
+
if (!nodeInterop && obj && obj.__esModule) {
|
|
88
|
+
return obj;
|
|
89
|
+
}
|
|
90
|
+
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
91
|
+
return {
|
|
92
|
+
default: obj
|
|
93
|
+
};
|
|
94
|
+
}
|
|
95
|
+
var cache = _getRequireWildcardCache(nodeInterop);
|
|
96
|
+
if (cache && cache.has(obj)) {
|
|
97
|
+
return cache.get(obj);
|
|
98
|
+
}
|
|
99
|
+
var newObj = {};
|
|
100
|
+
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
101
|
+
for(var key in obj){
|
|
102
|
+
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
103
|
+
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
104
|
+
if (desc && (desc.get || desc.set)) {
|
|
105
|
+
Object.defineProperty(newObj, key, desc);
|
|
106
|
+
} else {
|
|
107
|
+
newObj[key] = obj[key];
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
newObj.default = obj;
|
|
112
|
+
if (cache) {
|
|
113
|
+
cache.set(obj, newObj);
|
|
114
|
+
}
|
|
115
|
+
return newObj;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
/***/ }),
|
|
120
|
+
|
|
121
|
+
/***/ 42636:
|
|
122
|
+
/***/ ((module, exports, __webpack_require__) => {
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
"use client";
|
|
126
|
+
Object.defineProperty(exports, "__esModule", ({
|
|
127
|
+
value: true
|
|
128
|
+
}));
|
|
129
|
+
exports.defaultHead = defaultHead;
|
|
130
|
+
exports["default"] = void 0;
|
|
131
|
+
var _extends = (__webpack_require__(6495)/* ["default"] */ .Z);
|
|
132
|
+
var _interop_require_default = (__webpack_require__(92648)/* ["default"] */ .Z);
|
|
133
|
+
var _interop_require_wildcard = (__webpack_require__(91598)/* ["default"] */ .Z);
|
|
134
|
+
var _react = _interop_require_wildcard(__webpack_require__(16689));
|
|
135
|
+
var _sideEffect = _interop_require_default(__webpack_require__(82470));
|
|
136
|
+
var _ampContext = __webpack_require__(53918);
|
|
137
|
+
var _headManagerContext = __webpack_require__(92796);
|
|
138
|
+
var _ampMode = __webpack_require__(45732);
|
|
139
|
+
var _warnOnce = __webpack_require__(40618);
|
|
140
|
+
function defaultHead(inAmpMode = false) {
|
|
141
|
+
const head = [
|
|
142
|
+
/*#__PURE__*/ _react.default.createElement("meta", {
|
|
143
|
+
charSet: "utf-8"
|
|
144
|
+
})
|
|
145
|
+
];
|
|
146
|
+
if (!inAmpMode) {
|
|
147
|
+
head.push(/*#__PURE__*/ _react.default.createElement("meta", {
|
|
148
|
+
name: "viewport",
|
|
149
|
+
content: "width=device-width"
|
|
150
|
+
}));
|
|
151
|
+
}
|
|
152
|
+
return head;
|
|
153
|
+
}
|
|
154
|
+
function onlyReactElement(list, child) {
|
|
155
|
+
// React children can be "string" or "number" in this case we ignore them for backwards compat
|
|
156
|
+
if (typeof child === "string" || typeof child === "number") {
|
|
157
|
+
return list;
|
|
158
|
+
}
|
|
159
|
+
// Adds support for React.Fragment
|
|
160
|
+
if (child.type === _react.default.Fragment) {
|
|
161
|
+
return list.concat(_react.default.Children.toArray(child.props.children).reduce((fragmentList, fragmentChild)=>{
|
|
162
|
+
if (typeof fragmentChild === "string" || typeof fragmentChild === "number") {
|
|
163
|
+
return fragmentList;
|
|
164
|
+
}
|
|
165
|
+
return fragmentList.concat(fragmentChild);
|
|
166
|
+
}, []));
|
|
167
|
+
}
|
|
168
|
+
return list.concat(child);
|
|
169
|
+
}
|
|
170
|
+
const METATYPES = [
|
|
171
|
+
"name",
|
|
172
|
+
"httpEquiv",
|
|
173
|
+
"charSet",
|
|
174
|
+
"itemProp"
|
|
175
|
+
];
|
|
176
|
+
/*
|
|
177
|
+
returns a function for filtering head child elements
|
|
178
|
+
which shouldn't be duplicated, like <title/>
|
|
179
|
+
Also adds support for deduplicated `key` properties
|
|
180
|
+
*/ function unique() {
|
|
181
|
+
const keys = new Set();
|
|
182
|
+
const tags = new Set();
|
|
183
|
+
const metaTypes = new Set();
|
|
184
|
+
const metaCategories = {};
|
|
185
|
+
return (h)=>{
|
|
186
|
+
let isUnique = true;
|
|
187
|
+
let hasKey = false;
|
|
188
|
+
if (h.key && typeof h.key !== "number" && h.key.indexOf("$") > 0) {
|
|
189
|
+
hasKey = true;
|
|
190
|
+
const key = h.key.slice(h.key.indexOf("$") + 1);
|
|
191
|
+
if (keys.has(key)) {
|
|
192
|
+
isUnique = false;
|
|
193
|
+
} else {
|
|
194
|
+
keys.add(key);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
// eslint-disable-next-line default-case
|
|
198
|
+
switch(h.type){
|
|
199
|
+
case "title":
|
|
200
|
+
case "base":
|
|
201
|
+
if (tags.has(h.type)) {
|
|
202
|
+
isUnique = false;
|
|
203
|
+
} else {
|
|
204
|
+
tags.add(h.type);
|
|
205
|
+
}
|
|
206
|
+
break;
|
|
207
|
+
case "meta":
|
|
208
|
+
for(let i = 0, len = METATYPES.length; i < len; i++){
|
|
209
|
+
const metatype = METATYPES[i];
|
|
210
|
+
if (!h.props.hasOwnProperty(metatype)) continue;
|
|
211
|
+
if (metatype === "charSet") {
|
|
212
|
+
if (metaTypes.has(metatype)) {
|
|
213
|
+
isUnique = false;
|
|
214
|
+
} else {
|
|
215
|
+
metaTypes.add(metatype);
|
|
216
|
+
}
|
|
217
|
+
} else {
|
|
218
|
+
const category = h.props[metatype];
|
|
219
|
+
const categories = metaCategories[metatype] || new Set();
|
|
220
|
+
if ((metatype !== "name" || !hasKey) && categories.has(category)) {
|
|
221
|
+
isUnique = false;
|
|
222
|
+
} else {
|
|
223
|
+
categories.add(category);
|
|
224
|
+
metaCategories[metatype] = categories;
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
break;
|
|
229
|
+
}
|
|
230
|
+
return isUnique;
|
|
231
|
+
};
|
|
232
|
+
}
|
|
233
|
+
/**
|
|
234
|
+
*
|
|
235
|
+
* @param headChildrenElements List of children of <Head>
|
|
236
|
+
*/ function reduceComponents(headChildrenElements, props) {
|
|
237
|
+
const { inAmpMode } = props;
|
|
238
|
+
return headChildrenElements.reduce(onlyReactElement, []).reverse().concat(defaultHead(inAmpMode).reverse()).filter(unique()).reverse().map((c, i)=>{
|
|
239
|
+
const key = c.key || i;
|
|
240
|
+
if ( true && !inAmpMode) {
|
|
241
|
+
if (c.type === "link" && c.props["href"] && // TODO(prateekbh@): Replace this with const from `constants` when the tree shaking works.
|
|
242
|
+
[
|
|
243
|
+
"https://fonts.googleapis.com/css",
|
|
244
|
+
"https://use.typekit.net/"
|
|
245
|
+
].some((url)=>c.props["href"].startsWith(url))) {
|
|
246
|
+
const newProps = _extends({}, c.props || {});
|
|
247
|
+
newProps["data-href"] = newProps["href"];
|
|
248
|
+
newProps["href"] = undefined;
|
|
249
|
+
// Add this attribute to make it easy to identify optimized tags
|
|
250
|
+
newProps["data-optimized-fonts"] = true;
|
|
251
|
+
return /*#__PURE__*/ _react.default.cloneElement(c, newProps);
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
if (false) {}
|
|
255
|
+
return /*#__PURE__*/ _react.default.cloneElement(c, {
|
|
256
|
+
key
|
|
257
|
+
});
|
|
258
|
+
});
|
|
259
|
+
}
|
|
260
|
+
/**
|
|
261
|
+
* This component injects elements to `<head>` of your page.
|
|
262
|
+
* To avoid duplicated `tags` in `<head>` you can use the `key` property, which will make sure every tag is only rendered once.
|
|
263
|
+
*/ function Head({ children }) {
|
|
264
|
+
const ampState = (0, _react).useContext(_ampContext.AmpStateContext);
|
|
265
|
+
const headManager = (0, _react).useContext(_headManagerContext.HeadManagerContext);
|
|
266
|
+
return /*#__PURE__*/ _react.default.createElement(_sideEffect.default, {
|
|
267
|
+
reduceComponentsToState: reduceComponents,
|
|
268
|
+
headManager: headManager,
|
|
269
|
+
inAmpMode: (0, _ampMode).isInAmpMode(ampState)
|
|
270
|
+
}, children);
|
|
271
|
+
}
|
|
272
|
+
var _default = Head;
|
|
273
|
+
exports["default"] = _default;
|
|
274
|
+
if ((typeof exports.default === "function" || typeof exports.default === "object" && exports.default !== null) && typeof exports.default.__esModule === "undefined") {
|
|
275
|
+
Object.defineProperty(exports.default, "__esModule", {
|
|
276
|
+
value: true
|
|
277
|
+
});
|
|
278
|
+
Object.assign(exports.default, exports);
|
|
279
|
+
module.exports = exports.default;
|
|
280
|
+
} //# sourceMappingURL=head.js.map
|
|
281
|
+
|
|
282
|
+
|
|
283
|
+
/***/ })
|
|
284
|
+
|
|
285
|
+
};
|
|
286
|
+
;
|